Call it
curl https://api.peume.com/v1/call/youtube-search-the-web \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"query": "your query"
}
}'const res = await fetch("https://api.peume.com/v1/call/youtube-search-the-web", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"query": "your query"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/youtube-search-the-web",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"query": "your query"
}
},
)
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: youtube-search-the-web.
Parameters
queryRequiredstringThe search query.
max_resultsintegerResults to return (1-50, default 5).
crawl_resultsintegerFetch the full page content of this many top results in the same call (0-50, default 0; at most max_results). Each page that comes back adds the per-page price.
imagebooleanAlso return an `images` array (default false).
include_sitesarrayOnly return results from these domains, e.g. ['github.com']; a subdomain counts (old.reddit.com is on reddit.com). drops every other row from the answer, so fewer than max_results (or none) can come back; the number dropped is reported as filteredOutResults.
exclude_sitesarrayDrop results from these domains (subdomains included).
languagestringResult language code, e.g. 'en', 'zh-CN', 'fr'. There is no country parameter.
time_rangestringOnly results from the last day, week, month, or year.
· day · week · month · year
search_servicestringEngine to search. Omit to query several engines and their rankings. Web: google, bing, duckduckgo, yahoo, yandex; Chinese: bingcn, baidu, 360, quark, wechat, bilibili; community and reference: reddit, x, github, youtube, arxiv, wikipedia, imdb.
360 · · google · bing · bingcn · duckduckgo · yahoo · yandex · youtube · x · reddit · github …
pageintegerNative result page (1-100, default 1). Honoured by bing, bingcn and baidu only; other engines return page 1.
