search_docs
Find documentation pages by keyword or phrase across all projects — use this when you don't already know the exact project, section, and page. Hybrid lexical ranking (full-text + BM25 + trigram) returns the best-matching pages first, each with a snippet (matched terms wrapped in bold) and per-page metadata. Structured results carry project, section, page, title, score, snippet, stability (stable or unstable), and markdownLink, plus summary, mtime, sha, and buildHash when available. buildHash is the corpus provenance stamp — cite it alongside any claim derived from these results. A plain-text fallback lists the same hits. Use get_page to fetch a page once you know its project, section, and page; use list_projects to enumerate available projects.
Input Schema
{
"type": "object",
"properties": {
"query": {
"type": "string",
"description": "Natural-language or keyword query (minimum 2 non-whitespace characters). Examples: \"linear types\", \"deploy install\", \"kli init\". Stopword-only or pure-negation queries return no results."
}
},
"required": [
"query"
]
}Example
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "search_docs",
"arguments": {
"query": "linear types"
}
}
}Applicable Error Codes
| Code | Name | When |
|---|---|---|
-32001 |
tool-not-found | The named MCP tool is not registered in the active server registry. |
-32002 |
tool-execution-error | A tool was invoked successfully but its body raised an error. |
-32003 |
resource-not-found | The requested MCP resource URI is not registered. |
-32004 |
prompt-not-found | The named MCP prompt is not registered. |
-32005 |
tool-example-invalid | A tool's bundled :example payload failed validation against its auto-generated :schema. |
-32600 |
invalid-request | JSON-RPC 2.0 invalid-request: the JSON is well-formed but does not conform to the JSON-RPC envelope. |
-32601 |
method-not-found | JSON-RPC 2.0 method-not-found: the requested method is not registered on the server. |
-32602 |
invalid-params | JSON-RPC 2.0 invalid-params: the request 'params' value is missing required fields or carries unexpected ones. |
-32700 |
jsonrpc-parse-error | JSON-RPC 2.0 parse-error: the server could not decode the incoming message as JSON. |