[{"data":1,"prerenderedAt":599},["ShallowReactive",2],{"navigation_docs":3,"-providers-exa":104,"-providers-exa-surround":594},[4,44],{"title":5,"path":6,"stem":7,"children":8,"icon":43},"Guide","\u002Fguide","1.guide\u002F1.index",[9,11,15,19,23,27,31,35,39],{"title":10,"path":6,"stem":7},"Getting Started",{"title":12,"path":13,"stem":14},"Searching","\u002Fguide\u002Fsearch","1.guide\u002F2.search",{"title":16,"path":17,"stem":18},"Fan-out","\u002Fguide\u002Ffanout","1.guide\u002F3.fanout",{"title":20,"path":21,"stem":22},"Reading","\u002Fguide\u002Fread","1.guide\u002F4.read",{"title":24,"path":25,"stem":26},"Reverse Image Search","\u002Fguide\u002Fimage","1.guide\u002F5.image",{"title":28,"path":29,"stem":30},"CLI","\u002Fguide\u002Fcli","1.guide\u002F6.cli",{"title":32,"path":33,"stem":34},"Agents","\u002Fguide\u002Fagents","1.guide\u002F7.agents",{"title":36,"path":37,"stem":38},"Custom Providers","\u002Fguide\u002Fcustom","1.guide\u002F8.custom",{"title":40,"path":41,"stem":42},"Explorer","\u002Fguide\u002Fexplorer","1.guide\u002F9.explorer","i-lucide-book-open",{"title":45,"path":46,"stem":47,"children":48,"icon":103},"Providers","\u002Fproviders","2.providers\u002F0.index",[49,51,55,59,63,67,71,75,79,83,87,91,95,99],{"title":50,"path":46,"stem":47},"Overview",{"title":52,"path":53,"stem":54},"Brave","\u002Fproviders\u002Fbrave","2.providers\u002F01.brave",{"title":56,"path":57,"stem":58},"Context.dev","\u002Fproviders\u002Fcontext","2.providers\u002F02.context",{"title":60,"path":61,"stem":62},"Exa","\u002Fproviders\u002Fexa","2.providers\u002F03.exa",{"title":64,"path":65,"stem":66},"Firecrawl","\u002Fproviders\u002Ffirecrawl","2.providers\u002F04.firecrawl",{"title":68,"path":69,"stem":70},"Jina","\u002Fproviders\u002Fjina","2.providers\u002F05.jina",{"title":72,"path":73,"stem":74},"Mojeek","\u002Fproviders\u002Fmojeek","2.providers\u002F06.mojeek",{"title":76,"path":77,"stem":78},"SearXNG","\u002Fproviders\u002Fsearxng","2.providers\u002F07.searxng",{"title":80,"path":81,"stem":82},"SerpAPI","\u002Fproviders\u002Fserpapi","2.providers\u002F08.serpapi",{"title":84,"path":85,"stem":86},"SerpBase","\u002Fproviders\u002Fserpbase","2.providers\u002F09.serpbase",{"title":88,"path":89,"stem":90},"Tavily","\u002Fproviders\u002Ftavily","2.providers\u002F10.tavily",{"title":92,"path":93,"stem":94},"TinyFish","\u002Fproviders\u002Ftinyfish","2.providers\u002F11.tinyfish",{"title":96,"path":97,"stem":98},"OpenAI Codex","\u002Fproviders\u002Fopenai-codex","2.providers\u002F12.openai-codex",{"title":100,"path":101,"stem":102},"Marginalia","\u002Fproviders\u002Fmarginalia","2.providers\u002F13.marginalia","i-lucide-library",{"id":105,"title":60,"body":106,"description":587,"extension":588,"links":589,"meta":590,"navigation":156,"path":61,"seo":592,"stem":62,"__hash__":593},"docs\u002F2.providers\u002F03.exa.md",{"type":107,"value":108,"toc":580},"minimark",[109,113,118,296,304,308,385,408,412,437,466,500,504,567,571,576],[110,111],"provider-facts",{"provider":112},"exa",[114,115,117],"h2",{"id":116},"address-it","Address it",[119,120,125],"pre",{"className":121,"code":122,"language":123,"meta":124,"style":124},"language-ts shiki shiki-themes web web web","import { create, readUrl } from \"@agntn\u002Fweb\";\n\nconst exa = await create(\"exa\"); \u002F\u002F EXA_API_KEY\nconst results = await exa.search(\"typescript runtime benchmarks\", {\n  maxResults: 5,\n  summary: true,\n  fullText: true,\n  category: \"research paper\",\n  startPublishedDate: \"2026-01-01\",\n});\n\nconst page = await readUrl(\"https:\u002F\u002Fbun.sh\u002Fblog\", { provider: \"exa\", noCache: true });\n","ts","",[126,127,128,151,158,190,216,222,228,234,246,257,263,268],"code",{"__ignoreMap":124},[129,130,133,137,141,144,148],"span",{"class":131,"line":132},"line",1,[129,134,136],{"class":135},"skH_V","import",[129,138,140],{"class":139},"s38Sx"," { create, readUrl } ",[129,142,143],{"class":135},"from",[129,145,147],{"class":146},"shU9J"," \"@agntn\u002Fweb\"",[129,149,150],{"class":139},";\n",[129,152,154],{"class":131,"line":153},2,[129,155,157],{"emptyLinePlaceholder":156},true,"\n",[129,159,161,164,167,170,173,177,180,183,186],{"class":131,"line":160},3,[129,162,163],{"class":135},"const",[129,165,166],{"class":139}," exa ",[129,168,169],{"class":135},"=",[129,171,172],{"class":135}," await",[129,174,176],{"class":175},"sK71F"," create",[129,178,179],{"class":139},"(",[129,181,182],{"class":146},"\"exa\"",[129,184,185],{"class":139},"); ",[129,187,189],{"class":188},"scIB-","\u002F\u002F EXA_API_KEY\n",[129,191,193,195,198,200,202,205,208,210,213],{"class":131,"line":192},4,[129,194,163],{"class":135},[129,196,197],{"class":139}," results ",[129,199,169],{"class":135},[129,201,172],{"class":135},[129,203,204],{"class":139}," exa.",[129,206,207],{"class":175},"search",[129,209,179],{"class":139},[129,211,212],{"class":146},"\"typescript runtime benchmarks\"",[129,214,215],{"class":139},", {\n",[129,217,219],{"class":131,"line":218},5,[129,220,221],{"class":139},"  maxResults: 5,\n",[129,223,225],{"class":131,"line":224},6,[129,226,227],{"class":139},"  summary: true,\n",[129,229,231],{"class":131,"line":230},7,[129,232,233],{"class":139},"  fullText: true,\n",[129,235,237,240,243],{"class":131,"line":236},8,[129,238,239],{"class":139},"  category: ",[129,241,242],{"class":146},"\"research paper\"",[129,244,245],{"class":139},",\n",[129,247,249,252,255],{"class":131,"line":248},9,[129,250,251],{"class":139},"  startPublishedDate: ",[129,253,254],{"class":146},"\"2026-01-01\"",[129,256,245],{"class":139},[129,258,260],{"class":131,"line":259},10,[129,261,262],{"class":139},"});\n",[129,264,266],{"class":131,"line":265},11,[129,267,157],{"emptyLinePlaceholder":156},[129,269,271,273,276,278,280,283,285,288,291,293],{"class":131,"line":270},12,[129,272,163],{"class":135},[129,274,275],{"class":139}," page ",[129,277,169],{"class":135},[129,279,172],{"class":135},[129,281,282],{"class":175}," readUrl",[129,284,179],{"class":139},[129,286,287],{"class":146},"\"https:\u002F\u002Fbun.sh\u002Fblog\"",[129,289,290],{"class":139},", { provider: ",[129,292,182],{"class":146},[129,294,295],{"class":139},", noCache: true });\n",[297,298,299,300,303],"p",{},"The key goes in the ",[126,301,302],{},"x-api-key"," header, both requests are a POST.",[114,305,307],{"id":306},"what-it-reads","What it reads",[309,310,311,324],"table",{},[312,313,314],"thead",{},[315,316,317,321],"tr",{},[318,319,320],"th",{},"Call",[318,322,323],{},"Endpoint",[325,326,327,352],"tbody",{},[315,328,329,334],{},[330,331,332],"td",{},[126,333,207],{},[330,335,336,339,340,343,344,347,348,351],{},[126,337,338],{},"POST \u002Fsearch"," on api.exa.ai with ",[126,341,342],{},"type: \"auto\"",", ",[126,345,346],{},"numResults"," and a ",[126,349,350],{},"contents"," block",[315,353,354,359],{},[330,355,356],{},[126,357,358],{},"read",[330,360,361,364,365,343,368,343,371,374,375,378,379,374,382],{},[126,362,363],{},"POST \u002Fcontents"," with one URL in ",[126,366,367],{},"urls",[126,369,370],{},"text: true",[126,372,373],{},"maxAgeHours: 0"," for ",[126,376,377],{},"noCache"," and ",[126,380,381],{},"livecrawlTimeout",[126,383,384],{},"timeout",[297,386,387,390,391,394,395,390,398,343,401,390,404,407],{},[126,388,389],{},"contents.highlights"," follows ",[126,392,393],{},"highlights"," (default true), ",[126,396,397],{},"contents.summary",[126,399,400],{},"summary",[126,402,403],{},"contents.text",[126,405,406],{},"fullText",".",[114,409,411],{"id":410},"what-comes-back","What comes back",[297,413,414,417,418,421,422,425,426,429,430,433,434,436],{},[126,415,416],{},"snippet"," is the first highlight, cut at 500 characters with ",[126,419,420],{},"…",". Why cut it? Exa sends one highlight per hit, passages glued with ",[126,423,424],{},"...",", and a long forum thread gets 8,000 characters of it. Nobody needs that twice. Each highlight in ",[126,427,428],{},"highlights[]"," stops at 2,000, which still holds most of the query terms the full one had. Turn highlights off and the snippet is the start of ",[126,431,432],{},"text",", when ",[126,435,406],{}," asked for it.",[297,438,439,343,442,343,445,343,448,343,451,343,454,456,457,378,459,461,462,465],{},[126,440,441],{},"score",[126,443,444],{},"publishedDate",[126,446,447],{},"author",[126,449,450],{},"image",[126,452,453],{},"favicon",[126,455,428],{}," by default, ",[126,458,400],{},[126,460,432],{}," on request. Domain filters, a ",[126,463,464],{},"category"," forwarded as given, and both date bounds all work. The most complete result shape in the provider list.",[297,467,468,469,472,473,343,476,378,478,480,481,484,485,488,489,491,492,495,496,499],{},"Reads give the page text as markdown in ",[126,470,471],{},"content",", plus ",[126,474,475],{},"title",[126,477,444],{},[126,479,450],{}," when Exa has them, and Exa's ",[126,482,483],{},"requestId"," in ",[126,486,487],{},"metadata.requestId",". ",[126,490,384],{}," is in seconds and goes out as milliseconds, capped at Exa's 90. No links, images, selectors or ",[126,493,494],{},"maxTokens",", and ",[126,497,498],{},"format"," is always markdown, whatever you ask for.",[114,501,503],{"id":502},"gotchas","Gotchas",[505,506,507,513,518,525,531,554,560],"ul",{},[508,509,510,512],"li",{},[126,511,406],{}," returns the whole page for every result. Ten of those is a lot of tokens, stick to highlights unless you will actually read the text.",[508,514,515,517],{},[126,516,464],{}," is passed through as typed, so an unknown value is Exa's problem, not the library's.",[508,519,520,521,524],{},"Exa is first in the detection order. With ",[126,522,523],{},"EXA_API_KEY"," set it is the default provider, whether you meant that or not. For reads it is the opposite, last in line after Jina, Context.dev, Firecrawl, TinyFish and Tavily.",[508,526,527,528,530],{},"Contents answers from Exa's cache when it has the page and crawls it when it doesn't. Nothing says how old that copy is, so ",[126,529,377],{}," is the thing to reach for on anything that changes.",[508,532,533,534,537,538,541,542,545,546,549,550,553],{},"A page Contents cannot fetch is not an HTTP error. The request comes back 200 with an empty ",[126,535,536],{},"results"," and a tag in ",[126,539,540],{},"statuses",", like ",[126,543,544],{},"CRAWL_NOT_FOUND"," or ",[126,547,548],{},"CRAWL_HTTP_403",". That becomes a ",[126,551,552],{},"WebError"," with the tag, not a fallback.",[508,555,556,559],{},[126,557,558],{},"url"," on a read is the one Exa reports, which can be the page after a redirect, not the address you passed.",[508,561,562,563,566],{},"Spent credits come back as HTTP 402 ",[126,564,565],{},"NO_MORE_CREDITS",", and Exa checks credits before it even looks at the request. Automatic reads move on to the next reader.",[114,568,570],{"id":569},"where-it-lives","Where it lives",[297,572,573,407],{},[126,574,575],{},"src\u002Fproviders\u002Fexa.ts",[577,578,579],"style",{},"html pre.shiki code .skH_V, html code.shiki .skH_V{--shiki-light:var(--shiki-token-keyword);--shiki-default:var(--shiki-token-keyword);--shiki-dark:var(--shiki-token-keyword)}html pre.shiki code .s38Sx, html code.shiki .s38Sx{--shiki-light:var(--ui-text-highlighted);--shiki-default:var(--ui-text-highlighted);--shiki-dark:var(--ui-text-highlighted)}html pre.shiki code .shU9J, html code.shiki .shU9J{--shiki-light:var(--shiki-token-string);--shiki-default:var(--shiki-token-string);--shiki-dark:var(--shiki-token-string)}html pre.shiki code .sK71F, html code.shiki .sK71F{--shiki-light:var(--shiki-token-function);--shiki-default:var(--shiki-token-function);--shiki-dark:var(--shiki-token-function)}html pre.shiki code .scIB-, html code.shiki .scIB-{--shiki-light:var(--shiki-token-comment);--shiki-default:var(--shiki-token-comment);--shiki-dark:var(--shiki-token-comment)}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":124,"searchDepth":153,"depth":153,"links":581},[582,583,584,585,586],{"id":116,"depth":153,"text":117},{"id":306,"depth":153,"text":307},{"id":410,"depth":153,"text":411},{"id":502,"depth":153,"text":503},{"id":569,"depth":153,"text":570},"The Exa neural search API, the richest result shape of the built-ins, with highlights by default and summaries and full text on request, and Exa Contents for reading pages.","md",null,{"icon":591},"i-lucide-sparkles",{"title":60,"description":587},"m7snlZ9nTcXTEaKWF0Igcf8j_LuAbTkeOtTrdrvcwrE",[595,597],{"title":56,"path":57,"stem":58,"description":596,"children":-1},"The Context.dev API for search with Markdown ranked by relevance and for scraping pages into Markdown or HTML.",{"title":64,"path":65,"stem":66,"description":598,"children":-1},"The Firecrawl v2 API for search with scraped passages and for scraping a page into Markdown or HTML.",1791182559801]