# Agent Web Search Setup

Fixes web search on an agent whose model backend can't run it: a relay/reseller...

- Repository: https://github.com/daymade/claude-code-skills (1509 stars)
- Category: AI and agents
- License: MIT
- Last updated: 2026-11-01
- Runs scripts: yes, review before use

## Install

Claude Code: `npx skills add daymade/claude-code-skills --skill agent-web-search-setup -g -a claude-code -y`
Codex: `npx skills add daymade/claude-code-skills --skill agent-web-search-setup -g -a codex -y`
Cursor: `npx skills add daymade/claude-code-skills --skill agent-web-search-setup -g -a cursor -y`
Gemini CLI: `npx skills add daymade/claude-code-skills --skill agent-web-search-setup -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add daymade/claude-code-skills`

## Description

Fixes web search on an agent whose model backend can't run it: a relay/reseller proxying Claude or Codex returns empty instead of failing. Use when web search returns nothing, a model insists a shipped product doesn't exist, someone wants to give an agent internet access, or the user is on a third-party base URL, relay, or 中转站. Diagnoses which built-in tools are dead, removes them, and installs a working replacement.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Agent Web Search Setup

A model backend that cannot search is not the same as a model that searched and
found nothing, but from inside the conversation the two look identical. This
skill turns the first into the second, on whichever agent is in front of you.
It configures the agent's tools; it is not itself a search engine, so nothing
here answers a query directly, the proof of done is the agent's own session
calling a real tool.

## What actually breaks

Anthropic's `web_search` and `web_fetch` are **server tools**: the API runs them
during the request and splices results into the same response. OpenAI's Responses
API `web_search` works the same way. The client only ever declares the tool.

A reseller that proxies to another cloud cannot execute those. Anthropic's own
documentation states that web fetch is unavailable on Amazon Bedrock and Google
Cloud; search was measured failing the same way on both. What comes back is not
an error. It is an empty shell, so the model concludes the topic does not exist
and says so with total confidence. That is the whole bug, and it is why users
report their agent has "gotten stupid" rather than reporting a broken tool.

Three things follow, each of which cost real time to establish:

- **Switching models does not help.** One reseller was measured routing four
  model names to three different backends; none produced a working search.
- **`web_fetch` breaks with it.** Fixing only search moves the failure from "I
  found nothing" to "I found links but cannot open them."
- **Installing an alternative is not enough on its own.** With the dead tool
  still on the menu, a model made 21 web-search calls and 0 calls to an installed
  alternative whose description said the built-in was broken. Built-in tools win
  head-to-head. **The dead tool has to be removed, or nothing else you do
  matters.**

## 1. Prove it, on this machine

Do not take the user's word for which tool is broken, and do not take yours.

The rest: https://github.com/daymade/claude-code-skills/blob/HEAD/daymade-claude-code/agent-web-search-setup/SKILL.md
