{
"ok": true,
"data": {
"id": "_T8cn2J13-4",
"url": "https://www.youtube.com/watch?v=_T8cn2J13-4",
"title": "How We Are Going to the Moon - 4K",
"description": "While Apollo placed the first steps on the Moon, Artemis opens the door for humanity to sustainably work and live on another world...",
"publishedAt": "2019-12-19T17:43:14.000Z",
"durationSeconds": 331,
"duration": "00:05:31",
"viewCount": 11863645,
"likeCount": 480000,
"commentCount": 43988,
"commentsTurnedOff": false,
"tags": [
"NASA",
"Moon",
"Artemis"
],
"hashtags": [],
"category": "Science & Technology",
"thumbnail": "https://i.ytimg.com/vi/_T8cn2J13-4/maxresdefault.jpg",
"videoType": "video",
"isShort": false,
"isLive": false,
"liveStatus": "none",
"isMembersOnly": false,
"isAgeRestricted": false,
"isUnlisted": false,
"isFamilySafe": true,
"hasPaidPromotion": false,
"descriptionLinks": [],
"chapters": [],
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelName": "NASA",
"channelHandle": "@NASA",
"channelUrl": "https://www.youtube.com/@NASA",
"channelSubscriberCount": 15100000,
"channelIsVerified": true,
"scrapedAt": "2026-11-15T04:30:12.512Z"
},
"next_cursor": null
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39867/get+video+details?url=https://www.youtube.com/watch?v=_T8cn2J13-4' --header 'Authorization: Bearer YOUR_API_KEY'
{
"ok": true,
"data": {
"videoId": "_T8cn2J13-4",
"url": "https://www.youtube.com/watch?v=_T8cn2J13-4",
"title": "How We Are Going to the Moon - 4K",
"channelName": "NASA",
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelUrl": "https://www.youtube.com/@NASA",
"publishedAt": "2019-12-19T17:43:14.000Z",
"durationSeconds": 331,
"viewCount": 11863645,
"category": "Science & Technology",
"language": "en",
"languageName": "English",
"isAutoGenerated": false,
"wordCount": 873,
"availableLanguages": [
{
"language": "en",
"languageName": "English",
"isAutoGenerated": false
},
{
"language": "en",
"languageName": "English",
"isAutoGenerated": true
}
],
"thumbnailUrl": "https://i.ytimg.com/vi/_T8cn2J13-4/maxresdefault.jpg",
"keywords": [
"NASA",
"Moon",
"Artemis"
],
"description": "While Apollo placed the first steps on the Moon, Artemis opens the door...",
"fullText": "Between 1968 and 1972, America launched 9 human missions to the Moon, 6 of which successfully touched down...",
"segments": [
{
"start": 1.31,
"duration": 7.39,
"text": "Between 1968 and 1972, America launched 9 human missions to the Moon, 6 of which successfully"
},
{
"start": 8.7,
"duration": 4.2,
"text": "touched down",
"allowing 12 men to walk on the lunar surface.": null
}
],
"scrapedAt": "2026-11-15T04:30:13.101Z"
},
"next_cursor": null
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39868/get+video+transcript?url=https://www.youtube.com/watch?v=_T8cn2J13-4&lang=en&format=text' --header 'Authorization: Bearer YOUR_API_KEY'
{
"ok": true,
"data": {
"query": "nasa artemis",
"estimatedResults": 3510030,
"items": [
{
"type": "video",
"id": "_T8cn2J13-4",
"url": "https://www.youtube.com/watch?v=_T8cn2J13-4",
"title": "How We Are Going to the Moon - 4K",
"description": "While Apollo placed the first steps on the Moon, Artemis opens the door for humanity...",
"durationSeconds": 331,
"duration": "00:05:31",
"viewCount": 11863614,
"publishedTimeText": "6 years ago",
"publishedAt": "2020-11-15T00:00:00.000Z",
"thumbnail": "https://i.ytimg.com/vi/_T8cn2J13-4/hq720.jpg",
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelName": "NASA",
"channelHandle": "@NASA",
"channelUrl": "https://www.youtube.com/@NASA",
"channelIsVerified": true,
"isLive": false,
"isUpcoming": false,
"badges": [
"4K",
"CC"
],
"position": 1
}
]
},
"next_cursor": "eyJrIjoic2VhcmNoIiwicSI6Im5hc2EgYXJ0ZW1pcyIsImMiOiJFdU1DRWd4dVlYTmhJR0Z5ZEdWdGFYTWEw..."
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39869/search+youtube?q=drone footage&type=all&upload_date=any&duration=any&sort=relevance&features=hd,subtitles' --header 'Authorization: Bearer YOUR_API_KEY'
{
"ok": true,
"data": {
"id": "UCLA_DiR1FfKNvjuUpBHmylQ",
"url": "https://www.youtube.com/@NASA",
"name": "NASA",
"handle": "@NASA",
"description": "NASA's mission is to pioneer the future in space exploration, scientific discovery, and aeronautics research...",
"subscriberCount": 15100000,
"videoCount": 6202,
"viewCount": 1135840911,
"joinedAt": "2008-06-03",
"country": null,
"links": [
{
"title": "Website",
"url": "https://www.nasa.gov/"
}
],
"keywords": [
"NASA",
"space",
"astronomy"
],
"avatar": "https://yt3.googleusercontent.com/nasa-avatar=s900",
"banner": "https://yt3.googleusercontent.com/nasa-banner=w2560",
"isVerified": true,
"isFamilySafe": true,
"scrapedAt": "2026-11-15T04:30:14.227Z"
},
"next_cursor": null
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39870/get+channel+details?handle_or_url=@NASA' --header 'Authorization: Bearer YOUR_API_KEY'
{
"ok": true,
"data": {
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelName": "NASA",
"tab": "videos",
"sort": "popular",
"items": [
{
"type": "video",
"id": "EJxwWpaGoJs",
"url": "https://www.youtube.com/watch?v=EJxwWpaGoJs",
"title": "The Year of Pluto - New Horizons Documentary Brings Humanity Closer to the Edge of the Solar System",
"description": null,
"durationSeconds": 3514,
"duration": "00:58:34",
"viewCount": 21000000,
"publishedTimeText": "11 years ago",
"publishedAt": "2015-11-15T00:00:00.000Z",
"thumbnail": "https://i.ytimg.com/vi/EJxwWpaGoJs/hq720.jpg",
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelName": "NASA",
"channelHandle": "@NASA",
"channelUrl": "https://www.youtube.com/@NASA",
"channelIsVerified": null,
"isLive": false,
"isUpcoming": false,
"badges": [],
"position": 1
}
]
},
"next_cursor": "eyJrIjoiY2hhbm5lbC12aWRlb3MiLCJjaCI6IlVDTEFfRGlSMUZmS052anVVcEJIbXlsUSIs..."
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39871/get+channel+videos?handle_or_url=@NASA&tab=videos&sort=newest' --header 'Authorization: Bearer YOUR_API_KEY'
{
"ok": true,
"data": {
"videoId": "_T8cn2J13-4",
"commentCount": 43988,
"commentsTurnedOff": false,
"sort": "top",
"items": [
{
"id": "UgzExampleComment0AaABAg",
"text": "Can't wait to see people walk on the Moon again!",
"author": "@spacefan",
"authorChannelId": "UCxxxxxxxxxxxxxxxxxxxxxx",
"authorChannelUrl": "https://www.youtube.com/channel/UCxxxxxxxxxxxxxxxxxxxxxx",
"authorIsChannelOwner": false,
"authorIsVerified": false,
"likeCount": 1200,
"replyCount": 14,
"publishedAt": "2020-11-15T00:00:00.000Z",
"publishedTimeText": "6 years ago",
"isEdited": false,
"isPinned": false,
"hasCreatorHeart": false
}
]
},
"next_cursor": "eyJrIjoiY29tbWVudHMiLCJpZCI6Il9UOGNuMkoxMy00IiwicyI6InRvcCIsImMiOiJFZzBTQzE5VU9HTnVN..."
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39872/get+video+comments?url=_T8cn2J13-4&sort=top' --header 'Authorization: Bearer YOUR_API_KEY'
{
"ok": true,
"data": {
"playlistId": "PL2aBZuCeDwlQvNtHhNJtarm9OewQwVntv",
"url": "https://www.youtube.com/playlist?list=PL2aBZuCeDwlQvNtHhNJtarm9OewQwVntv",
"title": "Artemis II Mission Coverage",
"description": null,
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelName": "NASA",
"videoCount": 23,
"viewCount": 1049387,
"isUnlisted": false,
"items": [
{
"type": "video",
"id": "DYY4nnfxKbU",
"url": "https://www.youtube.com/watch?v=DYY4nnfxKbU",
"title": "NASA's Artemis II Crew Return to Houston",
"description": null,
"durationSeconds": 4860,
"duration": "01:21:00",
"viewCount": 1700000,
"publishedTimeText": "Streamed 7 months ago",
"publishedAt": "2026-04-15T00:00:00.000Z",
"thumbnail": "https://i.ytimg.com/vi/DYY4nnfxKbU/hqdefault.jpg",
"channelId": "UCLA_DiR1FfKNvjuUpBHmylQ",
"channelName": "NASA",
"channelHandle": "@NASA",
"channelUrl": "https://www.youtube.com/@NASA",
"channelIsVerified": null,
"isLive": false,
"isUpcoming": false,
"badges": [],
"position": 1
}
]
},
"next_cursor": null
}
curl --location --request GET 'https://zylalabs.com/api/15060/youtube+playlists+api/39873/get+playlist+videos?url=https://www.youtube.com/playlist?list=PL2aBZuCeDwlQvNtHhNJtarm9OewQwVntv' --header 'Authorization: Bearer YOUR_API_KEY'
注册后,每个开发者都会被分配一个个人 API 访问密钥,这是一个唯一的字母和数字组合,用于访问我们的 API 端点。要使用 YouTube Playlists API 进行身份验证,只需在 Authorization 标头中包含您的 bearer token。
| 标头 | 描述 |
|---|---|
授权
|
必需
应为 Bearer access_key. 订阅后,请查看上方的"您的 API 访问密钥"。
|
YouTube data in real time as JSON: video details, transcripts in any caption language, search results, channels, channel uploads and Shorts, comments and playlists.
任何视频包含的字幕语言,包括自动生成的字幕 请求语言代码或获取默认音轨
列表端点返回 next_cursor 将其作为游标参数传递以获取下一页直到 next_cursor 为 null
视频链接或ID用于视频和成绩单,频道链接、句柄或ID用于频道,播放列表链接或ID用于播放列表,自由文本用于搜索
转录端点返回一个错误代码,表示没有可用的转录,而不是数据
每个端点以JSON格式返回特定的YouTube数据例如“获取视频详细信息”端点提供视频元数据而“获取视频字幕”返回字幕其他端点如“搜索YouTube”返回搜索结果而“获取频道详细信息”提供关于频道的信息
关键字段因端点而异。在“获取视频详情”中,重要字段包括标题、观看次数和时长。在“获取频道详情”中,订阅者数量和描述等字段至关重要。每个端点的文档都列出了其特定字段
参数因端点而异。对于“搜索 YouTube”,您可以按结果类型、上传日期和持续时间筛选。“获取视频成绩单”端点接受语言代码。有关接受的参数的完整列表,请参阅每个端点的文档
响应数据采用JSON格式结构,包含“ok”状态和“data”对象。“data”对象包含特定于端点的相关字段,如视频详情或搜索结果,便于解析和使用
每个端点提供不同的信息:“获取视频详情”提供关于视频的元数据,“获取视频评论”列出用户评论,“获取播放列表视频”详细说明播放列表中的视频。这种多样性允许全面的数据检索
用户可以通过使用特定的参数自定义请求。例如,在“获取频道视频”中,您可以按受欢迎程度或年代排序。在“搜索 YouTube”中,您可以指定持续时间和上传日期等过滤器以优化结果
典型的用例包括分析视频表现、获取可访问性的转录文本以及汇总评论进行情感分析。开发人员可以将这些数据用于内容策划或教育工具等应用程序
通过直接访问YouTube的API来保持数据准确性,该API提供实时更新。该API反映了YouTube上可用的最新信息,确保用户获得当前和可靠的数据