> For the complete documentation index, see [llms.txt](https://limelight-1.gitbook.io/limelight-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://limelight-1.gitbook.io/limelight-docs/developers/api-and-widgets.md).

# API & Widgets

Limelight exposes market data through a backend REST API for discovery and display. On-chain trading flows go directly against the Move modules — see the [Bot Trading Guide](/limelight-docs/developers/bot-trading-guide.md).

## Market Data API

Read endpoints require no authentication — bots and front-ends can pull markets anonymously.

**What the backend provides:**

* A paginated, filterable list of markets (status, category, collateral, sort, expiry window).
* Cached metadata per market: title, outcomes, collateral, volume, TVL, expiry, status.

**Typical query parameters:**

| Param            | Values            | Notes                                                    |
| ---------------- | ----------------- | -------------------------------------------------------- |
| `status`         | `open` / `closed` | `open` = ACTIVE (tradeable). `closed` = ready to redeem. |
| `page` / `limit` | int / 1–100       | Paginate. Default 20.                                    |
| `category`       | string            | Filter by market category.                               |

Each market record includes the on-chain market address (pass it to your SDK calls for buy/sell/redeem), outcome metadata, the creator fee, and trading-window timestamps. Treat the cached `status` as a hint and re-check on-chain via the market's view function before trading.

## Widgets *(coming soon)*

Embeddable widgets — drop-in market cards and trade panels for partner sites — are planned for a later phase, alongside a partner SDK with rate-limit tiers and webhooks.

{% hint style="info" %}
Endpoint base URLs and the full schema are provided by the Limelight team. The shapes here describe the integration model, not final field names.
{% endhint %}


---

# 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, and the optional `goal` query parameter:

```
GET https://limelight-1.gitbook.io/limelight-docs/developers/api-and-widgets.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
