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

# Webhooks

> Subscribe to meeting lifecycle events and verify signed webhook deliveries.

Webhooks deliver selected meeting events to an HTTPS endpoint you control.

## Events

| Event                             | Meaning                           |
| --------------------------------- | --------------------------------- |
| `meeting.started`                 | Meeting started.                  |
| `meeting.ended`                   | Meeting ended.                    |
| `meeting.transcription.completed` | Transcription completed.          |
| `meeting.speaker_id.completed`    | Speaker identification completed. |
| `meeting.finalized`               | Meeting finalized.                |
| `meeting.automatic.surfaced`      | Automatic meeting surfaced.       |

## Payload fields

| Field               | Meaning                          |
| ------------------- | -------------------------------- |
| `meeting`           | Meeting identity and metadata.   |
| `timestamps`        | Start and end timing.            |
| `room`              | Room metadata.                   |
| `participants`      | Meeting participant list.        |
| `speakers`          | Speaker list.                    |
| `audio_metadata`    | Audio availability and metadata. |
| `transcript_text`   | Full transcript text.            |
| `transcript_events` | Transcript event list.           |
| `summary`           | Meeting summary.                 |
| `topics`            | Topic list.                      |
| `title`             | Meeting title.                   |

## Create a webhook

```python theme={null}
webhook = client.create_webhook(
    name="Meeting webhook",
    url="https://example.com/vued",
    events=["meeting.finalized"],
    payload_fields={"default": ["meeting", "timestamps", "title", "summary"]},
)
print(webhook["secret"])
```

## Verify signatures

Webhook deliveries include:

| Header                   | Meaning                               |
| ------------------------ | ------------------------------------- |
| `Vued-Webhook-Timestamp` | Unix timestamp used in the signature. |
| `Vued-Signature`         | `t=<timestamp>,v1=<hex_hmac_sha256>`. |

```python theme={null}
import hashlib
import hmac

timestamp = request.headers["Vued-Webhook-Timestamp"]
signature = request.headers["Vued-Signature"].split("v1=", 1)[1]
body = request.get_data()

expected = hmac.new(
    b"whsec_...",
    timestamp.encode() + b"." + body,
    hashlib.sha256,
).hexdigest()

ok = hmac.compare_digest(signature, expected)
```
