I’m learning how to use the graphQL Queries using Node.JS and i’m running into this issue.
shopifyAUTH = {
headers: {
“Content-Type”:“application/json”
,
“X-Shopify-Access-Token”: < my access token> ,
},
auth: {
username: < my username>,
password:
},
};
the following works:
let query = ‘{“query”: “query { draftOrders(first: 10) { edges { node { id } } } }”}’
axios.post(url,query,this.shopifyAUTH).then((result)=>{
}
However, this is giving me a error and i can’t figure out why.
let query = ‘{“query”: “query { draftOrders(first: 10, query: “status:OPEN”) { edges { node { id status } } } }”}’;
axios.post(url,query,this.shopifyAUTH).then((result)=>{
}
It seems like every query i make with arguments query, it fails and gives me an error of
query: ‘Required parameter missing or invalid’ .
Any help/advice would be appreciated ![]()