Skip to content

Commit bccd568

Browse files
authored
docs: websearch tool (#12359)
1 parent fd8c2fb commit bccd568

1 file changed

Lines changed: 33 additions & 0 deletions

File tree

packages/web/src/content/docs/tools.mdx

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,39 @@ Allows the LLM to fetch and read web pages. Useful for looking up documentation
286286

287287
---
288288

289+
### websearch
290+
291+
Search the web for information.
292+
293+
:::note
294+
This tool is only available when using the OpenCode provider or when the `OPENCODE_ENABLE_EXA` environment variable is set to any truthy value (e.g., `true` or `1`).
295+
296+
To enable when launching OpenCode:
297+
298+
```bash
299+
OPENCODE_ENABLE_EXA=1 opencode
300+
```
301+
:::
302+
303+
```json title="opencode.json" {4}
304+
{
305+
"$schema": "https://opencode.ai/config.json",
306+
"permission": {
307+
"websearch": "allow"
308+
}
309+
}
310+
```
311+
312+
Performs web searches using Exa AI to find relevant information online. Useful for researching topics, finding current events, or gathering information beyond the training data cutoff.
313+
314+
No API key is required — the tool connects directly to Exa AI's hosted MCP service without authentication.
315+
316+
:::tip
317+
Use `websearch` when you need to find information (discovery), and `webfetch` when you need to retrieve content from a specific URL (retrieval).
318+
:::
319+
320+
---
321+
289322
### question
290323

291324
Ask the user questions during execution.

0 commit comments

Comments
 (0)