Topics covering webhook creation & management, event handling, Pub/Sub, and Eventbridge, in Shopify apps.
Hello Team,
I am building a Shopify app and I am facing issues with webhooks. I created a orders/create webhook on the installation of the app at my store. The webhooks data created data as follow:
stdClass Object ( [webhooks] => Array ( [0] => stdClass Object ( [id] => 891007795363 [address] => https://buyfromfactory.net/MerchantBuyFactory/ordercreate [topic] => orders/create [created_at] => 2020-07-27T07:28:00-04:00 [updated_at] => 2020-07-27T07:28:00-04:00 [format] => json [fields] => Array ( ) [metafield_namespaces] => Array ( ) [api_version] => 2020-04 [private_metafield_namespaces] => Array ( ) ) ) )
I checked my webhooks is created successfully. But when I create an order then my files ordercreate is not run.
I created order at my store: Order id = 2594871869597. But when I check the response webhook files I did not get any response.
I tried many methods like delete old webhook and generate new ones. Still, I faced this issue. Please assist us as soon as possible.
Please help me as soon as possible.
Thanks
Are you able to go into the webhook receiver's end and see any HTTPS hit at all? Just wondering if perhaps the webhook handler might not be completing its task, but the actual message was sent to the receiver host.
Yes, we are able to hit the receiver end using https and we use static data and this is working fine. But when I install the app and create order then this webhook is not working.
Hi,
I'm not sure what do you mean by 'a solution for the webbook on the installation of the app at my store'.
Normally you will register the webhook after oath, which happens on app installation. If it it registered successfully it returns OK and then you can redirect to the welcome page or whatever. Then you should be able to receive the triggers.
Hi,
I created Order create webhook using API and I checked it's created successfully But when an order creating from the frontend than it's not triggering.
When I checked after create the same webhook manually from back-end than it's working fine but I need to create that webhook using API from my APP. Can you let me know how I can check what is the actual issue..?
Thanks
Hi,
Try to search in the docs/forums if the web-hooks are triggered by API calls. If API calls don't trigger web-hooks, you can trigger the web-hook manually on successful order creation.
If API calls do trigger web-hooks, then try to log each request and see if something is coming at your end.
I have created the webhook on another app that is hosted on my development server but the webhook link is pointed to the client-server and the file name is create.php. In this file, I write a static code to insert that data into the tst.txt file on the client-server. Now I create an order on our store ie on the development server then check the tst.txt file. In this file, data is written by webhook. So, on the client-server, the webhook is working fine.
But the issue is when we create a webhook in the app that is hosted on the client-server then I create order and check tst.txt file. I found the tst.txt file is empty. My webhook not worked.
Can you solve this issue?
Hello,
Can anyone solve this issue? Please help us it's very urgent.
In the admin panel there is a list with all registered webhooks @ yourdomain.myshopify.com/admin/settings/notifications. There you can test it.
If you use koa libraries to subscribe and recieve you might want to debug it and see if verify webhook request is working ok.
In the admin panel there is a list with all registered webhooks @ yourdomain.myshopify.com/admin/settings/notifications. There you can test it.
=> Yes, we test this and this is working fine. But I want a solution for the webbook on the installation of the app at my store. Can you tell me how I can test the webhook for this?
Hi friend, did you have any solution for the case? I am facing the same problem now.