From fc6d53c895df64f6e7350354b907e0d775d151a0 Mon Sep 17 00:00:00 2001 From: smartprogrammer93 Date: Mon, 16 Feb 2026 21:35:48 +0000 Subject: [PATCH] fix: correct import path in test and restore deleted schema help entries --- src/agents/tools/web-tools.url-allowlist.test.ts | 2 +- src/config/schema.help.ts | 15 ++++++++++----- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/agents/tools/web-tools.url-allowlist.test.ts b/src/agents/tools/web-tools.url-allowlist.test.ts index c3dbb24b6ce..d95c6496994 100644 --- a/src/agents/tools/web-tools.url-allowlist.test.ts +++ b/src/agents/tools/web-tools.url-allowlist.test.ts @@ -1,5 +1,5 @@ import { describe, expect, it } from "vitest"; -import type { OpenClawConfig } from "../config/config.js"; +import type { OpenClawConfig } from "../../config/config.js"; import { isUrlAllowedByAllowlist, resolveFetchUrlAllowlist } from "./web-fetch.js"; import { filterResultsByAllowlist, resolveUrlAllowlist } from "./web-search.js"; diff --git a/src/config/schema.help.ts b/src/config/schema.help.ts index b8f16123db2..e46af66b93d 100644 --- a/src/config/schema.help.ts +++ b/src/config/schema.help.ts @@ -93,13 +93,18 @@ export const FIELD_HELP: Record = { "tools.web.search.enabled": "Enable the web_search tool (requires a provider API key).", "tools.web.search.provider": 'Search provider ("brave" or "perplexity").', "tools.web.search.apiKey": "Brave Search API key (fallback: BRAVE_API_KEY env var).", - "tools.web.search.urlAllowlist": - "Optional URL/domain allowlist for web_search. When configured, Brave search results are filtered to only include URLs from allowed domains.", + "tools.web.search.maxResults": "Default number of results to return (1-10).", + "tools.web.search.timeoutSeconds": "Timeout in seconds for web_search requests.", + "tools.web.search.cacheTtlMinutes": "Cache TTL in minutes for web_search results.", + "tools.web.search.perplexity.apiKey": + "Perplexity or OpenRouter API key (fallback: PERPLEXITY_API_KEY or OPENROUTER_API_KEY env var).", + "tools.web.search.perplexity.baseUrl": + "Perplexity base URL override (default: https://openrouter.ai/api/v1 or https://api.perplexity.ai).", + "tools.web.search.perplexity.model": + 'Perplexity model override (default: "perplexity/sonar-pro").', "tools.web.urlAllowlist": - "Optional URL/domain allowlist shared by web_search and web_fetch. Accepts domain patterns like 'example.com', '*.github.com', 'docs.openclaw.ai'. When configured, only matching URLs are allowed.", + "Optional URL/domain allowlist shared by web_search and web_fetch. Accepts domain patterns like 'example.com', '*.github.com'. When configured, only matching URLs are allowed.", "tools.web.fetch.enabled": "Enable the web_fetch tool (lightweight HTTP fetch).", - "tools.web.fetch.urlAllowlist": - "Optional URL/domain allowlist for web_fetch. When configured, only URLs matching these patterns can be fetched.", "tools.web.fetch.maxChars": "Max characters returned by web_fetch (truncated).", "tools.web.fetch.maxCharsCap": "Hard cap for web_fetch maxChars (applies to config and tool calls).",