Create webhook
Creates a new webhook and returns the HMAC signing secret.
Overview
Creates a webhook for the authenticated company. The plaintext HMAC signing secret is included in the response only on creation — it is never returned again. Store it securely.Endpoint
POST /api/v2/webhooks
Request body
| Field | Type | Required | Description |
|---|---|---|---|
| url | string | Yes | Destination URL (must be HTTPS; internal/private IPs rejected) |
| alertIds | integer[] | Yes (unless isGlobal) | Alert configuration IDs to link (from GET /api/v2/companies/{id}/alerts) |
| isActive | boolean | No | Whether deliveries are enabled (default true) |
| isGlobal | boolean | No | Fire for all company alerts regardless of alertIds (default false) |
Response
200 OK —CreateWebhookResponse (extends WebhookDto)
| Field | Type | Description |
|---|---|---|
| id | integer | Webhook ID |
| url | string | Destination URL |
| alertIds | integer[] | Linked alert configuration IDs |
| isActive | boolean | Whether the webhook is active |
| isGlobal | boolean | Whether global delivery is enabled |
| createdAt | datetime | UTC creation timestamp |
| secret | string | Plaintext HMAC-SHA256 signing secret — store it now, not returned again |
| warning | string | null | Set when linked alerts have different types (payloads will have different data shapes) |
Example response
Error responses
| Status | Meaning |
|---|---|
| 401 | Missing or invalid token |
| 422 | Alert ID not found, unsupported alert type, or more than 50 alert IDs |
| 429 | Rate limit exceeded |
| 500 | Unexpected server error |
Authorizations
JWT Bearer token obtained from POST /api/v2/authentication/token/api-key.
Lifetime: ~24 hours (86,399 seconds). Cache the token and reuse it. Re-authenticate 5 minutes before expiry.
Scoping: API key tokens are scoped to the company the key belongs to and may restrict access to a vehicle allowlist and/or action set (see token claims).
No refresh endpoint — re-authenticate with your API key when the token expires.
Body
"https://your-server.example.com/telemax-webhook"
IDs of alerts to subscribe to. Must be of a supported type (see endpoint description). Required when isGlobal is false.
[101, 102]Response
Successful response