Anthropic has launched a new API that enables its Claude AI models to search the web, allowing developers to build applications that deliver current information. The company announced the rollout in a press release on Wednesday.
The API is part of Anthropic’s efforts to enhance its models and attract new customers. Last week, the company introduced a tool to connect applications to Claude and expanded its “deep research” capability, enabling Claude to search enterprise accounts, websites, and more.
According to Anthropic, developers can now “augment Claude’s comprehensive knowledge with current, real-world data by enabling the web search tool when making requests to [our] API.” This allows developers to build AI solutions that tap into current information without managing their own web search infrastructure.
When enabled, Claude uses its “reasoning” capabilities to determine whether a request requires up-to-date information or specialized knowledge. If necessary, Claude generates a search query, retrieves results, analyzes them, and provides an answer with citations. It can also refine its queries and conduct multiple searches, using earlier results to inform subsequent queries.
Which one to go for: Claude 3 Sonnet vs. Opus vs. Haiku
Developers can customize Claude’s behavior, specifying allowed and prohibited domains, as well as enabling or disabling web search at the organization level. Pricing for the API starts at $10 per 1,000 searches, and it is compatible with Anthropic’s Claude 3.7 Sonnet, Claude 3.5 Sonnet, and Claude 3.5 Haiku models.
The web search feature is also being integrated into Claude Code, Anthropic’s tool that allows developers to use Claude for coding tasks. With web search enabled, Claude Code can access current API documentation, technical articles, and other information on development tools and libraries. Claude Code remains in beta as a research preview.