GuidesConcepts

Markets and categories

How Predict groups questions into categories and markets, and which fields tell you whether a market is trading.

Everything you trade on Predict is a market: one Yes/No question with its own order book. Markets are grouped into categories.

Categories and markets

A category is one event or question, for example a football match, an election or "Will BTC be up at 6 PM?". It holds one or more markets.

  • One market: the category is a single Yes/No question.
  • Several markets: each market is one possible outcome of the event, asked as its own Yes/No question. In a tournament winner category, every team has a market such as "Will Arsenal win?".

When exactly one of a category's markets can resolve Yes, the category is negative-risk (isNegRisk: true). Those markets are linked on-chain, which lets you convert positions between them. See Negative-risk markets.

FieldOnWhat it tells you
id, slugcategoryHow you look the category up.
marketscategoryThe category's markets.
marketVariantcategory, marketThe kind of event, such as DEFAULT, SPORTS_MATCH or CRYPTO_UP_DOWN. It decides how the event is shown and what variantDetails holds.
isNegRiskcategory, marketWhether the markets are linked as a negative-risk set. It decides which exchange and approvals you need.
isYieldBearingcategory, marketWhether the collateral earns yield while it is locked. It decides which set of contracts the market uses. See Positions and outcome tokens.
decimalPrecisionmarketHow many decimals a price can have. See Prices.
feeRateBpsmarketThe market's taker fee. See Fees.
resolutionProvidercategoryWho decides the outcome. See Resolution.
tagscategoryThe topics the category is filed under.

Use Get categories and Get category by slug to browse events, and Get markets or Get market by ID to read a single market.

Series

Recurring up/down events, such as Bitcoin up or down every 5 minutes, belong to a series. Each round of a series is an ordinary category with its own markets, and its seriesSlug names the series it belongs to.

Get series lists every series, active or retired, and Get series by slug reads one, for example btc-updown-5m. Get series rounds lists a series' rounds. By default it returns the rounds that haven't ended, in start order, so the first is the live round and the rest are the rounds it rolls over to. Rounds are created ahead of time, so one page covers several rollovers. With status=ENDED, it returns past rounds, newest first.

Tags

Tags form a tree up to three levels deep, for example Sports, then Soccer, then EPL. Each tag has a level (1, 2 or 3) and the parentId of the tag above it. Use Get all tags to read the tree, and the tagIds parameter of Get categories to filter by it.

Translations

Categories, markets and outcomes can be translated. Get available languages lists the language codes in use, such as zh-CN. Get category translations returns the translations of a category, its markets and their outcomes, for the codes you pass in languages, for example zh-CN,ja-JP. A language with no completed translations is left out of the response. In the WebSocket API, Set language picks the language of the outcome names in your wallet events.

Outcomes

Each market has two outcomes, Yes and No. You find them in the market's outcomes array.

FieldMeaning
nameThe outcome's label, usually "Yes" or "No". Some markets use other labels, such as "Up" and "Down".
indexSet1 for the first outcome (Yes, or Up) and 2 for the second (No, or Down).
onChainIdThe ERC-1155 token ID of the outcome's shares. This is the tokenId you sign in an order.
statusWON or LOST once the market resolves, otherwise null.

Use indexSet rather than name to tell the outcomes apart. The labels change from market to market, but indexSet is always 1 for the first outcome and 2 for the second. Prices and the order book are quoted for the outcome whose indexSet is 1.

Prices and precision

A price is in USDT per share and runs from 0 to 1. A winning share pays 1 USDT, so a price of 0.62 means the market puts a 62% chance on that outcome.

decimalPrecision is 2 or 3. With 2, prices move in steps of 0.01 (62¢). With 3, they move in steps of 0.001 (62.5¢). An order whose price has more decimals than the market allows is rejected. See Place orders.

Market status

status follows the market from creation to resolution.

statusMeaningNew orders
REGISTEREDThe market is live.Accepted
PRICE_PROPOSEDAn outcome was proposed and resolution is under way.Accepted
PRICE_DISPUTEDThe proposed outcome was disputed.Accepted
PAUSEDThe market is paused.Rejected with create_order_market_not_trading
UNPAUSEDThe market was paused and is live again.Accepted
RESOLVEDThe outcome is final.Rejected
REMOVEDThe market was withdrawn.Rejected

The status=OPEN filter of Get markets returns the markets that accept orders: REGISTERED, PRICE_PROPOSED, PRICE_DISPUTED and UNPAUSED.

Trading status

tradingStatus says what you can do with orders right now. It can change while status stays the same, so check both before you quote.

tradingStatusWhat you can do
OPENPlace, match and remove orders.
MATCHING_NOT_ENABLEDMatching is switched off. Only post-only limit orders are accepted, and they rest on the book without matching. Market orders fail with create_order_market_orders_disabled, and other limit orders with create_order_trading_disabled. When matching is switched back on, any orders that cross are matched.
CANCEL_ONLYThe market is hidden. New orders are rejected, but you can still remove your open orders.
CLOSEDThe market is resolved or removed.

The trading status topic of the WebSocket API pushes each tradingStatus change. The market status topic sends only REGISTERED, PRICE_DISPUTED and RESOLVED, so read the other statuses from Get market by ID.

Pagination

List endpoints, such as Get categories and Get markets, return one page at a time.

  1. Send first to set the page size. For categories and markets it defaults to 20, and it can be at most 100.
  2. Read cursor from the response.
  3. Send it back as after to get the next page.

When there is no next page, cursor is null.

On this page