LurkAPI
Docs · Video details

Video details

One video or photo post: caption, stats, author, sound, hashtags and a playable MP4 URL.

1 credit per callFresh within 15 minutesMCP tool: tiktok_video
GEThttps://api.lurkapi.com/v2/tiktok/video

Example response

When to use this

Use it to track a post's views, likes, comments, shares and saves, or to get its media. video.playUrl plays without cookies until video.expires_at (about two days); fetch the post again for a fresh one. Photo posts have their slides in images.

playUrl can refuse visitors outside the US. Pass cdn_url=true to also get cdnUrl, the file on TikTok's CDN it redirects to, which plays from anywhere for a few hours (same credit).

Pass get_transcript=true to also get the captions as WEBVTT in transcript (same credit).

Deleted, private and region-locked posts return 404 not_found.

Example request

Copy one and replace YOUR_API_KEY with your API key (get one free). The code versions read the key from the LURKAPI_API_KEY environment variable instead.

Language

Parameters

Add them to the URL after a ?. Join several with &.

ParameterDescription
url
stringrequired
The video's URL, e.g. https://www.tiktok.com/@hubspot/video/7671325437229845774. Photo post URLs and bare video ids work too.
Example
https://www.tiktok.com/@hubspot/video/7671325437229845774
get_transcript
booleanoptional
true adds the captions as WEBVTT in transcript (null if the video has none).
One of
truefalse
Default
false
cdn_url
booleanoptional
true adds cdnUrl, the MP4 on TikTok's CDN that video.playUrl redirects to.
One of
truefalse
Default
false

Example response

A real response, captured from the live API. Lists are trimmed to a couple of items, and long text such as media links is cut short with ….

Show the example response (2 KB)
{
  "success": true,
  "credits_remaining": 999953,
  "credits_charged": 1,
  "id": "7671325437229845774",
  "url": "https://www.tiktok.com/@hubspot/video/7671325437229845774",
  "desc": "love at first MQL",
  "title": null,
  "createTime": 1786119661,
  "textLanguage": "en",
  "locationCreated": "US",
  "isAd": true,
  "author": {
    "id": "6921028957732193285",
    "uniqueId": "hubspot",
    "nickname": "HubSpot",
    "secUid": "MS4wLjABAAAAuY18L_r3HfP3KEtK0txT2RPxDj1uSMSqbHZF33aYcGVAwL3PUA50WeQkR2o53xqr",
    "verified": true,
    "privateAccount": false,
    "avatarThumb": "https://p16-common-sign.tiktokcdn-us.com/tos-useast5-avt-0068-tx/7351755…",
    "avatarLarger": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-avt-0068-tx/7351755…"
  },
  "stats": {
    "playCount": 1110,
    "diggCount": 25,
    "commentCount": 1,
    "shareCount": 0,
    "collectCount": 2,
    "repostCount": 0
  },
  "video": {
    "duration": 80,
    "width": 720,
    "height": 1280,
    "definition": "720p",
    "cover": "https://p16-common-sign.tiktokcdn-us.com/tos-useast5-p-85c255-tx/okN7mcf…",
    "dynamicCover": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-p-85c255-tx/oEDEMCV…",
    "playUrl": "https://www.tiktok.com/aweme/v1/play/?faid=1988&file_id=30509d3782234485…",
    "expires_at": 1791161052
  },
  "music": {
    "id": "7671325566393486094",
    "title": "original sound - HubSpot",
    "authorName": "HubSpot",
    "original": true,
    "duration": 80,
    "playUrl": "https://v16m.tiktokcdn-us.com/1aeffe1fb6526fe5e65e2fcd70809f0a/6ac0a43c/…",
    "cover": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-avt-0068-tx/7351755…"
  },
  "hashtags": [],
  "mentions": [],
  "images": []
}

Response fields

Every field in a successful response, and what it means. A name with [] belongs to each item of a list: images[].url is the url of every item in images. null means there's no value.

Show all 52 fields
FieldTypeDescription
successtrueAlways true here; errors have success: false.
credits_remainingnumberYour balance after this call. On anonymous playground calls: free tries left today.
credits_chargednumberCredits this call cost; 0 on free endpoints. On anonymous playground calls: tries used (1).
idstringVideo id, e.g. 7671325437229845774.
urlstringThe post on tiktok.com.
descstringCaption, hashtags included.
titlestringcan be nullA photo post's title, shown above the caption, e.g. tom & jerry art; null for videos and untitled posts.
createTimenumberPosted at, Unix seconds.
textLanguagestringcan be nullCaption language as TikTok detects it, e.g. en; un = undetermined; null if unknown.
locationCreatedstringcan be nullCountry the post was made in, as a 2-letter code. Only video details have it; null in lists and when unknown.
isAdbooleanA paid ad (Spark Ad or promoted post).
authorobjectWho posted it.
author.idstringNumeric user id.
author.uniqueIdstringUsername (handle), without @.
author.nicknamestringDisplay name.
author.secUidstringTikTok's long, stable user id; other tools ask for it.
author.verifiedbooleanHas the verified badge.
author.privateAccountbooleanThe account is private.
author.avatarThumbstringcan be nullSmall avatar URL (expires after a few days); null if TikTok has none.
author.avatarLargerstringcan be nullLarge avatar URL (expires after a few days); null if TikTok has none.
statsobjectEngagement when fetched, as tiktok.com gives it: exact for smaller counts, rounded for large ones (e.g. 2500000 views).
stats.playCountnumberViews.
stats.diggCountnumberLikes.
stats.commentCountnumberComments.
stats.shareCountnumberShares.
stats.collectCountnumbercan be nullSaves (favorites); null where TikTok doesn't show it.
stats.repostCountnumbercan be nullReposts; null where TikTok doesn't show it.
videoobjectThe video file. For photo posts see images.
video.durationnumberLength in seconds; 0 for photo posts.
video.widthnumberWidth in pixels; 0 for photo posts.
video.heightnumberHeight in pixels; 0 for photo posts.
video.definitionstringcan be nullQuality of the default rendition, e.g. 720p.
video.coverstringcan be nullCover image URL (expires after a few days); null if TikTok has none.
video.dynamicCoverstringcan be nullAnimated cover URL (expires after a few days); null if TikTok has none.
video.playUrlstringcan be nullMP4 URL that plays without cookies (h264, best quality). It redirects to TikTok's CDN and expires at expires_at; null if TikTok has none.
video.expires_atnumbercan be nullWhen playUrl stops working, Unix seconds; null if unknown.
musicobjectcan be nullThe sound; null if the post has none.
music.idstringSound id; pass it to song endpoints.
music.titlestringSound title, e.g. original sound.
music.authorNamestringcan be nullArtist, or the creator for original sounds.
music.originalbooleanAn original sound made with this post rather than a track.
music.durationnumbercan be nullLength in seconds.
music.playUrlstringcan be nullAudio URL (expires after a few hours); null if TikTok has none.
music.coverstringcan be nullSound cover image URL; null if TikTok has none.
hashtagsstring[]Hashtags in the caption, without #.
mentionsstring[]Usernames @mentioned in the caption.
imagesobject[]The slides of a photo post, in order. Empty for videos.
images[].urlstringImage URL (expires after a few days).
images[].widthnumberWidth in pixels.
images[].heightnumberHeight in pixels.
transcriptstringcan be null · may be missingWith get_transcript=true: the captions as WEBVTT in the video's original language; null if it has none.
cdnUrlstringcan be null · may be missingWith cdn_url=true: the MP4 on TikTok's CDN, without cookies and from anywhere, for a few hours; null for photo posts or when TikTok doesn't redirect.

Cost and freshness

Each call costs 1 credit. Calls turned away before they reach the platform (invalid parameters, a key or balance problem, a rate limit) are free, and so are 5xx errors. A not_found is charged, since the platform was checked. How charging works.

Answers are cached for up to 15 minutes. A repeat call within that time can return the same data, and costs the same.

Errors

A failed call returns success: false, an error message, a code your program can check, and a docs link. These are the errors this endpoint can return. All error codes.

StatusCodeMeaning
401missing_api_keyNo API key was sent. Put it in the x-api-key header.
401invalid_api_keyThis key doesn't exist or was revoked.
402insufficient_creditsNot enough credits for this call. Buy a pack, or wait for tomorrow's free top-up.
402over_max_creditsThis call would cost more than the max_credits you set. The error says what it needs; raise max_credits to allow it. Not charged.
403account_suspendedThis account is suspended. Email support@lurkapi.com. Not charged.
404not_foundWhat you asked for (a post, an ad, a subreddit) doesn't exist, or there's no endpoint at that path. Charged if the platform was checked.
405method_not_allowedEndpoints only take GET, with parameters in the URL.
429rate_limitedToo many calls in a short time. Wait as many seconds as the retry-after header says, then retry.
500internal_errorSomething broke on our side. Retry. Not charged.
502upstream_errorThe platform didn't send a usable answer. Retry. Not charged.
503upstream_busyAll our connections to the platform are busy. Retry in a few seconds. Not charged.
504upstream_timeoutThe platform took over 30 seconds to answer (90 for web pages). Retry. Not charged.

Use it in Claude

Connect LurkAPI to Claude and ask in plain English. This endpoint is the tiktok_video tool. For example:

Ask Claude
Use LurkAPI's tiktok_video tool with url "https://www.tiktok.com/@hubspot/video/7671325437229845774", then summarize what you find.

Claude calls tiktok_video with arguments like these, and each call costs 1 credit:

Tool arguments
{"url": "https://www.tiktok.com/@hubspot/video/7671325437229845774"}

To save tokens, tool results leave out empty fields, keep one URL per image or video, and give transcripts as plain text unless you pass timestamps=true. A result over 45,000 characters comes in parts. Its _note gives the offset for the next part, and later parts are free for 15 minutes. Pass trim=false for the full response.

From the blog

All posts