当前位置: 首页 > Skill >

dataify-youtube-transcript-by-id

dataify-youtube-transcript-by-id

dataify-youtube-transcript-by-id

通过视频ID构建器提交Dataify YouTube字幕任务,用于YouTube字幕文件的收集、爬取等操作。

1.2.0 2026.11.24 781
获取Skill文件查看使用说明
作 者:陆辰 许可证: 更新时间:2026.11.24
本文目录展开

Dataify YouTube Transcript By ID

Submit YouTube subtitle/transcript collection jobs through Dataify Builder by video ID. After a successful submission, give the user the task_id, the returned or inferred status, and tell them to visit Dataify to view results.

API TOKEN Handling

Use DATAIFY_API_TOKEN as the long-term saved token name.

  • If the user provides a token in the request, use it for this run.
  • If no token is provided, first check whether DATAIFY_API_TOKEN is already saved locally in the environment.
  • If DATAIFY_API_TOKEN is saved locally, use it without asking the user to re-enter the token.
  • If no token is available locally, tell the user they need to provide a Dataify API TOKEN.
  • If the user does not have an API TOKEN, tell them they can register or log in at Dataify to get one.
  • If the user already has an API TOKEN, tell them it is available in the top-right area of Dataify.
  • After the user provides an API TOKEN and no local DATAIFY_API_TOKEN is saved, ask whether they want to save it locally as DATAIFY_API_TOKEN for future use.
  • If the user wants to save it, give the appropriate command for their shell and ask them to run it; do not silently persist tokens without confirmation.
  • Do not call the Builder endpoint without a token.
  • Always call it API TOKEN in user-facing instructions. Prefer the environment variable name DATAIFY_API_TOKEN for saved local use.

PowerShell examples for saving the token for the current session:

$env:DATAIFY_API_TOKEN = "YOUR_DATAIFY_API_TOKEN"

For a persistent user-level variable on Windows:

[Environment]::SetEnvironmentVariable("DATAIFY_API_TOKEN", "YOUR_DATAIFY_API_TOKEN", "User")

Core Workflow

  1. Before submitting, show the user the required values, shared values, optional values, and defaults listed in the Parameter Checklist.
  2. For dropdown fields, show all allowed options as Markdown tables with both Label and Value columns. Use scripts/submit_dataify_youtube_transcript_by_id.py --list-options to print the full dropdown tables.
  3. Ask whether the user wants to change any value before running the task.
  4. Ask whether the user wants to collect multiple YouTube transcript groups. If yes, ask for multiple video_id values.
  5. Normalize the final video_id values into a list of spider_parameters objects.
  6. Normalize subtitles_language, subtitles_type, and selected_only into one shared spider_universal object.
  7. Resolve the Dataify token from explicit input or saved DATAIFY_API_TOKEN.
  8. If no token is available, ask the user to enter their API TOKEN and ask whether to save it as DATAIFY_API_TOKEN.
  9. Validate each video ID, dropdown value, and file name.
  10. Submit a Builder request to create the task.
  11. Read data.task_id from the Builder response and read data.status or status when present.
  12. Stop after Builder succeeds.
  13. Tell the user to visit Dataify to view or manage results.

Parameter Checklist

When the user invokes this skill, first tell them these values are used. Always display submitted parameters as a Markdown table; do not use a plain sentence or bullet list for the parameter confirmation.

Field Required Default Location Notes
video_id Yes 8RePenzQH80 spider_parameters Unique YouTube video ID used to identify the video whose subtitles should be collected.
subtitles_language No ab spider_universal Dropdown-style shared parameter. Subtitle language.
subtitles_type No auto_generated spider_universal Dropdown-style shared parameter. Subtitle type.
selected_only No false spider_universal Dropdown-style shared parameter. Whether to use only selected specifications.
file_name No {{TasksID}} Builder form field Use the default when the user does not change it.

Then ask: "Do you want to change any of these values before I submit the task?"

Also ask: "Do you want to collect multiple YouTube transcript groups? If yes, provide multiple video_id values."

If the user has already provided some values, show those values in place of the defaults and only ask whether the remaining/defaulted values should be changed.

Dropdown Options

Before asking the user to choose dropdown values, show all allowed options as Markdown tables with both Label and Value columns.

Use this command to print the complete tables:

python3 ".scriptssubmit_dataify_youtube_transcript_by_id.py" --list-options

If python3 is not available, use the local Python 3 command for that machine, such as python.

The script prints:

  • subtitles_language options, using the supplied cn value as Label and typeValue as Value.
  • subtitles_type options.
  • selected_only options.

Parameter Handling

  • video_id is required. If the user does not provide it, use the default 8RePenzQH80 only after showing it in the parameter confirmation table.
  • Trim leading and trailing whitespace from video_id.
  • video_id cannot be empty.
  • Multiple collection groups only repeat video_id inside spider_parameters.
  • subtitles_language, subtitles_type, and selected_only are shared parameters. Send them in spider_universal, not inside each spider_parameters object.
  • subtitles_language defaults to ab.
  • subtitles_type defaults to auto_generated.
  • selected_only defaults to false.
  • file_name defaults to {{TasksID}}. If the user changes it, submit the user-provided value.
  • file_name cannot be empty.

Single-group example:

spider_parameters=[{"video_id":"8RePenzQH80"}]
spider_universal={"subtitles_language":"ab","subtitles_type":"auto_generated","selected_only":"false"}

Multi-group example:

spider_parameters=[{"video_id":"8RePenzQH80"},{"video_id":"dQw4w9WgXcQ"}]
spider_universal={"subtitles_language":"ab","subtitles_type":"auto_generated","selected_only":"false"}

Dataify Builder Request

Use form fields rather than hand-built URL-encoded strings.

  • URL: https://scraperapi.dataify.com/builder?platform=1
  • Method: POST
  • Authorization header: Bearer DATAIFY_API_TOKEN
  • Content type: application/x-www-form-urlencoded
  • Fixed fields:
    • spider_name=youtube.com
    • spider_id=youtube_transcript_by-id
    • spider_errors=true
  • Default field:
    • file_name={{TasksID}}
  • Dynamic fields:
    • spider_parameters must be a JSON string array of video ID objects.
    • spider_universal must be a JSON string object containing shared subtitle settings.

Script

For stable execution, prefer scripts/submit_dataify_youtube_transcript_by_id.py with Python 3.6 or newer instead of rewriting the Builder flow.

python3 ".scriptssubmit_dataify_youtube_transcript_by_id.py" --video-id "8RePenzQH80"

To override the saved environment token or default shared parameters for one run:

python3 ".scriptssubmit_dataify_youtube_transcript_by_id.py" --api-token "YOUR_DATAIFY_API_TOKEN" --video-id "8RePenzQH80" --subtitles-language "ab" --subtitles-type "auto_generated" --selected-only "false" --file-name "{{TasksID}}"

To submit multiple video IDs:

python3 ".scriptssubmit_dataify_youtube_transcript_by_id.py" --params-json '[{"video_id":"8RePenzQH80"},{"video_id":"dQw4w9WgXcQ"}]'

The script prints a JSON summary with task_id, status, parameters, spider_universal, file_name, dashboard_url, and message.

Troubleshooting

Missing Dataify API TOKEN means no explicit token was passed and DATAIFY_API_TOKEN is not saved locally. Tell the user they need to provide their Dataify API TOKEN, ask whether they want to save it as DATAIFY_API_TOKEN, or tell them they can register or log in at Dataify to get one. If they already have a token, tell them it is in the top-right area of Dataify.

video_id cannot be empty means the required YouTube video ID is missing.

Unsupported subtitles_language means the value must be one of the allowed subtitle language codes.

Unsupported subtitles_type means the value must be auto_generated or uploader_provided.

Unsupported selected_only means the value must be false or true.

File name cannot be empty means no usable file_name was provided.

Necessary parameters is empty! usually means the Builder request was not submitted as form fields, spider_parameters was not a JSON string array, spider_universal was not a JSON string object, or one spider_parameters object is missing video_id.

Missing task_id usually means the authorization header, token, spider_name, spider_id, spider_parameters, or spider_universal is wrong.

Guardrails

  • Do not put subtitles_language, subtitles_type, or selected_only inside spider_parameters.
  • Do not omit spider_universal.
  • Do not poll for results after Builder succeeds.
  • Use only API TOKEN and DATAIFY_API_TOKEN when referring to authentication.
  • Do not hard-code local Python paths.
  • Do not claim the Builder response contains YouTube transcript files.
  • Do not invent result fields.
  • Always direct the user to Dataify after successful task creation.

推荐文章

更多
PHP时间戳与日期字符串相互转换方法详解

本文介绍PHP中时间数值(Unix时间戳)与日期字符串之间的相互转换方法。通过strtotime和date函数,实现将当前时间、指定日期转换为时间戳,以及将时间戳格式化为可读的日期时间字符串,并提供相关在线计算工具推荐。

2025.11.30 1,034
PHP日期转时间戳时区偏差怎么解决

在 PHP 中将日期字符串转换为时间戳时,若未显式指定时区,默认使用脚本配置的 date.timezone 或系统时区。当服务器时区与业务逻辑预期(如 UTC )不一致时,会产生偏差。解决核心是确保输入字符串携带明确时区信息,或在转换前统一设置时区上下文。

2026.10.24 1,031
PHP跨域配置:怎么安全地允许指定域名而非使用通配符

在 PHP 中安全地允许指定域名跨域,核心是解析请求头中的 Origin ,验证其是否在白名单内,然后动态设置 Access-Control-Allow-Origin 响应头。不要使用通配符 * ,也不要硬编码单一域名。

2025.03.29 1,019
JavaScript中利用replace结合正则实现replaceAll效果

JavaScript原生仅支持replace()进行单次或全局替换,缺乏类似Java的replaceAll()便捷方法。本文总结四种在JS中实现全量替换的方案:使用带g标志的正则、带gm标志的正则、扩展String原型以及split后join。通过对比代码示例,展示各方法的实现细节与适用场景,帮助开发者根据需求选择最优解。

2025.04.29 1,017
OpenAI的Jalapeno芯片未落地,教你分辨300兆瓦算力消息

OpenAI计划在SB Energy租赁的数据中心部署约300兆瓦自研Jalapeno推理芯片,但目前双方仍处于洽谈阶段,交易细节与上线时间表均未公布。本文带你按报道原文核实项目所处阶段,厘清芯片发布、电力功率与实际推理算力的边界,并将融资意向与签约、开工、投运节点分开追踪,避免误将规划容量计入现有算力。

2026.12.02 1,014
PHP实现基础文件上传:HTML表单与$_FILES处理流程

在 HTML 表单中设置 enctype="multipart/form-data" ,并在 PHP 后端通过 $_FILES 数组接收文件,调用 move_uploaded_file() 将临时文件移动到目标目录即可完成上传。

2026.09.07 1,014
Skill 文件
  • SKILL.md
    • Dataify YouTube Transcript By ID
    • API TOKEN Handling
    • Core Workflow
    • Parameter Checklist
    • Dropdown Options
    • Parameter Handling
    • Dataify Builder Request
    • Script
    • Troubleshooting
    • Guardrails
  • 项目或源文件

相关 Skill

更多
service-qa-coach service-qa-coach Review support quality for chat, email, phone, social DM, or marketplace service teams. Use when a team needs a QA scorecard, failure-mode analysis, coaching plan, calibration checklist, or service-improvement brief without live ticketing, CRM, or contact-center system access.
高中数学作业批改助手 高中数学作业批改助手 >图片识别 直接读取学生手写作答照片,识别公式、符号、步骤 🧮 自动推导 根据题目自动生成参考答案和评分细则,无需教师预设 📊 逐步给分 每个关键步骤独立评分,体现过程分 📝 结构化报告 输出含识别内容、参考答案、逐步评分、改进建议的完整报告 🗂 批量批改 支持一次性批改多道题,最终汇总得分表
Vibration Analysis Vibration Analysis 分析来自CMS趋势、RMS/峰值、频谱及SCADA报警的风机传动链(主轴、齿轮箱、发电机)振动数据。
Traditional Bone Tool Making Basics Traditional Bone Tool Making Basics Use when you need custom, durable, repairable tools like awls, needles, scrapers, harpoons, or fishing hooks made from local animal bones or antlers and comm...
音频混音工具 音频混音工具 名称:Sound Mixing Tool(标识 sound-mixing-tool) 短简介(≤60字):音乐/音效响度精确对齐 + 融合混音工作流:用 ffmpeg 两段式 loudnorm 把多组素材 LUFS 偏差压到 <0.10,再最小干预融合、导出可进引擎的独立分轨。 标签/关键词:音频混音 响度匹配 LUFS ffmpeg 游戏音频 音效设计 Wwise FMOD 分轨导出 后期处理 触发词:混音 · 响度匹配 · LUFS 对齐 · MIX 版本 · 音乐音效分轨 · 融合 · 不打架 · 不能盖住 适用场景 :游戏音频集成、影视短视频配乐、播客后期