HTTP API
The jevlin binary is one client of a public HTTP API, and anything that can send JSON over HTTPS can use it the same way. One project key authenticates every call, and an agent can register for a key without a person.
These pages are for calling the API yourself. If you use Jevlin through a coding agent, the binary already does all of this; start at the quickstart instead.
Hosts
| host | serves |
|---|---|
https://api.jevlin.ai | The search API: search, stream, fetch, decisions, fast presets, traces, feedback, judge, limits, turns, rollouts, account, and the public /healthz. |
https://agents-v1.jevlin.ai | Agent onboarding: register, the status poll, self-lookup and a fresh claim code. See How an agent gets an API key. |
https://platform.jevlin.ai | The platform people sign in to: keys, limits, credit, traces and the claim page at /claim. Not called with a key. |
Authentication
Send Authorization: Bearer sr-… on every call except registration and /healthz. Keys start with sr-. Create one on a project's API keys page on the platform, or let an agent register for one. Never put a key in a URL, a query string or a log line.
A key can be limited to some of three scopes, search, read and limits; the table below says which one each route needs, and a key with no scopes may do everything. See Limits, keys and headers.
All three hosts sit behind Cloudflare, so send a real User-Agent. curl's and Go's defaults pass; Python's default urllib agent is challenged.
Endpoints
| method · path | scope | spend-free | what it does |
|---|---|---|---|
POST /v1/search | search | no | One query, sent to several search providers at once, ranked, with costs and a trace id. Search |
POST /v1/search/stream | search | no | The same search, streamed as NDJSON events as each provider answers. Search |
POST /v1/fetch | search | no | The full text of up to five pages your own recent searches returned. Read a page in full |
POST /v1/decisions | search | no | Typed questions about a state, answered by a decision model with probabilities. Not offered on the hosted service yet: 503 decisions_disabled. Decisions |
GET /v1/decisions/models | read | yes | The decision models offered, each one's price, and whether this account can call it. 503 decisions_disabled on the hosted service for now. |
GET /v1/fast-sets | read or search | yes | The fast presets the router offers, and the default. Search |
GET /v1/traces | read | yes | Your project's recent requests, newest first, a page at a time. Traces and feedback |
GET /v1/traces/{id} | read | yes | One trace: the full response, every provider's status and cost. |
POST /v1/feedback | search | no | Labels on a trace, such as the results you cited. They train the ranker. |
POST /v1/judge | search | no | Experimental: an LLM judge's grades for a trace. Not calibrated yet. |
POST /v1/turns | search | yes | How a turn of an agent session ended. Optional, free, on its own rate. |
POST /v1/rollouts/outcome | search | yes | Attach the answer, the outcome and the reward to one of your rollouts, afterwards. Rollouts |
DELETE /v1/rollouts/outcome | search | yes | Delete your own outcomes, by rollout, question or group. |
GET /v1/rollouts/summary | read | yes | Searches, dated and live, cache hits and cost, per rollout, question and group. |
GET /v1/rollouts/export | read | yes | Your rollouts as NDJSON: each search with its stored response, its cutoff and its cost, beside the outcome and the reward. |
GET /v1/limits | read | yes | Your spend caps, and the spend today, this week and this month against them. Limits, keys and headers |
POST /v1/limits | limits | yes | Set daily, weekly and monthly spend caps. |
GET /v1/account | read | yes | The calling key (scopes, expiry), the rate windows, spend and caps, and retention, in one read. |
GET /healthz | none | — | The public readiness probe: {"ok": true}, or 503. |
POST /v1/agents/register | none | — | On agents-v1: an agent mints its own key, with no credential. |
GET /v1/agents/me | key | — | On agents-v1: the agent's status, found by the key alone. |
GET /v1/agents/{agent_id} | key | — | On agents-v1: the status poll, unclaimed, claimed or expired. |
POST /v1/agents/{agent_id}/claim-code | key | — | On agents-v1: a fresh claim link for an agent still unclaimed. |
A spend-free route works when the account is out of credit or at its spend ceiling; the others are refused with a 402 then. Spend-free is not rate-free: Rate limits says which calls count.
Every search, stream, fetch or decision response carries X-Request-Id before any body bytes. It is the trace id, equal to the body's request_id; keep it, since support and every trace read key on it. A search also names what answered it in decision.build: the router's build (version) and its tier configuration (config_hash).
Errors have one shape per host and a code to branch on; see Errors.
The first request
curl -s https://api.jevlin.ai/v1/search \
-H "Authorization: Bearer $JEVLIN_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query": "state of grid-scale battery storage 2026", "tier": "balanced"}'
The answer holds ranked candidates[], one per provider with its own status and cost_micros, and usage.cost_micros, what the call cost in millionths of a dollar (1,000,000 is $1). Add "view": "merged" for one list of pages across every provider, each saying which providers found it. The tiers and every request field are on Search.
For AI agents
Calling the API from Claude or another agent without the jevlin binary? Give it the skill file. It carries the whole contract in one file:
- self-registration and the claim;
- the search request and how to read the answer;
- threading searches into a trajectory, and the turn end;
- fetching a page in full;
- rate limits, spend caps and the account read;
- the feedback vocabulary;
- what to do on every error: stop on a
401, tell the person on a402, honorRetry-Afteron a429, and never loop on a billing error.
The two files:
- SKILL.md: the skill file, as Markdown.
- search-router-openapi.yaml: the OpenAPI 3.1 document, with every request field, response field, enum and error.
Both name the hosts above and are served from this site.