# exa_contents

tool by [@c0va23](/marketplace/@c0va23/tools)

A tool that fetches api.exa.ai.

- First published 2026-10-27 · release 2 on 2026-10-28
- [Download release 2](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a/latest.bylm.json)
- [0 stars](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a/stars)
- Needs a key: **EXA** — sent to https://api.exa.ai. Hint: Dashboard › API Keys: create a key at dashboard.exa.ai/api-keys and paste it here. [Get a key](https://dashboard.exa.ai/api-keys)

## What it holds

### What the model is told

**Tool the model sees**: `fetch_url-exa_contents`

```text
Read the full text of specific web pages with the Exa Contents API (POST https://api.exa.ai/contents). Use after an exa_search when you need the whole body of particular result URLs, or when the user gives you URLs to read. Returns clean page text plus title, URL and published date.
```

### Request

**Method and address**: `POST https://api.exa.ai/contents`

**Headers sent**:

- `x-api-key: {secrets.apiKey}`

**Body**: `application/json`

```json
{
  "urls": {urls},
  "text": {
    "maxCharacters": 20000
  }
}
```

**Accepted responses**: `application/json`

### Arguments the model passes

| Name | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `urls` | list of string | yes |  | Absolute http(s) URLs of the pages to read, one to a few per call (e.g. \["https://example.com/article"\]). |

### Responses

**Statuses that are errors**: 400 to 599

**A response filtered to nothing is an error**: no

**What the model reads for an error**: The status line, then the body

**Retries**: A 429 or a 503 is sent again, 3 times at most, waiting 1000 ms first and doubling, 60000 ms at most

**Kept for the app's response details screen**: the first 65536 characters of the body and of each filter's output; the model never reads them

### Filters over the response, in order

#### Step 1

A jq program, giving `text/markdown`

```
def clip: if (length > 20000) then .[0:20000] + "\n\n[... page text truncated at 20000 characters ...]" else . end;
(.statuses // []) as $st |
[ .results[] |
    "### " + (.title // "(untitled)")
    + "\nURL: " + (.url // "")
    + (if ((.publishedDate // "") | length) > 0 then "\nPublished: " + .publishedDate else "" end)
    + (if ((.author // "") | length) > 0 then "\nAuthor: " + .author else "" end)
    + "\n\n" + (if ((.text // "") | length) > 0 then (.text | clip) else "(no readable text returned for this URL)" end)
] as $out |
( [ $st[] | select(.status == "error") | "- " + .id + ": " + ((.error.tag // "error") | tostring) ]
  | if length > 0 then "Failed to fetch:\n" + (join("\n")) + "\n\n" else "" end )
+ ( if ($out | length) == 0 then "No page content was returned." else ($out | join("\n\n---\n\n")) end )
```

When the program outputs several values, only the first is passed on. A string is passed on without its quotes.

### Keys

**`apiKey`**: **EXA**, an API key

## Downloads

Downloaded 7 times directly. Included in 3 downloads of other listings. 7 downloads in the last 30 days.

## Releases

| Release | Published | Downloads | File |
| --- | --- | --- | --- |
| [2](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a/releases/2) | 2026-10-28 | [4](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a?release=2) | [download](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a/v/2.bylm.json) |
| [1](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a/releases/1) | 2026-10-27 | [3](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a?release=1) | [download](/marketplace/listings/01a17d8f-e4da-7652-a733-db468993bf2a/v/1.bylm.json) |

---

[Bring Your LM](/) · [Docs](/docs/features) · [Marketplace](/marketplace)

[Articles](/articles) · [Releases](/releases) · [Bundle Format](/marketplace/bundle-format) · [Marketplace Terms](/terms) · [App Privacy](/privacy) · [Website Privacy](/website-privacy) · [Open Source](/open-source) · [llms.txt](/llms.txt)
