# Delete webhook

> Delete a webhook.

Canonical: <https://www.tryadeli.com/docs/api/webhooks/delete-webhook>

`DELETE https://app.tryadeli.com/api/v1/webhooks/{webhookId}`

Authorization: `Bearer <API key>` — see [Authentication](https://www.tryadeli.com/docs/authentication)

Delete a webhook. Events not yet delivered to it are dropped. To rotate a
signing secret, delete the webhook and create it again.

Returns `204` with no body.

**Errors** — `401 unauthorized`, `404 webhook_not_found`.

## Request examples

**cURL**

```bash
curl -X DELETE "https://app.tryadeli.com/api/v1/webhooks/00000000-0000-4000-8000-000000000009" \
  -H "Authorization: Bearer $ADELI_API_KEY"
```

**JavaScript**

```javascript
const response = await fetch("https://app.tryadeli.com/api/v1/webhooks/00000000-0000-4000-8000-000000000009", {
  method: "DELETE",
  headers: {
    Authorization: `Bearer ${process.env.ADELI_API_KEY}`,
  },
});
console.log(response.status); // 204: no body
```

**Python**

```python
import os

import requests

response = requests.delete(
    "https://app.tryadeli.com/api/v1/webhooks/00000000-0000-4000-8000-000000000009",
    headers={"Authorization": f"Bearer {os.environ['ADELI_API_KEY']}"},
)
print(response.status_code)  # 204: no body
```

## Responses

### 204 No Content

```text
(empty body)
```

### 404

```json
{
  "error": {
    "code": "webhook_not_found",
    "message": "Webhook not found"
  }
}
```
