get_video_frames
Extract video frames at specific timestamps to see what a YouTube video actually shows, solving the problem that transcripts miss visual details like clicks and dialog values.
Instructions
See what a video actually shows at chosen moments. Returns real images.
Transcripts cannot capture a screen-based tutorial. "Click this, then drag it here" has no referent in text, toolbar clicks are usually silent, typed dialog values are rarely spoken, and auto-captions mangle exactly the technical terms you need. Use this to look at the moments that matter.
The intended workflow is two steps, and doing it in this order is what keeps it cheap:
get_video_transcript(..., include_timestamps=True) to find WHICH moments matter, across as many videos as you like.
get_video_frames(video_id, timestamps=[...]) on just those moments.
The video-only stream is fetched to a temp file first, then every frame comes off it locally. That sounds expensive and is not: video-only means no audio track, so a 31 minute 720p tutorial is about 32 MB and lands in under 10 seconds, and further calls on the same video are instant because the file is kept for the life of the server process (3 videos max, deleted on exit). Asking for many timestamps in ONE call is therefore much cheaper than many calls, and vastly cheaper than one call per frame on different videos.
Args: video_url_or_id: An 11-character video ID or any YouTube video URL. timestamps: The moments to capture, as 'S', 'M:SS' or 'H:MM:SS' strings (e.g. ["4:12", "11:38", "1:02:05"]). Take these from a timestamped transcript. every_seconds: Instead of explicit timestamps, sample evenly this many seconds apart. Use only when surveying an unfamiliar video; explicit timestamps are far cheaper. Ignored if timestamps is given. max_frames: Hard cap on frames returned (1-20, default 6). Every frame costs context, so keep this tight. width: Output width in pixels (320-1920, default 1280). Do not go below about 960 if you need to read menu labels or dialog values. max_height: Source stream height to fetch (default 720, which is enough to read a CAD toolbar and keeps the fetch small). Raise to 1080 only if 720 proves too coarse. quality: JPEG quality, 2 is best and 31 is worst (default 4).
Returns: A list whose first item is a text summary (video title, duration, and the timestamp of each frame in order), followed by one image per timestamp. Frames that could not be captured are reported in the summary text rather than failing the whole call.
Errors: Raises ValueError for bad arguments or unparseable timestamps, and RuntimeError if ffmpeg is missing or the video has no playable stream.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| width | No | ||
| quality | No | ||
| max_frames | No | ||
| max_height | No | ||
| timestamps | No | ||
| every_seconds | No | ||
| video_url_or_id | Yes |