Webhooks
Webhook management and events
Returns list of all webhook event types with descriptions and example payloads
GET /api/webhook/events HTTP/1.1
Host:
Accept: */*
Returns list of all webhook event types with descriptions and example payloads
[
{
"eventType": "extracted",
"description": "Triggered after successful AI extraction of submission data",
"examplePayload": {
"eventId": "123e4567-e89b-12d3-a456-426614174000",
"eventType": "extracted",
"timestamp": "2023-10-28T12:00:00.000Z",
"submissionId": "sub_789012",
"templateId": "tpl_345678"
}
}
]Event type that triggers the webhook
extractedURL where webhook notifications will be sent
https://example.com/webhook-endpointThe webhook subscription has been created
Bad request - URL and event are required
Internal server error
POST /api/webhook/subscription HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 66
{
"event": "extracted",
"url": "https://example.com/webhook-endpoint"
}{
"id": "123e4567-e89b-12d3-a456-426614174000",
"event": "extracted",
"url": "https://example.com/webhook-endpoint",
"secret": "123e4567-e89b-12d3-a456-426614174000",
"createdAt": "2023-01-01T12:00:00Z",
"updatedAt": "2023-01-01T13:30:00Z"
}List of webhook subscriptions
Internal server error
GET /api/webhook/subscriptions HTTP/1.1
Host:
Accept: */*
[
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"event": "extracted",
"url": "https://example.com/webhook-endpoint",
"secret": "123e4567-e89b-12d3-a456-426614174000",
"createdAt": "2023-01-01T12:00:00Z",
"updatedAt": "2023-01-01T13:30:00Z"
}
]Subscription ID
The webhook subscription details
Subscription not found
Internal server error
GET /api/webhook/subscription/{id} HTTP/1.1
Host:
Accept: */*
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"event": "extracted",
"url": "https://example.com/webhook-endpoint",
"secret": "123e4567-e89b-12d3-a456-426614174000",
"createdAt": "2023-01-01T12:00:00Z",
"updatedAt": "2023-01-01T13:30:00Z"
}Subscription ID
Event type that triggers the webhook
extractedURL where webhook notifications will be sent
https://example.com/webhook-endpointThe updated webhook subscription
Subscription not found
Internal server error
PUT /api/webhook/subscription/{id} HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 66
{
"event": "extracted",
"url": "https://example.com/webhook-endpoint"
}{
"id": "123e4567-e89b-12d3-a456-426614174000",
"event": "extracted",
"url": "https://example.com/webhook-endpoint",
"secret": "123e4567-e89b-12d3-a456-426614174000",
"createdAt": "2023-01-01T12:00:00Z",
"updatedAt": "2023-01-01T13:30:00Z"
}Subscription ID
Subscription successfully deleted
Subscription not found
Internal server error
DELETE /api/webhook/subscription/{id} HTTP/1.1
Host:
Accept: */*
{
"success": true
}Last updated
Was this helpful?