Skip to main content
Use Brave Search through Corsair: one client, typed API calls. Create a search key in the Brave Search API dashboard (https://api-dashboard.search.brave.com/app/keys); it is sent as the X-Subscription-Token header. Things to know before you call:
  • Plans. Brave sells three plans, each with its own key scope: Search ($5 per 1,000 requests: `web.*`, `llm.context`, `news`, `videos`, `images`, `local.*`), Answers ($4 per 1,000 searches plus $5 per million input and output tokens: `answers.*`) and Autosuggest/Spellcheck ($5 per 10,000 requests: suggest.search, spellcheck.search). A call outside the key’s plan answers 400 OPTION_NOT_IN_PLAN. Failed calls are not billed.
  • llm.context vs web.search. llm.context returns extracted page text sized to a token budget, for grounding a model; web.search returns ranked titles, URLs and snippets plus news, video, discussion, FAQ and local sections.
  • Places. local.placeSearch finds businesses and landmarks by text (location: "tokyo japan") or latitude/longitude. Its result ids (and the ids in web.search locations) feed local.pois and local.descriptions; they expire after 8 hours.
  • Rich results. web.search with enable_rich_callback: true returns rich.hint.callback_key for queries like “weather in london”; web.rich fetches the live data for it.
  • Answers. answers.create answers from one search; enable_citations collects inline citations (offsets into the answer text) into citations. answers.research runs multi-search deep research for up to research_maximum_number_of_seconds (default 180). Both stream from Brave and return one completion with citations, cost (Brave’s usage line in USD) and any other tagged items in tags.
  • Location headers. Pass location: { lat, long, city, country, ... } on web.search, llm.context and local.pois for local results; it is sent as X-Loc-* headers and kept out of error messages.
  • Admin API. admin.* reads usage and key lists with a separate admin key (bsk_admin_..., made on the dashboard’s Admin keys page). Set it as the adminKey option or store it as the account’s admin_key; a search key gets 401 ADMIN_KEY_INVALID.
  • Managed pricing. With authType: 'managed_pricing', searches run on Corsair’s Brave Search key and are billed in Corsair credits. Operations Corsair doesn’t price (Answers research, the Admin API) are refused and nothing is charged.
  • Rate limits. Every response carries X-RateLimit-* headers with one value per window (per second, per month). A per-second 429 RATE_LIMITED is retried after a second; a spent monthly quota is not.
  • Brave’s Summarizer endpoints are deprecated (replaced by Answers) and not included.
What you get:
  • 17 typed API operations

Setup

1

Install

2

Add the plugin

corsair.ts
With multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.
3

Choose authentication

4

Connect a tenant

Mint a connect link and send the tenant to it. Hub hosts the page and delivers the result to your app — see Connect / OAuth.

Example API calls

Search the web
Get LLM context for a question
See the full list on the API page.

What’s next

API reference

Every bravesearch.api.* operation with input and output types.

Connect / OAuth

createLink, Hub delivery, and tenant connect flows.

Use with agents

Expose this plugin’s operations as MCP tools.