GroundsocialDocs

API · YouTube

GET /youtube/videos/{id}/transcript

A YouTube video’s transcript: timestamped segments and full text, in a chosen language.

RequestGET /v1/youtube/videos/{id}/transcript
Operation idyoutube.video.transcript
Cost2 credits, refunded if the call fails
AuthAPI key: Authorization: Bearer <key> or x-api-key.

A YouTube video’s transcript: timestamped segments and full text, in a chosen language.

Path parameters

NameTypeRequiredDescription
idstringyesA video or Short id, or any URL of it (watch, youtu.be, shorts, live, embed). Example: dQw4w9WgXcQ.

Query parameters

NameTypeRequiredDescription
languagestringnoISO 639-1 language code (en, es, pt-BR). Example: en.
original_audio"0" | "1" | "true" | "false"notrue: only the original spoken language (wins over language). One of 0, 1, true, false.

Responses

StatusMeaningSchema
200The transcript.YouTubeTranscript
400Invalid input. Nothing was charged.Error
401Missing or invalid API key.Error
402Not enough credits, a spend cap was reached, or payment is required.Error
403The target is private, or the account is suspended.Error
404The video, channel, playlist or post does not exist, was removed, or has nothing there.Error
429Too many requests. Wait for Retry-After seconds.Error
503YouTube is temporarily unavailable. Retryable; nothing was charged.Error

YouTubeTranscript fields

FieldTypeDescription
kind"youtube#transcript"
videoIdstring
languageCodestring
languageNamestring
isAutoGeneratedboolean
isTranslatedbooleanTrue when YouTube machine-translated the track into the asked language.
textstringThe whole transcript, segments joined with spaces.
segmentsYouTubeTranscriptSegment[]
availableLanguagesYouTubeCaptionTrack[]

Errors use one shape everywhere; see Errors for every code and what to do.