Hello,
I’m starting a development using the API gateway, I’ve already created an PUBLIC app and turned it into a sales channel. After that I entered the oAuth URL to get the permissions and code to generate the token:
https://shop.myshopify.com/admin/oauth/authorize?client_id=XXX&scope=unauthenticated_read_product_listings,unauthenticated_write_checkouts,unauthenticated_write_customers,unauthenticated_read_customer_tags,unauthenticated_read_content,unauthenticated_read_product_tags&redirect_uri=https://XXX&state=nonce1
After that, I created the token:
POST https://shop.myshopify.com/admin/oauth/access_token
{
"client_id": "XXX",
"client_secret": "shpss_YYY,
"code": "TTT"
}
This request returned a JSON that looked like this:
{
"access_token": "shpat_CCC",
"scope": "unauthenticated_read_product_listings,unauthenticated_write_checkouts,unauthenticated_write_customers,unauthenticated_read_customer_tags,unauthenticated_read_content,unauthenticated_read_product_tags"
}
Now when I try to run any route from the storefront API, for example:
POST https://shop.myshopify.com/api/2021-10/graphql.json
Header → X-Shopify-Storefront-Access-Token: shpat_CCC
{
products(first:5) {
edges {
node {
id
}
}
}
}
I get a 403 Forbidden error. Has anyone ever experienced this? Can you help me solve it?