Answered
Shopify GraphQL
Hi,
Has anyone successfully connected to Shopify via GraphQL? We're trying to use the PriceLists query
https://shopify.dev/api/admin-graphql/2022-04/queries/priceLists
to query and update International Prices (which are only accessible in Shopify via GraphQL and not the REST API).
If so, would you be happy to share the json and how you entered it?
Many Thanks,
Stew
0
Comments
Hi Pangaia Admin
We have GraphQL connector that you can use to set up integration with a Shopify GraphQL endpoint. Here is the kb for setting up a connection: https://docs.celigo.com/hc/en-us/articles/4843857027227
Here is an example of value for the base URI in the connection:
And to test the connection, here is an example of the query:
In the export step, you can then build the GraphQL queries - see below for example:
The above example uses the following pagination set up
Thanks
Hi,
Thanks for the quick response. I can connect OK to the GraphQL but when we try to preview the export we still get a syntax error even though I have copied and pasted the code above in (I think).
Here's the syntax error:
{
"errors": [
{
"message": "Parse error on \"query\" (STRING) at [1, 2]",
"locations": [
{
"line": 1,
"column": 2
}
]
}
]
}
and here's the config:
I have noticed a '/' at the end of the request URL - might that be causing issues? How would I remove that?
Thanks,
Stewart
Pangaia Admin
Your screenshot shows the preview is successful, though it returns 0 record. If you click on the parsed output tab, you'll see the records.
Where do you see the syntax error message?
Thanks
Hi Viliandy, we see the syntax error here:
There doesn't seem to be anything in the parsed output (I tried it with accepts marketing true and false in case that was the issue).
Thanks,
Stewart
Pangaia Admin
I cannot tell where the syntax issue is at. I suggest you start with a simple query then build up to a more complex query that uses variables etc, then include pagination. Here is 1 example of a simple query asking for first 10 customer records. If you can't get the simple example below to return records (assuming you have customer records), then please log a support ticket so we can help you further. Thanks
Hi,
I tried this using the integrator.io instance and it worked fine.
However, it doesn't seem to work on the eu.integrator.io instance - so maybe the issue is to do with that? I noticed that the UI looks different as well - the eu.integrator.io instance has a section for Request URL which integrator.io didn't seem to. Would you be able to get someone to look into that please?
Thanks,
Stewart
Pangaia Admin
Hi Stewart, I noted that you logged a support ticket for eu.integrator.io instance question and a support has accepted your ticket. Support team will follow up with your question via the support ticket.
Thank you
Pangaia Admin
Hi Steve, fyi, we just published this guide to help with building the GraphQL request on our connector. https://docs.celigo.com/hc/en-us/articles/6177684981787-Build-GraphQL-queries
Thanks
Please sign in to leave a comment.