Sand AISand AI MAGI-2MAGI-2 è ora su SandBase: video in 1080p con audio nativoProvalo ora

YouTube Channel ID from URL (V2)

Documentazione API
https://api.sandbase.ai/v1/api/youtube/web/channel-id-v2

Resolves a YouTube channel URL into its unique channel ID and standardized channel URL. Accepts various URL formats including handles, custom URLs, and user links.

Prezzo
$0.001USD / chiamata
Metodo
POST
Risposta
JSON
Parametri
1 obbligatori · 0 opzionali

Playground

Input
Channel URL.
OutputEsempio
Rispostaoutputs · 159 B · 8 righe
[
  {
    "data": {
      "channel_id": "UCeu6U67OzJhV1KwBansH3Dg",
      "channel_url": "https://www.youtube.com/channel/UCeu6U67OzJhV1KwBansH3Dg"
    }
  }
]

Esempi

Seleziona un esempio per caricare i suoi input e il risultato nel playground.

README API

YouTube Channel ID from URL (V2) API

Takes a YouTube channel URL and returns the channel's unique ID and its standard channel URL. The input is channel_url, which can be a handle, custom URL, user link, or channel link.

Use cases

  • Convert a creator's @handle link into a UC... channel ID before you call other channel APIs.
  • Clean up channel links that users paste in different formats and store one standard URL per channel.
  • Check that a submitted channel link points to a real channel.
  • Build a lookup table that maps handles from a spreadsheet to channel IDs.

Request

curl -X POST "https://api.sandbase.ai/v1/api/youtube/web/channel-id-v2" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"channel_url": "https://www.youtube.com/@CozyCraftYT"}'

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

Parameters

NameTypeRequiredDescription
channel_urlstringYesChannel URL.

Example response

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

{
  "channel_id": "UCeu6U67OzJhV1KwBansH3Dg",
  "channel_url": "https://www.youtube.com/channel/UCeu6U67OzJhV1KwBansH3Dg"
}

Response fields

FieldMeaning
channel_idThe unique YouTube channel ID. It starts with UC, for example UCeu6U67OzJhV1KwBansH3Dg.
channel_urlThe standard channel URL built from the ID, in the form https://www.youtube.com/channel/<channel_id>.

Notes

  • Pass the full URL in channel_url. The example uses a handle URL: https://www.youtube.com/@CozyCraftYT.
  • The response gives the same ID in channel_id and inside channel_url, so you can use either one.
  • To go the other way and get a URL from an ID, use YouTube Channel URL by ID.
  • For profile details of the channel, call YouTube Channel Information next.

Pricing

$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

Esplora altro

API correlate

Tutte le API
APIPrezzoRisposta
YouTube$0.001 per chiamataJSON
YouTube$0.001 per chiamataJSON
YouTube$0.001 per chiamataJSON
YouTube$0.001 per chiamataJSON
YouTube$0.001 per chiamataJSON
YouTube$0.001 per chiamataJSON

Guide:Best YouTube API in 2026: Pricing Compared

Domande

FAQ

Come uso l'API YouTube Channel ID from URL (V2)?

Invia una richiesta POST a https://api.sandbase.ai/v1/api/youtube/web/channel-id-v2 con la tua chiave API di SandBase nell'header Authorization (Bearer) e i parametri nel body JSON. Puoi anche provarla nel Playground di questa pagina senza scrivere codice.

Quanto costa l'API YouTube Channel ID from URL (V2)?

$0.001 per chiamata, addebitato dal tuo saldo SandBase. Paghi solo le chiamate che effettui; non c'è alcun abbonamento.

Quali parametri accetta l'API YouTube Channel ID from URL (V2)?

Richiesti: channel_url (string). La tabella dei parametri e il Playground di questa pagina elencano tutti i campi.

Cosa restituisce l'API YouTube Channel ID from URL (V2)?

Una risposta JSON restituita nella stessa richiesta HTTP (sincrona). Il README di questa pagina include una risposta di esempio.

Mi serve un account sviluppatore o una chiave API YouTube?

No. YouTube Channel ID from URL (V2) funziona tramite SandBase, quindi una sola chiave API SandBase copre questo endpoint e tutte le altre API e modelli del catalogo. Non è necessario richiedere separatamente l'accesso alle API YouTube.