Scrape Videos
Create a new scrape job
Extract comprehensive details from a specific video by providing its URL. This endpoint returns all available metadata, including engagement metrics, captions (if available), user comments, and much more. It is ideal for in-depth content analysis and comment tracking.
Base URL
POST https://youtube-scraper-api.datashake.com/v1/scrape
Request payload
callback_url
Field type: string
Required: true
Description: A URL to receive API results via a JSON POST request.
url
Field type: string
Required: true
Description: URL of the YouTube video to scrape.
get_comments
Field type: boolean
Required: false
Description: Set this to true
to collect comments. Retrieve them using the comments endpoint after request completion.
external_identifier
Field type: string
Required: false
Description: A custom identifier for tracking your request. This value will be included in the callback payload.
Code example
curl --location 'https://youtube-scraper-api.datashake.com/v1/scrape' --header 'x-api-key: your-api-key' --header 'Content-Type: application/json' --request POST --data '{"url": "https://www.youtube.com/watch?v=1iqra1ojEvM", "callback_url": "https://example.com/callback", "external_identifier": "my-custom-id", "get_comments": true}'
import requests
url = "https://youtube-scraper-api.datashake.com/v1/scrape"
payload = {
"url": "https://www.youtube.com/watch?v=1iqra1ojEvM",
"callback_url": "https://example.com/callback",
"external_identifier": "my-custom-id",
"get_comments": true
}
headers = {
"x-api-key": "your-api-key",
}
response = requests.post(url=url, headers=headers, json=payload)
Response and callback payload
API response exmaple
{
"status": "created",
"message": "Your request was successfully submitted.",
"request_id": "1742515679047322765-7538bd54-2bd7-45"
}
Callback payload example
{
"request_id":"1743405732704235622-3e02dd3d-6b32-49",
"status":"completed",
"credits_used":1164,
"request_metadata": {
"url": "https://www.youtube.com/watch?v=1iqra1ojEvM"
"callback_url": "http://example.com/callback",
"external_identifier": "my-custom-id",
"get_comments": true
},
"results":[
{
"title":"Black Mirror: Season 7 | Official Trailer | Netflix",
"video_url":"https://www.youtube.com/watch?v=1iqra1ojEvM",
"video_id":"1iqra1ojEvM",
"thumbnail_url":null,
"channel_name":"Netflix",
"channel_id":"UCWOA1ZGywLbqmigxE4Qlvuw",
"channel_url":"https://www.youtube.com/@Netflix",
"description":"Lose your mind. Lose your reality. The Emmy Award winning series returns with six new stories. Nothing is as it seems.\n\nWatch on Netflix: https://www.netflix.com/title/81651202\n\nAbout Netflix:\nNetflix is one of the world's leading entertainment services, with 300 million paid memberships in over 190 countries enjoying TV series, films and games across a wide variety of genres and languages. Members can play, pause and resume watching as much as they want, anytime, anywhere, and can change their plans at any time.\n\nBlack Mirror: Season 7 | Official Trailer | Netflix\n / @netflix ",
"view_count":3255775,
"likes_count":95000,
"comments_count":5745,
"duration":"00:02:59",
"upload_date":"2025-03-13",
"hashtags":[],
"subscribers_count":30100000,
"captions":"We'd like to welcome you back.\n-Ready?\n-Yeah. Three, two…\nAnd action.\nThey call it mind-expanding.\nIt alters your neural structure.\nThe mind is a computer.\nSuddenly, you're not\njust more receptive.\nYou become a receiver.\nSometimes we have to do things\nthat we don't wanna do.\nI just want something magical,\ntimeless.\nCome with me.\nWe'll all be cyborgs before long.\nYeah.\nJust remember that they're AIs.\nTo them, this is real.\n-Ready?\n-I'm ready.\nKids love honey.\nThat's why parents love\nHoney Nugs.\nThe sweetest way to start your day.\nWe were getting quite a following.\nYes.\nWe have to create software\nthat elevates us.\nOr else what is the fucking point\nof the tools at our disposal?\nI've never seen anything like it.\nHumans consider artificial life\nto be somehow less than them.\n-Do you have a problem with me?\n-What?\nShe was just a bit odd.\nOdd?\nWe're all a bit odd.\nMy heart is pounding like a drum.\nI'd have listened.\n-And you'd have heard her?\n-Yes, I would!\nYou are a fucking miracle.\nIt's a game.\nWhat are most games about?\nEscapism?\nKilling.\nI don't like this game.\nI'm losing my mind.",
"created_at":"2025-04-07T10:08:06.515150Z",
"updated_at":"2025-04-07T10:08:06.515154Z"
}
],
"summary":null,
"pagination":null
}
Get scraping results
Use this endpoint to retrieve results in a synchronous manner.
Note that this endpoint is not intended for polling - make sure to check if your request has completed before calling it.
Base URL
GET https://youtube-scraper-api.datashake.com/v1/scrape/:request_id
Path parameters
request_id
Field type: string
Required: true
Description: The unique identifier for the request.
Code example
curl --location 'https://youtube-scraper-api.datashake.com/v1/scrape/1742517759478683074-2b1a61cf-89d0-4d' --header 'x-api-key: your-api-key'
import requests
url = "https://youtube-scraper-api.datashake.com/v1/scrape/1742517759478683074-2b1a61cf-89d0-4d"
headers = {
"x-api-key": "your-api-key",
}
response = requests.get(url=url, headers=headers)
Response
API response example
{
"request_id":"1743405732704235622-3e02dd3d-6b32-49",
"status":"completed",
"credits_used":1164,
"request_metadata": {
"url": "https://www.youtube.com/watch?v=1iqra1ojEvM"
"callback_url": "http://example.com/callback",
"external_identifier": "my-custom-id",
"get_comments": true
},
"results":[
{
"title":"Black Mirror: Season 7 | Official Trailer | Netflix",
"video_url":"https://www.youtube.com/watch?v=1iqra1ojEvM",
"video_id":"1iqra1ojEvM",
"thumbnail_url":null,
"channel_name":"Netflix",
"channel_id":"UCWOA1ZGywLbqmigxE4Qlvuw",
"channel_url":"https://www.youtube.com/@Netflix",
"description":"Lose your mind. Lose your reality. The Emmy Award winning series returns with six new stories. Nothing is as it seems.\n\nWatch on Netflix: https://www.netflix.com/title/81651202\n\nAbout Netflix:\nNetflix is one of the world's leading entertainment services, with 300 million paid memberships in over 190 countries enjoying TV series, films and games across a wide variety of genres and languages. Members can play, pause and resume watching as much as they want, anytime, anywhere, and can change their plans at any time.\n\nBlack Mirror: Season 7 | Official Trailer | Netflix\n / @netflix ",
"view_count":3255775,
"likes_count":95000,
"comments_count":5745,
"duration":"00:02:59",
"upload_date":"2025-03-13",
"hashtags":[],
"subscribers_count":30100000,
"captions":"We'd like to welcome you back.\n-Ready?\n-Yeah. Three, two…\nAnd action.\nThey call it mind-expanding.\nIt alters your neural structure.\nThe mind is a computer.\nSuddenly, you're not\njust more receptive.\nYou become a receiver.\nSometimes we have to do things\nthat we don't wanna do.\nI just want something magical,\ntimeless.\nCome with me.\nWe'll all be cyborgs before long.\nYeah.\nJust remember that they're AIs.\nTo them, this is real.\n-Ready?\n-I'm ready.\nKids love honey.\nThat's why parents love\nHoney Nugs.\nThe sweetest way to start your day.\nWe were getting quite a following.\nYes.\nWe have to create software\nthat elevates us.\nOr else what is the fucking point\nof the tools at our disposal?\nI've never seen anything like it.\nHumans consider artificial life\nto be somehow less than them.\n-Do you have a problem with me?\n-What?\nShe was just a bit odd.\nOdd?\nWe're all a bit odd.\nMy heart is pounding like a drum.\nI'd have listened.\n-And you'd have heard her?\n-Yes, I would!\nYou are a fucking miracle.\nIt's a game.\nWhat are most games about?\nEscapism?\nKilling.\nI don't like this game.\nI'm losing my mind.",
"created_at":"2025-04-07T10:08:06.515150Z",
"updated_at":"2025-04-07T10:08:06.515154Z"
}
],
"summary":null,
"pagination":null
}
API Response example
{
"results": [
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "lBsttFDJB2o",
"thumbnail_url": "https://i.ytimg.com/vi/lBsttFDJB2o/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLAyuc5Cxz-XZNFDvSLtj2n45cfzug",
"title": "George Ezra - Green Green Grass (Lyrics)",
"snippet": "George Ezra - ",
"channel_name": "The Vibe Guide",
"channel_url": "https://www.youtube.com/@thevibeguide",
"upload_date": "2023-03-21",
"duration": "00:02:49",
"view_count": 21238644,
"video_url": "https://www.youtube.com/watch?v=lBsttFDJB2o",
"verified": true
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "csZV3w_nscg",
"thumbnail_url": "https://i.ytimg.com/vi/csZV3w_nscg/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLDEhEwLceR_q-TtMaEuypeQ394MmQ",
"title": "The Best of Al Green - Greatest Hits (Full Album Stream) [30 Minutes]",
"snippet": "Official full stream of Al ",
"channel_name": "Al Green",
"channel_url": "https://www.youtube.com/channel/UCiE5dPVpnFpPl8ki4QjLH5Q",
"upload_date": "2017-03-21",
"duration": "00:35:26",
"view_count": 20167776,
"video_url": "https://www.youtube.com/watch?v=csZV3w_nscg",
"verified": false
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "F7KdQ8CTe5E",
"thumbnail_url": "https://i.ytimg.com/vi/F7KdQ8CTe5E/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLC7SNIRRNQ1FiTjjcGd8pq3o-__8w",
"title": "Morgan Wallen - Smile (Official Music Video)",
"snippet": "Pre-order Morgan Wallen's new album 'I'm The Problem', out May 16: https://morganwallen.lnk.to/imtheproblemalbum Listen to ...",
"channel_name": "Morgan Wallen",
"channel_url": "https://www.youtube.com/channel/UCzIyoPv6j1MAZpDHKLGP_eA",
"upload_date": "2025-01-20",
"duration": "00:05:18",
"view_count": 18670613,
"video_url": "https://www.youtube.com/watch?v=F7KdQ8CTe5E",
"verified": false
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "BF5I3Sp4XTg",
"thumbnail_url": "https://i.ytimg.com/vi/BF5I3Sp4XTg/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLBpKS7nFLdn_vmDFV79pBbbyQMJWw",
"title": "\"money money green green\" Kaytoven - MONEY! (Lyrics) Good Loyal Thots Remix",
"snippet": "\"money money ",
"channel_name": "The Vibe Guide",
"channel_url": "https://www.youtube.com/@thevibeguide",
"upload_date": "2024-04-21",
"duration": "00:01:21",
"view_count": 18692582,
"video_url": "https://www.youtube.com/watch?v=BF5I3Sp4XTg",
"verified": true
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "eY1BkifJBOU",
"thumbnail_url": "https://i.ytimg.com/vi/eY1BkifJBOU/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLB43zAqomu3KNdBVKkwrk388At6LA",
"title": "DANGARO TALIA RANI || MUSIC VIDEO | POOJA , UTKAL | GREEN MUSIC ENTERTAINMENT",
"snippet": "Song : Dangaro Talia Rani Video Artist : Utkal,Pooja Singer : Shiva mukhi & Ashima Panda ",
"channel_name": "Green music and entertainment",
"channel_url": "https://www.youtube.com/@Greenmusicandentertainment",
"upload_date": "2020-03-21",
"duration": "00:07:10",
"view_count": 17895282,
"video_url": "https://www.youtube.com/watch?v=eY1BkifJBOU",
"verified": false
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "hXmFgsVvV5M",
"thumbnail_url": "https://i.ytimg.com/vi/hXmFgsVvV5M/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLBX4NB7r5XATml0_9zm7XSXqAwHkA",
"title": "Deep Sleep | Third Eye Chakra | 432Hz | Binaural Beats | Black Screen",
"snippet": "We can unlock the flow state within us when we align ourselves with Phi. Through sympathetic resonance and our Phi Balance ...",
"channel_name": "Phi Tribe",
"channel_url": "https://www.youtube.com/@PhiTribe",
"upload_date": "2023-03-21",
"duration": "08:00:26",
"view_count": 17758055,
"video_url": "https://www.youtube.com/watch?v=hXmFgsVvV5M",
"verified": false
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "3SXHxJzS-Lg",
"thumbnail_url": "https://i.ytimg.com/vi/3SXHxJzS-Lg/hq720_2.jpg?sqp=-oaymwFBCNAFEJQDSFryq4qpAzMIARUAAIhCGADYAQHiAQoIGBACGAY4AUAB8AEB-AG2CIACuAiKAgwIABABGB8gZShVMA8=&rs=AOn4CLAidbfgUeD3FwVUFjEmykOozkUwsA",
"title": "Squid Game Edit | Red Light Green Light | Sleepwalker | #squidgame #squidgameseason2 #edit #viral",
"snippet": "SquidGame, SquidGameSeason2, SquidGameChallenge, Netflix, Edit, Edits, Viral, Trending, Shorts, ShortsFeed, Sleepwalker, ...",
"channel_name": "𝐁𝐥𝐱𝐤𝐞",
"channel_url": "https://www.youtube.com/@BlxkeEditss",
"upload_date": "2024-05-21",
"duration": "00:00:28",
"view_count": 12458832,
"video_url": "https://www.youtube.com/watch?v=3SXHxJzS-Lg",
"verified": false
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "Fdrrrym4ZB8",
"thumbnail_url": "https://i.ytimg.com/vi/Fdrrrym4ZB8/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLDtE4qJkMv17RrSAN6gg0c0tGNMOA",
"title": "Vivian Green - Get Right Back To My Baby (Official Music Video)",
"snippet": "Download “Get Right Back To My Baby” iTunes: http://smarturl.it/VGRighBack_iTunes Amazon Mp3: ...",
"channel_name": "VivianGreenVEVO",
"channel_url": "https://www.youtube.com/@VivianGreenVEVO",
"upload_date": "2016-03-21",
"duration": "00:04:03",
"view_count": 10037548,
"video_url": "https://www.youtube.com/watch?v=Fdrrrym4ZB8",
"verified": true
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "xTzpFvl0F7Y",
"thumbnail_url": "https://i.ytimg.com/vi/xTzpFvl0F7Y/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLBnjEStfx0i7ILUtSS-CY7mdRIKug",
"title": "LIL TAY - SUCKER 4 GREEN (MONEY) (Official Music Video)",
"snippet": "Listen to SUCKER 4 ",
"channel_name": "LIL TAY",
"channel_url": "https://www.youtube.com/channel/UCdFjlnv-TEz-hMmnDzsAXig",
"upload_date": "2024-03-21",
"duration": "00:03:35",
"view_count": 8897612,
"video_url": "https://www.youtube.com/watch?v=xTzpFvl0F7Y",
"verified": false
},
{
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"video_id": "orBcmzwprr8",
"thumbnail_url": "https://i.ytimg.com/vi/orBcmzwprr8/hq720.jpg?sqp=-oaymwEnCNAFEJQDSFryq4qpAxkIARUAAIhCGAHYAQHiAQoIGBACGAY4AUAB&rs=AOn4CLADBz79UWLsrX4Q_ivM0DOAqws_qg",
"title": "Green Noise, Black Screen 🟢⬛ • 12 hours • No ads",
"snippet": "Green",
"channel_name": "DJ Grossman",
"channel_url": "https://www.youtube.com/channel/UCQPzVxdgmiNeYjzMFQpPhdQ",
"upload_date": "2022-03-21",
"duration": "12:00:00",
"view_count": 8675081,
"video_url": "https://www.youtube.com/watch?v=orBcmzwprr8",
"verified": false
}
],
"summary": {
"request_id": "1742546457946506999-897b27cc-acd7-4a",
"total_videos": 100,
"total_views": 3511306556,
"average_views_per_video": 35113065.0,
"unique_channels_count": 63,
"created_at": "2025-03-21T08:41:08.520064Z"
},
"pagination": {
"total": 100,
"page": 1,
"per_page": 10,
"total_pages": 10
}
}