Web Search
Search Brave's independent web index. Returns web results plus news, videos, discussions, FAQ, infobox and locations where relevant.
Example code
// Using @orth/sdk - The simplest way to call APIs
// Install: npm install @orth/sdk
import Orthogonal from "@orth/sdk";
const orthogonal = new Orthogonal({
apiKey: process.env.ORTHOGONAL_API_KEY,
});
const output = await orthogonal.run({
api: "brave-search",
path: "/web/search",
query: {
"q": "example"
}
});
console.log(output);Query parameters
Search query (max 600 chars, 75 words). Supports operators like site:, filetype:, quotes and -exclusions
2-letter country code for results (default US)
Language code for results (default en)
UI language, e.g. en-US
Web results per page (1-20, default 20)
Page offset (0-9)
off, moderate, or strict (default moderate)
pd (24h), pw (7d), pm (31d), py (365d), or YYYY-MM-DDtoYYYY-MM-DD
Comma list of result types: discussions,faq,infobox,news,query,videos,web,locations
Up to 5 extra excerpts per result
Spellcheck the query (default true)
Include highlight markers in snippets
metric or imperial
Goggle URL or inline definition for custom re-ranking
Apply search operators (default true)
Include fetch metadata for results (default false)