A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
Hey there,
I use the last Shopify API and the function shopify.webhooks.register to register the webhooks of my user for my app.
Most of the time it works fine and webhooks are registered correctly. But for some user, the ORDERS_CREATE webhook is not registered for some reasons.
The function return me the following object: (I dont have any errors)
{
APP_UNINSTALLED: [],
APP_SUBSCRIPTIONS_UPDATE: [],
SHOP_UPDATE: [],
ORDERS_CREATE: [],
PRODUCTS_UPDATE: [],
PRODUCTS_DELETE: []
}
Can you help me with that ?
Thanks a lot
need to see the results of the request not just if you think its false in order to make heads or tails of this.
Hello Garyrg,
The object you can see in my first message is the result of the shopify.webhooks.register request.
Thank you a lot
thats a formatted response from your code. I want to see the raw response from shopify
Hello Garyrg,
I am really sorry but how I am supposed to get it?
I displayed directly the response of the query shopify.webhooks.register.
And i got:
Please tell me how I can get you the "raw" response so I can make it for you 🙏
Thanks a lot
well the issue is that you are using a library to perform the operation for you. I do all my work directly with the apis, without any middleware that parses the responses, so I see the http headers, and filecontent that is returned in the httprequest. Shopify would not return an empty array like that without any other information.
Something else is going on. Unfortunately I cant see what.. you should be getting some kind of response.
Hi @marcreese,
Thanks for your post. For assistance registering webhooks with a library like the one in the screenshots you would need to reach out to the support team for the library.
To register webhooks directly without a library the REST and GraphQL API documentation is below:
- [REST Admin API webhook docs]
- [GraphQL Admin API webhookSubscriptionCreate mutation]
- [In Depth Developer Docs about Shopify Webhooks]
Hope you have a great day
Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog