DeepSeek has released Search and Fetch APIs designed to provide agents and retrieval-augmented generation (RAG) applications with access to live web content, according to its API documentation.

The Search API finds web pages for a given query and returns structured results using DeepSeek’s in-house search engine. The Fetch API retrieves a single web page and returns its content formatted as Markdown. Both operate as raw JSON APIs and use the same bearer authentication as the standard DeepSeek API.
The Search API accepts several parameters, including the search query (required, 1 to 128 Unicode characters), result count (default 10, range 1-50), and an optional “ori_question” field to provide the user’s original question for improved query understanding. Developers can optionally request page content inclusion and specify localization via IP address.
The Search API supports multiple query operators for refined searching: the “site:” operator restricts results to specific domains, “-site:” excludes domains, “-” excludes specific terms, “-"…"” excludes exact phrases, “"…"” matches exact phrases, “lang:” restricts by language code, “after:” and “before:” filter by publication date. These operators can be combined in a single query.
Search results include a rerank score (0 to 3, with 1.5 or above indicating high-quality results), title, URL, snippet (100-200 characters), summary (600-800 characters), optional page content, site name, site icon, publication date in RFC 3339 format, and authority tier (0-4, with 3 or above indicating highly authoritative sources).
The Fetch API retrieves content from a specified URL (maximum 8192 characters, HTTP or HTTPS only, no embedded credentials) and returns the page title and content as Markdown text. Fetching is subject to target site availability and access policies.
Error handling follows OpenAI-compatible error formatting, with HTTP status codes ranging from 400 (invalid request) to 504 (downstream timeout). For rate limit errors (429), timeout errors (408), and server errors (5xx), the documentation recommends waiting and retrying. For insufficient account balance (402), users must top up before retrying.
Key facts
- DeepSeek Search and Fetch APIs provide live web content access for agents and RAG applications
- Search API uses DeepSeek’s in-house search engine and returns structured results with relevance scores
- Fetch API retrieves single web pages and returns content as Markdown
- APIs use bearer token authentication and cost $0.75 per 1000 successful requests
- Search API supports advanced query operators including site restrictions, exact phrase matching, language filtering, and date range filtering
- Search results include rerank scores (0-3), summaries, authority tiers, and optional full page content
