{"uid":"cap_fwnBU1Y4B154sNDkA4VeQ","slug":"toolroute-by-youraitools-b795a587","name":"ToolRoute by YourAITools","description":"Tool selection API for AI agents (tool routing). Pick the tools an agent needs for a task from a large tool list: send set_id (from the free /v1/register) or tools, plus the task. Returns a ranked shortlist (adaptive 3-12, or k), confidence, matched terms, token savings and the definitions in MCP, OpenAI, Anthropic or Gemini form. BM25, no LLM. Unknown set_id: 404, never charged.","url":"https://api.youraitools.co/toolroute/v1/route?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["query"],"properties":{"k":{"type":"integer","maximum":50,"minimum":1,"description":"Fixed shortlist size (default adaptive)"},"max_k":{"type":"integer","maximum":50,"minimum":1,"description":"Upper bound for the adaptive size (default 12)"},"query":{"type":"string","description":"The task or user request to route, e.g. \"check if this wallet is sanctioned\"."},"tools":{"type":"array","items":{"type":"object"},"description":"Tool definitions (MCP, OpenAI, Anthropic, Gemini or Bedrock form), max 500. For route: only if you have no set_id (the set is registered on the fly)."},"format":{"enum":["mcp","openai","anthropic","gemini","names"],"type":"string","description":"Definition format (default mcp; names = names only)"},"set_id":{"type":"string","description":"set_id (\"ts_...\" from register, or a ToolFit pin)."}},"description":"Search intents: tool routing, tool selection api, reduce tool tokens, rag over tools, mcp tool router, pick tools for task"}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","properties":{"query":{"type":"string"},"set_id":{"type":"string"},"tokens":{"type":"object"},"widened":{"type":"boolean"},"shortlist":{"type":"array"},"confidence":{"type":"string"}}}}}}},"responseSchema":{"type":"json","example":{"query":"read a web page as markdown","set_id":"ts_0d467a406d3eb14344c41c32d8802268","tokens":{"all":11585,"saved_pct":89,"shortlist":1278},"widened":false,"shortlist":[{"name":"read_url","score":14.23,"matched":["read","web","page","markdown"]},{"name":"scan_url","score":8.09,"matched":["read","web","page"]},{"name":"detect_stack","score":7.05,"matched":["web","page"]}],"confidence":"high"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_l-JveeT1M7rutnglxlDpi","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Selects and ranks the most relevant tools from a large toolset for a given task using BM25, returning a shortlist with confidence scores and token-saving stats.","exampleAgentPrompt":"I have a registered tool set with ID ts_0d467a406d3eb14344c41c32d8802268 — can you use ToolRoute to find the best tools for the task 'check if this wallet is sanctioned', return up to 5 results in OpenAI format?","exampleUseCases":[{"title":"Slim agent context before LLM call","prompt":"I have 300 tools registered under set_id ts_abc123 and my agent needs to answer 'summarize and translate a PDF'. Use ToolRoute to pick the top 8 most relevant tools in MCP format so I don't blow my token budget."},{"title":"On-the-fly tool routing without registration","prompt":"I don't have a set_id yet — here are my 20 tool definitions as JSON objects. Use ToolRoute to find which ones best match the task 'send an email with an attachment', and give me the shortlist in OpenAI format with confidence info."},{"title":"Adaptive tool selection for crypto compliance task","prompt":"Route the task 'screen a blockchain address for sanctions and AML risk' against my registered toolset ts_xyz789 and return whatever adaptive shortlist size makes sense, in Anthropic format, so I can see which tools are most relevant."}],"resultDescription":"Returns a JSON object with the original query, set_id, a ranked shortlist of tools (each with name, BM25 score, and matched terms), a confidence level (high/medium/low), token counts for the full set vs shortlist plus percentage saved, a widened flag, and full tool definitions in the requested format (MCP, OpenAI, Anthropic, Gemini, or names-only).","failureModes":["Unknown set_id returns 404 and the caller is never charged","Malformed tool definitions in the tools array may result in no matches or low confidence","Query too vague may return low-confidence shortlist with many weakly matched tools","Exceeding max 500 tools in the tools array will be rejected","k or max_k out of range (1-50) returns validation error"],"whenToPreferThis":"Choose ToolRoute when your agent has a large toolset (50+ tools) and you need to cheaply narrow it down to a relevant shortlist before passing tool definitions to an LLM, saving context tokens. It uses BM25 (no LLM call) so it is fast and deterministic. Prefer it over embedding-based tool selectors when you want transparent keyword matching and matched-term explanations. Best when you have a pre-registered tool set (set_id) for minimal per-call overhead, or when you want to route on-the-fly with inline tool definitions.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-25T12:31:07.137Z","isFirstParty":false,"canonicalSlug":"toolroute-by-youraitools-b795a587"}