Skip to content

Function: webFetchTool()

webFetchTool(opts?): Tool<{ format?: "text" | "html"; maxLength?: number; url: string; }, { content: string; contentType?: string; status: number; title?: string; truncated: boolean; url: string; }, unknown, unknown, ToolExecutionContext<unknown, unknown, unknown>, string, unknown>

Build the web_fetch tool. Spread it into the agents that should be able to read a page’s contents.

WebSearchToolOptions = {}

Tool<{ format?: "text" | "html"; maxLength?: number; url: string; }, { content: string; contentType?: string; status: number; title?: string; truncated: boolean; url: string; }, unknown, unknown, ToolExecutionContext<unknown, unknown, unknown>, string, unknown>

import { webFetchTool } from "@dbx-tools/appkit-web-search";
tools: () => ({ web_fetch: webFetchTool({ approval: "*.internal.example.com" }) })