> For the complete documentation index, see [llms.txt](https://docs.ojolabs.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ojolabs.xyz/markets/api/resolution.md).

# Resolution

Check market resolution status and oracle assertion details.

## Get Resolution Status

Returns the resolution status for a market, including any active UMA oracle assertion.

```
GET /api/v1/resolution/{marketId}
```

### Path Parameters

| Parameter  | Type    | Description       |
| ---------- | ------- | ----------------- |
| `marketId` | bytes32 | Market identifier |

### Response (Unresolved, No Assertion)

```json
{
  "marketId": "0x1234...abcd",
  "expired": false,
  "resolved": false
}
```

### Response (Assertion Active)

```json
{
  "marketId": "0x1234...abcd",
  "expired": true,
  "resolved": false,
  "assertion": {
    "id": "0xAssertionId...",
    "proposer": "0xProposerAddress...",
    "proposedOutcome": true,
    "bondAmount": "5000000",
    "assertionTime": 1735689000,
    "expirationTime": 1735696200,
    "settled": false,
    "settlementResolution": false,
    "disputed": false
  }
}
```

### Response (Resolved)

```json
{
  "marketId": "0x1234...abcd",
  "expired": true,
  "resolved": true,
  "winningOutcome": 0
}
```

### Fields

| Field            | Type   | Description                                              |
| ---------------- | ------ | -------------------------------------------------------- |
| `marketId`       | string | Market identifier                                        |
| `expired`        | bool   | Whether the market expiration time has passed            |
| `resolved`       | bool   | Whether the market has been settled                      |
| `winningOutcome` | int    | `0` = YES won, `1` = NO won (only present when resolved) |

### Assertion Fields

| Field                  | Type   | Description                                            |
| ---------------------- | ------ | ------------------------------------------------------ |
| `id`                   | string | UMA assertion identifier                               |
| `proposer`             | string | Address that proposed the resolution                   |
| `proposedOutcome`      | bool   | `true` = YES, `false` = NO                             |
| `bondAmount`           | string | UMA bond amount in USDC                                |
| `assertionTime`        | int64  | When the assertion was made                            |
| `expirationTime`       | int64  | When the dispute window ends (2 hours after assertion) |
| `settled`              | bool   | Whether the assertion has been settled                 |
| `settlementResolution` | bool   | Final resolution after settlement                      |
| `disputed`             | bool   | Whether the assertion was disputed                     |

### Resolution Flow

{% stepper %}
{% step %}

### Market expires

The market expiration time passes (`expired: true`).
{% endstep %}

{% step %}

### Proposer submits assertion

A proposer submits a resolution assertion with a UMA bond (`assertion` present).
{% endstep %}

{% step %}

### Dispute window opens

A 2-hour dispute window opens (`expirationTime` set).
{% endstep %}

{% step %}

### Undisputed: assertion settles

If undisputed, assertion settles and market resolves (`resolved: true`, `winningOutcome` set).
{% endstep %}

{% step %}

### Disputed: UMA arbitrates

If disputed, UMA oracle arbitrates the outcome.
{% endstep %}
{% endstepper %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ojolabs.xyz/markets/api/resolution.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
