How to remove Shopify Webhooks via Shopify API?

I'm having trouble removing Webhooks that I created through the Shopify API. To create a webhook, I used this code in RoR:

webhook = ShopifyAPI::Webhook.create(format: "json", topic: "orders/create", address: "some address") 

I can send a GET request and get all the created webcams. But when I send a DELETE request with the corresponding ID, the response will be "404 Not Found - errors: Not found". I am sending a DELETE request using Firefox's RESTClient, and the format is as follows:

 DELETE https://api_key: shared-secret@hostname /admin/webhooks/1855159.json 

It may not work because the web hosts were created through the API. Is there any other way to remove webcams? Thanks in advance!

+4
source share
3 answers

This is how you delete the website created by your application. Webhook 1855159 was created by the store and was not created by the application and can only be deleted by the store administrator.

+2
source

I think that when you delete an application from the admin panel, the webcams created by this application are automatically deleted

+1
source

DELETE / admin / webhooks / 4759306.json

Delete web host

Remove existing web store from store

 DELETE /admin/webhooks/#{id}.json 
0
source

All Articles