Topics covering webhook creation & management, event handling, Pub/Sub, and Eventbridge, in Shopify apps.
Hello there,
I am currently working on a shopify app (not embedded, api version: 6.2.0),
following this steps: GitHub - Shopify/shopify-api-js: Shopify Admin API Library for Node. Accelerate development with sup...
this app will be installed at a single shop and the only function will be to detect a new order via webhook and send an email with a specific format of the order data
the Webhook seems to be registered correctly but my Problem arises when I try to Process the Webhook. I just get the error:
//Error
C:\Users\censored\Desktop\Auth\node_modules\@shopify\shopify-api\lib\webhooks\process.js:72
throw new ShopifyErrors.InvalidWebhookError({
^
InvalidWebhookError: Could not validate request for topic orders/create
at Object.<anonymous> (C:\Users\censored\Desktop\Auth\node_modules\@shopify\shopify-api\lib\webhooks\process.js:72:23)
at Generator.next (<anonymous>)
at fulfilled (C:\Users\censored\Desktop\Auth\node_modules\tslib\tslib.js:164:62) {
response: undefined
}
//app use
//addHandlers
Solved! Go to the solution
This is an accepted solution.
Hey Zesa,
Just wanted to pass on a quick suggestion regarding this post. If you are have any technical questions or concerns about the functionality of a Shopify development tool(Shopify CLI, API Libraries, etc), the best place to bring them would be the official Github repository; in this case [Issues - shopify-api-js](https://github.com/Shopify/shopify-api-js/issues), though searching through open and closed issues is always a good place to start. If you can't find anything related or haven't already created a post over there, we suggest including as much detail as possible and any troubleshooting, findings, or updates like you have here.
Hope this helps provide some direction - Cheers!
@awwdam - Shopify Developer Support
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
I got a small little update:
by changing app.use(express.json()) to
This is an accepted solution.
Hey Zesa,
Just wanted to pass on a quick suggestion regarding this post. If you are have any technical questions or concerns about the functionality of a Shopify development tool(Shopify CLI, API Libraries, etc), the best place to bring them would be the official Github repository; in this case [Issues - shopify-api-js](https://github.com/Shopify/shopify-api-js/issues), though searching through open and closed issues is always a good place to start. If you can't find anything related or haven't already created a post over there, we suggest including as much detail as possible and any troubleshooting, findings, or updates like you have here.
Hope this helps provide some direction - Cheers!
@awwdam - Shopify Developer Support
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