
Company News
Free Business Plan Upgrades for Open Source Maintainers
Open source maintainers are under more pressure than ever. We're raising our open source program from the Team plan to the Business plan, free.
@toolroute/sdk
Advanced tools
Agent tool routing in two lines. ToolRoute tells your agent which MCP server to use — backed by real execution data from thousands of agents.
import { ToolRoute } from '@toolroute/sdk'
const tr = new ToolRoute()
// 1. Get a recommendation
const route = await tr.route({ task: 'extract pricing data from competitor websites' })
console.log(route.recommended_skill) // "firecrawl-mcp"
// 2. Execute the tool (your code)
const result = await runSkill(route.recommended_skill, task)
// 3. Report the outcome — earns routing credits
await tr.report({
skill: route.recommended_skill,
outcome: result.success ? 'success' : 'failure',
latency_ms: result.latency,
cost_usd: result.cost
})
That's it. Three calls. Your agent now routes intelligently and contributes to the global benchmark dataset.
npm install @toolroute/sdk
new ToolRoute(config?)| Option | Type | Default | Description |
|---|---|---|---|
baseUrl | string | https://toolroute.io | ToolRoute API base URL |
timeoutMs | number | 800 | Hard timeout — ToolRoute never blocks your agent |
agentName | string | — | Agent name for telemetry attribution |
agentKind | string | — | autonomous, copilot, workflow-agent, evaluation-agent, hybrid |
modelFamily | string | — | e.g., claude-4, gpt-4o |
hostClient | string | — | e.g., claude-code, cursor |
tr.route(request)Get a confidence-scored tool recommendation.
const route = await tr.route({
task: 'browser automation for form filling', // natural language
constraints: {
priority: 'best_value', // best_value | best_quality | lowest_cost | ...
trust_floor: 7, // minimum trust score (0-10)
max_cost_usd: 0.05, // cost ceiling
}
})
// Response:
// {
// recommended_skill: "playwright-mcp",
// confidence: 0.85,
// alternatives: ["skyvern-mcp", "chrome-devtools-mcp"],
// recommended_combo: ["playwright-mcp", "firecrawl-mcp"],
// fallback: "skyvern-mcp",
// scores: { value_score: 9.1, output_score: 9.3, ... }
// }
tr.report(request)Report execution outcome. Fire-and-forget — never blocks.
await tr.report({
skill: 'firecrawl-mcp',
outcome: 'success', // success | partial_success | failure | aborted
latency_ms: 2400,
cost_usd: 0.003,
quality_rating: 8.5, // 0-10
task_fingerprint: 'pricing-extraction-001',
fallback_skill: 'exa-mcp', // if a fallback was used
})
tr.preflight()Health check. Never throws.
const health = await tr.preflight()
// { healthy: true, latency_ms: 45, version: "1.1.0" }
tr.missions(eventSlug?)List available benchmark missions for bonus rewards.
const { missions } = await tr.missions('web-research-extraction')
| Contribution Type | Multiplier |
|---|---|
| Run telemetry | 1.0x |
| Fallback chain report | 1.5x |
| Comparative evaluation | 2.5x |
| Benchmark package | 4.0x |
MIT
FAQs
ToolRoute SDK — route, execute, report. Two-line agent integration.
The npm package @toolroute/sdk receives a total of 239 weekly downloads. As such, @toolroute/sdk popularity was classified as not popular.
We found that @toolroute/sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Open source maintainers are under more pressure than ever. We're raising our open source program from the Team plan to the Business plan, free.

Security News
The supply chain control that delays freshly published gems now covers lockfile generation and gem vendoring in Ruby projects.

Security News
During a UK cyber test, a Mythos 5 agent used sockpuppets, social engineering, and prompt injection to try to get a maintainer to merge malware.