How webhooks work
- Register an HTTPS endpoint via
POST /v1/webhooks - Receive a signing secret — used to verify that payloads come from Buildmarkets
- Buildmarkets delivers a JSON payload to your URL via HTTP POST whenever a subscribed event fires
- Your server validates the signature, processes the event, and returns a
2xxstatus - Buildmarkets retries failed deliveries automatically (see Security & Delivery)
The secret is shown only once. Store it securely at registration time — it cannot be retrieved again. If lost, delete the webhook and create a new one.
Endpoints
| Method | Path | Description |
|---|---|---|
POST | /v1/webhooks | Register a new webhook endpoint |
GET | /v1/webhooks | List all registered webhooks |
GET | /v1/webhooks/{webhookId} | Get details for a specific webhook |
PATCH | /v1/webhooks/{webhookId} | Update URL, events, or status |
DELETE | /v1/webhooks/{webhookId} | Permanently remove a webhook |
POST | /v1/webhooks/{webhookId}/test | Send a test event to verify connectivity |
GET | /v1/webhooks/{webhookId}/deliveries | View delivery attempt history |
Create a webhook
Registers a new HTTPS endpoint to receive events. Pass an emptyevents array to subscribe to all event types. Pass specific event names to subscribe to a subset.
POST /v1/webhooks
Request body
| Field | Type | Required | Description |
|---|---|---|---|
url | string (URI) | ✅ | HTTPS URL where Buildmarkets will POST event payloads. Must be a valid https:// URL |
events | array of strings | ✅ | Event types to subscribe to. Pass an empty array [] to receive all events. See Webhook Events Reference for valid values |
Response body (201 Created)
| Field | Type | Description |
|---|---|---|
id | string (UUID) | Unique identifier for this webhook |
url | string | The registered HTTPS endpoint |
events | array of strings | Subscribed event types (empty = all) |
status | string | Webhook status: active or disabled |
secret | string | Shown only once. HMAC signing secret — store this securely immediately |
created_at | string (ISO 8601) | Registration timestamp |
⚠️ Store thesecretnow. It is returned exactly once in the201response and cannot be retrieved again. If lost, the webhook must be deleted and recreated.
Example request — subscribe to all events
Example request — subscribe to specific events
Example response
List webhooks
Returns all registered webhook endpoints for your account.GET /v1/webhooks
Example request
Example response
Note: Thesecretfield is not included in list or get responses — only in the initial201creation response.
Get a webhook
Returns the configuration for a single registered webhook by ID. The signingsecret is not returned.
GET /v1/webhooks/{webhookId}
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
webhookId | string (UUID) | ✅ | The webhook ID |
Example request
Update a webhook
Updates the URL, subscribed events, or status of an existing webhook. Only include fields you want to change.PATCH /v1/webhooks/{webhookId}
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
webhookId | string (UUID) | ✅ | The webhook ID to update |
Request body (all fields optional)
| Field | Type | Description |
|---|---|---|
url | string | New HTTPS URL to deliver events to |
events | array of strings | Updated list of subscribed event types |
status | string | active to enable delivery, disabled to pause it |
Example request — disable a webhook temporarily
Example request — update URL and event subscriptions
Send a test event
Triggers a synthetic test payload to be sent to the webhook’s registered URL. Use this to verify that your endpoint is reachable and correctly processing Buildmarkets payloads without waiting for a real event to occur.POST /v1/webhooks/{webhookId}/test
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
webhookId | string (UUID) | ✅ | The webhook ID to test |
Example request
"event_type": "webhook.test" to the registered URL. Your endpoint should respond with a 2xx status. Check the delivery history to see whether it was received successfully.
Delete a webhook
Permanently removes the webhook. Delivery to the registered URL stops immediately. This action cannot be undone.DELETE /v1/webhooks/{webhookId}
Returns 204 No Content on success.
Example request
Common errors
| HTTP Status | Error | Cause |
|---|---|---|
400 | INVALID_URL | Webhook URL is not a valid https:// URI |
400 | INVALID_EVENT | One or more event names in the events array are not recognized |
404 | WEBHOOK_NOT_FOUND | No webhook found for the provided webhookId |
Next steps
- Webhook Events Reference → — Full list of event types and their payload schemas
- Webhook Security & Delivery → — Signature verification, retry logic, and delivery history