YouTube Video Thumbnail
Structured YouTube data: every input is optional. Cursor-paginated, 1 credit per successful call.
Overview
Section titled “Overview”Call GET /api/v2/youtube-video-thumbnail/. The results are in data.videos; send data.next_cursor back as cursor to get the next page. 8 optional parameters refine the call (see Parameters).
Request
Section titled “Request”curl -G "https://api.scrapier.io/api/v2/youtube-video-thumbnail/" \ -H "X-API-Key: YOUR_API_KEY" \ --max-time 210const params = new URLSearchParams({});
const res = await fetch(`https://api.scrapier.io/api/v2/youtube-video-thumbnail/?${params}`, { headers: { "X-API-Key": "YOUR_API_KEY" }, signal: AbortSignal.timeout(210_000),});const body = await res.json();if (!res.ok) throw new Error(body.error ?? body.detail ?? `HTTP ${res.status}`);
console.log(body.data.videos);import requests
resp = requests.get( "https://api.scrapier.io/api/v2/youtube-video-thumbnail/", headers={"X-API-Key": "YOUR_API_KEY"}, params={}, timeout=210,)body = resp.json()if not resp.ok: raise RuntimeError(body.get("error") or body.get("detail"))
print(body["data"]["videos"])curl -X POST "https://api.scrapier.io/api/v2/youtube-video-thumbnail/" \ -H "X-API-Key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{}' \ --max-time 210Parameters
Section titled “Parameters”| Name | Type | Required | Default | Description |
|---|---|---|---|---|
X-API-Key header | string | yes | — | Your API key from the dashboard. |
urls | string | no | https://www.youtube.com/watch?v=dQw4w9WgXcQ | VIDEO MODE: watch / youtu.be / shorts / embed URL or bare 11-char id. Single lookup (next_cursor always null, result under video). Required unless channel_url is given. |
channel_url | string | no | — | CHANNEL MODE: @handle, /channel/UC…, /c/… or /user/… URL. ~10 videos per page (newest first) under videos, paged through YouTube's own continuation token. Required first call; ignored when cursor is supplied. |
cursor | string | no | — | Pagination cursor returned in the previous response's next_cursor. Pass it back unchanged to fetch the next page. When next_cursor is null, you have reached the last page. |
channel_tab | string | no | videos | Channel mode: which listing to walk. videosshortsstreams locked in cursor |
start_date | string | no | — | Channel mode: only videos uploaded on/after (YYYY-MM-DD or ISO 8601). locked in cursor |
end_date | string | no | — | Channel mode: only videos uploaded on/before (YYYY-MM-DD or ISO 8601). locked in cursor |
verify_thumbnails | boolean | no | true | Probe every file on i.ytimg.com (real size / bytes / dropped). locked in cursor |
include_frames | boolean | no | true | Also return the auto-generated frame thumbnails (frame_items). locked in cursor |
Advanced
| Name | Type | Default | Description |
|---|---|---|---|
use_proxy | boolean | true | Route the request through Scrapier's residential proxy pool. Default: true. Leave as is unless support tells you otherwise. |
raw_data | boolean | false | When true, the response carries the full raw upstream payload(s) the scraper received (GraphQL / JSON API bodies, HTML, embedded JSON-LD -- exactly as the platform returned them) under raw_responses, in place of the formatted items. When false (default) you get the formatted output. Pagination (cursor / next_cursor) works the same in both modes. |
Response
Section titled “Response”{ "success": true, "data": { "mode": "channel", "channel_url": "@MrBeast", "channel_tab": "videos", "start_date": "2025-06-01T00:00:00Z", "end_date": null, "page": 1, "page_size": 10, "videos": [ { "input_channel": "@MrBeast", "position": 1, "mode": "channel", "video_id": "gTKS8SAwUzE", "status": "ok", "url": "https://www.youtube.com/watch?v=gTKS8SAwUzE", "title": "I Survived The Most Extreme Places On Earth", "channel_name": "MrBeast", "channel_id": "UCX6OQ3DkcsbYNE6H8uQQuVA", "published_at": "2026-09-05T09:00:01-07:00", "published_at_utc": "2026-09-05T16:00:01Z", "published_text": "Sep 5, 2026", "duration_seconds": 1452, "view_count": 98123456, "is_short": false, "thumbnail_count": 10, "dropped": 0, "largest": { "id": "maxres", "width": 1280, "height": 720, "format": "webp", "ratio": "16:9", "url": "https://i.ytimg.com/vi_webp/gTKS8SAwUzE/maxresdefault.webp", "name": "maxresdefault", "file": "maxresdefault.webp", "group": "standard", "frame": null, "aspect": 1.7778, "orientation": "landscape", "megapixels": 0.922, "aliases": [ "hq720.webp" ], "verified": true, "available": true, "status_code": 206, "bytes": 199522, "content_type": "image/webp", "actual_width": 1280, "actual_height": 720, "actual_ratio": "16:9", "matches_declared": true, "cache_max_age": 7200, "last_modified": null, "etag": "\"1757088000\"", "is_largest": true, "attempts": 1, "error": null }, "items": [ { "id": "default", "width": 120, "height": 90, "format": "webp", "ratio": "4:3", "url": "https://i.ytimg.com/vi_webp/gTKS8SAwUzE/default.webp", "name": "default", "file": "default.webp", "group": "standard", "frame": null, "aspect": 1.3333, "orientation": "landscape", "megapixels": 0.011, "aliases": [], "verified": true, "available": true, "status_code": 206, "bytes": 3120, "content_type": "image/webp", "actual_width": 120, "actual_height": 90, "actual_ratio": "4:3", "matches_declared": true, "cache_max_age": 7200, "last_modified": null, "etag": "\"1757088000\"", "is_largest": false, "attempts": 1, "error": null }, "... one entry per EXISTING standard size (default / medium / high / standard / maxres) in webp then jpg" ], "dropped_items": [], "extra_dropped_items": [], "largest_any": null, "original_aspect_items": [ "... oardefault / frame0 when they exist" ], "frame_items": [ "... auto-generated frames 1/2/3 at every size when include_frames=true" ], "summary": { "standard_candidates": 10, "standard_available": 10, "standard_dropped": 0, "extra_candidates": 3, "extra_available": 1, "extra_dropped": 2, "formats": [ "webp", "jpg" ], "sizes_available": [ "default", "medium", "high" ], "sizes_missing": [], "total_bytes": 612345, "verified": true, "has_maxres": true }, "video": { "id": "gTKS8SAwUzE", "url": "https://www.youtube.com/watch?v=gTKS8SAwUzE", "title": "I Survived The Most Extreme Places On Earth", "duration_text": "24:12", "published_at": "2026-09-05T09:00:01-07:00", "category": "Entertainment", "playability_status": "OK", "original_aspect_ratio": "16:9", "orientation": "landscape", "listing": { "title": "I Survived The Most Extreme Places On Earth", "published_text": "2 weeks ago", "views_text": "98M views", "view_count": 98000000, "duration_text": "24:12", "duration_seconds": 1452, "badges": [], "is_live": false, "is_upcoming": false, "thumbnails": [ { "url": "https://i.ytimg.com/vi/gTKS8SAwUzE/hqdefault.jpg?sqp=...", "width": 168, "height": 94 } ], "kind": "video" }, "...": "same video object as v1 (channel, keywords, storyboards, og_image, flags)" }, "channel": { "id": "UCX6OQ3DkcsbYNE6H8uQQuVA", "name": "MrBeast", "handle": "@MrBeast", "url": "https://www.youtube.com/channel/UCX6OQ3DkcsbYNE6H8uQQuVA", "handle_url": "https://www.youtube.com/@MrBeast", "description": "SUBSCRIBE FOR A COOKIE!", "subscriber_count_text": "517M subscribers", "subscriber_count": 517000000, "video_count_text": "1K videos", "video_count": 1000, "is_family_safe": true, "rss_url": "https://www.youtube.com/feeds/videos.xml?channel_id=UCX6OQ3DkcsbYNE6H8uQQuVA", "avatar": [ { "url": "https://yt3.googleusercontent.com/...=s900-c-k-c0x00ffffff-no-rj", "width": 900, "height": 900 } ], "banner": [ { "url": "https://yt3.googleusercontent.com/...", "width": 1060, "height": 175 } ], "tabs": [ "Home", "Videos", "Shorts" ] }, "source": { "mode": "channel", "input_channel": "@MrBeast", "channel_path": "/@MrBeast", "channel_tab": "videos", "resolved_url": "https://www.youtube.com/@MrBeast/videos?hl=en", "max_videos": null, "start_date": "2025-06-01T00:00:00Z", "end_date": null, "position": 1, "listing_page": 1 }, "attempts": 14, "processing_ms": 2310, "warnings": [], "scraped_at": "2026-09-19T08:12:04.512Z" } ], "next_cursor": "eyJsayI6eyJpbmNsdWRlX2ZyYW1lcyI6ImZhbHNlIiwic3RhcnRfZGF0ZSI6IjIwMjUtMDYtMDEifSwibSI6ImNoYW5uZWwiLCJvZmYiOjEwLCJwIjoxLCJwb3MiOjEwLCJxIjoiQE1yQmVhc3QiLCJzZWVuIjpbIi4uLiJdLCJ0b2siOm51bGx9" }}Bad input. The exact message varies by endpoint.
{ "success": false, "error": "…"}Balance below the endpoint’s price.
{ "error": "Insufficient credits. Buy more to scrape more.", "balance": 1, "required": 2}Invalid or unknown API key.
{ "detail": "Authentication service unavailable or invalid API key."}Throttled — wait for Retry-After.
{ "detail": "Request was throttled. Expected available in N seconds."}Sample from the live catalog; arrays trimmed to 3 items. Results are in data.videos.
Response fields
Section titled “Response fields”| Field | Type | Example | Description |
|---|---|---|---|
mode | string | channel | — |
channel_url | string | @MrBeast | — |
channel_tab | string | videos | — |
start_date | string | 2025-06-01T00:00:00Z | — |
end_date | null | null | — |
page | integer | 1 | — |
page_size | integer | 10 | — |
videos | array | [1 item] | The results. |
next_cursor | string | eyJsayI6eyJpbmNsdWRlX2ZyYW1lcyI6ImZhbHNlIiwic… | Pass back as cursor for the next page. null on the last page. |
videos[].input_channel | string | @MrBeast | — |
videos[].position | integer | 1 | — |
videos[].mode | string | channel | — |
videos[].video_id | string | gTKS8SAwUzE | — |
videos[].status | string | ok | — |
videos[].url | string | https://www.youtube.com/watch?v=gTKS8SAwUzE | — |
videos[].title | string | I Survived The Most Extreme Places On Earth | — |
videos[].channel_name | string | MrBeast | — |
videos[].channel_id | string | UCX6OQ3DkcsbYNE6H8uQQuVA | — |
videos[].published_at | string | 2026-09-05T09:00:01-07:00 | — |
videos[].published_at_utc | string | 2026-09-05T16:00:01Z | — |
videos[].published_text | string | Sep 5, 2026 | — |
videos[].duration_seconds | integer | 1452 | — |
videos[].view_count | integer | 98123456 | — |
videos[].is_short | boolean | false | — |
videos[].thumbnail_count | integer | 10 | — |
videos[].dropped | integer | 0 | — |
videos[].largest | object | {…} | — |
videos[].items | array | [2 items] | — |
videos[].dropped_items | array | [] | — |
videos[].extra_dropped_items | array | [] | — |
videos[].largest_any | null | null | — |
videos[].original_aspect_items | array | [1 item] | — |
videos[].frame_items | array | [1 item] | — |
videos[].summary | object | {…} | — |
videos[].video | object | {…} | — |
videos[].channel | object | {…} | — |
videos[].source | object | {…} | — |
videos[].attempts | integer | 14 | — |
videos[].processing_ms | integer | 2310 | — |
videos[].warnings | array | [] | — |
videos[].scraped_at | string | 2026-09-19T08:12:04.512Z | — |
Pagination
Section titled “Pagination”Pass data.next_cursor back as cursor until it is null. Required inputs are ignored once a cursor is sent. Each page is one billed call. More in Pagination.
const url = "https://api.scrapier.io/api/v2/youtube-video-thumbnail/";let params = {};const items = [];
for (let page = 0; page < 10; page++) { // each page is one billed call const res = await fetch(`${url}?${new URLSearchParams(params)}`, { headers: { "X-API-Key": "YOUR_API_KEY" }, signal: AbortSignal.timeout(210_000), }); const body = await res.json(); if (!res.ok) throw new Error(body.error ?? body.detail ?? `HTTP ${res.status}`); const data = body.data; items.push(...(data.videos ?? [])); if (!data.next_cursor) break; // null = last page params = { cursor: data.next_cursor };}import requests
URL = "https://api.scrapier.io/api/v2/youtube-video-thumbnail/"HEADERS = {"X-API-Key": "YOUR_API_KEY"}params = {}items = []
for _ in range(10): # each page is one billed call resp = requests.get(URL, headers=HEADERS, params=params, timeout=210) resp.raise_for_status() data = resp.json()["data"] items.extend(data.get("videos") or []) if not data.get("next_cursor"): # None = last page break params = {"cursor": data["next_cursor"]}Errors
Section titled “Errors”Failed calls are free. Branch on the HTTP status and read the message from error (or detail). Full details in Errors.
| Status | Meaning | Retry? | Charged? |
|---|---|---|---|
400 | Bad or missing input. | No — fix the params | No |
401 / 403 | Missing, invalid or revoked API key. | No — fix the key | No |
402 | Out of credits (body has balance). | No — top up | No |
404 | Unknown endpoint slug. | No — check the slug | No |
429 / 503 | Busy or throttled. | Yes — after Retry-After | No |
5xx | Target site or upstream failure, or timeout. | Yes — with backoff | No |
- Locked into the cursor:
channel_tab,start_date,end_date,verify_thumbnails,include_frames. Set them on the first call; later pages reuse them.
Related
Section titled “Related”- YouTube Channel Info — Structured YouTube data: send
urls. Single lookup, 1 credit per successful call. - YouTube Channel Live/Streams — Structured YouTube data: send
channels. Cursor-paginated, 1 credit per successful call. - YouTube Channel Video Scraper — Structured YouTube data: send
youtube_channels. Cursor-paginated, 1 credit per successful call. - YouTube Comment Replies — Structured YouTube data: send
continuation_tokens. Cursor-paginated, 1 credit per successful call.