GET
/
youtube
/
channel
/
videos
import { Supadata } from '@supadata/js';

const supadata = new Supadata({
apiKey: 'YOUR_API_KEY',
});
const videos = await supadata.youtube.channel.videos({
id: 'RickAstleyVEVO', // can be url, id, handle
limit: 50, // Optional: limit the number of videos to fetch
type: 'all', // Optional: 'all', 'video', 'short', 'live' (default 'all')
});
console.log(`Found ${videos.videoIds.length} regular videos, ${videos.shortIds.length} shorts, and ${videos.liveIds.length} live streams.`);
{
  "videoIds": [
    "dQw4w9WgXcQ",
    "xvFZjo5PgG0"
  ],
  "shortIds": [
    "dQw4w9WgXcQ",
    "xvFZjo5PgG0"
  ],
  "liveIds": [
    "dQw4w9WgXcQ",
    "xvFZjo5PgG0"
  ]
}

Authorizations

x-api-key
string
header
required

Query Parameters

id
string
required

YouTube channel URL, handle or ID. See supported URL formats.

Examples:

"https://www.youtube.com/channel/UCuAXFkgsw1L7xaCfnd5JJOw"

"https://youtube.com/c/rickastley"

"UCuAXFkgsw1L7xaCfnd5JJOw"

"@rickastley"

"rickastley"

limit
number
default:30

Maximum number of video IDs to return. If type = all, vertical videos are prioritized.

Required range: 1 <= x <= 5000
Example:

10

type
enum<string>
default:video

Type of videos to return.

Available options:
all,
video,
short,
live
Example:

"video"

Response

200
application/json

Successfully fetched channel video IDs

The response is of type object.