# YouTube Channel Playlists Scraper (`googleapi/youtube-channel-playlists-scraper`) Actor

Collect source-backed public YouTube playlists with channel context, displayed totals, and structured member-video details.

- **URL**: https://apify.com/googleapi/youtube-channel-playlists-scraper.md
- **Developed by:** [Google API](https://apify.com/googleapi) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.99 / 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.

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

### What this Actor does

YouTube Channel Playlists Scraper collects public playlists shown on a channel's Playlists tab or on a public playlist page. Each row represents a playlist and can include playlist details, channel context, and member-video information.

### Input

Provide a public channel Playlists URL or a direct playlist URL with `startUrls` or `url`. You can also use `queries` (or one `query`) when public YouTube search results expose playlist cards. `maxItems` limits playlist rows, and `deduplicate` removes repeated playlist IDs.

```json
{"startUrls":[{"url":"https://www.youtube.com/@YouTubeMusic/playlists"}],"maxItems":25}
```

Set `includePlaylistDetails` to `true` to read each playlist's public page for its description, displayed totals, and member videos. This option is off by default. `includeMedia` controls public channel, playlist, and video thumbnail URLs.

```json
{"url":"https://www.youtube.com/playlist?list=PLexample123","includePlaylistDetails":true,"includeMedia":true}
```

See the Input tab for URL aliases, supported settings, and run limits. This Actor reads one public playlist surface per source.

### Dataset output

Each record includes playlist identity (`playlistId`, `playlistName`, `playlistUrl`), owner information, playlist description, displayed video and view totals, update text, thumbnail URL, and available channel profile details.

With playlist details enabled, `playlistVideos` can contain member video IDs, titles, URLs, channel names, displayed view counts, publication labels, durations, thumbnails, and badges. `videoIds` provides a flat list of exposed member IDs.

```json
{
  "playlistId": "PLexample123",
  "playlistName": "Example Playlist",
  "playlistUrl": "https://www.youtube.com/playlist?list=PLexample123",
  "playlistOwnerName": "Example Channel",
  "playlistVideoCount": 4,
  "playlistVideoCountText": "4 videos",
  "playlistViewCountText": "825 views",
  "playlistVideos": [
    {
      "videoId": "dQw4w9WgXcQ",
      "title": "Example video",
      "videoUrl": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
      "publishedAtText": "2 weeks ago",
      "durationText": "2:46"
    }
  ],
  "videoIds": ["dQw4w9WgXcQ"],
  "videosSampled": 1
}
```

Compact counts may be estimates; the original displayed labels are retained. Relative publication labels remain text rather than being converted into exact dates. If YouTube does not expose member details, `playlistVideos` may be empty.

Dataset results can be downloaded in JSON, CSV, Excel, or another format supported by Apify. The run page also provides result totals and source status.

### Coverage and responsible use

Results reflect public pages available at run time and may vary by channel, locale, or playlist. The Actor does not sign in or access private playlists. Follow YouTube's terms and applicable laws when using the data.

# Actor input Schema

## `startUrls` (type: `array`):

Primary public YouTube channel, playlist, or search URLs. Object form is recommended in the Apify UI.

## `sourceUrls` (type: `array`):

Compatibility alias for an array of public HTTPS YouTube URLs.

## `channelUrls` (type: `array`):

Compatibility alias for public YouTube channel, playlist, or search URLs.

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

Compatibility alias for an array of public YouTube URLs.

## `url` (type: `string`):

Compatibility alias for one public YouTube URL.

## `channelUrl` (type: `string`):

Compatibility alias for one public YouTube channel, playlist, or search URL.

## `queries` (type: `array`):

Optional public YouTube search queries. Playlist rows are returned only when the search page exposes playlist renderers.

## `query` (type: `string`):

Compatibility alias for one search query.

## `searchQuery` (type: `string`):

Compatibility alias for one search query.

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

Global maximum of normal playlist records across all source pages. Default: 25.

## `maxPages` (type: `integer`):

This Actor reads one public playlist surface per source; only 1 is accepted.

## `deduplicate` (type: `boolean`):

Remove repeated playlists across source URLs using playlist ID.

## `includePlaylistDetails` (type: `boolean`):

Fetch one public YouTube playlist page per emitted playlist, with DNS and redirect validation and an 8-second timeout. Disabled by default.

## `includeMedia` (type: `boolean`):

Include public channel artwork, playlist thumbnails, and member-video thumbnails when exposed.

## `requestDelayMs` (type: `integer`):

Delay between ordered public requests.

## `maxConcurrency` (type: `integer`):

Requests are intentionally ordered and serial; only 1 is accepted.

## `maxRequestRetries` (type: `integer`):

Finite retries for transient fetch failures; access boundaries are not retried indefinitely.

## `requestTimeoutSecs` (type: `integer`):

Timeout for each public page request.

## `requestTimeoutMs` (type: `integer`):

Compatibility alias for requestTimeoutSecs.

## `maxResponseBytes` (type: `integer`):

Maximum HTML bytes retained from a public response.

## `userAgent` (type: `string`):

Optional ordinary browser user agent. Stealth and fingerprint spoofing are not used.

## `locale` (type: `string`):

Accept-Language value for public requests.

## `proxyConfiguration` (type: `object`):

Validated for compatibility, but this Actor uses direct fetch and does not route requests through a proxy.

## `page` (type: `integer`):

One-based source page. This Actor currently reads the first playlist surface only.

## Actor input object example

```json
{
  "maxItems": 25,
  "maxPages": 1,
  "deduplicate": true,
  "includePlaylistDetails": false,
  "includeMedia": true,
  "requestDelayMs": 0,
  "maxConcurrency": 1,
  "maxRequestRetries": 1,
  "requestTimeoutSecs": 30,
  "maxResponseBytes": 2000000,
  "locale": "en-US",
  "page": 1
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

## `output` (type: `string`):

No description

## `runSummary` (type: `string`):

No description

## `runHealth` (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("googleapi/youtube-channel-playlists-scraper").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("googleapi/youtube-channel-playlists-scraper").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 googleapi/youtube-channel-playlists-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,googleapi/youtube-channel-playlists-scraper"
        }
    }
}
```

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/4yfqAm8C5hqJgT4bX/builds/icLLz17IfgwxZf2tg/openapi.json
