TikTok · API
TikTok Video Stats API
Views, likes, comments, shares and collects for a public TikTok video.
EndpointGET /v1/tiktok/stats
Cost1 credit live
Cache hit0 credits
ReturnsOne object
Call it
curl -G 'https://api.sourcevine.io/v1/tiktok/stats' \
-H 'Authorization: Bearer sv_live_...' \
--data-urlencode 'url=https://www.tiktok.com/@username/video/7042118893001'const res = await fetch(
'https://api.sourcevine.io/v1/tiktok/stats?' + new URLSearchParams({
url: 'https://www.tiktok.com/@username/video/7042118893001',
}),
{ headers: { Authorization: 'Bearer sv_live_...' } },
);
const { success, data } = await res.json();import requests
r = requests.get(
"https://api.sourcevine.io/v1/tiktok/stats",
params={"url": "https://www.tiktok.com/@username/video/7042118893001"},
headers={"Authorization": "Bearer sv_live_..."},
)
data = r.json()["data"]Parameters
| Name | Required | Notes |
|---|---|---|
| url | Yes | A public TikTok URL. |
| access_key | Yes | Your key. Send it as Authorization: Bearer orx-access-key where you can — a key in a query string ends up in proxy logs and browser history. |
| cache | No | Defaults to true. Set false to force a live read, which always costs credits. |
Billing
A live read costs 1 credit and a cache hit costs nothing. Every response says which it was, in thecached field and in the X-Credits-Chargedheader. A resource that turns out to be private, deleted, or that we could not reach is never charged.
Other APIs
TikTok Profile API/v1/tiktok/profileTikTok Channel Videos API/v1/tiktok/postsYouTube Video Stats API/v1/youtube/statsYouTube Channel API/v1/youtube/channelYouTube Channel Videos API/v1/youtube/videosYouTube Transcript API/v1/youtube/transcript
All APIs →