# YouTube Frame & Storyboard Extractor — Frames at Any Timestamp (`xyrelith-data/youtube-frame-storyboard-extractor`) Actor

Extract still frames from YouTube videos, Shorts, playlists and channels at exact timestamps, every N seconds, chapter starts or scene changes. Storyboard mode slices official preview sprites fast; full-resolution mode cuts frames with ffmpeg.

- **URL**: https://apify.com/xyrelith-data/youtube-frame-storyboard-extractor.md
- **Developed by:** [Xyrelith Data](https://apify.com/xyrelith-data) (community)
- **Categories:** Videos, Social media, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.49 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## YouTube Frame & Storyboard Extractor — Frames at Any Timestamp

Turn public YouTube videos into timestamped still images without a video editor, a screen recorder
or a frame-by-frame download. Pick a video, Shorts, playlist or channel, choose how frames are
selected, and get image links with the video title, channel, chapter, storyboard level and the
spoken caption line for every frame.

The actor is built for AI vision pipelines, research, thumbnail discovery, storyboard review and
content QA. It needs no cookies, no login and no API key.

### Why storyboard mode

YouTube stores a preview storyboard for most public videos: a grid of small frames generated across
the whole timeline. Storyboard mode slices that grid directly. A ten-minute video returns frames in
seconds, without downloading the video file, and the images are ready for LLM vision, contact sheets
or quick editorial review.

When you need a larger image, switch to full-resolution mode. The actor cuts the real video stream
at the requested timestamps and still returns chapter, transcript and thumbnail context.

### Frame selection modes

| Mode | What it returns |
|---|---|
| **Storyboard intervals** | One frame at every preview interval YouTube provides (usually every 2-10 seconds, depending on video length). The fastest way to sample a whole video. |
| **Exact timestamp list** | One frame at each time you supply: `83`, `1:23`, `01:02:03` or `1:23.5`. |
| **Every N seconds** | A regular grid of frames from the start of the video. |
| **N evenly spaced frames** | A fixed number of frames spread evenly across the duration. |
| **Scene changes** | Frames where the picture changes enough to be a new scene, with a scene score and a minimum gap between results. |
| **Chapter starts** | One frame at every chapter timestamp found in the video description. |

### Input

| Field | Type | Default | What it does |
|---|---|---|---|
| `videoUrls` | string list, required | – | Video, Shorts, embed, live, playlist or channel URLs, or bare video IDs. Playlists and channels expand to their most recent videos. |
| `mode` | select | `storyboard` | Frame selection mode: `storyboard`, `timestamps`, `everyNSeconds`, `evenlySpaced`, `sceneChanges` or `chapterStarts`. |
| `timestamps` | string list | – | Times for **Exact timestamp list** mode: `83`, `1:23`, `01:02:03` or `1:23.5`. |
| `intervalSeconds` | integer | `10` | Spacing for **Every N seconds** mode. |
| `frameCount` | integer | `10` | Number of frames for **N evenly spaced frames** mode. |
| `sceneThreshold` | integer | `28` | Sensitivity for **Scene changes** mode, from 1 (very sensitive) to 100 (hard cuts only). |
| `minSceneGapSeconds` | integer | `2` | Minimum distance between two scene frames. |
| `quality` | select | `storyboard` | `storyboard` for fast preview frames, `fullResolution` for real video frames cut with ffmpeg. |
| `storyboardLevel` | select | `auto` | `auto`, `low`, `medium`, `high` or `max`. Higher levels return larger preview cells. |
| `maxResolution` | select | `720` | Maximum height for full-resolution frames: 360p to 2160p or best available. |
| `imageFormat` | select | `jpg` | `jpg`, `png` or `webp`. |
| `imageQuality` | integer | `90` | Compression quality from 40 to 100 for JPEG/WebP. |
| `maxItems` | integer | `50` | Hard cap on the number of frames in the run. |
| `maxVideosPerSource` | integer | `10` | How many recent videos to take from each playlist or channel. |
| `includeTranscript` | boolean | `false` | Add the caption line spoken at each frame when a caption track exists. |
| `transcriptLanguage` | select | `en` | Preferred caption language. Falls back to another available track. |
| `includeAutoGeneratedCaptions` | boolean | `true` | Allow automatic speech-recognition captions when no human track exists. |
| `includeThumbnails` | boolean | `true` | Add every available official thumbnail size to each frame. |

### Output

Every dataset item is one frame. The record includes:

- **Video:** `videoId`, `videoUrl`, `videoTitle`, `channelName`, `channelId`, `channelUrl`,
  `durationSeconds`, `durationHms`, `publishedAt`, `publishedText`, `viewCount`, `likeCount`.
- **Frame:** `frameUrl` (key-value store link), `frameKey`, `frameFormat`, `frameWidth`,
  `frameHeight`, `quality`, `mode`.
- **Time:** `timestampSeconds`, `timestampMs`, `timestampHms`.
- **Storyboard:** `storyboardLevel`, `storyboardWidth`, `storyboardHeight`,
  `storyboardIntervalSeconds`, `frameIndex`.
- **Context:** `chapterTitle`, `chapterStartSeconds`, `chapterStartHms`, `transcriptText`,
  `transcriptStartSeconds`, `transcriptEndSeconds`, `transcriptLanguage`, `sceneScore`.
- **Thumbnails:** `officialThumbnails` with every available official size (`maxresdefault`,
  `sddefault`, `hq720`, `hqdefault`, `mqdefault`, `default` and the `hq1`-`hq3` auto frames),
  each with its real pixel width and height.
- **Meta:** `frameId`, `recordType`, `sourceUrl`, `scrapedAt`, plus `fallbackReason` when a
  full-resolution cut had to use a storyboard fallback.

Empty fields are omitted, never sent as `null`.

### Examples

Storyboard frames from one video:

```json
{
  "videoUrls": ["https://www.youtube.com/watch?v=aqz-KE-bpKQ"],
  "mode": "storyboard",
  "quality": "storyboard",
  "maxItems": 10
}
```

Exact timestamps with chapter and transcript context:

```json
{
  "videoUrls": ["https://www.youtube.com/watch?v=aircAruvnKk"],
  "mode": "timestamps",
  "timestamps": ["0:00", "1:07", "2:42", "5:31"],
  "includeTranscript": true,
  "transcriptLanguage": "en"
}
```

One frame at each chapter start:

```json
{
  "videoUrls": ["https://www.youtube.com/watch?v=aircAruvnKk"],
  "mode": "chapterStarts",
  "maxItems": 20
}
```

Full-resolution frames from a playlist, capped to the first five videos:

```json
{
  "videoUrls": ["https://www.youtube.com/playlist?list=PLFgquLnL59alCl_2TQvOiD5Vgm1hCaGSI"],
  "mode": "everyNSeconds",
  "intervalSeconds": 30,
  "quality": "fullResolution",
  "maxResolution": "720",
  "maxItems": 25,
  "maxVideosPerSource": 5
}
```

Scene-change frames for an AI storyboard:

```json
{
  "videoUrls": ["https://www.youtube.com/watch?v=aqz-KE-bpKQ"],
  "mode": "sceneChanges",
  "sceneThreshold": 25,
  "minSceneGapSeconds": 3,
  "maxItems": 15
}
```

### Use cases

- **AI vision and multimodal RAG:** attach a real frame and its timestamp to every transcript chunk.
- **Thumbnail and cover research:** compare official thumbnails with actual frames at key moments.
- **Storyboard and shot-list review:** sample a whole video in seconds and inspect scene boundaries.
- **Chapter and tutorial QA:** verify that each chapter starts with the promised visual.
- **Podcast and interview clips:** find the frame that matches a quote or a chapter title.
- **Channel monitoring:** run a channel URL and collect frames from its latest uploads.

### Frame delivery and retention

Frame images are saved to the run's Apify key-value store and each record contains a public
`frameUrl`. Key-value store retention follows the retention setting of the store on your Apify
account; copy or export the links you need for long-term storage. The dataset itself contains all
text fields and remains available according to your dataset retention settings.

### FAQ

**Do I need cookies, a login or an API key?**
No. The actor reads public video pages and official preview images without user credentials.
Private, members-only, age-restricted or region-blocked videos can fail and are reported in the run
status instead of producing fake rows.

**Do I have to download the video?**
No for storyboard mode. It slices YouTube's own preview storyboard. Full-resolution mode downloads
only the stream data needed for the requested timestamps.

**Why is a frame smaller than 1280x720?**
Storyboard frames are preview images: commonly 48x27, 80x45 or 160x90, and up to 320x180 when that
level is available. Choose full-resolution mode when you need the video's real pixel size.

**What happens for very short videos without a storyboard?**
The actor uses the three official auto-generated thumbnail frames (`hq1`-`hq3`) and marks them with
`quality: "thumbnailFallback"` and a `fallbackReason`.

**Can I use Shorts and playlists?**
Yes. Shorts are treated as normal videos; playlists and channels expand to their most recent videos,
limited by `maxVideosPerSource`.

**Why does a frame not land exactly on my timestamp?**
Storyboard frames are discrete. The actor picks the nearest storyboard frame at or before the
requested time (and reports the actual `timestampSeconds`). Use full-resolution mode for exact
video-frame timestamps.

**Can I get frames for a live stream?**
Live and upcoming streams do not have a completed preview storyboard. They are skipped with a clear
status message.

**Is the transcript always available?**
Only when the video has captions. `includeTranscript` adds the spoken line; without a matching track
the field is omitted and the status message says so.

**Can I get every official thumbnail?**
Yes, with `includeThumbnails: true` each frame carries every available official size plus its real
pixel dimensions.

# Actor input Schema

## `videoUrls` (type: `array`):

YouTube links or bare 11-character video IDs. Watch, youtu.be, Shorts, embed, live, playlist and channel URLs are accepted. Playlists and channels expand to their most recent videos.

## `mode` (type: `string`):

How timestamps are chosen. Storyboard mode samples every native preview interval; timestamps mode uses the exact times below.

## `timestamps` (type: `array`):

(mode=timestamps) Times such as 83, 1:23, 01:02:03 or 1:23.5. One frame is returned at each time.

## `intervalSeconds` (type: `integer`):

(mode=everyNSeconds) One frame every this many seconds.

## `frameCount` (type: `integer`):

(mode=evenlySpaced) How many frames to spread across each video.

## `sceneThreshold` (type: `integer`):

(mode=sceneChanges) Pixel-difference score from 1 (very sensitive) to 100 (only hard cuts).

## `minSceneGapSeconds` (type: `integer`):

(mode=sceneChanges) Do not return two scene frames closer than this many seconds.

## `quality` (type: `string`):

Storyboard slices official preview sprites without downloading the video. Full resolution cuts real video frames with ffmpeg and may fall back to a storyboard frame when a stream cannot be cut.

## `storyboardLevel` (type: `string`):

Preview sprite resolution. Auto uses the highest level available for the video; max prefers the 320x180 level when present.

## `maxResolution` (type: `string`):

(quality=fullResolution) Upper bound for the source video stream.

## `imageFormat` (type: `string`):

Format of the frame files saved to the key-value store.

## `imageQuality` (type: `integer`):

Compression quality for JPEG and WebP frames.

## `maxItems` (type: `integer`):

Hard cap on frames across all videos in the run.

## `maxVideosPerSource` (type: `integer`):

How many recent videos to expand from each playlist or channel URL.

## `includeTranscript` (type: `boolean`):

Add the caption line spoken at each frame when a caption track exists.

## `transcriptLanguage` (type: `string`):

Preferred caption language. Falls back to another available track when the exact language is missing.

## `includeAutoGeneratedCaptions` (type: `boolean`):

Use automatic speech-recognition tracks when a human caption track is unavailable.

## `includeThumbnails` (type: `boolean`):

Add every available official YouTube thumbnail size to each frame (maxres, sd, hq720, hq, mq, default and hq1-3).

## Actor input object example

```json
{
  "videoUrls": [
    "https://www.youtube.com/watch?v=aqz-KE-bpKQ"
  ],
  "mode": "storyboard",
  "intervalSeconds": 10,
  "frameCount": 10,
  "sceneThreshold": 28,
  "minSceneGapSeconds": 2,
  "quality": "storyboard",
  "storyboardLevel": "auto",
  "maxResolution": "720",
  "imageFormat": "jpg",
  "imageQuality": 90,
  "maxItems": 2,
  "maxVideosPerSource": 10,
  "includeTranscript": false,
  "transcriptLanguage": "en",
  "includeAutoGeneratedCaptions": false,
  "includeThumbnails": true
}
```

# Actor output Schema

## `frames` (type: `string`):

Dataset containing every extracted frame and its video, timestamp, chapter, transcript and thumbnail fields.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "videoUrls": [
        "https://www.youtube.com/watch?v=aqz-KE-bpKQ"
    ],
    "mode": "storyboard",
    "quality": "storyboard",
    "storyboardLevel": "auto",
    "imageFormat": "jpg",
    "maxItems": 2,
    "includeTranscript": false,
    "includeAutoGeneratedCaptions": false,
    "includeThumbnails": true
};

// Run the Actor and wait for it to finish
const run = await client.actor("xyrelith-data/youtube-frame-storyboard-extractor").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "videoUrls": ["https://www.youtube.com/watch?v=aqz-KE-bpKQ"],
    "mode": "storyboard",
    "quality": "storyboard",
    "storyboardLevel": "auto",
    "imageFormat": "jpg",
    "maxItems": 2,
    "includeTranscript": False,
    "includeAutoGeneratedCaptions": False,
    "includeThumbnails": True,
}

# Run the Actor and wait for it to finish
run = client.actor("xyrelith-data/youtube-frame-storyboard-extractor").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "videoUrls": [
    "https://www.youtube.com/watch?v=aqz-KE-bpKQ"
  ],
  "mode": "storyboard",
  "quality": "storyboard",
  "storyboardLevel": "auto",
  "imageFormat": "jpg",
  "maxItems": 2,
  "includeTranscript": false,
  "includeAutoGeneratedCaptions": false,
  "includeThumbnails": true
}' |
apify call xyrelith-data/youtube-frame-storyboard-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,xyrelith-data/youtube-frame-storyboard-extractor"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/Z8uYe4P9z5IZs8Z0v/builds/aj47NrGve06TfcWJm/openapi.json
