Node SDK
The official, typed Node.js / TypeScript client. Fetch transcripts, channels, playlists, and search as structured data, ESM + CommonJS, zero runtime dependencies.
Official SDK. Source + issues on GitHub. Your key falls back to the TRANSCRIPTFETCH_API_KEY env var, keep it server-side. One credit per successful caption fetch (AI audio transcription bills per started 5 minutes of audio); failed/blocked/no-transcript requests are free.
Using n8n? There is a community node that wraps this API for n8n workflows, no code required: n8n-nodes-transcriptfetch.
Install
Requires Node 18+ (uses the built-in fetch). Ships types for TypeScript.
Quickstart
Get an API key (100 free credits a month) at the dashboard, then:
By default a transcript comes back as timestamped segments and has no text; the response carries exactly one of the two. To get one plain string instead, turn timestamps off:
Endpoints
video/channel/playlist accept URLs or raw IDs (normalized automatically).
Long media and jobs
mode: "audio", or any captionless source that is not short, answers 202 with a job instead of a transcript: poll the job (or pass callbackUrl) and read the result from there. Short captionless media usually still comes back inline in the same call. The full contract, including what AI transcription costs, is in the transcription guide.
Pagination
List endpoints are cursor-paginated. Iterate every result with an async generator:
Errors
All errors subclass TranscriptFetchError. API errors carry .status, .code, .message, and .requestId.
Reliability built in. Automatic retries on 429 (honoring Retry-After) and 5xx with exponential backoff; every write auto-sends an Idempotency-Key so a retried request is never double-charged. Configure via new TranscriptFetch({ apiKey, baseUrl, timeout: 30000, maxRetries: 2 }).
Prefer raw HTTP? The API is plain HTTPS/JSON, see the endpoint reference for every route and the response format.