$npx -y skills add ZeroPointRepo/youtube-skills --skill youtube-apiUse when YouTube data is needed without Google API quotas or OAuth setup: transcripts, video metadata, channel info, search results, playlists. Triggers on pasted YouTube links, creator names, @handles, topic research, video summaries, channel browsing, or any request where YouTu
| 1 | # YouTube API |
| 2 | |
| 3 | YouTube data access via [TranscriptAPI.com](https://transcriptapi.com) — no Google API quota needed. |
| 4 | |
| 5 | ## Setup |
| 6 | |
| 7 | If `$TRANSCRIPT_API_KEY` is not set, read [references/auth-setup.md](references/auth-setup.md) and follow the instructions there to get and store the key. |
| 8 | |
| 9 | ## Required Headers |
| 10 | |
| 11 | Every request needs two headers: |
| 12 | |
| 13 | - **Authorization:** `Bearer $TRANSCRIPT_API_KEY` |
| 14 | - **User-Agent:** your agent's name and version if known (e.g. `HermesAgent/0.11.0`, `ClaudeCode/1.0`). Version is optional — agent name alone is fine. Do not omit this header or send a bare default — Cloudflare will return a 403 (error code 1010) and block the request. |
| 15 | |
| 16 | ## API Reference |
| 17 | |
| 18 | Full OpenAPI spec: [transcriptapi.com/openapi.json](https://transcriptapi.com/openapi.json) — consult this for the latest parameters and schemas. |
| 19 | |
| 20 | ## Endpoint Reference |
| 21 | |
| 22 | All endpoints: `https://transcriptapi.com/api/v2/youtube/...` |
| 23 | |
| 24 | Channel endpoints accept `channel` — an `@handle`, channel URL, or `UC...` ID. Playlist endpoints accept `playlist` — a playlist URL or ID. |
| 25 | |
| 26 | | Endpoint | Method | Cost | |
| 27 | | ----------------------------------- | ------ | -------- | |
| 28 | | `/transcript?video_url=ID` | GET | 1 | |
| 29 | | `/search?q=QUERY&type=video` | GET | 1 | |
| 30 | | `/channel/resolve?input=@handle` | GET | **free** | |
| 31 | | `/channel/latest?channel=@handle` | GET | **free** | |
| 32 | | `/channel/videos?channel=@handle` | GET | 1/page | |
| 33 | | `/channel/search?channel=@handle&q=Q` | GET | 1 | |
| 34 | | `/playlist/videos?playlist=PL_ID` | GET | 1/page | |
| 35 | |
| 36 | ## Quick Examples |
| 37 | |
| 38 | **Search videos:** |
| 39 | |
| 40 | ```bash |
| 41 | curl -s "https://transcriptapi.com/api/v2/youtube/search\ |
| 42 | ?q=python+tutorial&type=video&limit=10" \ |
| 43 | -H "Authorization: Bearer $TRANSCRIPT_API_KEY" \ |
| 44 | -H "User-Agent: YourAgent/1.0" |
| 45 | ``` |
| 46 | |
| 47 | **Get transcript:** |
| 48 | |
| 49 | ```bash |
| 50 | curl -s "https://transcriptapi.com/api/v2/youtube/transcript\ |
| 51 | ?video_url=dQw4w9WgXcQ&format=text&include_timestamp=true&send_metadata=true" \ |
| 52 | -H "Authorization: Bearer $TRANSCRIPT_API_KEY" \ |
| 53 | -H "User-Agent: YourAgent/1.0" |
| 54 | ``` |
| 55 | |
| 56 | **Resolve channel handle (free):** |
| 57 | |
| 58 | ```bash |
| 59 | curl -s "https://transcriptapi.com/api/v2/youtube/channel/resolve?input=@TED" \ |
| 60 | -H "Authorization: Bearer $TRANSCRIPT_API_KEY" \ |
| 61 | -H "User-Agent: YourAgent/1.0" |
| 62 | ``` |
| 63 | |
| 64 | **Latest videos (free):** |
| 65 | |
| 66 | ```bash |
| 67 | curl -s "https://transcriptapi.com/api/v2/youtube/channel/latest?channel=@TED" \ |
| 68 | -H "Authorization: Bearer $TRANSCRIPT_API_KEY" \ |
| 69 | -H "User-Agent: YourAgent/1.0" |
| 70 | ``` |
| 71 | |
| 72 | **Browse channel uploads (paginated):** |
| 73 | |
| 74 | ```bash |
| 75 | curl -s "https://transcriptapi.com/api/v2/youtube/channel/videos?channel=@NASA" \ |
| 76 | -H "Authorization: Bearer $TRANSCRIPT_API_KEY" \ |
| 77 | -H "User-Agent: YourAgent/1.0" |
| 78 | # Use continuation token from response for next pages |
| 79 | ``` |
| 80 | |
| 81 | **Browse playlist (paginated):** |
| 82 | |
| 83 | ```bash |
| 84 | curl -s "https://transcriptapi.com/api/v2/youtube/playlist/videos?playlist=PL_PLAYLIST_ID" \ |
| 85 | -H "Authorization: Bearer $TRANSCRIPT_API_KEY" \ |
| 86 | -H "User-Agent: YourAgent/1.0" |
| 87 | ``` |
| 88 | |
| 89 | ## Parameter Validation |
| 90 | |
| 91 | | Field | Rule | |
| 92 | | -------------- | ------------------------------------------------------- | |
| 93 | | `channel` | `@handle`, channel URL, or `UC...` ID | |
| 94 | | `playlist` | Playlist URL or ID (`PL`/`UU`/`LL`/`FL`/`OL` prefix) | |
| 95 | | `q` (search) | 1-200 chars | |
| 96 | | `limit` | 1-50 | |
| 97 | | `continuation` | non-empty string | |
| 98 | |
| 99 | ## Why Not Google's API? |
| 100 | |
| 101 | | | Google YouTube Data API | TranscriptAPI | |
| 102 | | ----------- | ------------------------------- | -------------------------- | |
| 103 | | Quota | 10,000 units/day (100 searches) | Credit-based, no daily cap | |
| 104 | | Setup | OAuth |