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

# POST Create a webhook

> Create a webhook endpoint and return its secret.

## Endpoint

```txt theme={null}
POST /api/v1/webhooks
```

## Body

| Field    | Type      | Required | Description       |
| -------- | --------- | -------- | ----------------- |
| `url`    | string    | yes      | URL de réception  |
| `events` | string\[] | yes      | 1 à 50 événements |

## Success response `201`

```json theme={null}
{
  "data": {
    "id": "wh_uuid",
    "url": "https://example.com/webhooks/msgflash",
    "secret": "generated_once_secret",
    "events": ["message.delivered"],
    "active": true
  }
}
```
