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

# Quickstart

> Call the public market data endpoint with no account, then get a scoped API key and make your first authenticated request.

## 1. Call the API right now

Market data needs no key and no account:

```bash theme={null}
curl "https://api.totalis.trade/markets?limit=3"
```

Every market in the response carries the `ticker` and `venue` you reference when you build a parlay
leg (one outcome inside a parlay). [List markets](/solana/api-reference/markets/list) has the filters for
category, venue, and search.

Everything past this point needs a key.

## 2. Get an API key

Create a key from the [Totalis Dashboard](https://app.totalis.trade), under account settings, then
API keys. Give it only the scopes (permissions) your integration needs. For a read-only start,
`account:read`, `positions:read`, and `balances:read` are enough. The full scope catalog is on
[Authentication](/solana/authentication).

<Frame caption="The key form in the app, shown with the Trading preset. Pick Read-only for a first key.">
  <img src="https://mintcdn.com/ucalledit/YdiR6y3UIknGsFJp/images/app/02-api-keys.png?fit=max&auto=format&n=YdiR6y3UIknGsFJp&q=85&s=be1916f379998b3fa2fedc146859e4a0" alt="The API Keys settings page with a key name field, permission presets, and the scope checkboxes" width="967" height="846" data-path="images/app/02-api-keys.png" />
</Frame>

<Warning>
  Copy the key when it is shown. It is displayed exactly once and cannot be retrieved later.
</Warning>

Store it in an environment variable:

```bash theme={null}
export TOTALIS_API_KEY="api_live_..."
```

## 3. Make your first authenticated call

Every request to `https://api.totalis.trade` carries your key in the `X-API-Key` header. Confirm it
works by reading your profile:

```bash theme={null}
curl https://api.totalis.trade/v1/me \
  -H "X-API-Key: $TOTALIS_API_KEY"
```

```json theme={null}
{
  "data": {
    "id": "did:privy:...",
    "username": "satoshi",
    "wallet_address": "7Xy..."
  }
}
```

Every successful response wraps the resource in a `data` envelope.

| Response | Meaning |
| - | - |
| `200` | The key works. |
| `401` | The key is missing, invalid, or revoked. |
| `403` | The key is valid but lacks the scope for this endpoint, or does not start with `api_`. |

## 4. Read your account

Pull your balances, open positions, and stats in one call:

```bash theme={null}
curl https://api.totalis.trade/v1/portfolio \
  -H "X-API-Key: $TOTALIS_API_KEY"
```

## 5. Before you can trade

Reads work as soon as your key does. Placing a parlay needs two more things:

<Steps>
  <Step title="USDC in your wallet">
    Send native Solana USDC to the address from
    [`GET /v1/wallet`](/solana/api-reference/user/get-wallet). When you place a parlay, the stake moves
    into your on-chain vault by itself. See [Funding](/solana/guides/funding).
  </Step>

  <Step title="Trading enabled">
    A one time consent in the app that lets Totalis sign trades on your behalf. You cannot do this
    from the REST API. Check the current state with
    [`GET /v1/wallet/delegation-status`](/solana/api-reference/funds/delegation-status).
  </Step>
</Steps>

## Next steps

<CardGroup cols={2}>
  <Card title="How parlays work" icon="arrows-spin" href="/solana/guides/lifecycle">
    The full path from quote request to settlement.
  </Card>

  <Card title="Limits and fees" icon="scale-balanced" href="/solana/limits-and-fees">
    Bet range, leg counts, timing windows, and both fees.
  </Card>

  <Card title="Reading your data" icon="table-list" href="/solana/guides/reading-data">
    Positions, history, settlement outcomes, and P\&L.
  </Card>

  <Card title="Glossary" icon="book" href="/solana/glossary">
    Every field name and unit convention, defined once.
  </Card>
</CardGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.