MCPcopy Create free account
hub / github.com/codeaashu/claude-code / prompt

Function prompt

src/tools/WebFetchTool/WebFetchTool.ts:181–190  ·  view source on GitHub ↗
(_options)

Source from the content-addressed store, hash-verified

179 }
180 },
181 async prompt(_options) {
182 // Always include the auth warning regardless of whether ToolSearch is
183 // currently in the tools list. Conditionally toggling this prefix based
184 // on ToolSearch availability caused the tool description to flicker
185 // between SDK query() calls (when ToolSearch enablement varies due to
186 // MCP tool count thresholds), invalidating the Anthropic API prompt
187 // cache on each toggle — two consecutive cache misses per flicker event.
188 return `IMPORTANT: WebFetch WILL FAIL for authenticated or private URLs. Before using this tool, check if the URL points to an authenticated service (e.g. Google Docs, Confluence, Jira, GitHub). If so, look for a specialized MCP tool that provides authenticated access.
189${DESCRIPTION}`
190 },
191 async validateInput(input) {
192 const { url } = input
193 try {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected