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

# Markets & Events

> Understand the core Prediction Markets data model: the relationship between Markets and Events, their identifiers, and how to query them through the API.

Prediction Markets are organized around two core concepts: **Market** and **Event**. Understanding their relationship is fundamental to querying data, trading, and presenting markets in a product.

![Image](https://mintcdn.com/dexbuilder/HmQKrNhFx36mwspk/images/image-1.png?fit=max\&auto=format\&n=HmQKrNhFx36mwspk\&q=85\&s=6df36cee7e176d670384bcd1c8f733bb)

## Market

A Market is the smallest tradable unit. Each Market represents a question with an objectively determinable outcome and typically contains two outcomes: Yes and No.

Each Market usually includes:

| Identifier | Description |
| - | - |
| Condition ID | Unique identifier for the market condition in the CTF contract |
| Question ID | Hash of the market question used for outcome settlement |
| Token IDs | ERC-1155 outcome-token IDs used for CLOB trading, typically one for Yes and one for No |

### Example

For example:

> *"Will Bitcoin reach \$100,000 before December 2026?"*

This creates two outcome tokens:

* **Yes Token**: if the condition is met, it can be redeemed for 1 USDT after settlement.
* **No Token**: if the condition is not met, it can be redeemed for 1 USDT after settlement.

## Event

An Event is a container used to organize one or more related Markets. It can contain a single Market or multiple related outcome markets.

### Single-Market Event

When an Event contains only one Market, the Event and Market are effectively the same concept from a product perspective:

```text theme={null}
Event: Will Bitcoin reach $100,000 before December 2026?
   └── Market: Will Bitcoin reach $100,000 before December 2026? (Yes/No)
```

### Multi-Market Event

When an Event contains multiple Markets, several related questions can be grouped under one Event. In some multi-outcome Events, the Market outcomes are mutually exclusive. These Markets can form a Negative Risk Group: only one Market ultimately settles to Yes, while the others settle to No.

```text theme={null}
Event: Who will win the presidential election?
   ├── Market: Candidate A? (Yes/No)
   ├── Market: Candidate B? (Yes/No)
   ├── Market: Candidate C? (Yes/No)
   └── Market: Other? (Yes/No)
```

## Identifying Markets and Events

Both Markets and Events have unique slugs that can be used to query a specific resource.

```text theme={null}
https://example.com/event/fed-decision-in-october
                          └── slug: fed-decision-in-october
```

```bash theme={null}
curl "https://api.dexbuilder.com/api/v4/prediction/events/slug/fed-decision-in-october"
```

## Sports Market Considerations

For sports markets, unfilled limit orders may be automatically cancelled once the event officially starts in order to clear the order book. Because actual start times may be earlier or later than scheduled, integrations should actively monitor order status around the event start rather than relying only on the scheduled start time.

## Next Steps

> [card] [Prices & Order Book](https://dexbuilder.mintlify.site/en/event-markets/prices-orderbook.md)
>
> Learn how prices are formed and how the order book works.

> [card] [Discover Markets](https://dexbuilder.mintlify.site/en/event-markets/discover-markets.md)
>
> Start querying Events and Markets through the API.


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