Providers
Exa
The Exa neural search API, the richest result shape of the built-ins, with highlights by default and summaries and full text on request.
- env var
- EXA_API_KEY
- auth
- x-api-key header
- operations
- search
- results
- 10, up to 100
Address it
import { create } from "@agntn/web";
const exa = await create("exa"); // EXA_API_KEY
const results = await exa.search("typescript runtime benchmarks", {
maxResults: 5,
summary: true,
fullText: true,
category: "research paper",
startPublishedDate: "2026-01-01",
});
The key goes in the x-api-key header, the request is a POST.
What it reads
| Call | Endpoint |
|---|---|
search | POST /search on api.exa.ai with type: "auto", numResults and a contents block |
contents.highlights follows highlights (default true), contents.summary follows summary, contents.text follows fullText.
What comes back
score, publishedDate, author, image, favicon, highlights[] by default, summary and text on request. Domain filters, a category forwarded as given, and both date bounds all work. The most complete result shape in the provider list.
Gotchas
fullTextreturns the whole page for every result. Ten of those is a lot of tokens, stick to highlights unless you will actually read the text.categoryis passed through as typed, so an unknown value is Exa's problem, not the library's.- Exa is first in the detection order. With
EXA_API_KEYset it is the default provider, whether you meant that or not.
Where it lives
src/providers/exa.ts.