BetaServer tools are currently in beta. The API and behavior may change.
Server Tools vs Plugins vs User-Defined Tools
Server tools are tools the model can invoke zero or more times during a request. OpenRouter handles execution transparently.
Plugins inject or mutate a request or response to add functionality (e.g. response healing, PDF parsing). They always run once when enabled.
User-defined tools are standard function-calling tools where the model suggests a call and your application executes it.
The Web Search plugin (
plugins: [{ "id": "web" }]) is deprecated. Use the openrouter:web_search server tool instead. See Migrating from the Web Search Plugin.
Available Server Tools
Tools API
The tools catalog is available programmatically.GET /api/v1/tools lists every server tool. GET /api/v1/tools/{name} returns one tool, by canonical name or any accepted alias, with the list of models that run it natively.
How Server Tools Work
- You include one or more server tools in the
toolsarray of your API request. - The model decides whether and when to call each server tool based on the user’s prompt.
- OpenRouter intercepts the tool call, executes it server-side, and returns the result to the model.
- The model uses the result to formulate its response. It may call the tool again if needed.
Native Execution
Some providers have a built-in version of a server tool. For example, OpenAI and Anthropic (as well as other providers) have built-in web search tools. When the model’s endpoint has a “native” version of a tool available, OpenRouter can request the tool to be executed through the provider instead of running its own engine. This is thenative engine in the server tool configuration.
Which endpoints run a tool natively
Each endpoint object returned by the endpoints API has anative_tools field. The key is the canonical OpenRouter server tool name. For example, for web search, it is openrouter:web_search. The value is the name of the provider’s tool. For most tools the provider runs it. Bash is the exception: Anthropic’s built-in bash tool returns the command to your application, which runs it. See Bash.
Privacy and regional availability
Each server tool has an execution path, an In-Region Routing (IRR) availability, and its own data handling. Model-provider ZDR enforcement and IRR apply to the inference request. A tool backend is covered only where the table below states it.Execution paths
- Provider: the model’s provider runs the tool natively. See Native Execution.
- OpenRouter: OpenRouter runs the tool in-process, in an OpenRouter-operated sandbox, in an inner model generation, or by calling a third-party service such as Exa, Parallel, Perplexity, or Firecrawl.
- Client: OpenRouter returns the tool call to your application, which runs it.
Server tool matrix
The
GET /api/v1/tools response lists each tool’s engines with executed_by and data_regions.
ZDR enforcement
ZDR settings restrict which provider endpoints serve model inference. They do not disable server tools or plugins, and they do not change the retention policy of a third-party backend. OpenRouter enforces one tool-level ZDR rule: when ZDR is enforced in your privacy settings or a guardrail, Web Search, Web Fetch, and the Web Search plugin reject the Firecrawl engine. No other tool backend is filtered by ZDR. Review each third-party service’s retention policy before you enable a tool that calls it.IRR availability
A regional request passes two gates:- Request admission. The regional hostname (
eu.openrouter.aiorus.openrouter.ai) and any guardrailallowed_data_regionsdecide whether the request is accepted. See In-Region Routing. - Execution residency. Each server tool and plugin engine is then checked against the request’s region. With
engine: "auto"or no engine, OpenRouter selects only engines resident in that region. A pinned engine that is not resident in the region is rejected.
403 error, and the Web Search plugin returns a 400 error. OpenRouter does not fall back to global infrastructure. Remove the tool or send the request to https://openrouter.ai.
On regional endpoints, client-side Bash is rejected when the same request includes another server tool without an in-region native path. Apply Patch and Advisor have in-region native paths; the other server tools do not.
Tool Call Limits
Every request that uses server tools runs an agent loop with a step budget. Each tool call the model makes (a web search, an image generation, etc.) consumes one step; when the budget is exhausted, the model is asked to produce its final answer with the context gathered so far. Two top-level request fields control the outer loop (both are siblings ofmessages and tools):
Tools that run their own inner agent loops have separate, per-tool budgets configured via the tool’s
parameters:
These inner budgets bound each panelist or worker model’s own tool loop and are independent of the outer request budget.
Quick Start
Add server tools to thetools array using the openrouter: type prefix:
Combining with User-Defined Tools
Server tools and user-defined tools can be used in the same request:Usage Tracking
Server tool usage is tracked in the responseusage object:
Next Steps
- Web Search. Search the web for real-time information
- Datetime. Get the current date and time
- Image Generation. Generate images from text prompts
- Web Fetch. Fetch and extract content from URLs
- Apply Patch. Propose file edits via V4A diffs
- Shell. Run commands in a hosted, sandboxed shell
- Bash. Anthropic-style bash tool with optional sandboxed server-side execution
- Fusion. Run a panel of models and an analyst for multi-model analysis
- Advisor. Consult a stronger model for guidance mid-generation
- Subagent. Delegate self-contained tasks to a smaller, faster worker model
- Search Models. Search and filter the OpenRouter model catalog
- Tool Calling. Learn about user-defined tool calling