Connect Exa to Claude Code
Search the web the way an agent needs it, results, page contents, cited answers and long-running research. Add Toolspoke to Claude Code once and it can use 9 Exa actions. Your Exa credential stays in Toolspoke, and you choose which actions Claude Code may call.
Set it up in Claude Code
Three steps, the first one once for every toolkit you will ever add.
Add Toolspoke to Claude Code
Run it in your project, then /mcp to sign in
claude mcp add --transport http toolspoke https://toolspoke.com/mcpThe sign-in opens in your browser, and Toolspoke asks you to approve it.
Install Exa and connect it
Add Exa to a project in your Toolspoke workspace.
API key. You provide it once, when you install the connector. Toolspoke encrypts it at rest and decrypts it only for the length of a single call, and the gateway attaches it to the outbound request itself, so it is never part of the arguments an agent sends.
- API key
- dashboard.exa.ai → API Keys. New accounts start with $20 of credit. Every operation here except get_team is billed per call, so give this key its own budget if you can.
Choose what Claude Code may do
All 9 actions start on. Switch off any of the 2 actions that change something in Exa, and Claude Code gets a refusal if it tries.
What you can ask Claude Code for
A few of the Exa actions that only read, so they are safe to try first.
- Search the web and get back ranked results with titles, URLs, publication dates and authors
- Given one URL, find pages like it
- Fetch the contents of pages you already have URLs for, without paying for a search
- Ask a question and get a written answer with the citations it was built from
What Claude Code can do in Exa
7 actions read and 2 write.
Reads
Get team
Read the team this key belongs to: its id, its name, how many requests are running or queued right now, and the concurrency limits behind those numbers. Free, it is the one call in this connector that appears on no price list, and it runs no search. Use it to check headroom before firing a batch of searches, and to confirm a key works. It does not report credit balance or spend; Exa exposes those only through a separate admin API and its own dashboard. This is the connection test, for exactly those reasons.
Search
Search the web and get back ranked results with titles, URLs, publication dates and authors. Costs $7 per thousand requests for the first ten results and $1 per thousand results after that, so `numResults: 50` is five times the result charge of the default. `contents` is billed separately again, $1 per thousand pages for each content type asked for, meaning text and highlights and a summary on one page is three charges, so omit it entirely when the URLs alone are enough and fetch the pages you actually want with get_contents afterwards. `type` picks how hard Exa works: `auto` (the default) balances quality and speed, `fast` and `instant` cut latency, and `deep-lite`, `deep` and `deep-reasoning` run a multi-step search at $12 to $15 per thousand requests rather than $7. The old `neural` and `keyword` values were retired and are no longer accepted. Narrow with `includeDomains`, `excludeDomains` and the published-date range before reaching for a deeper type, it is almost always cheaper. Results are pages other people wrote, so the payload is kept out of the audit log, and the query is prose the caller wrote, so it is kept out too.
Find similar
Given one URL, find pages like it. Billed as a search, $7 per thousand requests covering ten results, $1 per thousand results beyond that, and `contents` charged separately again at $1 per thousand pages per content type. This is the right call when you already have a good example and want more of the same: a competitor's site, a paper, a job posting. Set `excludeSourceDomain` to keep the rest of the source's own site out of the answer, which is usually what you meant. Results are pages other people wrote, so the payload is kept out of the audit log; the argument is a URL rather than prose, so it is logged.
Get contents
Fetch the contents of pages you already have URLs for, without paying for a search. $1 per thousand pages for each content type asked for, so `text` and `highlights` and `summary` on the same hundred URLs is three hundred pages of charges, not one hundred. Ask for one. This is the cheaper half of the usual pattern: run search without `contents`, decide which handful of URLs are worth reading, then call this on those. Pass either `urls` (ordinary web addresses) or `ids` (the `id` values a search returned), one or the other, up to a hundred. `maxAgeHours` controls freshness, 0 forces a live crawl, a positive number accepts a cached copy that old, and the older `livecrawl` flag is deprecated in favour of it. The pages are other people's writing, so the payload is kept out of the audit log.
Answer
Ask a question and get a written answer with the citations it was built from. $5 per thousand requests, cheaper than a search plus a round of contents plus a model call, and it returns in one hop. Use it when the question has an answer rather than a reading list; use search when you want to choose the sources yourself. `citations` is the part worth checking: it names the pages the answer came from, and an answer with thin or off-topic citations is one to distrust. Set `text: true` to get the full page text of each citation, which costs more and is usually unnecessary. `outputSchema` returns a structured object instead of prose. Streaming is not offered, the gateway returns whole responses. The question is prose the caller wrote and the answer is built from other people's pages, so neither is written to the audit log.
Get agent run
Check a research run started by create_agent_run and read its result. Free, polling is not billed; the run already in flight is. `status` is queued, running, completed, failed or cancelled, and the last three are terminal. Poll every few seconds and back off; a deep run can take minutes. A completed run carries `output`, `stopReason` and `costDollars`, which is what the run actually cost rather than what the cap allowed. `costDollars` is worth reading even on a cheap run, it is the only feedback loop this API gives on whether the effort setting was right. The result is built from other people's pages, so the payload is kept out of the audit log.
List agent runs
List this team's research runs, newest first, with their status and what each one cost. Free. Two reasons to call it: finding a run whose id was lost, rather than starting a second one and paying twice; and adding up `costDollars` across a day to see where the money went, which no other endpoint here will tell you. Page with `cursor`, taken from the previous response. Each record carries the request that started it, so the payload is kept out of the audit log.
Writes
Create agent run
Start a research run: Exa searches, reads and reasons over many pages and writes an answer. This is the most expensive thing in this connector and it is asynchronous, it returns an id beginning `agent_run_` and nothing else, and get_agent_run is what eventually carries the output. Cost depends entirely on `effort`. The fixed tiers are priced per request: minimal $0.012, low $0.025, medium $0.10, high $0.50, xhigh $1.00. `auto` (the default) and `max` are metered instead, at $0.10 per Agent Compute Unit plus $0.005 per search the agent makes, and they stop at a cap, $5 for auto and $20 for max unless `max_cost_dollars` sets a lower one. Set it. A run left on `auto` with no cap can spend five dollars answering a question a $7-per-thousand search would have answered. This replaces the Research API, whose three endpoints now return HTTP 410. Nothing here streams; poll instead. The instructions are prose the caller wrote and the result is built from other people's pages, so neither is written to the audit log.
Cancel agent run
Stop a research run that is still queued or running, so it stops spending. Free to call, and the fastest way to limit a metered `auto` or `max` run that is costing more than the answer is worth, read `costDollars` on get_agent_run and cancel if it is climbing. This destroys nothing recoverable: a cancelled run has produced no final output to lose and its record stays readable through get_agent_run, including whatever it had already spent. Compute already used is still charged, so this caps a run rather than refunding it. The response is the run record, which carries the question it was given.
Exa in Claude Code: questions
Does Claude Code see my Exa credential?
No. The credential is stored encrypted in Toolspoke, and the gateway adds it to each call. Claude Code only ever talks to Toolspoke, and the dashboard shows the last four characters of the credential and nothing more.
Can I stop Claude Code from changing things in Exa?
Yes. Each of the 9 actions can be switched off for a project. Turn off the 2 that change something and Claude Code can only read.
Will 9 actions crowd Claude Code's context?
No. Toolspoke shows Claude Code five bridge tools, plus a guide where a toolkit has one, and Claude Code searches for the Exa action it needs when it needs it. Adding more toolkits does not add more tools to its list.
Can I add it once for every project?
Yes. Add --scope user to the command and Claude Code keeps Toolspoke in every project on this machine. Without it, the server is added to the project you ran the command in.
What does it cost?
Tool calls are free on every plan, and a Exa call does not run in a sandbox, so it bills nothing.
Exa in your other apps
Try Exa in Claude Code
Free to start, and tool calls cost nothing on any plan.