Development discussions around Shopify APIs
Hello,
I'm trying to perform a query on products through the graphql api :
Except that I'm getting errors saying that specific fields are not part of the object itself in my example it's
Field 'isGiftCard' doesn't exist on type 'Product'
(although and according to documentation it does exist)
knowing that : i'm using a graphql client with version 2020-04
and these are the the scopes I'm requesting :
"scopes":"unauthenticated_read_product_inventory,unauthenticated_read_product_listings,unauthenticated_write_checkouts,unauthenticated_read_checkouts,unauthenticated_read_customers,read_products",
This is the mutation i'm performing :
query {
collectionByHandle(handle: "${collectionHandle}") {
products(first: 100) {
edges {
node {
id
title
createdAt
description
descriptionHtml
handle
onlineStoreUrl
publishedAt
tags
title
updatedAt
vendor
isGiftCard
totalInventory
images(first:100){
edges{
node{
altText
originalSrc
id
}
}
}
options{
id
name
values
}
variants(first: 100) {
edges {
node {
id
inventoryItem {
requiresShipping
}
selectedOptions{
name
value
}
image{
id
originalSrc
}
title
priceV2{
amount
currencyCode
}
sku
weight
weightUnit
compareAtPrice
}
}
}
}
}
}
}
}`;
Thanks in advance !
Solved! Go to the solution
This is an accepted solution.
My bad, i was requesting the storefront api instead of the admin api
This is an accepted solution.
My bad, i was requesting the storefront api instead of the admin api
User | RANK |
---|---|
10 | |
4 | |
3 | |
3 | |
3 |
We're excited to announce improvements to the threaded messaging experience in our communi...
By TyW May 31, 2023Thank you to everyone who participated in our AMA with Klaviyo. It was great to see so man...
By Jacqui May 30, 2023Photo by Marco Verch Sales channels on Shopify are various platforms where you can sell...
By Ollie May 25, 2023