Webhook on create orders called twice.

Webhook on create orders called twice.

New Member
12 0 0


I have webhook on create orders. 


We added inventory check in our project (in this webhook) and then I noticed, that we sometimes get twice webhook on create orders.

I added check in our code, but can you help me understand reason for error?

Part of my logs in app and my comments herehttps://drive.google.com/open?id=0B703S72xAJ5qdENwWVpQX1JLM0U


Replies 4 (4)

Shopify Staff
1134 84 234

Hello Valentina, 

It looks like we're occasionally not receiving a response within 5 seconds when sending webhooks to your service. It then times out and assumes that the webhook was not received as per our webhook response guidelines here

More often than not, prioritizing responding to the webhook before actually doing any processing of it helps cut down on occurrences like this pretty drastically. 

Josh | Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

Shopify Partner
8 1 0

Dear Josh,


How can i send a 200 response back to Shopify?


I am using the php as the language to communicate with Shopify.


Much appreciated,


Kind regards,



7 0 1



I believed to response back to Shopify is simply use a header()

A good example is

$data = file_get_contents("php://input");
('HTTP/1.1 200 OK');

source (https://community.shopify.com/c/Shopify-APIs-SDKs/How-to-send-success-respond-to-webhook-using-PHP/t...)

New Member
12 0 0

Thank you!