Questions about the shop parameter in the Redirect URL

Questions about the shop parameter in the Redirect URL

SmartSellerKode
Shopify Partner
1 0 0

Hello,

I am facing difficulties configuring the OAuth flow for my Shopify app. Currently, our authentication flow is set up as follows:

  1. The user clicks to install the app from the Shopify App Store.
  2. The user is redirected to https://myapp.com/auth.

I would like to know if the shop parameter is automatically sent to this URL when the user comes from Shopify. For example, if my redirect URL is https://myapp.com/auth, can I expect Shopify to redirect the user to https://myapp.com/auth?shop=example.myshopify.com automatically?

Our app is being rejected during review because, according to the Shopify team, the user should not pass through our UI before the OAuth authorization. However, without passing through our UI, I don't know the shop name (shop) and thus cannot proceed correctly with the OAuth flow.

We have already implemented the OAuth process, capturing both the code and access token. Our issue lies with Shopify's requirement regarding the app page link. The link should not redirect to our app's UI first; instead, it should take the user to install from the Shopify admin and then return to our app, as demonstrated by the Polar Analytics app.

I have attached an image showing the Polar Analytics app. When the user clicks to install, it directly takes them to Shopify. I would like to understand how to properly architect this link.

 

How can I set up the authentication flow to ensure the shop name is captured automatically and the user is redirected according to Shopify's guidelines, without manual intervention?

Thank you for your assistance.

 

SmartSellerKode_0-1723118080622.png

 

Replies 0 (0)