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

> ## Agent Instructions
> The Markdown of an API reference page leaves out the OpenAPI schema.
> Every object an endpoint returns or a webhook carries, with each field's type, presence and meaning, is on https://docs.0xinsider.com/api-reference/objects.md.
> The full OpenAPI 3.1 spec names each operation's and each webhook's exact parameters, request body and response schema: https://docs.0xinsider.com/api-reference/openapi.json.

# Trader markets

> List one wallet's sports and esports markets, open and settled, with cost and realized P&L.

Use this endpoint for the rows on a wallet's profile positions table, including markets that have settled. [Positions](https://docs.0xinsider.com/api-reference/endpoint/get-positions.md) is the live board and still leaves resolved markets out.

`status=closed` is the profile's Closed tab and the default. `status=open` is the Open tab. `status=all` returns both in one time order, newest last trade first. The endpoint needs a Pro or Max key.

## Parameters

| Parameter | Description |
| - | - |
| `address` | The wallet address, a known username, or the trader's `trd_` id. |
| `status` | `open`, `closed`, or `all`. The default is `closed`. |
| `limit` | Markets per page, from 1 to 100. The default is 20. |
| `cursor` | `next_cursor` from the previous page. Send it with the same `status`. |

## Which rows each status returns

A row is in `open` when the position is still live, its stored cost is at least \$0.10, and the market has no winner.

A row is in `closed` when the position is no longer live, or the market has a winner, or the live position's stored cost is under \$0.10.

A live position with no winner and no stored cost is returned only for `status=all`.

## Key response fields

| Field | Meaning |
| - | - |
| `condition_id` | The market's condition id. |
| `title` | The market question. `null` when none is stored. |
| `category` | The market's category. `null` when none is stored. |
| `status` | `resolved` when the market has a winner. Otherwise the position's own status: `open` while the wallet holds a live position, `resolved` when it holds none, on a market that may still trade. `resolved_at` tells the two `resolved` cases apart. |
| `cost` | The stored cost, the figure the profile labels Cost. An exact decimal: `value`, `unit` (`USD`), `scale`, and `basis`. `null` means the cost is not stored, never zero. |
| `realized_pnl` | The stored realized P\&L, the figure the profile labels Realized. The same exact-decimal shape. `null` means it is not stored, never zero. |
| `resolved_at` | When the market settled. `null` when it has not, including a closed position on a market that still trades. |
| `last_trade_at` | The position's last trade. A `null` sorts after every dated row. |

Rows are ordered by `last_trade_at` descending, then `condition_id` descending. A row with no `last_trade_at` comes after every dated row, as on the profile. `has_more` is true when another page exists. `next_cursor` is absent on the last page. There is no total count.

## Example

```bash theme={null}
curl -H "Authorization: Bearer $OXINSIDER_API_KEY" \
  "https://api.0xinsider.com/api/v1/trader/swisstony/markets?status=closed&limit=20"
```

Send the returned `next_cursor` as `cursor` with the same `status`. A cursor from another status returns `400` with `param` `cursor`. An unknown `status` returns `400` with `param` `status`.

## What it does not return

* Markets outside sports and esports.
* The wallet address on each row. You already named the wallet.
* A total count of matching markets.
* The live positions board. That stays [`GET /api/v1/positions`](https://docs.0xinsider.com/api-reference/endpoint/get-positions), which still leaves resolved markets out.
* A wallet 0xinsider has no record of. That returns `404`.

## Caching

Save the response's `ETag` and send it in `If-None-Match` on your next request. If nothing has changed, the server returns `304 Not Modified` with no body.


## API Specification

The full API specification for this endpoint is available in the [documentation index](https://docs.0xinsider.com/llms.txt).


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