Unlisted Public APP test oauth in localhost

Solved
sankar
New Member
12 0 0

Hi Team,

 

We have a django applocation and we wanted to review our appliction in Shopify, for that we are implementing Oauth2 in our application. We want to test oauth in our local system and then we will move to production. How can we test it in our local system?  Thanks in advance.

0 Likes
_JB
Shopify Staff
Shopify Staff
750 87 165

Hey @sankar,

 

We recommend using Ngrok to test locally, then when it's time to move to production you just replace the ngrok URLs with your production URLs.

 

If you haven't already, I recommend taking a look at our OAuth doc which outlines the full Shopify OAuth flow. Also this tutorial contains steps for exposing your local development environment to the web using ngrok.

JB | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

0 Likes
sankar
New Member
12 0 0

Hi JB,

 

Thanks for quick reply. In Step 2 of Oauth implementation steps there is below GET url.

 

https://{shop}.myshopify.com/admin/oauth/authorize?client_id={api_key}&scope={scopes}&redirect_uri={redirect_uri}&state={nonce}&grant_options[]={access_mode}

 

Is this call done Shopify or we have to call it by our system?

0 Likes
_JB
Shopify Staff
Shopify Staff
750 87 165

This is an accepted solution.

Hey @sankar,

 

When a customer installs your app, Shopify will redirect them to the install URL you specified in the partner dashboard.

 

You need to redirect the customer back to the /admin/oauth/authorize URL with the parameters included. This redirect displays a prompt to the merchant, allowing them to accept your requested scopes and install the app.

JB | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

0 Likes
sankar
New Member
12 0 0

Thanks JB. We are done with Oauth implementation. Oauth is the only criteria for app review right?

0 Likes