100 free credits. No credit card required. Get a key

TikTok transcript API

What is said in a TikTok video, from the caption track TikTok made for it: the WebVTT file, plain text and timed segments, in the original language or a translation.

GET /v1/tiktok/videos/{id}/transcript1 credit per callRefunded on failure
import os, requests

res = requests.get(
    "https://api.groundsocial.dev/v1/tiktok/videos/7707446852798549279/transcript",
    headers={"Authorization": f"Bearer {os.environ['GROUNDSOCIAL_API_KEY']}"},
)
res.raise_for_status()
data = res.json()
Response
200 · 1 credit
{
"itemId": "7707446852798549279",
"language": "eng-US",
"source": "ASR",
"webvtt": "WEBVTT\n\n\n00:00:00.380 --> 00:00:02.740\ngarlic butter steak bites and potatoes\n\n00:00:02.741 --> 00:00:05.861\nlet's make …",
"text": "garlic butter steak bites and potatoes let's make it first you're gonna wash and peel and dice your russet potatoes into…",
"segments": [
{
"start": 0.38,
"end": 2.74,
"text": "garlic butter steak bites and potatoes"
},
{
"start": 2.741,
"end": 5.861,
"text": "let's make it first you're gonna wash and peel and dice"
}
],
"subtitleInfos": [
{
"Format": "webvtt",
"LanguageCodeName": "eng-US",
"LanguageID": "2",
"Size": 1639,
"Source": "ASR",
"Url": "https://v16m-webapp.tiktokcdn-us.com/af4491975f5a9c37d168d840db7a7da5/6b08c4d5/video/tos/useast8/tos-useast8-v-0068-tx2/…",
"UrlExpire": 1795736789,
"Version": "1:big_caption"
}
]
}

Parameters

NameTypeDescription
idpath · requiredstringA video (or photo post) id, or its URL (www.tiktok.com/@user/video/<id>). Example: 7707446852798549279.
languagequerystringLanguage code, e.g. en, es, pt-BR.
Response fields

200 with a TikTokTranscriptResponse, in TikTok’s own web JSON (itemStruct, userInfo, comments).

FieldTypeDescription
itemIdstringVideo id, as a decimal string.
languagestringThe track’s language code, e.g. eng-US.
sourcestringWho made the track: ASR (TikTok’s auto captions), MT (machine translation) or the creator.
webvttstringThe track as TikTok serves it (WebVTT).
textstringThe cues joined into plain text.
segmentsobject[]
subtitleInfosobject[]Every track TikTok lists for the video (languages, formats).
Status codes
StatusMeaning
200The transcript.
400Invalid input. Nothing was charged.
401Missing or invalid API key.
402Not enough credits, a spend cap was reached, or payment is required.
403The target is private, or the account is suspended.
404The account, video, comment, hashtag or sound does not exist on TikTok, or was removed.
429Too many requests. Wait for Retry-After seconds.
503TikTok is temporarily unavailable. Retryable; nothing was charged.

Every error has code, message, hint and retryable. All error codes

Questions

What if a video has no speech?

TikTok makes no caption track for it, so it answers 404 target_not_found, never charged.

TikTok is a trademark of ByteDance Ltd. We are not affiliated with or endorsed by TikTok or ByteDance.