From 42cdd0bdf44e8ab85108d46e5eb177e95bc713cf Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Sat, 2 May 2026 04:42:51 +0100 Subject: [PATCH] docs(brave): redirect legacy search page --- CHANGELOG.md | 2 +- docs/.i18n/glossary.zh-CN.json | 4 ++ docs/brave-search.md | 106 ++------------------------------- 3 files changed, 10 insertions(+), 102 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 74a93fa949b..fdccc367355 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -44,7 +44,7 @@ Docs: https://docs.openclaw.ai - Web search: point missing-key errors to `web_fetch` for known URLs and the browser tool for interactive pages. Thanks @zhaoyang97. - Web search: late-bind managed agent `web_search` calls to the current runtime config snapshot, so existing sessions do not keep stale unresolved SecretRefs after secrets reload. Fixes #75420. Thanks @richardmqq. - Web search: honor `baseUrl` overrides for Gemini, Grok, and x_search provider-owned config, so proxy-backed search tools no longer dial hardcoded public endpoints. Supersedes #61972. Thanks @Lanfei. -- Web search/Brave: point Brave provider metadata at the canonical `/tools/brave-search` docs page. Fixes #65870 and supersedes #65892. Thanks @Magicray1217 and @Jah-yee. +- Web search/Brave: point Brave provider metadata at the canonical `/tools/brave-search` docs page and make the legacy `/brave-search` docs page a redirect stub. Fixes #65870 and supersedes #65892. Thanks @Magicray1217 and @Jah-yee. - Web search/Brave: allow `freshness` and bounded date ranges in `llm-context` mode, matching Brave's documented LLM Context API support. Supersedes #51005. Thanks @remusao. - Web fetch: resolve external plugin `webFetchProviders` for non-sandboxed `web_fetch`, while keeping sandboxed fetches limited to bundled providers. Fixes #74915. Thanks @ultrahighsuper and @mingmingtsao. - Heartbeat: strip legacy `[TOOL_CALL]...[/TOOL_CALL]` and `[TOOL_RESULT]...[/TOOL_RESULT]` pseudo-call blocks from heartbeat replies before channel delivery. Fixes #54138. Thanks @Deniable9570. diff --git a/docs/.i18n/glossary.zh-CN.json b/docs/.i18n/glossary.zh-CN.json index 272f75b8034..31358840c73 100644 --- a/docs/.i18n/glossary.zh-CN.json +++ b/docs/.i18n/glossary.zh-CN.json @@ -27,6 +27,10 @@ "source": "Azure Speech provider", "target": "Azure Speech provider" }, + { + "source": "Web tools", + "target": "Web 工具" + }, { "source": "Status", "target": "Status" diff --git a/docs/brave-search.md b/docs/brave-search.md index 716cd26f515..1579cdf3f08 100644 --- a/docs/brave-search.md +++ b/docs/brave-search.md @@ -1,107 +1,11 @@ --- -summary: "Brave Search API setup for web_search" -read_when: - - You want to use Brave Search for web_search - - You need a BRAVE_API_KEY or plan details -title: "Brave search (legacy path)" +summary: "Redirect to /tools/brave-search" +title: "Brave search" +redirect: /tools/brave-search --- -# Brave Search API - -OpenClaw supports Brave Search API as a `web_search` provider. - -## Get an API key - -1. Create a Brave Search API account at [https://brave.com/search/api/](https://brave.com/search/api/) -2. In the dashboard, choose the **Search** plan and generate an API key. -3. Store the key in config or set `BRAVE_API_KEY` in the Gateway environment. - -## Config example - -```json5 -{ - plugins: { - entries: { - brave: { - config: { - webSearch: { - apiKey: "BRAVE_API_KEY_HERE", - mode: "web", // or "llm-context" - }, - }, - }, - }, - }, - tools: { - web: { - search: { - provider: "brave", - maxResults: 5, - timeoutSeconds: 30, - }, - }, - }, -} -``` - -Provider-specific Brave search settings now live under `plugins.entries.brave.config.webSearch.*`. -Legacy `tools.web.search.apiKey` still loads through the compatibility shim, but it is no longer the canonical config path. - -`webSearch.mode` controls the Brave transport: - -- `web` (default): normal Brave web search with titles, URLs, and snippets -- `llm-context`: Brave LLM Context API with pre-extracted text chunks and sources for grounding - -## Tool parameters - -| Parameter | Description | -| ------------- | ------------------------------------------------------------------- | -| `query` | Search query (required) | -| `count` | Number of results to return (1-10, default: 5) | -| `country` | 2-letter ISO country code (e.g., "US", "DE") | -| `language` | ISO 639-1 language code for search results (e.g., "en", "de", "fr") | -| `search_lang` | Brave search-language code (e.g., `en`, `en-gb`, `zh-hans`) | -| `ui_lang` | ISO language code for UI elements | -| `freshness` | Time filter: `day` (24h), `week`, `month`, or `year` | -| `date_after` | Only results published after this date (YYYY-MM-DD) | -| `date_before` | Only results published before this date (YYYY-MM-DD) | - -**Examples:** - -```javascript -// Country and language-specific search -await web_search({ - query: "renewable energy", - country: "DE", - language: "de", -}); - -// Recent results (past week) -await web_search({ - query: "AI news", - freshness: "week", -}); - -// Date range search -await web_search({ - query: "AI developments", - date_after: "2024-01-01", - date_before: "2024-06-30", -}); -``` - -## Notes - -- OpenClaw uses the Brave **Search** plan. If you have a legacy subscription (e.g. the original Free plan with 2,000 queries/month), it remains valid but does not include newer features like LLM Context or higher rate limits. -- Each Brave plan includes **\$5/month in free credit** (renewing). The Search plan costs \$5 per 1,000 requests, so the credit covers 1,000 queries/month. Set your usage limit in the Brave dashboard to avoid unexpected charges. See the [Brave API portal](https://brave.com/search/api/) for current plans. -- The Search plan includes the LLM Context endpoint and AI inference rights. Storing results to train or tune models requires a plan with explicit storage rights. See the Brave [Terms of Service](https://api-dashboard.search.brave.com/terms-of-service). -- `llm-context` mode returns grounded source entries instead of the normal web-search snippet shape. -- `llm-context` mode does not support `ui_lang`, `freshness`, `date_after`, or `date_before`. -- `ui_lang` must include a region subtag like `en-US`. -- Results are cached for 15 minutes by default (configurable via `cacheTtlMinutes`). - -See [Web tools](/tools/web) for the full web_search configuration. +This page has moved to [Brave Search](/tools/brave-search). ## Related -- [Brave search](/tools/brave-search) +- [Web tools](/tools/web)