> ## Documentation Index
> Fetch the complete documentation index at: https://exa.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> The Exa API is served at https://api.exa.ai. Authenticate with `Authorization: Bearer $EXA_API_KEY` (or `x-api-key: $EXA_API_KEY`); create keys at https://dashboard.exa.ai/api-keys?utm_source=docs&utm_medium=docs&utm_campaign=markdown_instructions. Every way an agent can get access to Exa is described at https://exa.ai/auth.md.
> Prefer the official SDKs, `exa-py` (`pip install exa-py`) and `exa-js` (`npm install exa-js`); both read `EXA_API_KEY` from the environment.
> Tool-using agents can call Exa without writing code through the hosted MCP server at https://mcp.exa.ai/mcp, or install the Exa agent skill with `npx skills add exa-labs/agent-skills` (skill file: https://exa.ai/docs/skill.md).
> The OpenAPI specs at https://exa.ai/docs/exa-spec.yaml and https://exa.ai/docs/team-management-spec.yaml are the source of truth for request and response schemas.

# Polymarket

> Get prediction-market odds, price history, order books, and trader positions.

[Polymarket](https://polymarket.com) is a prediction-market platform where
market prices represent the crowd's implied probability of real-world
outcomes. [Exa Connect](https://exa.ai/docs/agent/connect/overview.md) provides
read-only access to Polymarket's public market data.

Attach `polymarket` to an [Exa Agent](https://exa.ai/docs/agent/quickstart.md) run, and the
agent queries Polymarket alongside Exa web search.

## Use it for

* Finding prediction markets and current market-implied odds for a topic.
* Comparing how the implied probability of an outcome changed over time.
* Inspecting market liquidity, bid/ask depth, and top position holders.
* Reviewing a trader's current positions and recent on-chain activity.

## Provider ID

Use this value in `dataSources`:

```text theme={null}
polymarket
```

## Pricing

Polymarket calls carry no provider charge: you pay only the standard
[Agent run pricing](https://exa.ai/docs/agent/quickstart.md#pricing).

## Data available

| Data | Description |
| - | - |
| Markets and events | Current prediction markets and events, with implied-probability prices, volume, and liquidity. |
| Price history | How an outcome's implied probability moved over time. |
| Order books | Live bid/ask depth and spread for a market outcome. |
| Holders and traders | Top position holders for a market, plus a trader's current positions and recent on-chain activity. |

## Example

Get the market-implied odds of a Fed rate cut and how they moved over the past month.

```python Python theme={null}
from exa_py import Exa

exa = Exa()
run = exa.agent.runs.create(
    query=(
        "What are the current market-implied odds of a Fed rate cut at the "
        "next FOMC meeting, and how have they moved over the past month?"
    ),
    data_sources=[{"provider": "polymarket"}],
    output_schema={
        "type": "object",
        "required": ["market", "currentProbability", "trend"],
        "properties": {
            "market": {"type": "string", "description": "the market question"},
            "currentProbability": {"type": "number", "description": "between 0 and 1"},
            "trend": {"type": "string", "description": "how the implied probability moved over the past month"},
        },
    },
)
run = exa.agent.runs.poll_until_finished(run.id)
```

```typescript TypeScript theme={null}
import Exa from "exa-js";

const exa = new Exa();
const run = await exa.agent.runs.create({
  query:
    "What are the current market-implied odds of a Fed rate cut at the next FOMC meeting, and how have they moved over the past month?",
  dataSources: [{ provider: "polymarket" }],
  outputSchema: {
    type: "object",
    required: ["market", "currentProbability", "trend"],
    properties: {
      market: { type: "string", description: "the market question" },
      currentProbability: { type: "number", description: "between 0 and 1" },
      trend: { type: "string", description: "how the implied probability moved over the past month" },
    },
  },
});
```

```bash cURL theme={null}
curl -s -X POST "https://api.exa.ai/agent/runs" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $EXA_API_KEY" \
  -d '{
    "query": "What are the current market-implied odds of a Fed rate cut at the next FOMC meeting, and how have they moved over the past month?",
    "dataSources": [{ "provider": "polymarket" }],
    "outputSchema": {
      "type": "object",
      "required": ["market", "currentProbability", "trend"],
      "properties": {
        "market": { "type": "string", "description": "the market question" },
        "currentProbability": { "type": "number", "description": "between 0 and 1" },
        "trend": { "type": "string", "description": "how the implied probability moved over the past month" }
      }
    }
  }'
```

## Pairs well with

* [Exa web search](https://exa.ai/docs/search/quickstart.md): add reporting and background context to market odds.
* [Particle](https://exa.ai/docs/agent/connect/particle.md): pull the news coverage behind a move in the odds.
* [Financial Datasets](https://exa.ai/docs/agent/connect/financialdatasets.md): connect market-implied odds to prices, fundamentals, and macro data.

## Next steps

> [card] [Attach it to a run](https://exa.ai/docs/agent/connect/overview.md)
>
> The Exa Connect quickstart covers `dataSources`, pricing, and the full partner catalog.

> [card] [Combine providers](https://exa.ai/docs/agent/connect/combining-providers.md)
>
> Attach up to five partners to one run and shape the query so each one fires.

> [card] [Learn Exa Agent](https://exa.ai/docs/agent/quickstart.md)
>
> Create runs, stream progress, design output schemas, and control effort and cost.

> [card] [Get an API key](https://dashboard.exa.ai/api-keys?utm_source=docs\&utm_medium=docs\&utm_campaign=connect_provider_card)
>
> Create a key in the dashboard and run this page's example as-is. New accounts start with free credits.
