GET / searches the web and returns the results; POST / returns the content of one page. Call them from your own application when a feature needs information from the web. You do not need a model or a chat request; they take your company's API key like every other API call (API authentication), and each successful call uses Premium tokens. For your first request and the base URL, see Use the API.
Send the search text in q:
curl -G https://platform.datamind.ai/llm/web/search \ -H "x-api-key: $DATAMIND_API_KEY" \ --data-urlencode "q=industry trends 2026"
query is read as an alias for q; if both carry a value, the one in q is used.A call without a search text is refused with Search query is required (use 'q' or 'query' parameter).
Send the page's address in url, in a JSON body:
curl https://platform.datamind.ai/llm/web/read \
-H "x-api-key: $DATAMIND_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "url": "https://example.com/report" }'url is required and must not be empty. A body that is not a JSON object is refused with Request body must be a JSON object, and an empty or missing url with 'url' is required.
Both endpoints relay the answer unchanged: your application receives the same status, body and content type that the service produced, including a non-success status. When the platform itself refuses the call, or cannot reach the service, the call fails with a DataMind error rather than a relayed answer; the shared statuses and codes are on Errors and retries.
Each successful call uses Premium tokens:
| Call | Premium tokens per successful call |
|---|---|
| Web search | 1,500 |
| Page read | 2,000 |
Only a call that succeeds (HTTP 200) uses tokens; a call that fails costs nothing. Every forwarded call is recorded. These calls draw on the same Premium tokens as your chat usage; the Web Search and Web Read tiles on Pricing show the rates, as searches and reads per 1M Premium tokens.
The same limits as chat requests apply: requests per minute, requests running at once, and the spend cap on billable usage. How the gates work is on Limits and the spend cap, and the codes a refused call carries are on Errors and retries.
| When | What the error says |
|---|---|
| No search text was sent | Search query is required (use 'q' or 'query' parameter) |
| The read body is not a JSON object | Request body must be a JSON object |
No url was sent, or it is empty | 'url' is required |
| Personal data, with Prohibit PII transmission on | Status 400, code content_filter; the call is not forwarded |
| The service that answers the call is briefly unavailable | Status 503, code service_unavailable; retry shortly |
The full status and code reference, and what to retry, is on Errors and retries.
A successful web search uses 1,500 Premium tokens, and a successful page read uses 2,000. The Web Search and Web Read tiles on Pricing show the same rates.
No. Only a call that succeeds (HTTP 200) uses Premium tokens. A call that fails, or that comes back with an error status, costs nothing.
Either: query is an alias for q. Send the text in one of the two; if both carry a value, the one in q is used.
Yes. Everything you add to the query string besides the search text is forwarded unchanged.
No. The answer is relayed as the service sent it: the same status, body and content type, including a non-success status. When the platform itself refuses the call, or cannot reach the service, the call fails with a DataMind error rather than a relayed answer (Errors and retries).
Yes. The same limits as chat requests apply: requests per minute, requests running at once, and the spend cap on billable usage. Limits and the spend cap explains when a call is refused.
Yes. With Prohibit PII transmission on, the search text and the URL are checked before the call is forwarded; a call with personal data is refused with status 400 and code content_filter and is not forwarded. See Settings.
The service that answers the call was briefly unavailable, so the call answered 503 with the code service_unavailable. Retry shortly.