How can search support be checked before calling a Claude model?

The Citead team, updated

In short. Read capabilities.server_tools.web_search.supported before sending a Claude API request with web search.

Definition: In the Claude API, search support is a model capability exposed by the Models API. Before sending a Messages API request with the web search server tool, read capabilities.server_tools.web_search.supported for the model you intend to use.

Key facts

  • Anthropic's web search tool documentation tells you to read capabilities.server_tools.web_search.supported before sending a request.
  • The Models overview says that each available model response includes max_input_tokens, max_tokens, and a capabilities object.
  • The Models API reference defines server_tools for web search and code execution. Its parent supported value covers either tool.
  • A true web_search.supported value covers at least one web search tool version. It does not select every version or establish that organization settings allow the request.

What does the Models API expose?

The Models API lists available models at GET /v1/models. Each model record has an id and a capabilities object. The API reference describes that object as a mapping of capability names to support details, and the capabilities value can be null.

For search, inspect the nested field below. The parent server_tools.supported value answers a broader question because Anthropic defines it as true when the model supports at least one of web search or code execution. The nested web search field answers the model-level check for the tool named in this entry.

"server_tools": {
  "code_execution": {
    "supported": true
  },
  "supported": true,
  "web_search": {
    "supported": true
  }
}

Anthropic's Models overview also separates this server-tool capability from the top-level code_execution capability. The latter describes whether code run by the code execution tool can call other tools, including web search during programmatic tool calling.

How can an application check one model?

Use GET /v1/models/{model_id} when the application already has one model identifier or alias. The Models API reference documents both forms and says that the response can resolve an alias to a model ID. Read the returned field before constructing the Messages API tools array.

The list endpoint can also support a model picker. The API documents active, deprecated, and retired lifecycle filters, and says that more recently released models are listed first. A picker can therefore retain the model identifier returned by the API while displaying the human-readable display_name.

For a direct API check, Anthropic's documented request is:

curl https://api.anthropic.com/v1/models \
    -H 'anthropic-version: 2023-06-01' \
    -H "X-Api-Key: $ANTHROPIC_API_KEY"

The response example contains id: "claude-opus-5-5" and the nested web_search support field. A caller using the single-model endpoint can apply the same field test to that record.

What can still affect the request?

The capability value describes model support. Anthropic's web search documentation says web search is enabled for an organization unless an administrator disables it in the Claude Console. When it is disabled, a request that includes the tool fails with a 400 invalid_request_error.

Deployment also matters. The documentation lists web search for the Claude API, Claude Platform on AWS, and Microsoft Foundry. Google Cloud has the basic web search tool only, while Amazon Bedrock has no web search availability in this documentation. A true model field therefore needs to be read together with the platform and organization configuration.

The documentation lists web_search_20250305 for basic search, web_search_20260209 for dynamic filtering, and web_search_20260318 for response inclusion control. The Models API field reports support for at least one version, so the chosen version needs its own platform check. For dynamic filtering, the web search documentation says that allowed_callers defaults to code_execution_20260120; setting allowed_callers: ["direct"] calls web search directly.

FAQ

Does server_tools.supported answer whether web search is available?

No. Anthropic's Models overview defines that parent value as support for at least one of web search and code execution. Read server_tools.web_search.supported for the web search check.

Does a true web search capability cover every tool version?

No. The Models overview says that the value is true when the model accepts at least one version, so the selected web search version still needs to be checked against the deployment documentation.

The web search documentation says that a request including the tool fails with a 400 invalid_request_error when web search is disabled for the organization.

Sources

  1. Anthropic, "Web search tool", undated
  2. Anthropic, "Models overview", undated
  3. Anthropic, "Models", undated

Check how a page reads to answer engines. Open the GEO score analyzer

Test a page and see what to fix first

The analysis usually takes less than 10 seconds and needs no account.

400,000+ pages scored in the public benchmark