I’m sending a POST
request to create a webhook for the orders/create
event. Although I’m getting a 200 OK
response, the response body shows an empty webhooks
array:
@body = {"webhooks": []}
What’s strange is that I have another store where I use the exact same process, and it works perfectly, webhooks are created as expected. But for this specific store, the response consistently returns an empty list.
Here’s the full response for reference:
#<ShopifyAPI::Clients::HttpResponse:0x00007fc7c7cadca8
@api_call_limit={:request_count=>1, :bucket_size=>80},
@body={"webhooks"=>[]},
@code=200,
@headers={
"date"=>["Thu, 27 Mar 2025 16:54:02 GMT"],
"content-type"=>["application/json; charset=utf-8"],
"transfer-encoding"=>["chunked"],
"connection"=>["close"],
"x-sorting-hat-podid"=>["322"],
"x-sorting-hat-shopid"=>["88263065923"],
"vary"=>["Accept-Encoding"],
"referrer-policy"=>["origin-when-cross-origin"],
"x-frame-options"=>["DENY"],
"x-shopid"=>["88263065923"],
"x-shardid"=>["322"],
"x-stats-userid"=>[""],
"x-stats-apiclientid"=>["235261394945"],
"x-stats-apipermissionid"=>["846637564227"],
"x-shopify-api-version"=>["2025-01"],
"http_x_shopify_shop_api_call_limit"=>["1/80"],
"x-shopify-shop-api-call-limit"=>["1/80"],
"strict-transport-security"=>["max-age=7889238"],
"x-request-id"=>["3a523480-4857-42c1-afeb-850d91fc0e20-1743094442"],
"server-timing"=>["processing;dur=133", "cfRequestDuration;dur=167.000055"],
"content-security-policy"=>[
"default-src 'self' data: blob: 'unsafe-inline' 'unsafe-eval' https://* shopify-pos://*; block-all-mixed-content; child-src 'self' https://* shopify-pos://*; connect-src 'self' wss://* https://*; frame-ancestors 'none'; img-src 'self' data: blob: https:; script-src https://cdn.shopify.com https://cdn.shopifycdn.net https://checkout.pci.shopifyinc.com https://checkout.pci.shopifyinc.com/build/75a428d/card_fields.js https://api.stripe.com https://mpsnare.iesnare.com https://appcenter.intuit.com https://www.paypal.com https://js.braintreegateway.com https://c.paypal.com https://maps.googleapis.com https://www.google-analytics.com https://v.shopify.com 'self' 'unsafe-inline' 'unsafe-eval'; upgrade-insecure-requests; report-uri /csp-report?_