1. readfetch
  2. choose
  3. /v1/search

Search · Scale and monitoring

POST/v1/search

Web search without a search subscription, returning titles, URLs and snippets.

  • $0.005
  • query
  • lang

What it does

Run a web search without a separate search API subscription. Returns titles, URLs, and snippets only — not full page text; follow with readfetch_text, readfetch_probe, or readfetch_scrape on a chosen result URL. `limit` is 1–20 (default 5). Optional `lang` biases locale (e.g. en, de-DE). Optional `tbs` filters recency: h= past hour, d= day, w= week, m= month, y= year. Use readfetch_map/readfetch_crawl when you already know the site; readfetch_* URL tools when you have the link.

Price

Quoted by the 402 before anything runs.

  • $0.005per call
  • billedonly when content is delivered
  • no keythe payment is the credential

When to call it

Cheapest endpoint that answers the question, first.

Call it when the sentence above is the whole job. Its neighbours solve the same URL with a different trade-off — a browser instead of plain HTTP, a site instead of one page, one section instead of a document. /choose walks the decision, cheapest first, browser last.

Unsure whether another URL is worth paying for at all? /v1/probe is free: metadata plus the full extracted text on the first 3 probes per IP per day (a ~400-character preview after that) before you pay for a priced route.

Request fields

JSON body shape for POST /v1/search — use with the client snippets below, not as a bare POST.

FieldTypeDefaultWhat it does
query requiredstring—Search query string.
limitnumber5Maximum number of results to return (default 5).
langstring—Optional language/locale hint, e.g. en or de-DE.
tbsstring—Optional recency filter: h=hour, d=day, w=week, m=month, y=year.

Make the call

Unpaid REST stops at 402. Use readfetch-client, @readfetch/client, or MCP @readfetch/mcp-x402-proxy — they sign x402 and retry. The JSON below is the argument shape for call() / route helpers.

example body
{
  "query": "readfetch"
}

readfetch-client / @readfetch/client (latest+) handle x402 on paid routes — full API on /integrations#clients.

python
# pip install readfetch-client
# export EVM_PRIVATE_KEY=0x…
import asyncio
from readfetch_client import call

async def main():
    data = await call(
        "search",
        {
          "query": "readfetch"
        },
    )

asyncio.run(main())
javascript
// npm install @readfetch/client
// export EVM_PRIVATE_KEY=0x…
import { call } from "@readfetch/client";

const data = await call("search", {
  "query": "readfetch"
});

Response

Fields shown are the ones a caller branches on.

200 ok
{
  "billed": true,
  "hint": null,
  "query": "rust async runtime",
  "results": [
    {
      "position": 1,
      "snippet": "...",
      "title": "Tokio",
      "url": "https://tokio.rs/"
    }
  ],
  "status": "success"
}

Limits

Requests are JSON, 1 MiB maximum. Redirects are re-validated at every hop and capped at 5; the final URL is reported. Every call runs on one whole-call budget — DNS, connect, redirects, retries and any render share that clock, and no step starts a fresh timer. Where the endpoint publishes a timeout_s, its default and ceiling are the whole-call budget in the strip above. A budget that expires mid-walk returns status: "partial", and nothing is charged for what was not delivered.

Failures come back as {"error": "…", "hint": "…"} with a status to branch on. Shapes: /docs#errors.

Billing

$0.005 per delivered call. A response with billed: false settles nothing and names the next call to try.

billed: false on 200 usually means empty upstream results. 502/504 settle nothing.

RECEIPT, claims, and billing rules: /docs#billing.

Settlement, receipts and claims: /docs.