# YouTube Video Metadata & Thumbnail Extractor (`quanmatrix/youtube-video-metadata-extractor`) Actor

Use this Actor to extract youtube video metadata and thumbnail into clean structured results for automation and AI workflows. Extract clean YouTube video titles, channel names, thumbnails and normalized URLs from public video links without API keys or quota setup. One structured result per URL with

- **URL**: https://apify.com/quanmatrix/youtube-video-metadata-extractor.md
- **Developed by:** [Rafael Barreto Haddad](https://apify.com/quanmatrix) (community)
- **Categories:** Social media, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.43 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
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 Video Metadata & Thumbnail Extractor

Use this Actor to extract youtube video metadata and thumbnail into clean structured results for automation and AI workflows. It is designed for repeatable human, API, Apify AI, and MCP-driven workflows.

Extract clean, automation-ready metadata from public YouTube video URLs without creating a YouTube Data API project, managing API keys, or dealing with quota configuration.

This Actor is intentionally focused: give it YouTube video URLs and receive one predictable dataset item per input URL with normalized identifiers, title, channel/author information, thumbnail URL, provider metadata, and explicit success or error status.

### Why use this Actor

Use it when you need lightweight YouTube enrichment rather than a large scraping stack. It is designed for workflows where predictable output, minimal setup, low per-result cost, and explicit failures matter more than collecting every possible YouTube metric.

Unlike workflows that require Google Cloud credentials and YouTube Data API quota management, this Actor uses public YouTube oEmbed metadata for supported public videos. No external API key is required.

### Key features

- No YouTube Data API key required
- No Google Cloud project or quota configuration
- Accepts standard `youtube.com/watch` and `youtu.be` video URLs
- Normalizes the video URL and extracts the video ID
- Returns video title and channel/author name
- Returns the public thumbnail URL
- Includes provider metadata when available
- Produces one dataset item per input URL
- Returns an explicit `ok` status and error information instead of silently dropping failed inputs
- Processes up to 200 input URLs per run
- Structured JSON output for pipelines, catalogs, spreadsheets, databases, and automation tools

### Input

Provide an array of public YouTube video URLs.

```json
{
  "urls": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "https://youtu.be/aqz-KE-bpKQ"
  ],
  "max_videos": 50
}
```

`max_videos` can be set from 1 to 200.

### Output

Each input URL produces a dataset record. Successful records include fields such as:

- `input`
- `video_url`
- `video_id`
- `ok`
- `title`
- `author_name`
- `thumbnail_url`
- `provider_name`

Failed or unsupported inputs are represented explicitly so downstream workflows can distinguish a real failure from an empty result.

### Example

A successful result can be used directly for video catalogs, CMS enrichment, editorial databases, thumbnail inventories, monitoring lists, or other automated workflows without additional parsing of a YouTube page.

The Actor keeps the output deliberately compact and predictable so it is easy to map into Zapier, Make, n8n, spreadsheets, databases, or custom applications.

### Use cases

- Enrich a catalog of YouTube URLs with titles and thumbnails
- Build editorial or research inventories
- Normalize mixed YouTube URL formats
- Populate CMS or database records
- Validate public video links in automated workflows
- Collect thumbnail references for media-management pipelines
- Add channel/author metadata to existing URL lists

### Pricing

Pay per result. The configured price is **$0.0005 per dataset item**, equivalent to **$0.50 per 1,000 processed results** before any plan-specific platform considerations.

One input URL produces one result record, including explicit error records when an input cannot be enriched.

### Limitations

This Actor is not intended to replace the full YouTube Data API. It focuses on lightweight public oEmbed metadata and does not promise private data, authenticated content, view counts, likes, comments, transcripts, tags, or other fields that are not exposed by the public metadata source.

Private, deleted, restricted, unavailable, or unsupported videos may return an error result. The Actor does not bypass authentication, access controls, or platform restrictions.

### Responsible use

Use the Actor only with public URLs and in accordance with applicable laws, platform terms, and your own data-handling requirements.

# Changelog

This Actor's version history is a separate document: https://apify.com/quanmatrix/youtube-video-metadata-extractor/changelog.md

# Actor input Schema

## `urls` (type: `array`):

Public YouTube video URLs to enrich.

## `max_videos` (type: `integer`):

Maximum number of input URLs processed in one run.

## `previousSnapshot` (type: `array`):

Optional previous output rows used to detect title, thumbnail or channel changes.

## `previousAnalysis` (type: `object`):

Optional prior Gen2 output used to calculate decision-metric deltas and regression.

## `valuePerImpactUnitUsd` (type: `number`):

Optional user-supplied economic value per impact unit. Leave empty to avoid monetary estimation.

## `monthlyRuns` (type: `integer`):

Optional expected monthly run count used only with valuePerImpactUnitUsd for economic impact estimation.

## `mcpConnectors` (type: `array`):

Optional MCP connectors authorized in your Apify account. Use them to send or write this Actor result to tools such as Slack, Notion, GitHub, Sentry, Supabase, or another compatible MCP service.

## `mcpToolName` (type: `string`):

Optional exact MCP tool name. Leave blank to let the selected MCP action preset discover a compatible tool automatically.

## `mcpToolArguments` (type: `object`):

JSON object passed to the selected MCP tool. String values may use {{actor\_title}}, {{result\_summary}}, or {{result\_json}} placeholders.

## `mcpFailOnError` (type: `boolean`):

When enabled, an MCP delivery error fails the Actor run. Disabled by default so data extraction and intelligence results remain available even if the external destination is unavailable.

## `mcpActionPreset` (type: `string`):

Choose a safe action pattern. AUTO\_SAFE\_WRITE discovers a compatible non-destructive write tool automatically; use a specific preset for Slack, GitHub, Notion, or database delivery.

## Actor input object example

```json
{
  "urls": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
  ],
  "max_videos": 50,
  "monthlyRuns": 1,
  "mcpToolName": "",
  "mcpToolArguments": {},
  "mcpFailOnError": false,
  "mcpActionPreset": "AUTO_SAFE_WRITE"
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("quanmatrix/youtube-video-metadata-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 = {}

# Run the Actor and wait for it to finish
run = client.actor("quanmatrix/youtube-video-metadata-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 '{}' |
apify call quanmatrix/youtube-video-metadata-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,quanmatrix/youtube-video-metadata-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/v3NDBnmgF5xAkqUc8/builds/gusJbxdw26RLHqXFt/openapi.json
