Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hi community, i am trying to get all products published to primary market.
I assume that can be done using catalogs connection through Admin API.
I am a little stuck on doing this query to achieve that:
query Markets { markets(first: 10) { edges { node { name catalogs(first: 10) { edges{ node { publication { name } }} } } } } }
Receiving the following error:
{
"errors": [
{
"message": "Access denied for publication field.",
"locations": [
{
"line": 8,
"column": 17
}
],
"path": [
"markets",
"edges",
0,
"node",
"catalogs",
"edges",
0,
"node",
"publication"
],
"extensions": {
"code": "ACCESS_DENIED",
"documentation": "https://shopify.dev/api/usage/access-scopes"
}
},
]
}
Here is the access scopes given to the app:
scopes = "read_markets,read_orders,read_products,unauthenticated_read_product_listings, write_products"
"write_products" was added according to that manual with no success.
What access rights is needed to run that query?
Or it can be retrieved in some other way ?
Solved! Go to the solution
This is an accepted solution.
Solved with "read_publications" permission, access scopes doc possibly need an update.
Also tried the following with added scope "read_publications" (not documented in access scopes doc) with same error:
query {
catalogs(first: 10) {
edges {
node {
title
id
publication{
products(first: 10) {
edges {node {
title
}}
}
}
}
}
}
}
This is an accepted solution.
Solved with "read_publications" permission, access scopes doc possibly need an update.
Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024Hey Community! It’s time to share some appreciation and celebrate what we have accomplis...
By JasonH Nov 14, 2024In today’s interview, we sat down with @BSS-Commerce to discuss practical strategies f...
By JasonH Nov 13, 2024