🚀 Quickstart Guide
This guide will help you understand the basic workflow of using the ZapCap API to enhance your videos with dynamic, automated subtitles. Each section includes curl examples to get you started quickly.
Getting Started
To begin, you'll need an API key which authenticates your requests to the ZapCap API. You can get your API key from the ZapCap dashboard.
For all examples below, replace YOUR_API_KEY
with your actual API key.
Step 1: Upload a Video
Start by uploading a video to the ZapCap API. You have several options:
Option A: Direct Upload
See API Reference: Upload Video for all available parameters and configuration options
curl -X POST "https://api.zapcap.ai/videos" \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: multipart/form-data" \
-F "file=@/path/to/your/video.mp4"
Option B: Upload by URL
See API Reference: Upload Video by URL for all available parameters and configuration options
curl -X POST "https://api.zapcap.ai/videos/url" \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com/path/to/video.mp4"
}'
Both methods will return a response like:
{
"status": "uploaded",
"id": "cd97a23f-6c6d-4af7-ad66-b04ed4bb1c5e",
"storageId": "storage-123"
}
Save the id
value - you'll need it for the next steps.
Step 2: Get Available Templates
Visit the Dashboard Templates page to view all the templates available.
Before creating a task, you'll need to choose a template:
See API Reference: Get Templates for response schema details
curl -X GET "https://api.zapcap.ai/templates" \
-H "x-api-key: YOUR_API_KEY"
The response will include a list of available templates. Note down the id
of the template you want to use.
Step 3: Create a Video Task
Create a processing task using your video ID and chosen template:
See API Reference: Create Video Task for all available parameters and configuration options
curl -X POST "https://api.zapcap.ai/videos/YOUR_VIDEO_ID/task" \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"templateId": "YOUR_TEMPLATE_ID",
"autoApprove": true,
"language": "en"
}'
This will return a response with your task ID:
{
"taskId": "54abe67d-be14-4c78-800b-01d12bcfaaa6"
}
Step 4: Monitor Task Progress
Check the status of your task:
See API Reference: Get Video Task for complete response schema
curl -X GET "https://api.zapcap.ai/videos/YOUR_VIDEO_ID/task/YOUR_TASK_ID" \
-H "x-api-key: YOUR_API_KEY"
The response will include the current status:
{
"status": "completed", // or "pending", "transcribing", etc.
"id": "54abe67d-be14-4c78-800b-01d12bcfaaa6",
"transcript": "https://download-url-for-transcript",
"downloadUrl": "https://download-url-for-video"
// ... other fields
}
Step 5: Approve Transcript (If Required)
If you didn't set autoApprove: true
, you'll need to approve the transcript:
See API Reference: Approve Transcript for more details
curl -X POST "https://api.zapcap.ai/videos/YOUR_VIDEO_ID/task/YOUR_TASK_ID/approve-transcript" \
-H "x-api-key: YOUR_API_KEY"
Download Results
Once the task is completed, use the URLs from the task status response to download your results:
# Download the transcript
curl -o transcript.json "TRANSCRIPT_URL_FROM_STATUS"
# Download the final video
curl -o final_video.mp4 "DOWNLOAD_URL_FROM_STATUS"
Tips for Success
- Video Format: Ensure your video is in MP4 or QuickTime format
- File Size: For larger files (>100MB), consider using the multipart upload endpoint
- TTL: Add
?ttl=30d
to upload requests to set a 30-day retention period. Read more here - Error Handling: Always check the response status and error messages
- API Limits: Check our limitations page for current API limits
Next Steps
- Explore configuration options to customize subtitle appearance
- Learn about webhook notifications for automated status updates
- Check out the full API reference for detailed endpoint documentation
- See complete code examples in Node.js, Python, and curl