When using the Exa API, you can request different types of content to be returned for each search result.
Text (text=True)
Returns the full text content of the result, formatted as markdown. It extracts the main content (like article body text) while filtering out navigation elements, pop-ups, and other peripheral text. This is extractive content taken directly from the page’s source.Summary (summary=True)
Provides a concise summary generated from the text, tailored to a specific query you provide. This is abstractive content created by processing the source text using Gemini Flash.Structured Summaries
You can also request structured summaries by providing a JSON schema:Highlights
Delivers key excerpts from the text that are most relevant to your search query, emphasizing important information within the content. This is also extractive content from the source. You can configure highlights in two ways:-
Simple boolean (
highlights=True): Returns default highlights based on the search query -
Detailed configuration (pass as an object):
query: The specific query to use for generating highlights (if different from search query)numSentences: Number of sentences per highlight (minimum: 1)highlightsPerUrl: Maximum number of highlights to return per URL (minimum: 1)
Context String
Returns page contents as a single combined string ready for LLM RAG applications. When you setcontext=True, all result contents are joined together into one text block.
Performance Note: Context strings often perform better than highlights for RAG applications because they provide more complete information from each page.
How it works:
- If you have 5 results and set a 1000 character limit, each result gets about 200 characters
- We recommend using 10000+ characters for best results
- No character limit works best when possible
Configuration:
- Simple boolean (
context=True): Returns all content combined with no character limit - With character limit (pass as an object):
Images and favicons
You can get images from webpages by settingimageLinks (under contents.extras.imageLinks) to specify how many images you want per result. Each result also includes the website’s favicon URL and a representative image URL when available.
Crawl Errors
The contents endpoint provides detailed status information for each URL through thestatuses field in the response. The endpoint only returns an error if there’s an internal issue on Exa’s end - all other cases are reported through individual URL statuses.
Each response includes a statuses array with status information for each requested URL:
CRAWL_NOT_FOUND: Content not found (HTTP 404)CRAWL_TIMEOUT: The target page returned a timeout error (HTTP 408)CRAWL_LIVECRAWL_TIMEOUT: ThelivecrawlTimeoutparameter limit was reached during crawlingSOURCE_NOT_AVAILABLE: Access forbidden or source unavailable (HTTP 403)CRAWL_UNKNOWN_ERROR: Other errors (HTTP 500+)
statuses field for each URL:

