Videos
Adding a Webhook

Webhook Subscription

To receive notifications when your videos are ready, you need to subscribe to webhooks for specific templates.

Subscribe to Webhook

Endpoint: POST /api/dynamic/video/subscribe

Headers:

  • X-API-KEY: Your API key (required)
  • Content-Type: application/json

Request Body:

{
    "template_id": "your_template_id",
    "hookUrl": "https://your-webhook-url.com/endpoint"
}
FieldTypeDescription
template_idstringThe ID of the template you want to subscribe to
hookUrlstringThe URL where you want to receive webhook notifications

Response:

{
    "success": true
}

Error Responses:

  • 400 Bad Request: If template_id or hookUrl is missing
  • 401 Unauthorized: If the API key is missing or invalid
  • 500 Internal Server Error: If there's an issue subscribing to the webhook

Example Usage:

curl -X POST 'https://krumzi.com/api/dynamic/video/subscribe' \
-H 'X-API-KEY: your_api_key_here' \
-H 'Content-Type: application/json' \
-d '{"template_id": "template_12345abcde", "hookUrl": "https://your-webhook-url.com/endpoint"}'

After subscribing, you will receive webhook notifications at the specified URL whenever a video created with the specified template is ready.