---
title: "Create Webhook"
method: POST
path: "/v1/webhooks"
tags: ["Webhooks"]
---

# Create Webhook

`POST /v1/webhooks`

## Request

- Base URL: `https://api.ensemble.markets` (the document declares no server; this is the origin it was published from)
- URL: `https://api.ensemble.markets/v1/webhooks`
- Auth: HTTP bearer

Register a receiver. Deliveries are POSTs signed with the returned HMAC
secret; `secret` documents the verification scheme. Business plan.

## Request body

- WebhookCreateRequest
  - `url` string, uri, required: HTTPS URL that receives signed POST deliveries
  - `description` string, nullable: A label

## Response `201`

Successful Response

- Webhook
  - `id` string, required: Webhook ID (webhook_... or legacy UUID). Use the returned ID verbatim.
  - `url` string, required: Receiver URL
  - `secret` string, required: HMAC signing secret. Verify a delivery by computing HMAC-SHA256(secret, '{t}.{raw_body}') and comparing it to the v1 value in the X-Ensemble-Signature header ('t=<ts>,v1=<hex>').
  - `description` string, nullable
  - `enabled` boolean, required: Whether deliveries are active
  - `last_delivery_at` string, date-time, nullable: Most recent delivery attempt
  - `last_delivery_status` string, nullable: HTTP status or error label of the most recent delivery
  - `created_at` string, date-time, required

## Other responses

- `4XX`: The request was refused; `error.type` says why
- `5XX`: The server failed; quote `X-Request-Id` when reporting it

---

[API](https://skmtc.dev/ensemble/apis/ensemble-api.md) · [All operations](https://skmtc.dev/ensemble/apis/ensemble-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ensemble/apis/ensemble-api/revisions/4c0fbd80c197?raw)
