> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anivahealth.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Удалить вебхук

> Удалить вебхук и его доставки

Удаляет вебхук, его секреты и доставки. Это действие нельзя отменить. Чтобы приостановить
вебхук, отправь `status: "disabled"` через [Обновить вебхук](https://docs.anivahealth.com/ru/api/webhooks/update-webhook.md).

> [!NOTE]
>
> Требуется scope `webhooks_manage`.

## Запрос

### Параметры пути

**id** `string` *required*

Идентификатор вебхука (UUID).

## Ответ

При успехе API возвращает `204 No Content` с пустым телом ответа.

## Ответы с ошибками

| Статус | Описание |
| - | - |
| `400` | Некорректный запрос. См. сообщение `error`. |
| `401` | Неверный API-ключ. |
| `403` | API-ключ не передан или у него нет scope `webhooks_manage`. |
| `404` | Вебхук не найден или принадлежит другому API-ключу. |
| `500` | Внутренняя ошибка сервера. |

```bash cURL theme={null}
curl --request DELETE \
  --url https://anivahealth.com/api/v1/webhooks/4a6c8e0f-2b4d-4f6a-8c0e-2a4c6e8f0b1d \
  --header 'x-api-key: YOUR_API_KEY'
```

```json 404 theme={null}
{
  "error": "Webhook not found"
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.