MCPTube REST API reference generated from OpenAPI 3.1: routes, parameters, responses and error codes to download audio and video and transcribe YouTube videos.
Generated from the OpenAPI 3.1 specification, also available at https://mcp.mcptube.com/v1/openapi.json. Every route uses the Authorization: Bearer mct_YOUR_KEY header.
POST/v1/audio
Download audio
Downloads the audio of a YouTube video as MP3 (default, with cover art and tags) or M4A (original AAC). Returns a download link valid for 60 min.
When processing takes longer than ~90 s, the response is 202 with `statusUrl`: poll `GET /jobs/{id}` until `status` = `done`.
Body (JSON)
Field
Type
Description
urlrequired
string
URL or ID of a YouTube video (watch, youtu.be, shorts, live, embed or clip).
format
"mp3" | "m4a"
Output format. Default: mp3.
audioLanguage
string
Preferred audio track when the video has dubs (e.g. "pt", "en", "original").
integer, -9007199254740991 to 9007199254740991 | null
fileNamerequired
string
fileSizeBytesrequired
integer, -9007199254740991 to 9007199254740991
downloadUrlrequired
string
Download link, no authentication (the random identifier is the secret).
expiresAtrequired
string
The file is deleted from the server at this time (60 min after creation).
planNote
string
Present when the plan lowered the request (e.g. resolution), in the caller locale.
audioFormatrequired
object | null
200 OK
{
"videoId": "dQw4w9WgXcQ",
"title": "Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster)",
"author": "Rick Astley",
"durationSeconds": 213,
"fileName": "dQw4w9WgXcQ-Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster).mp3",
"fileSizeBytes": 6441731,
"downloadUrl": "https://mcp.mcptube.com/files/-U4ALuInCNI-3Rk8DxAtEOpUHuRy5NQ5/dQw4w9WgXcQ-Rick%20Astley%20-%20Never%20Gonna%20Give%20You%20Up.mp3",
"expiresAt": "2026-10-21T22:12:24.000Z",
"audioFormat": {
"container": "mp4",
"videoCodec": null,
"audioCodec": "mp4a.40.2",
"height": null,
"fps": null,
"audioTrack": null
}
}
Other responses
Status
When
202
Still processing: the job keeps running in the background.
400
Invalid request: invalid_request (body or field) or invalid_url (invalid URL or playlist).
401
unauthorized: no credential, or an invalid, revoked or expired key or token.
403
plan_limit (video length, AI transcription outside Pro, monthly AI transcription cap) or banned (blocked IP).
404
video_unavailable (missing, private or removed video; does not use quota).
429
quota_exceeded (daily quota) or failures_exceeded (too many failed attempts in a short time; try again later).
500
internal: server failure; try again.
503
youtube_blocked (YouTube refused the server; does not use quota) or service_unavailable.
POST/v1/video
Download video
Downloads the video as MP4: H.264 up to 1080p; above that VP9 or AV1, with no re-encoding. AAC audio, cover art and chapters. The plan may lower the resolution (planNote).
When processing takes longer than ~90 s, the response is 202 with `statusUrl`: poll `GET /jobs/{id}` until `status` = `done`.
Body (JSON)
Field
Type
Description
urlrequired
string
URL or ID of a YouTube video (watch, youtu.be, shorts, live, embed or clip).
maxHeight
integer, 144 to 4320
Maximum height in pixels (144, 360, 480, 720, 1080, 1440, 2160). Default: 1080. The plan may lower it (planNote).
integer, -9007199254740991 to 9007199254740991 | null
fileNamerequired
string
fileSizeBytesrequired
integer, -9007199254740991 to 9007199254740991
downloadUrlrequired
string
Download link, no authentication (the random identifier is the secret).
expiresAtrequired
string
The file is deleted from the server at this time (60 min after creation).
planNote
string
Present when the plan lowered the request (e.g. resolution), in the caller locale.
videoCodecrequired
"h264" | "vp9" | "av1" | null
compatibilityNote
string
Present when the video is not H.264.
videoFormatrequired
object | null
audioFormatrequired
object | null
200 OK
{
"videoId": "dQw4w9WgXcQ",
"title": "Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster)",
"author": "Rick Astley",
"durationSeconds": 213,
"fileName": "dQw4w9WgXcQ-Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster).mp4",
"fileSizeBytes": 30007919,
"downloadUrl": "https://mcp.mcptube.com/files/q2w8XyZ0fJ4mN1aB7cD9eF3gH5iK6lM8/dQw4w9WgXcQ-Rick%20Astley.mp4",
"expiresAt": "2026-10-21T22:15:10.000Z",
"videoCodec": "h264",
"planNote": "Resolution capped at 720p (requested: 1080p). Your plan: Free. Upgrade to Pro for 500 calls a day, video with no quality or length limits and AI transcription: https://app.mcptube.com/dashboard/billing?checkout=pro_monthly",
"videoFormat": {
"container": "mp4",
"videoCodec": "avc1.4d401f",
"audioCodec": null,
"height": 720,
"fps": 25,
"audioTrack": null
},
"audioFormat": {
"container": "mp4",
"videoCodec": null,
"audioCodec": "mp4a.40.2",
"height": null,
"fps": null,
"audioTrack": null
}
}
Other responses
Status
When
202
Still processing: the job keeps running in the background.
400
Invalid request: invalid_request (body or field) or invalid_url (invalid URL or playlist).
401
unauthorized: no credential, or an invalid, revoked or expired key or token.
403
plan_limit (video length, AI transcription outside Pro, monthly AI transcription cap) or banned (blocked IP).
404
video_unavailable (missing, private or removed video; does not use quota).
429
quota_exceeded (daily quota) or failures_exceeded (too many failed attempts in a short time; try again later).
500
internal: server failure; try again.
503
youtube_blocked (YouTube refused the server; does not use quota) or service_unavailable.
POST/v1/transcribe
Transcribe video
Uses the YouTube captions (manual before automatic). Without captions, transcribes the audio with AI (Pro only, up to 30 hours a month). The response carries SRT and/or text according to `format`.
When processing takes longer than ~90 s, the response is 202 with `statusUrl`: poll `GET /jobs/{id}` until `status` = `done`.
Body (JSON)
Field
Type
Description
urlrequired
string
URL or ID of a YouTube video (watch, youtu.be, shorts, live, embed or clip).
language
string
Caption language (ISO code, e.g. "pt", "en"). Empty: the original captions of the video.
forceAiTranscription
boolean
Ignores YouTube captions and transcribes the audio with AI (Pro only). Default: false.
format
"srt" | "text" | "both"
What to return: SRT, plain text or both. Default: both.
Where the transcript came from: youtube-captions (manual captions), youtube-auto-captions (automatic captions) or ai-transcription (audio transcribed by AI, Pro).
languagerequired
string | null
languageNamerequired
string | null
cueCountrequired
integer, -9007199254740991 to 9007199254740991
aiTranscriptionSecondsrequired
integer, -9007199254740991 to 9007199254740991 | null
Seconds of audio transcribed by AI (null when it came from captions).
aiTranscriptionUsedSeconds
integer, -9007199254740991 to 9007199254740991
AI transcription used this month, in seconds (Pro).
aiTranscriptionLimitSeconds
integer, -9007199254740991 to 9007199254740991
Monthly AI transcription cap, in seconds (Pro: 108000 s = 30 h).
srt
string
Captions in SRT format (format srt or both).
text
string
Plain text (format text or both).
200 OK
{
"videoId": "dQw4w9WgXcQ",
"title": "Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster)",
"author": "Rick Astley",
"durationSeconds": 213,
"source": "youtube-captions",
"language": "en",
"languageName": "English",
"cueCount": 61,
"aiTranscriptionSeconds": null,
"text": "We're no strangers to love You know the rules and so do I ..."
}
Other responses
Status
When
202
Still processing: the job keeps running in the background.
400
Invalid request: invalid_request (body or field) or invalid_url (invalid URL or playlist).
401
unauthorized: no credential, or an invalid, revoked or expired key or token.
403
plan_limit (video length, AI transcription outside Pro, monthly AI transcription cap) or banned (blocked IP).
404
video_unavailable (missing, private or removed video; does not use quota).
429
quota_exceeded (daily quota) or failures_exceeded (too many failed attempts in a short time; try again later).
500
internal: server failure; try again.
503
youtube_blocked (YouTube refused the server; does not use quota) or service_unavailable.
GET/v1/me
Plan and quotas
Caller's plan, daily quota (resets at 00:00 UTC) and AI transcription this month. Does not use quota.