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

# overview

> Track Solana wallets and stream live trade, balance and PnL data with the OceanX Developer API.

The OceanX Developer API lets you track Solana wallets, quote swaps, read live
market context, and receive the same data and live feed the OceanX app itself
uses — programmatically. **v1** covers **wallet tracking**, **spot quotes**,
**token charts**, and the read-only **Market Lighthouse** activity frame.

<Note>
  The API is currently in **beta** and **free** to use while in beta.
</Note>

## Base URL

```text theme={null}
https://www.oceanx.trade/api/v1
```

Use the `www.` host directly — the apex `oceanx.trade` issues a 307 redirect, and some HTTP clients drop the `Authorization` header across a cross-host redirect.

All endpoints are under `/api/v1`. Responses are JSON. CORS is open (`Access-Control-Allow-Origin: *`), but **your API key is a secret** — call the API from a server or trusted backend, never expose the key in a public browser app.

## What you can do with v1

<CardGroup cols={2}>
  <Card title="Track wallets" icon="wallet" href="/api/endpoints/wallets">
    Add, list and remove Solana wallets from your tracker.
  </Card>

  <Card title="Read tracker state" icon="list" href="/api/endpoints/snapshot">
    Pull your groups, wallets and status in one snapshot.
  </Card>

  <Card title="Recent trades" icon="chart-line" href="/api/endpoints/trades">
    Fetch the most recent normalized trades across tracked wallets.
  </Card>

  <Card title="Realtime WebSocket" icon="bolt" href="/api/realtime">
    Stream live trade, balance and PnL frames as they happen.
  </Card>

  <Card title="Quote a swap" icon="calculator" href="/api/endpoints/spot-quote">
    Price, route and impact for a size, off our own router.
  </Card>

  <Card title="Check an exit" icon="door-open" href="/api/endpoints/spot-exit-check">
    Can a whole position leave, and at what price?
  </Card>

  <Card title="Chart a token" icon="chart-candlestick" href="/api/endpoints/chart">
    OHLCV candles from 1s to 1 month, on Solana and eight EVM chains.
  </Card>

  <Card title="Read market activity" icon="tower-broadcast" href="/api/endpoints/market-lighthouse">
    DEX and launchpad volume, traders, launches and migrations by window.
  </Card>
</CardGroup>

## Quickstart

<Steps>
  <Step title="Create an API key">
    In the OceanX app, go to **Settings → Developer API** (also reachable from the account menu → **Developer API**) and create a new key. The key is shown **once** — store it securely.
  </Step>

  <Step title="Make your first request">
    ```bash theme={null}
    curl https://www.oceanx.trade/api/v1/tracker/wallets \
      -H "Authorization: Bearer $OCEANX_API_KEY"
    ```
  </Step>

  <Step title="Track a wallet">
    ```bash theme={null}
    curl -X POST https://www.oceanx.trade/api/v1/tracker/wallets \
      -H "Authorization: Bearer $OCEANX_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{"wallet":"5Q544fKrFoe6tsEbD7S8EmxGTJYAKtTVhAW5Q5pge4j1","label":"Whale #1","emoji":"🐳"}'
    ```
  </Step>

  <Step title="Open a realtime session">
    See the [Realtime feed](/api/realtime) guide to stream live updates over WebSocket.
  </Step>
</Steps>
