When to use it
- Podcasters with hour-long episodes who want 5-10 shorts per episode.
- YouTubers who want to auto-distribute clips to TikTok and Reels without manual editing.
- Course creators with lecture footage looking to extract teasers.
- Companies with conference talks who want to surface highlights.
For raw video → social post workflows, pair this with Multi-Platform Post.
Endpoint
POST /api/v1/clipper/youtubeQuickstart
curl -X POST https://api.reelsbuilder.ai/api/v1/clipper/youtube \
-H "Authorization: Bearer $REELSBUILDER_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"youtube_url": "https://youtube.com/watch?v=abc123",
"clip_count": 5,
"clip_duration_target_sec": 45,
"captions": true,
"face_tracking": true,
"webhook_url": "https://your-app.example.com/webhooks/clips"
}'Initial response
{
"success": true,
"data": {
"job_id": "cjob_01HKZ...",
"status": "queued",
"estimated_completion_sec": 240,
"source": {
"youtube_url": "https://youtube.com/watch?v=abc123",
"duration_sec": 3420,
"title": "How we ship 10x faster than competitors"
}
},
"meta": { "request_id": "req_...", "credits_used": 50, "credits_remaining": 950 }
}Completion webhook
POST https://your-app.example.com/webhooks/clips
X-RB-Event-Type: clips.completed
{
"event_id": "evt_...",
"event_type": "clips.completed",
"data": {
"job_id": "cjob_01HKZ...",
"status": "completed",
"clips": [
{
"clip_id": "clp_01HKZ...",
"title": "The 3-day shipping rule",
"url": "https://cdn.reelsbuilder.ai/c/clp_.../clip.mp4",
"thumbnail_url": "https://cdn.reelsbuilder.ai/c/clp_.../thumb.jpg",
"source_start_sec": 412,
"source_end_sec": 458,
"duration_sec": 46,
"viral_score": 0.91,
"transcript": "So the way we ship 10x faster is...",
"keywords": ["shipping velocity", "engineering culture"]
}
],
"credits_used": 50,
"credits_refunded": 0
}
}Parameters
| Field | Type | Required | Description |
|---|---|---|---|
youtube_url | URL | yes | Public YouTube URL. Private/unlisted videos need youtube_oauth_token. |
clip_count | integer | no | 1-20. Default 5. Each clip costs 10 credits. |
clip_duration_target_sec | integer | no | 15-90. Default 45. AI picks segments close to this. |
captions | boolean | string | no | true for default karaoke style, or a specific style. Default true. |
face_tracking | boolean | no | Auto-crop to follow the speaker's face when reformatting to 9:16. Default true. |
aspect_ratio | enum | no | 9:16 (default), 1:1, 16:9. |
brand_id | string | no | From Brand DNA. Adds logo overlay + brand-matched caption style. |
min_viral_score | number | no | 0.0-1.0. Default 0.6. Filter clips below this AI-predicted virality score. |
topic_filter | string[] | no | Keywords; only return clips with transcripts matching at least one. |
webhook_url | URL | recommended | HTTPS URL for completion callback. |
How viral score works
Every candidate clip is scored 0.0–1.0 by a model that looks at:
- Hook strength — does the opening 3 seconds grab attention?
- Self-contained narrative — does the clip work without context from the rest of the video?
- Engagement signals — laughs, gasps, "wait, what?" reactions, tonal shifts
- Quotability — punchy lines that could become captions
Default filter is 0.6 (decent). For top-quality only, use 0.85.
Examples
TypeScript
const r = await fetch("https://api.reelsbuilder.ai/api/v1/clipper/youtube", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.REELSBUILDER_API_KEY}`,
"Content-Type": "application/json",
"Idempotency-Key": crypto.randomUUID(),
},
body: JSON.stringify({
youtube_url: "https://youtube.com/watch?v=abc123",
clip_count: 5,
min_viral_score: 0.85,
brand_id: process.env.BRAND_ID,
webhook_url: "https://your-app.example.com/webhooks/clips",
}),
});
const { data: job } = await r.json();
console.log(`Job ${job.job_id} — ${job.source.title} (~${job.estimated_completion_sec}s)`);Python
import os, uuid, requests
r = requests.post(
"https://api.reelsbuilder.ai/api/v1/clipper/youtube",
headers={
"Authorization": f"Bearer {os.environ['REELSBUILDER_API_KEY']}",
"Idempotency-Key": str(uuid.uuid4()),
},
json={
"youtube_url": "https://youtube.com/watch?v=abc123",
"clip_count": 5,
"min_viral_score": 0.85,
"brand_id": os.environ.get("BRAND_ID"),
"webhook_url": "https://your-app.example.com/webhooks/clips",
},
)
job = r.json()["data"]
print(f"Job {job['job_id']} - {job['source']['title']} ({job['estimated_completion_sec']}s)")Chained with multi-platform posting
Once clips are ready, fan-out post all of them in parallel:
// In your webhook handler
for (const clip of payload.data.clips) {
await fetch("https://api.reelsbuilder.ai/api/v1/post", {
method: "POST",
headers: { ...auth, "Idempotency-Key": clip.clip_id },
body: JSON.stringify({
video_url: clip.url,
caption: clip.title,
platforms: ["tiktok", "instagram", "youtube_shorts"],
}),
});
}Pricing
- 10 credits per clip returned. The base cost in the initial response is your
clip_count× 10. - No charge for clips filtered out by
min_viral_score. If you ask for 10 and only 7 pass the threshold, you're charged 70 credits and refunded 30. - Source video processing is free. No per-minute fee for the input.
Source video limits
- Max source duration: 4 hours
- Min source duration: 60 seconds (anything shorter is rejected)
- Languages supported: 99 via ElevenLabs Scribe v2 STT
- Private/unlisted YouTube videos require
youtube_oauth_tokenwith read scope
See also
- Transcribe + Captions API — caption an arbitrary video URL
- Multi-Platform Post API — distribute the clips
- Webhooks — receive completion event