Call it
curl https://api.peume.com/v1/call/tiktok-playlist-videos \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"playlist_id": "your playlist id"
}
}'const res = await fetch("https://api.peume.com/v1/call/tiktok-playlist-videos", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"playlist_id": "your playlist id"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/tiktok-playlist-videos",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"playlist_id": "your playlist id"
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: tiktok-playlist-videos.
Parameters
playlist_idRequiredstringThe numeric playlist ID, the `playlist_id` of a `user_playlists` row, or a playlist link such as https://www.tiktok.com/@<user>/playlist/<name>-<ID>.
page_tokenstringPage token. Leave it out for the first page, then pass back the previous response's `next_page_token` exactly as received, with the other parameters unchanged. Each page holds up to 30 videos and counts as one call; videos that can no longer be viewed are left out, so a short page is not the end. Tokens last 24 hours, and only a page without `next_page_token` is the last one.
