Call it
curl https://api.peume.com/v1/call/tiktok-search-douyin-videos \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"keyword": "your keyword",
"cursor": 10
}
}'const res = await fetch("https://api.peume.com/v1/call/tiktok-search-douyin-videos", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"keyword": "your keyword",
"cursor": 10
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/tiktok-search-douyin-videos",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"keyword": "your keyword",
"cursor": 10
}
},
)
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-search-douyin-videos.
Parameters
keywordstringKeyword
cursorintegerOffset cursor for pagination, obtained from the last response
sort_typestringSort type: 0=Comprehensive, 1=Most Likes, 2=Latest
publish_timestringPublish time filter: 0=Unlimited, 1=Last day, 7=Last week, 180=Last half year
filter_durationstringVideo duration filter: 0=Unlimited, 0-1=Within 1 minute, 1-5=1 to 5 minutes, 5-10000=More than 5 minutes
content_typestringContent type: 0=All, 1=Video, 2=Picture, 3=Article
search_idstringSearch ID for pagination, obtained from the last response
backtracestringBacktrace for pagination, obtained from the last response
Other ways to do it
Same job, other sources, cheapest first.
