Web search
The WebSearch tool gives the model real-time web grounding. One tool name, several execution paths — picked automatically per channel:
| Channel | Path |
|---|---|
Anthropic (anthropic, and Anthropic-protocol customs) | Server-side web_search declaration (native) |
DeepSeek Anthropic (deepseek-anthropic) | Same Anthropic-style server-side search on DeepSeek's /anthropic endpoint |
| Gemini | Built-in googleSearch grounding (native) |
xAI Grok (xai, xai-oauth, or base URL on api.x.ai) | Client POST …/responses with built-in {"type":"web_search"} (Grok Build parity; tool name stays WebSearch) |
Everyone else (plain deepseek OpenAI-compat, Kimi, MiniMax, custom proxies, …) | AnySearch HTTP fallback (needs key) |
All paths render the same unified, clickable Sources: footer under the answer.
Prefer channels with built-in search
For DeepSeek, use deepseek-anthropic (not plain deepseek) if you want native search without AnySearch. For Grok, use xai-oauth or xai — search does not require AnySearch when the Responses path succeeds.
Setting up AnySearch
Non-native channels need an AnySearch API key — sign up and create one at the official site: anysearch.com. Three equivalent ways to configure it:
# 1. persist in config (recommended)
hipmmcode config set anysearchApiKey=as_sk_...
# 2. in the REPL
/anysearch key=as_sk_...
# 3. environment (not persisted)
export ANYSEARCH_API_KEY=as_sk_... # or ANYSEARCH_KEYResolution order: config → ANYSEARCH_API_KEY → ANYSEARCH_KEY.
The /anysearch panel
Typing /anysearch with no arguments (alias /search) opens an interactive picker — the header shows the current state and the masked key; ↑/↓ to move, Enter to confirm, Esc to cancel:
› /anysearch AnySearch current: on · key: as_sk_…9f2c ❯ Enable — turn on WebSearch fallback for non-native providers (active) Disable — turn off; tools that need search will fail explicitly Set API key — enter a new key (free-form input on next screen) ↑/↓ move · Enter confirm · Esc cancel
Choosing Set API key drops to a free-form input screen:
Paste your AnySearch API key (as_sk_...): █
The key is persisted to config and takes effect immediately — no restart.
Toggles
| Command / key | Effect |
|---|---|
/anysearch on|off (alias /search) — or anysearchEnabled | Enable/disable the AnySearch fallback; /anysearch key=… sets the key inline. Bare form opens the panel above |
/nativesearch on|off (alias /native) — or nativeSearchEnabled | Enable/disable provider-native search. Off forces every channel through AnySearch, useful when you want one consistent search backend. Bare /nativesearch opens the same two-row Enable / Disable picker with the current state marked (active) |
WebFetch
WebFetch complements search: it fetches a specific URL, converts the page to text, and reads it. No key required.
Verifying
Ask something time-sensitive on your channel of choice:
› what was announced at the latest Rust release?You should see a WebSearch tool card and a Sources: footer with clickable links. If instead you get "WebSearch needs an API key", set anysearchApiKey as above; if you get "WebSearch is disabled", run /anysearch on.