JustSERPDocs
TikTok

TikTok Transcripts

The captions of one TikTok video with their times, answered as the document: `transcripts` and `available_languages`.

GET
/v1/tiktok/transcripts

The captions of one TikTok video with their times, answered as the document: transcripts and available_languages. Name the video with url, or video_id with username. Without language the original caption is answered (a machine translation is not preferred); with it, an exact match is preferred (en, eng and eng-US all select English) and otherwise the same base language. A language the video lacks, or a video with no captions, is a 200 with available_languages and an error and no transcripts. duration is the cue's own length. zero_retention is not handled.

Authorization

headerX-API-Key<token>

Your API key.

Query Parameters

cancel_token?string

A name you make up for this request (a UUID is fine), so you can later GET /v1/cancel with it. Only you know it, so only you can cancel. Use a new one for every request, retries included: a cancelled token stays cancelled for a few minutes.

Length1 <= length <= 128
url?string

The video's address, or a vm.tiktok.com / vt.tiktok.com / tiktok.com/t/ share link.

video_id?string

The number at the end of the video's address. Needs username.

Match^\d+$
username?string

The creator's username. Needs video_id.

Match^@?[a-zA-Z0-9_.]{1,24}$
language?string

A caption language (en, eng, pt-BR ...). Default: the original caption.

Match^[a-zA-Z]{2,3}(-[a-zA-Z0-9]{2,8}){0,2}$

Response Body

The transcript, as the document. When the page could not be parsed, the usual envelope.

application/json
  1. response

The first keys of a document-form answer. Unlike DocumentHead there is no search_information unless the engine has one (there is none for the AI engines, Events, Events Details, Facebook, Tripadvisor Place, Trending Now and the Apple engines' places).

search_metadata*
search_parameters*

The parameters the search ran with, defaults filled in; engine is the engine's name.

search_information?
transcripts?array<>
available_languages?array<>
error?string

Why there is no transcript (no captions, or a language the video lacks).

Example Request
curl -X GET 'https://api.justserp.com/v1/tiktok/transcripts?url=https%3A%2F%2Fwww.tiktok.com%2F%40tiktok%2Fvideo%2F7700009319382650142'
Example Response
{  "search_metadata": {    "id": "string",    "status": "Success",    "created_at": "string",    "request_url": "string",    "html_url": "string"  },  "search_parameters": {},  "search_information": {},  "transcripts": [    {      "text": "string",      "start": 0,      "duration": 0    }  ],  "available_languages": [    {      "name": "string",      "lang": "string",      "is_selected": true    }  ],  "error": "string"}