Create webhook endpoint
Creates a webhook receiver at an absolute HTTP(S) URL; HTTPS is recommended for production. status must be active or inactive. subscribed_events accepts public standard event names or ["*"]; signing_secret is optional, and retry_policy.max_attempts defaults to 3 and accepts 0..5.
https://api.unifyport.ai/v1/webhook-endpointsHeaders
X-Api-KeyWorkspace API key. The workspace is resolved from this header.
Content-TypeUse application/json when sending a JSON request body.
Path parameters
This endpoint has no path parameters.
Request body
urlAbsolute HTTP(S) URL that receives webhook events. Use HTTPS in production.
format: uri
statusEndpoint status: active or inactive.
enum: active, inactive
subscribed_events[]Public standard event types delivered to the endpoint. Use ["*"] for every public standard event; provider.raw_event is not included.
signing_secretOptional webhook signing secret. Use placeholders in examples.
retry_policyobjectOptional retry settings. max_attempts is the number of retries after the initial request, defaults to 3, and accepts integers from 0 to 5; 0 means initial delivery only.
retry_policyOptional retry settings. max_attempts is the number of retries after the initial request, defaults to 3, and accepts integers from 0 to 5; 0 means initial delivery only.
max_attemptsRetries after the initial delivery, from 0 to 5; 0 means initial delivery only.
Response body
idWebhook endpoint identifier (we_...).
urlAbsolute HTTP(S) URL that receives webhook deliveries; HTTPS is recommended for production.
format: uri
statusEndpoint status: active or inactive.
enum: active, inactive
subscribed_events[]Public standard event types delivered to the endpoint; ["*"] means all public events and does not include provider.raw_event.
signing_enabledtrue when a signing secret is set and deliveries are signed.
retry_policyobjectRetry settings returned by the API. max_attempts counts retries after the initial delivery, defaults to 3, and is limited to 0-5.
retry_policyRetry settings returned by the API. max_attempts counts retries after the initial delivery, defaults to 3, and is limited to 0-5.
max_attemptsConfigured retries after the initial delivery, from 0 to 5.
Responses
201Request succeeded. See the example response body.
400The request body, path, or parameters are invalid.
401The X-Api-Key header is missing or invalid.
Request
curl -X POST https://api.unifyport.ai/v1/webhook-endpoints \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com/webhook",
"status": "active",
"subscribed_events": ["*"],
"signing_secret": "<WEBHOOK_SIGNING_SECRET>"
}'Response
{
"data": {
"id": "we_example",
"url": "https://example.com/webhook",
"status": "active",
"subscribed_events": ["*"],
"signing_enabled": true,
"retry_policy": {
"max_attempts": 3
}
}
}