> ## Documentation Index
> Fetch the complete documentation index at: https://mindcase.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# YouTube Channel Videos / Shorts / Streams

> Extract YouTube channel data from URLs, with video lists, subscriber counts, and channel metadata

`$0.4 / 1k videos`

Extract YouTube channel data from URLs, with video lists, subscriber counts, and channel metadata

## Endpoint

`POST /api/v1/agents/youtube/channels/run`

## Parameters

<ParamField body="urls" type="array" required>
  **List** · YouTube channel URLs. One per line.
</ParamField>

<ParamField body="maxVideos" type="integer" default={50}>
  **Number** · Videos per channel. Use 0 for all.
</ParamField>

<ParamField body="sortVideosBy" type="string" default="NEWEST">
  **Dropdown** · Sort order for videos.

  **Options:** `NEWEST`, `POPULAR`, `OLDEST`

  *Legend: `NEWEST` = Newest First, `POPULAR` = Most Popular, `OLDEST` = Oldest First*
</ParamField>

<ParamField body="maxShorts" type="integer">
  **Number** · Shorts per channel. Use 0 for all, leave blank to skip.
</ParamField>

<ParamField body="maxStreams" type="integer">
  **Number** · Live streams per channel. Use 0 for all, leave blank to skip.
</ParamField>

## Response columns

| Field                | Display name         | Type    |
| -------------------- | -------------------- | ------- |
| `channelUrl`         | Channel URL          | url     |
| `videoUrl`           | Video URL            | url     |
| `videoTitle`         | Video Title          | text    |
| `posted`             | Posted               | text    |
| `duration`           | Duration             | text    |
| `views`              | Views                | number  |
| `channel`            | Channel              | text    |
| `channelHandle`      | Channel Handle       | text    |
| `channelDescription` | Channel Description  | text    |
| `channelLinkText`    | Channel Link Text    | text    |
| `channelLinkUrl`     | Channel Link URL     | url     |
| `channelLocation`    | Channel Location     | text    |
| `channelJoined`      | Channel Joined       | text    |
| `channelTotalVideos` | Channel Total Videos | number  |
| `channelTotalViews`  | Channel Total Views  | number  |
| `subscribers`        | Subscribers          | number  |
| `ageRestricted`      | Age Restricted       | boolean |
| `channelVerified`    | Channel Verified     | boolean |
| `type`               | Type                 | text    |
| `channelListPage`    | Channel List Page    | text    |
| `order`              | Order                | number  |
| `channelAvatar`      | Channel Avatar       | url     |
| `channelBanner`      | Channel Banner       | url     |
| `thumbnail`          | Thumbnail            | url     |

## Example

<CodeGroup>
  ```bash curl theme={null}
  curl -X POST https://api.mindcase.co/api/v1/agents/youtube/channels/run \
    -H "Authorization: Bearer mk_live_abc123def456" \
    -H "Content-Type: application/json" \
    -d '{
    "params": {
      "urls": [
        {
          "url": "https://www.youtube.com/@MrBeast"
        }
      ],
      "maxVideos": 10,
      "maxShorts": 0,
      "maxStreams": 0
    }
  }'
  ```

  ```python Python theme={null}
  import requests

  resp = requests.post(
      "https://api.mindcase.co/api/v1/agents/youtube/channels/run",
      headers={"Authorization": "Bearer mk_live_abc123def456"},
      json={"params": {
      "urls": [
          {
              "url": "https://www.youtube.com/@MrBeast"
          }
      ],
      "maxVideos": 10,
      "maxShorts": 0,
      "maxStreams": 0
  }},
  )
  data = resp.json()
  ```
</CodeGroup>

### Example response

```json Response theme={null}
{
  "job_id": "job_7f3a2b1c",
  "status": "completed",
  "data": [
    {
      "channelUrl": "https://www.youtube.com/channel/UCX6OQ3DkcsbYNE6H8uQQuVA",
      "videoUrl": "https://www.youtube.com/watch?v=zRtGL0-5rg4",
      "videoTitle": "Last To Leave Grocery Store, Wins $250,000",
      "posted": "13 days ago",
      "duration": "42:57",
      "views": 115000000,
      "channel": "MrBeast",
      "channelHandle": "MrBeast",
      "channelDescription": "SUBSCRIBE FOR A COOKIE!\nNew MrBeast or MrBeast Gaming video every single Saturday at noon eastern time!\nAccomplishments:\n- Raised $20,000,000 To Plant 20,000,000 Trees\n- Removed 30,000,000 pounds of trash from the ocean\n- Helped 2,000 people walk again\n- Helped 1,000 blind people see\n- Helped 1,000 deaf people hear\n- Built wells in Africa\n- Built and gave away 100 houses\n- Adopted every dog in a shelter (twice)\n- Given millions to charity\n- Started my own snack company Feastables\n- Started my own software company Viewstats\n- Started Lunchly, a tasty, better-for-you lunch option\n- Gave away a private island (twice)\n- Gave away 1 million meals\n- I counted to 100k\n- Ran a marathon in the world's largest shoes\n- Survived 50 hours in Antarctica\n- Recreated Squid Game in real life\n- Created the largest competition show with 1000 people (Beast Games)\n- Gave $5,000,000 to one person\n- Passed T-Series to become most subscribed YouTube channel \ud83e\udd79\nyou get it, I appreciate all of you so much :)",
      "channelLinkText": null,
      "channelLinkUrl": null,
      "channelLocation": "United States",
      "channelJoined": "Feb 19, 2012",
      "channelTotalVideos": 972,
      "channelTotalViews": 119792170605,
      "subscribers": 480000000,
      "ageRestricted": false,
      "channelVerified": true,
      "type": "video",
      "channelListPage": "videos",
      "order": 0,
      "channelAvatar": "https://yt3.googleusercontent.com/nxYrc_1_2f77DoBadyxMTmv7ZpRZapHR5jbuYe7PlPd5cIRJxtNNEYyOC0ZsxaDyJJzXrnJiuDE=s68-c-k-c0x00ffffff-no-rj",
      "channelBanner": "https://yt3.googleusercontent.com/mHMO_eEMp0dPvh0ADwXhPXNYb_GnjSVsLI8biqF1CpxT8OPl7izhNQsDPD3JHhd5y5Mg9GrP=w2560-fcrop64=1,00005a57ffffa5a8-k-c0xffffffff-no-nd-rj",
      "thumbnail": "https://i.ytimg.com/vi/zRtGL0-5rg4/hqdefault.jpg?sqp=-oaymwEmCKgBEF5IWvKriqkDGQgBFQAAiEIYAdgBAeIBCggYEAIYBjgBQAE=&rs=AOn4CLC27MWa9QRwlLhSSh4KlNGUMPuwrQ"
    }
  ]
}
```
