ScriptBase

API Reference

GET /api/v1/transcribe

Transcribe

Extract a transcript from any supported video URL.

Endpoint: GET /api/v1/transcribe

Base URL: https://api.scriptbase.app

Cost: 1 credit per request (failed requests are free)

Parameters

NameTypeRequiredDefaultDescription
urlstringYesVideo URL to transcribe
languagestringNoenTarget language (ISO 639-1)
formatstringNojsonOutput format: json, srt, or text

Headers

HeaderRequiredDescription
X-API-KeyYesYour API key

Example

curl "https://api.scriptbase.app/api/v1/transcribe?url=https://www.youtube.com/watch?v=dQw4w9WgXcQ&format=json&language=en" \
  -H "X-API-Key: your_api_key"

Response

{
  "success": true,
  "data": {
    "segments": [
      {
        "text": "We're no strangers to love",
        "start": 18.0,
        "duration": 3.5
      },
      {
        "text": "You know the rules and so do I",
        "start": 21.5,
        "duration": 3.2
      }
    ]
  },
  "meta": {
    "platform": "youtube",
    "format": "json",
    "credits_used": 1,
    "credits_remaining": 19
  }
}

Output Formats

JSON (default)

Segments with text, start time, and duration:

{
  "segments": [
    { "text": "Hello world", "start": 0.0, "duration": 2.5 }
  ]
}

SRT

Standard subtitle format for video players:

1
00:00:00,000 --> 00:00:02,500
Hello world

Text

Plain text, one line per segment:

Hello world
Welcome to the video

Supported Platforms

YouTube, TikTok, Instagram, Facebook, X (Twitter), and Rumble.

Unsupported URLs return a 400 error with the list of supported platforms.

Errors

StatusErrorCause
400url query parameter is requiredMissing url param
400format must be json, srt, or textInvalid format
400Unsupported URLPlatform not supported
401Missing X-API-Key headerNo API key provided
401Invalid API keyKey is inactive or doesn't exist
401API key expiredKey past expiration date
402Insufficient creditsNo credits remaining
502Upstream service errorTranscription service failed
504Transcript processing timed outRequest took too long