据 AlphaMoat 统计,截至 2026-09,youtube-apify-transcript 累计下载 4,711 次、获 5 个星标,在全部 5,078 个 AI 技能中排名第 2,015 位,在「数据分析」分类(399 个)中排名第 161 位。
| 平台 | 累计安装 | 累计下载 | 星标 | 评论 |
|---|---|---|---|---|
| ClawHub ↗ | 151 | 4,711 | 5 | - |
| SkillHub ↗ | 263 | 4,660 | 5 | — |
各平台的计数口径不同,统计时间不一致。
YouTube 屏蔽来自云 IP(AWS、GCP 等)的字幕请求;Apify 经住宅代理转发请求绕过 bot 检测。默认 actor 为 topaz_sharingan/youtube-transcript-scraper-1(2026-08-31 核验公开未弃用,30 天 36,362 次成功 0 次失败);按事件计费 $0.01/结果($10.00/1,000 个结果),Apify 免费计划每月 $5 预付即约 500 个视频(旧文档的 $0.007/714 个是错误的);缓存命中不启动 actor 运行、不计费。输入仅 startUrls 与 timestamps 两个字段,无语言字段——--lang 对默认 actor 不生效(仅对 pintostudio/starvibe/karamelo 等 actor 转发)。用法:python3 scripts/fetch_transcript.py "URL"(默认文本、走缓存),--json、--output、--batch urls.txt(打印成本约 $0.02/2 次 API 调用)、--no-cache、--cache-stats、--clear-cache;缓存目录默认技能目录下 .cache/,可用 YT_TRANSCRIPT_CACHE_DIR 覆盖。Agent 指令:总结视频时先用脚本取字幕,再用自身模型直接总结,勿用 --summarize。需 APIFY_API_TOKEN(https://console.apify.com/account/integrations 获取)与 python3 -m pip install requests。
资料发布于 2026-10-29
以下是根据技能文档生成的示例,不代表实际运行结果。
2026-09 起统计方法调整:同名技能按作者分别统计,并覆盖全部技能。图中虚线为调整前的月份,与之后的数据不直接比较,也不计算跨越调整的增长。
| 月份 | 累计下载 | 环比 | 星标 |
|---|---|---|---|
| 2026-09 | 4,711 | — | 5 |
| 2026-08 | 4,501 | +4.2% | 5 |
| 2026-07 | 4,320 | +6.6% | 5 |
| 2026-06 | 4,052 | +4.5% | 5 |
| 2026-05 | 3,878 | — | 5 |
| 2026-03 | 3,327 | — | 5 |
以下是作者发布的原始文件,按纯文本显示,本站未做修改或审核;其中的链接不可点击,命令请核实后再运行。抓取于 2026-10-23。
---
name: youtube-apify-transcript
version: 1.4.0
description: Fetch YouTube transcripts via the Apify API. Works from cloud IPs (Hetzner, AWS, etc.) by bypassing YouTube's bot detection. Features local caching (free repeat requests) and batch mode. Requires APIFY_API_TOKEN and the Python requests library.
tags: [youtube, transcript, apify, video, subtitles, captions, cloud-ip, free-tier, web-scraping, caching, batch]
metadata:
openclaw:
requires:
bins: ["python3"]
env: ["APIFY_API_TOKEN"] primaryEnv: APIFY_API_TOKEN
envVars:
- name: APIFY_API_TOKEN
required: true
description: "Apify API token from https://console.apify.com/account/integrations"
- name: YT_TRANSCRIPT_CACHE_DIR
required: false
description: "Cache directory. Defaults to .cache/ in the skill directory."
note: "Install the Python dependency once: python3 -m pip install requests"
---
# youtube-apify-transcript
Fetch YouTube transcripts via Apify API (works from cloud IPs, bypasses YouTube bot detection).
## Why Apify?
YouTube blocks transcript requests from cloud IPs (AWS, GCP, etc.). Apify runs the request through residential proxies, bypassing bot detection.
## Default actor
`topaz_sharingan/youtube-transcript-scraper-1` (YouTube Transcript Ninja). Store sheet: https://apify.com/topaz_sharingan/youtube-transcript-scraper-1
Checked against the Apify API on 2026-08-31:
- Public, not deprecated (`isDeprecated: false`, `notice: NONE`)
- Last code change: 2026-07-19
- 30-day public runs: 36,362 succeeded, 0 failed, 91 timed out, 18 aborted (36,471 total)
### Cost
Pay per event: $0.01 per result ($10.00 per 1,000 results). The actor page states platform compute is included in that event price. Older docs that said $0.007 per video were wrong.
Apify Free plan (https://apify.com/pricing, 2026-08-31): $5 prepaid usage per month, no credit card. Unused credits do not roll over.
Free-tier video count: $5 / $0.01 = **500 videos per month**, not 714. (714 was $5 / $0.007.) Repeat requests served from the local cache do not start an actor run.
Track spend at https://console.apify.com/billing
### Input
OpenAPI input schema on 2026-08-31 has two fields:
| Field | Type | Required | Default | Role |
| --- | --- | --- | --- | --- |
| `startUrls` | string[] | yes | (none) | YouTube video URLs |
| `timestamps` | boolean | no | `false` | `true`: transcript as `{timestamp, text}` array. `false`: joined text |
There is no language field. `--lang` on the CLI does not change the default actor's input. The script only forwards `--lang` for other actor IDs (`pintostudio`, `starvibe`, `karamelo`). For `topaz_sharingan~Youtube-Transcript-Scraper-1` it sends `startUrls` only.
```json
{
"startUrls": ["https://www.youtube.com/watch?v=VIDEO_ID"],
"timestamps": false
}
```
The schema types `startUrls` items as strings. The script currently sends `[{"url": "..."}]` Request-list objects.
### Output
Actor sheet examples:
- `timestamps: false` → `{"transcript": "plain text..."}`
- `timestamps: true` → `{"transcript": [{"timestamp": "0:01", "text": "..."}]}`
The skill script also looks for `text`, `captions`, `title` / `videoTitle`, and `channelName`. If a run returns only `transcript`, formatting depends on whether that value is a string or a list.
## Links
- [Apify Pricing](https://apify.com/pricing)
- [Get API token](https://console.apify.com/account/integrations)
- [YouTube Transcripts Actor](https://apify.com/topaz_sharingan/youtube-transcript-scraper-1)
## Setup
1. Create a free Apify account: https://apify.com/
2. Get your API token: https://console.apify.com/account/integrations
3. Set the environment variable and install `requests` yourself. OpenClaw has no `kind: pip` installer (allowed kinds: brew, node, go, uv, download), so this is a manual step.
```bash
# Add to ~/.bashrc or ~/.zshrc
export APIFY_API_TOKEN="apify_api_YOUR_TOKEN_HERE"
# Python dependency (once)
python3 -m pip install requests
# Or use .env file (never commit this!)
echo 'APIFY_API_TOKEN=apify_api_YOUR_TOKEN_HERE' >> .env
```
## Usage
### Basic Usage
```bash
# Get transcript as text (uses cache by default)
python3 scripts/fetch_transcript.py "https://www.youtube.com/watch?v=VIDEO_ID"
# Short URL also works
python3 scripts/fetch_transcript.py "https://youtu.be/VIDEO_ID"
```
### Options
```bash
# Output to file
python3 scripts/fetch_transcript.py "URL" --output transcript.txt
# JSON format (includes timestamps when the payload has them)
python3 scripts/fetch_transcript.py "URL" --json
# Both: JSON to file
python3 scripts/fetch_transcript.py "URL" --json --output transcript.json
# --lang is accepted by the CLI but is not sent to the default actor
# (no language field on topaz_sharingan/youtube-transcript-scraper-1).
python3 scripts/fetch_transcript.py "URL" --lang de
```
### Caching
Transcripts are cached locally by default. Repeat requests for the same video do not start an actor run.
```bash
# First request: fetches from Apify ($0.01)
python3 scripts/fetch_transcript.py "URL"
# Second request: uses cache
python3 scripts/fetch_transcript.py "URL"
# Output: [cached] Transcript for: VIDEO_ID
# Bypass cache (force fresh fetch)
python3 scripts/fetch_transcript.py "URL" --no-cache
# View cache stats
python3 scripts/fetch_transcript.py --cache-stats
# Clear all cached transcripts
python3 scripts/fetch_transcript.py --clear-cache
```
Cache location: `.cache/` in skill directory (override with `YT_TRANSCRIPT_CACHE_DIR` env var)
### Batch Mode
Process multiple videos at once:
```bash
# Create a file with URLs (one per line)
cat > urls.txt << EOF
https://youtube.com/watch?v=VIDEO1
https://youtu.be/VIDEO2
https://youtube.com/watch?v=VIDEO3
EOF
# Process all URLs
python3 scripts/fetch_transcript.py --batch urls.txt
# Output:
# [1/3] Fetching VIDEO1...
# [2/3] [cached] VIDEO2
# [3/3] Fetching VIDEO3...
# Batch complete: 2 fetched, 1 cached, 0 failed
# [Cost: ~$0.020 for 2 API call(s)]
# Batch with JSON output to file
python3 scripts/fetch_transcript.py --batch urls.txt --json --output all_transcripts.json
```
The script's cost line prints $0.01 per result, so two fetched videos show about $0.02.
### Output Formats
**Text (default):**
```
Hello and welcome to this video.
Today we're going to talk about...
```
**JSON (--json):**
```json
{
"video_id": "dQw4w9WgXcQ",
"title": "Video Title",
"transcript": [
{"start": 0.0, "duration": 2.5, "text": "Hello and welcome"},
{"start": 2.5, "duration": 3.0, "text": "to this video"}
],
"full_text": "Hello and welcome to this video..."
}
```
The actor's timestamped items use `timestamp` (string like `"0:01"`), not `start` / `duration`. The JSON example above is the skill script's shape when captions already have those keys.
## Agent Instructions
When the user asks to summarize a YouTube video, first fetch the transcript using the script, then summarize the transcript text directly using your own model capabilities. Do NOT use --summarize flag.
## Error Handling
The script handles common errors:
- Invalid YouTube URL
- Video has no transcript
- API quota exceeded
- Network errors
## Metadata
Runtime requirements live in the YAML frontmatter (`metadata.openclaw`). OpenClaw 2.0 (v2026.8.1) installer kinds are brew, node, go, uv, and download. There is no `kind: pip`. Install `requests` with `python3 -m pip install requests`.
AdMapix 的取数层:把广告与应用相关的查询转成接口调用,只回原始 JSON。
走 Tavily 检索公开网页,返回带链接与摘要的结构化结果。
把数据库、表格与导出的原始数据变成可决策结论的数据分析技能。
用 Yahoo Finance 数据做股票与加密货币分析、组合跟踪的技能。
管理本地自选股清单,并按代码汇总同花顺行情与近期表现的技能。
知了标讯:查询和分析招标、中标、供应商与采购市场信息。
用命令行监控博客与 RSS/Atom 源的更新。
汇总 Codex 或 Claude 按模型计费的使用成本。
在多个搜索服务间自动路由,返回排序结果与网页正文。
按需切换 20 种内置人格,获得不同任务视角。
topic-monitor 将网页搜索、RSS/Atom 和 GitHub 发布合并为主题提醒或摘要。
agent-chronicle 将智能体会话活动整理为反思日记与每周摘要。
通过 ElevenLabs API 生成语音
数据月份:2026-09 · 下载/星标/安装数聚合自公开技能注册库(ClawHub、SkillHub),按月更新。口径说明见数据方法。