youtube/
transcripts
tiktok / profilesTikTok Profiles APItiktok / videosTikTok Videos APItiktok / video-transcriptTikTok Video Transcript APItiktok / commentsTikTok Comments APItiktok / comment-repliesTikTok Comment Replies APItiktok / searchTikTok Search APItiktok / hashtagsTikTok Hashtags APItiktok / trending-feedTikTok Trending Feed APItiktok / followers-listTikTok Followers List APItiktok / following-listTikTok Following List APItiktok / user-videosTikTok User Videos APItiktok / live-room-infoTikTok Live Room Info APIx / profilesTwitter Profile Scraper APIx / followers-listX Followers List APIx / postsTwitter Tweet Scraper APIx / post-retweetersX Post Retweeters APIx / user-postsTwitter User Tweets Scraper APIx / searchTwitter Search APIx / following-listX Following List APIx / post-quotesX Post Quotes APIx / post-repliesX Post Replies APIx / trendsX Trends APIinstagram / postsInstagram Posts APIinstagram / post-infoInstagram Post Info APIinstagram / hashtag-postsInstagram Hashtag Posts APIinstagram / reels-searchInstagram Reels Search APIinstagram / story-highlightsInstagram Story Highlights APIinstagram / tagged-postsInstagram Tagged Posts APIinstagram / transcriptInstagram Transcript APIinstagram / audio-reelsInstagram Audio Reels APIinstagram / commentsInstagram Comments APIfacebook / pagesFacebook Pages APIfacebook / postsFacebook Posts APIfacebook / group-postsFacebook Group Posts APIfacebook / reelsFacebook Reels APIfacebook / commentsFacebook Comments APIfacebook / comment-repliesFacebook Comment Replies APIfacebook / company-reviewsFacebook Company Reviews APIfacebook / video-transcriptFacebook Video Transcript APIfacebook / ad-transcriptFacebook Ad Transcript APIfacebook / events-searchFacebook Events Search APIfacebook / event-detailsFacebook Event Details APIfacebook / profile-eventsFacebook Profile Events APIfacebook / profile-photosFacebook Profile Photos APIfacebook / profilesFacebook Profiles APIinstagram / followers-countInstagram Followers Count APIinstagram / profilesInstagram Profiles APIinstagram / followers-listInstagram Followers List APIinstagram / following-listInstagram Following List APIinstagram / reelsInstagram Reels APIinstagram / searchInstagram Search APIinstagram / highlight-itemsInstagram Highlight Items APIinstagram / trending-reelsInstagram Trending Reels APIyoutube / channelsYouTube Channels APIyoutube / videosYouTube Videos APIyoutube / channel-videosYouTube Channel Videos APIyoutube / playlist-videosYouTube Playlist Videos APIyoutube / channel-live-videosYouTube Channel Live Videos APIyoutube / commentsYouTube Comments APIyoutube / comment-repliesYouTube Comment Replies APIyoutube / community-postsYouTube Community Posts APIyoutube / shortsYouTube Shorts APIyoutube / searchYouTube Search APIyoutube / hashtag-searchYouTube Hashtag Search APIyoutube / transcriptsYouTube Transcripts APIlinkedin / profilesLinkedIn Profiles APIlinkedin / companiesLinkedIn Companies APIlinkedin / postsLinkedIn Posts APIlinkedin / jobsLinkedIn Jobs APIlinkedin / company-jobsLinkedIn Company Jobs APIlinkedin / company-postsLinkedIn Company Posts APIlinkedin / post-commentsLinkedIn Post Comments APIlinkedin / profile-postsLinkedIn Profile Posts APIlinkedin / search-jobsLinkedIn Search Jobs APIlinkedin / search-peopleLinkedIn Search People APIlinkedin / search-postsLinkedIn Search Posts APIreddit / postsReddit Posts APIreddit / commentsReddit Comments APIreddit / subreddit-postsReddit Subreddit Posts APIreddit / searchReddit Search APIpinterest / profilesPinterest Profiles APIpinterest / pinsPinterest Pins APIpinterest / user-pinsPinterest User Pins APIpinterest / searchPinterest Search APIthreads / postsThreads Posts APIthreads / profilesThreads Profiles APIthreads / user-postsThreads User Posts APIbluesky / profileBluesky Profile APIbluesky / postBluesky Post APIbluesky / user-postsBluesky User Posts APIfacebook-marketplace / location-searchFacebook Marketplace Location Search APIfacebook-marketplace / searchFacebook Marketplace Search APIfacebook-marketplace / itemFacebook Marketplace Item APIfacebook-ad-library / adFacebook Ad Library Ad APIfacebook-ad-library / company-adsFacebook Ad Library Company Ads APIfacebook-ad-library / company-searchFacebook Ad Library Company Search APIfacebook-ad-library / searchFacebook Ad Library Search APIgoogle-ad-library / adGoogle Ad Library Ad APIgoogle-ad-library / advertiser-searchGoogle Ad Library Advertiser Search APIgoogle-ad-library / company-adsGoogle Ad Library Company Ads APIgoogle-maps / searchGoogle Maps Search APIgoogle-maps / place-detailsGoogle Maps Place Details APIgoogle-maps / reviewsGoogle Maps Reviews APItiktok-ad-library / adTikTok Ad Library Ad APItiktok-ad-library / searchTikTok Ad Library Search APIlinkedin-ad-library / adLinkedIn Ad Library Ad APIlinkedin-ad-library / searchLinkedIn Ad Library Search APItiktok-shop / searchTikTok Shop Search APItiktok-shop / productsTikTok Shop Products APItiktok-shop / productTikTok Shop Product APItiktok-shop / product-reviewsTikTok Shop Product Reviews APIseo / google-organic-serpGoogle Organic SERP APIseo / keyword-difficultyKeyword Difficulty APIseo / keyword-overviewKeyword Overview APIseo / keyword-search-volumeKeyword Search Volume APIseo / keywords-for-siteKeywords for Site APIseo / keyword-suggestionsKeyword Suggestions APIseo / ranked-keywordsRanked Keywords APIseo / related-keywordsRelated Keywords APIseo / relevant-pagesRelevant Pages APIseo / search-intentSearch Intent APItiktok-shop / user-showcaseTikTok Shop User Showcase APIsnapchat / profileSnapchat Profile APIsnapchat / spotlightSnapchat Spotlight APIsnapchat / spotlight-commentsSnapchat Spotlight Comments APItwitch / profileTwitch Profile APItwitch / user-videosTwitch User Videos APIkwai / profileKwai Profile APIkwai / user-postsKwai User Posts APIkwai / postKwai Post APIamazon / best-sellersAmazon Best Sellers APIamazon / product-detailAmazon Product Details APIamazon / product-searchAmazon Product Search APIamazon / reviewsAmazon Reviews APIamazon / seller-infoAmazon Seller Info APIgoogle-play / app-detailGoogle Play App Detail APIgoogle-play / app-rankingsGoogle Play App Rankings APIgoogle-play / app-reviewsGoogle Play App Reviews APIapple-app-store / app-detailApple App Store App Detail APIapple-app-store / app-reviewsApple App Store App Reviews APIapple-app-store / rankingsApple App Store Rankings APItruth-social / profileTruth Social Profile APItruth-social / user-postsTruth Social User Posts APItruth-social / postTruth Social Post APIdouyin / live-room-detailDouyin Live Room Detail APIdouyin / user-profileDouyin User Profile APIdouyin / user-videosDouyin User Videos APIdouyin / video-commentsDouyin Video Comments APIdouyin / video-detailDouyin Video Detail APIdouyin / video-searchDouyin Video Search APIrednote / comment-repliesRednote Comment Replies APIrednote / home-recommendationsRednote Home Recommendations APIrednote / note-commentsRednote Note Comments APIrednote / note-detailRednote Note Detail APIrednote / search-notesRednote Search Notes APIrednote / search-usersRednote Search Users APIrednote / user-notesRednote User Notes APIrednote / user-profileRednote User Profile API

通过 YouTube 公开视频 URL 获取可用纯文本字幕,可指定偏好语言,并返回标准化文本、实际语言、字幕来源、频道信息和视频时长。

YouTube Transcripts API

字幕文本
纯文本
首选语言
每条结果 0.5 积分
等待提交
等待提交

填写参数并发送请求,任务状态和标准化结果会显示在这里。

README

YouTube Transcripts

YouTube Transcripts 是公开视频可用字幕的纯文本版本,包含语言、字幕来源、频道信息、发布时间和视频时长。这些文本可用于无障碍阅读、搜索、引用核对、主题分析、摘要和内容索引。

主要特性

  • 多视频字幕获取一个请求可以获取多个公开视频的可用字幕文本。
  • 首选语言选择使用 en 或 zh-CN 等有效 BCP-47 code 请求首选语言。
  • 可用语言信息同时返回实际选中的语言和可用字幕语言列表。
  • 纯文本字幕格式统一输出 plaintext,并在已知时返回字幕来源信息。
  • 可追溯的视频上下文每条字幕关联视频 ID、标题、频道信息、发布时间、时长和 collected_at。

参数

参数必填描述
urls必填公开 YouTube 视频 URL,多个值使用逗号或换行分隔。
language可选可选的首选 BCP-47 字幕语言,例如 en 或 zh-CN;实际返回语言可能不同。

如何使用

先筛出真正需要处理的视频,再请求字幕。文本进入搜索、RAG、摘要、翻译或合规流程前,务必确认实际返回语言与字幕来源。

  1. 选择公开视频 URL,最好先通过发现或详情审核排除无关内容。
  2. 向 /v1/youtube/transcripts POST urls 和可选 BCP-47 language,并保存 task_id。
  3. 轮询 /v1/tasks/{task_id};即使任务成功,结果数也可能少于提交 URL 数。
  4. 逐条检查 language、available_languages 与 transcript_source,再切分纯文本;has_more 为 true 时继续翻页。
curl -X POST "https://api.socq.ai/v1/youtube/transcripts" \
  -H "Authorization: Bearer $SOCQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"urls":["https://www.youtube.com/watch?v=arj7oStGLkU"],"language":"en"}'

# 轮询 GET /v1/tasks/{task_id}
# 读取 GET /v1/tasks/{task_id}?limit=50

最佳使用场景

  • 视频摘要 使用可用字幕文本为长视频生成摘要、研究笔记或内容简报。
  • 可搜索视频档案 把字幕文本与视频 ID、标题、频道信息和语言元数据一起建立索引。
  • 主题与信息提取 从指定公开视频集合中识别主题、实体、观点和关键词。
  • 翻译与本地化 根据实际语言和可用语言字段,把字幕文本分发到翻译流程。

使用建议

  • 下游分流必须使用返回的 language,而不是请求偏好;回退到其他可用轨道属于正常结果。
  • 自动生成字幕可能错误识别人名、标点和专业术语。保留 transcript_source,高风险内容必须对照原视频。
  • 成功任务结果较少通常表示部分视频没有可用公开字幕,不等于整个批次失败。
  • plaintext 不包含分段时间戳或说话人标签,不应从响应中编造精确引用时间或发言人。
  • 文本可以在下游切分,但每个片段都应保留视频 ID、语言、来源与 collected_at,确保引用可追溯。
  • 字幕需要进入可搜索目录时,可用 Videos 补齐标题、媒体与公开指标。
  • 如果业务必须精确覆盖某种语言,应先检查 available_languages,并把回退结果交给人工复核。

需要其他类型的 YouTube 公开数据时,可以使用以下 API。

探索其他平台

还可以将 YouTube 数据与其他已支持社交平台的公开数据结合使用。

YouTube Transcripts API常见问题