Example Usage
import { DeferredToolsControl } from "@openrouter/sdk/models";
let value: DeferredToolsControl = {
profile: "portable",
protocol: "v1",
search: {
type: "bm25",
},
validation: "runtime",
};
Fields
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
interface | models.Interface | ➖ | How the universal profile exposes the hidden catalog to the provider. Absent or wrappers: the tool_search and tool_exec tools. code_mode: one tool_code tool that runs a short JavaScript program in which search() and call() reach the catalog, so several searches and calls complete in one tool result. Experimental. | |
profile | models.Profile | ✔️ | Loading profile. portable serves the defer_loading tools with router-built search and call wrappers on any model and keeps the catalog fixed. universal defers every wrappable tool behind the same wrappers so the provider-facing tool list never changes, and rebuilds the catalog from each request so tools can be added or removed mid-conversation. | |
protocol | models.Protocol | ✔️ | N/A | |
scope | models.DeferredToolsControlScope | ➖ | Which tools the universal profile defers. Absent or all: every wrappable tool outside the coding-harness core set. mcp: only MCP server tools (mcp__* names and Responses namespaces outside functions); the harness keeps its own built-in tools direct. Experimental. | |
search | models.DeferredToolsSearchStrategy | ✔️ | Router-local regex/BM25 or caller-owned custom search. | { “max_results”: 5, “type”: “bm25” } |
validation | models.Validation | ✔️ | Where tool-call arguments are checked against the original schema. Only runtime (in OpenRouter) is available in this release. |