App reviews, troubleshooting, and recommendations
I am developing an app with checkout UI extensibility, where I am calling a graphQL API to fetch the the product and it variants. I need the field "quantityAvailable" for the variant.
Here I am sharing the query:
query { product(id: "${lineProductID}") { id title totalInventory variants(first: 10) { edges { node { id title quantityAvailable availableForSale requiresShipping sku } } } } }
message : "Access denied for quantityAvailable field. Required access: `unauthenticated_read_product_inventory` access scope."Here I am sharing my apps access scope which I have in the shopify.app.toml file:
# This file stores configurations for your Shopify app. scopes = "read_orders,write_orders,write_products,read_products,read_inventory,read_product_listings,unauthenticated_read_product_inventory,unauthenticated_read_product_listings,unauthenticated_read_collection_publications,unauthenticated_read_product_publications,unauthenticated_read_product_tags,unauthenticated_read_selling_plans,unauthenticated_read_collection_listings"Please help me to resolve the issue. It is urgently needed.
Did you find a solution to this?
@Sanchari I got the same exact error trying to access "quantityAvailable": it complains about missing "unauthenticated_read_product_inventory" access, yet I can see it there in the apps' scopes. Did you figure out the solution? Thanks.
Hey!
I solved this. You have to check this field in your headless plugin settings.
Sorry which field?
I am not using any headless plugin
Starting a B2B store is a big undertaking that requires careful planning and execution. W...
By JasonH Sep 23, 2024By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024