Delete a webhook endpoint
On this page
DELETE
/v1/webhook-endpoints/{endpoint_id}delete_webhook_endpoint| Risk | write |
| Authentication | API key or OAuth access token |
| Scopes | webhooks:write |
| Idempotency | natural: repeating the call gives the same result |
| Dry run | yes: add dry_run=true to the query |
| Success status | 200 |
| Response type | application/json |
What it does#
- Use when: You no longer want deliveries to an address.
- Do not use when: you only want to stop deliveries for a while (call update_webhook_endpoint with status paused).
- Side effects: Deletes the endpoint and its delivery history.
- Reversible: No.
- Required scope: webhooks:write.
- Idempotency: safe to repeat (same result).
- Typical next step: call create_webhook_endpoint if you need a new one.
Scopes#
webhooks:write: Create, change and delete webhook endpoints.
Side effects#
- Deletes the endpoint and its delivery history
Request#
Path parameters#
| Field | Type | Description |
|---|---|---|
endpoint_id | string |
Query parameters#
None.
Every mutation also accepts dry_run=true: it runs every check and returns {"dry_run": true, "would": {...}} without writing anything.
Response#
| Field | Type | Required | Description |
|---|---|---|---|
deleted | exactly true | yes | |
id | string | yes |
Examples#
deleted#
Request:
curl -X DELETE 'https://api.seemly.com/v1/webhook-endpoints/whe_4d8x2p0q7r3m9k1v5t6w8y0z' \
-H "Authorization: Bearer $SEEMLY_API_KEY"const response = await fetch("https://api.seemly.com/v1/webhook-endpoints/whe_4d8x2p0q7r3m9k1v5t6w8y0z", {
method: "DELETE",
headers: {
"Authorization": `Bearer ${process.env.SEEMLY_API_KEY}`,
},
});
const result = await response.json();
console.log(response.status, result);import os
import requests
response = requests.delete(
"https://api.seemly.com/v1/webhook-endpoints/whe_4d8x2p0q7r3m9k1v5t6w8y0z",
headers={
"Authorization": f"Bearer {os.environ['SEEMLY_API_KEY']}",
},
)
print(response.status_code, response.json())Response: 200:
{
"deleted": true,
"id": "whe_4d8x2p0q7r3m9k1v5t6w8y0z"
}Errors#
Every error is an application/problem+json body with a code, a fix sentence and next_actions. See reading a problem response.