Sample what is currently carrying TikTok. This endpoint needs no ID and no keyword at all, since an optional count is its only parameter, and it returns a feed of videos performing right now complete with authors, captions, sounds and engagement counts. Polling it on a schedule gives you a running picture of the platform without maintaining any seed list.
curl -X GET "https://api.primeapi.co/trending-posts?count=30" \
-H "X-PrimeAPI-Key: YOUR_API_KEY"
import requests
url = "https://api.primeapi.co/trending-posts?count=30"
headers = {"X-PrimeAPI-Key": "YOUR_API_KEY"}
response = requests.get(url, headers=headers)
print(response.json())
print("Credits left:", response.headers.get("X-PrimeAPI-Balance"))
{
"extra": {
"fatal_item_ids": [],
"logid": "2025011709485508DA30FD0D54C310FF86",
"now": 1737107337000
},
"hasMore": true,
"itemList": [
{
"AIGCDescription": "",
"CategoryType": 100,
"author": {
"avatarLarger": "https://p16-sign-useast2a.tiktokcdn.com/tos-useast2a-avt-0068-euttp/a88d95cba34c15d40e5e35bba9607cab~c5_1080x1080.jpeg?lk3s=a5d48078&nonce=61711&refresh_token=87ee4bbfd7188202b245b6693180107d&x-expires=1737277200&x-signature=JcuEuo8%2Fi%2FTEHdrvxfuOkMfgJNw%3D&shp=a5d48078&shcp=81f88b70",
"avatarMedium": "https://p16-sign-useast2a.tiktokcdn.com/tos-useast2a-avt-0068-euttp/a88d95cba34c15d40e5e35bba9607cab~c5_720x720.jpeg?lk3s=a5d48078&nonce=37025&refresh_token=5889d045277421ff076e921b37ad163b&x-expires=1737277200&x-signature=s6ytZKsQN2Tz%2FSd%2BSuviUyeYeZ0%3D&shp=a5d48078&shcp=81f88b70",
"avatarThumb": "https://p16-sign-useast2a.tiktokcdn.com/tos-useast2a-avt-0068-euttp/a88d95cba34c15d40e5e35bba9607cab~c5_100x100.jpeg?lk3s=a5d48078&nonce=15129&refresh_token=38e303f4f164c985e3eaa1521fd98b30&x-expires=1737277200&x-signature=B4qFdhdd%2BS2IPcWdBb%2BNv1n4fLM%3D&shp=a5d48078&shcp=81f88b70",
"commentSetting": 0,
"downloadSetting": 3,
"duetSetting": 0,
"ftc": false,
"id": "7376380023543317536",
"isADVirtual": false,
"isEmbedBanned": false,
"nickname": "New wave pictures",
"openFavorite": false,
"privateAccount": false,
"relation": 0,
"secUid": "MS4wLjABAAAASfrQueTWv2Z4UosPlSsTd3BMlN1w91k1ZzCFOGBooUhvnjEOfkrJNfxAdr2UZHBj",
"secret": false,
"signature": "telegram info Bel of App\nGamasha 8128164\nDogo 8706413\nQuinton 760 4367",
"stitchSetting": 0,
"uniqueId": "newwavepictures1",
"verified": false
},
"backendSourceEventTracking": "fyp_32",
"collected": false,
"contents": [
{
"desc": "A camera slow"
}
],
"createTime": 1734131502,
"desc": "A camera slow",
"digged": false,
"diversificationId": 10052,
"duetDisplay": 0,
"forFriend": false,
"id": "7448038044839496993",
... (truncated)