Sand AISand AI MAGI-2MAGI-2 が SandBase に登場しました: ネイティブ音声付き 1080p 動画今すぐ試す

YouTube Playlist

APIドキュメント
https://api.sandbase.ai/v1/api/youtube/playlist

List every video in a YouTube playlist (title, length, and channel per video plus playlist owner and totals).

料金
$0.0012 からUSD / 回
メソッド
POST
レスポンス
JSON
パラメータ
必須 1 件 · 任意 0 件

プレイグラウンド

入力
The playlist ID: the "list" parameter in a playlist URL (e.g. "PLu0W_9lII9ahIappRPN0MCAgtOu3lQjQi").
出力準備完了

出力はここに表示されます

入力を完了してから[実行]をクリックしてください。

API README

YouTube Playlist API

Returns the videos in a YouTube playlist, plus the playlist title, owner, and total video count. It needs one input: the playlistId from the list parameter of a playlist URL.

Use cases

  • Export a playlist's track list with titles, channels, and durations into a spreadsheet.
  • Add up lengthSeconds across a playlist to estimate its total running time.
  • Check which channels appear in a curated music playlist.
  • Collect video IDs from a playlist and pass them to a video details API.

Request

curl -X POST "https://api.sandbase.ai/v1/api/youtube/playlist" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"playlistId": "PLMC9KNkIncKtPzgY-5rmhvj7fax8fdxoj"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
playlistIdstringYesThe playlist ID: the "list" parameter in a playlist URL (e.g. "PLu0W_9lII9ahIappRPN0MCAgtOu3lQjQi").

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "data": {
    "authorHandle": "Redlist-JustHits",
    "authorId": "UCs72iRpTEuwV3y6pdWYLgiw",
    "authorUrl": "https://www.youtube.com/@Redlist-JustHits",
    "owner": "Redlist - Just Hits",
    "title": "Pop Music Playlist - Timeless Pop Songs (Updated Weekly 2026)",
    "totalVideos": 200,
    "videos": [
      {
        "channel": "Lady Gaga",
        "id": "kPa7bsKwL-c",
        "lengthSeconds": 253,
        "lengthText": "4:13",
        "thumbnail": "https://i.ytimg.com/vi/kPa7bsKwL-c/hqdefault.jpg?sqp=-oaymwEnCNACELwBSFryq4qpAxk…",
        "title": "Lady Gaga, Bruno Mars - Die With A Smile (Official Music Video)",
        "url": "https://www.youtube.com/watch?v=kPa7bsKwL-c"
      }
    ]
  },
  "found": true
}

Response fields

FieldMeaning
data.titleTitle of the playlist.
data.owner / data.authorHandleDisplay name and @handle of the channel that owns the playlist.
data.authorId / data.authorUrlID and URL of the owner's channel.
data.totalVideosNumber of videos in the playlist, as reported for the playlist as a whole.
data.videos[].idYouTube video ID. It matches the v value in data.videos[].url.
data.videos[].titleTitle of the video.
data.videos[].channelName of the channel that posted the video. It can differ from the playlist owner.
data.videos[].lengthSeconds / data.videos[].lengthTextVideo length as a number of seconds and as display text such as 4:13.
data.videos[].url / data.videos[].thumbnailLink to the video's watch page and to its thumbnail image.
foundtrue when the playlist was found.

Notes

  • Take playlistId from the list parameter in a playlist URL, for example PLMC9KNkIncKtPzgY-5rmhvj7fax8fdxoj.
  • The request has no pagination parameter. Compare data.totalVideos with the length of data.videos to see how many videos came back.
  • Pass a video ID from data.videos[].id to YouTube Video Details for more about one video.
  • Use YouTube Channel Playlists to find playlist IDs for a channel.

Pricing

Billed at the actual cost of each call, about $0.0012 for the request above. Failed calls are not charged.

さらに探索

関連 APIs

すべての APIs
API価格レスポンス
YouTube1回あたり $0.0012 からJSON
YouTube1回あたり $0.00045 からJSON
YouTube1回あたり $0.0012 からJSON
YouTube1回あたり $0.0012 からJSON
YouTube1回あたり $0.0012 からJSON
YouTube$0.014286 / 回JSON

ガイド:Best YouTube API in 2026: Pricing Compared

質問

FAQ

YouTube Playlist API はどのように使いますか?

Authorization ヘッダー(Bearer)に SandBase API key を指定し、パラメータを JSON ボディで送信して https://api.sandbase.ai/v1/api/youtube/playlist に POST リクエストを送ります。このページの Playground で、コードを書かずに試すこともできます。

YouTube Playlist API の料金はいくらですか?

1回あたり $0.0012 から、SandBase 残高から課金されます。課金対象はご利用分のみで、サブスクリプションはありません。

YouTube Playlist API はどのパラメータを受け付けますか?

必須: playlistId (string)。 このページの Parameters テーブルと Playground に、すべてのフィールドが一覧表示されています。

YouTube Playlist API は何を返しますか?

同じ HTTP リクエスト内で返される JSON レスポンスです(同期)。 このページの README にサンプルレスポンスがあります。

YouTube の開発者アカウントまたは API key は必要ですか?

いいえ。YouTube Playlist は SandBase 経由で動作するため、SandBase の API key 1つでこのエンドポイントと、カタログ内の他のすべての API とモデルを利用できます。YouTube の API アクセスを別途申請する必要はありません。