YouTube Transcript Skill
Purpose
Fetch the existing transcript/captions for a YouTube video. This skill does NOT download audio or call transcription APIs — it only retrieves transcripts YouTube already has.
How to Use
python ~/.cursor/skills/youtube-transcript/scripts/youtube_transcript.py --url <youtube_url>
Arguments
| Arg | Required | Description |
|---|---|---|
--url |
Yes | YouTube video URL |
--output |
No | Write transcript to file; if omitted, print to stdout |
--output-format |
No | text (default) or json |
--language |
No | Preferred language code (default: en) |
--test |
No | Run diagnostics against a known test video |
Exit Codes
0Success1Invalid args or URL3Transcript not available
Errors go to stderr. Transcript goes to stdout or --output file.
On Failure
If this skill exits with code 3 (transcript not available), use the transcribe-audio skill as fallback:
python ~/.cursor/skills/transcribe-audio/scripts/transcribe_audio.py --youtube-url <same_url>
Output Formats
text (default): Plain transcript.
json:
{
"url": "https://...",
"video_id": "...",
"source": "youtube_api",
"transcript": "..."
}
Dependencies
youtube-transcript-api(pip install youtube-transcript-api)