For discussing the development and usage of Checkout UI extensions, post-purchase extensions, web pixels, Customer Accounts UI extensions, and POS UI extensions
Access denied for quantityAvailable field. Required access: `unauthenticated_read_product_inventory` access scope.
Solved! Go to the solution
This is an accepted solution.
Hi there 👋
At this time this scope is unavailable for the Storefront API via Checkout UI extensions. I have brought this to the attention of the team. You can also create a Github Issue requesting this scope be added.
To learn more visit the Shopify Help Center or the Community Blog.
This is an accepted solution.
Hi there 👋
At this time this scope is unavailable for the Storefront API via Checkout UI extensions. I have brought this to the attention of the team. You can also create a Github Issue requesting this scope be added.
To learn more visit the Shopify Help Center or the Community Blog.
Got it. Thank you @lizk
Hi Lizk - any update on this? I would also like to be able to access this scope from Checkout UI extensions.
@lizk is there any update to this yet or are we still unable to access quantityAvailable in checkout UI extensions?
Edit: found the docs stating what scopes are available in UI extensions: https://shopify.dev/docs/api/checkout-ui-extensions/2024-04/configuration#api-access still seems weird not all of them are available. And the error message is just plain wrong then.
How do you figure out a scope is unavaliable for Checkout UI extensions? This is really confusing and I wasted a lot of time debugging this behaviour. Looking at the documention from my error messages ("Access denied for quantityAvailable field. Required access: `unauthenticated_read_product_inventory` access scope.") it seems like it should work if you add the access scope to the TOML file following https://shopify.dev/api/usage/access-scopes.
And why are there some scopes unavailable or the Storefront API via Checkout UI extensions???
@frede-1994 I opened an issue on github about this 7 months ago, maybe if you added a comment there it might help bump it up in priority:
https://github.com/Shopify/ui-extensions/issues/1594