Call it
curl https://api.peume.com/v1/call/search-youtube-3 \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"timeout": 50
}
}'const res = await fetch("https://api.peume.com/v1/call/search-youtube-3", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"timeout": 50
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/search-youtube-3",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"timeout": 50
}
},
)
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: search-youtube-3.
Parameters
typestringResult type. Omit for mixed results. Movies appear in video_results. Channels and playlists cannot use upload_date, duration or features. Shorts cannot use duration. Movies cannot use live, subtitles, creative_commons or 3d features.
channel · movie · playlist · shorts · video
upload_datestringLimit results by upload date.
this_month · this_week · this_year · today
durationstringVideo duration: under 3 minutes, 3–20 minutes, or over 20 minutes.
between_3_and_20_min · over_20_min · under_3_min
featuresstringComma-separated features: live, 4k, hd, subtitles, creative_commons, 360, vr180, 3d, hdr, location. Combined features must all match.
sort_bystringYouTube ranking: relevance (default) or popularity. Popularity is not a strict numerical view-count sort. Uses YouTube's current ranking choices.
popularity · relevance
qstringSearch query. Required for the first page; omit with page_token. Required on the first page.
hlstringYouTube interface language, such as en or pt-BR. Defaults to en. Omit with page_token.
glstringTwo-letter country code. Defaults to US. Omit with page_token.
spstringAdvanced YouTube filter token from a results URL. Use either sp or named filters, never both. Omit with page_token. Use either sp or named filters, never both. Raw or once-URL-encoded values from a YouTube results URL are accepted.
page_tokenstringOpaque next_page_token from the preceding response. Send it alone to continue the same search; tokens expire after one hour. Send page_token alone, without query, locale or filter parameters. It preserves all filters.
timeoutnumberSeconds may spend before giving up (max 50, default 50). A timed-out call is not billed.
Example: 50
