Setting up Shopify API integration?

I’m working on setting up integration with the Shopify API through a REST API resource with OAuth 2. What is the proper way to set this up?

Hi William! just to double check, are you sure you need to setup oauth? if you’re building an app for your own shopify store, i’d think that the using the private api token is sufficient https://help.shopify.com/en/api/getting-started/api-credentials#generate-private-api-credentials

Hi Abdul, and thanks for the response! To clarify, I’m trying to build an app that can be used across Shopify stores (i.e. a public app), and so would require OAuth setup. More precisely, I would like the Retool app to prompt the user for their Shopify credentials (and grab an access token) upon launch.

ok got it! then yeah you definitely want oauth for that

i was just looking at these instructions: https://help.shopify.com/en/api/getting-started/authentication/oauth#step-1-get-client-credentials

im guessing you’ll want to fill out a form that looks like this:


^(this is for either the REST resource or the graphql resource, whichever one you choose since shopify supports both)

try this out and lmk if it works for you @wyin

Ah, got it. Thanks!

Correct me if I’m wrong, though, but this does still look like it’s specific to one shop. Is there a way to allow this to be agnostic to shops? (i.e. would redirect to Shopify’s auth, the user would log in to their shop, authorize a Shopify app that would be linked to the Retool tool, and then would return to the Retool tool with the access token)

Because for example I would have no idea what {shop} would be because it would be different for every shop. Same for client ID, secret, etc. (unless those are referring to the app-specific information)

What do you think? @abdul-nimeri

ohhhh yeah you’re right! maybe we need to add support for this. i’ll double-check

Got it. Does support for this exist right now? Would like to build this tool ASAP

unfortunately it doesn’t look like we support this :frowning:

it’s a bit late on my end (EU timezone), but i’ll look into this tomorrow to scope out how much work it’d take to support this

and hopefully i can get back to you with a timeline

@abdul-nimeri That would be wonderful, thank you!

I’m thinking: Could we hack it (for now) by requesting a Shopify shop URL through a textbox and then pass that into our REST API?

Hmm. Got it. how about just authenticating in an entirely different app (not even on Retool), grabbing the access token, and then having the brand just enter that manually into Retool?