TikTok
Videos list
List an account’s latest videos, newest first.
Endpoint
GET
/s/tiktok/postsSend your API key in the X-API-Key header. tiktok is the usual service slug; use the one shown on your subscription if it differs.
Query parameters
| Name | Description |
|---|---|
usernamerequired | Account name, with or without the leading @.Example: khaby.lame |
Example request
curl '/s/tiktok/posts?username=khaby.lame' \
-H 'X-API-Key: YOUR_API_KEY'Example response
The result is in data. Fields the platform didn't report are left out. Field reference: response shapes.
{
"data": {
"items": [
{
"platform": "tiktok",
"id": "7311234567890123456",
"url": "https://www.tiktok.com/@khaby.lame/video/7311234567890123456",
"type": "video",
"text": "When life is simple",
"media": [
{
"type": "video",
"url": "https://v16-webapp-prime.tiktok.example/video.mp4"
}
],
"stats": {
"views": 25000000
}
}
],
"hasMore": false
}
}Notes
- Returns the account’s latest videos (usually about 10), newest first, in 1 to 3 seconds. There is no next page: hasMore is false. Private accounts return 403.
- Each item has the link, caption, cover and views. TikTok sets the list size; count is ignored. Use the video endpoint for full details of one video.
- To get a video file, pass the item’s url to Download file.