The CaptionBurn API allows you to programmatically add animated captions to videos. Generate TikTok-style captions with word-by-word highlighting, multiple animation styles, and platform-specific safe zones.
Base URL: https://api.captionburn.com/v1
Here's a complete example of creating a captioned video:
# 1. Upload your video
curl -X POST https://api.captionburn.com/v1/upload \
-H "Authorization: Bearer cf_your_api_key" \
-F "file=@video.mp4"
# Response: { "videoUrl": "https://...", "duration": 30.5 }
# 2. Create a caption job
curl -X POST https://api.captionburn.com/v1/jobs \
-H "Authorization: Bearer cf_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"videoUrl": "https://...",
"transcriptionMode": "auto",
"style": {
"fontFamily": "Inter",
"fontSize": 48,
"primaryColor": "#FFFFFF",
"animation": "bounce"
},
"platform": "tiktok"
}'
# 3. Poll for completion
curl https://api.captionburn.com/v1/jobs/{job_id} \
-H "Authorization: Bearer cf_your_api_key"CaptionBurn supports two authentication methods: API keys (recommended for server-side) and JWT tokens (for browser-based apps using Supabase Auth).
Best for server-side integrations. Generate keys from your dashboard.
Authorization: Bearer cf_your_api_keyFor browser apps. Use the access token from Supabase Auth.
Authorization: Bearer eyJhbGci...Get account information and usage statistics for the authenticated user.
Jobs are the core resource for creating captioned videos. Each job goes through stages: pending → processing → rendering → completed (or failed).
Upload videos to our secure storage before creating jobs. Supported formats: MP4, MOV, WebM.
Get available caption styles, fonts, animations, and platform-specific safe zones. These endpoints don't require authentication.
Manage your subscription and check credit balance. 1 credit = 1 minute of video processing.
Rate limits vary by plan tier. Limits are applied per user/API key.
| Plan | Requests/min | Concurrent Jobs | Max Video Duration |
|---|---|---|---|
| Free | 10 | 1 | 2 minutes |
| Starter | 30 | 2 | 5 minutes |
| Pro | 60 | 5 | 10 minutes |
| Business | 120 | 10 | 30 minutes |
All responses include rate limit information in headers:
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 45
X-RateLimit-Reset: 1705312800The API uses standard HTTP status codes. All errors return a JSON body witherror andcode fields.
{
"error": "Insufficient credits",
"code": "INSUFFICIENT_CREDITS",
"details": {
"required": 5,
"available": 2
}
}| Code | Status | Description |
|---|---|---|
UNAUTHORIZED | 401 | Invalid or missing authentication |
FORBIDDEN | 403 | Not allowed to access this resource |
NOT_FOUND | 404 | Resource not found |
VALIDATION_ERROR | 400 | Invalid request body |
INSUFFICIENT_CREDITS | 402 | Not enough credits |
RATE_LIMITED | 429 | Too many requests |
FILE_TOO_LARGE | 413 | Upload exceeds size limit |
INVALID_FILE_TYPE | 400 | Unsupported file format |
JOB_FAILED | 500 | Job processing failed |
INTERNAL_ERROR | 500 | Unexpected server error |
Need help? Contact us at support@captionburn.com