DELETE/v1/webhooks/{id}
Unsubscribe a webhook
PARAMETERS
- idpath · stringREQUIRED
- The webhook ide.g. hook_8m3kq2xv7zpw4rcn6bdt
REQUEST
curl -X DELETE "https://api.imageapis.com/v1/webhooks/hook_8m3kq2xv7zpw4rcn6bdt" \ -H "X-API-Key: YOUR_KEY"
import requests
r = requests.delete("https://api.imageapis.com/v1/webhooks/hook_8m3kq2xv7zpw4rcn6bdt", headers={"X-API-Key": "YOUR_KEY"})
print(r.status_code, r.headers.get("X-Gw-Remaining"))
print(r.text)
const r = await fetch("https://api.imageapis.com/v1/webhooks/hook_8m3kq2xv7zpw4rcn6bdt", {
method: "DELETE",
headers: { "X-API-Key": "YOUR_KEY" }
});
console.log(r.status, r.headers.get("X-Gw-Remaining"));
console.log(await r.text());
RESPONSE
200OK
{
"id": "hook_8m3kq2xv7zpw4rcn6bdt",
"object": "webhook",
"deleted": true
}
401Missing or invalid API key (from the gateway)
404No such template or record on this account
{
"error": "string",
"message": "string",
"param": "string"
}