Markets & Events
Openfish organizes predictions with two concepts:
- A market is one tradable prediction question.
- An event groups related markets into one browsing and metadata unit.
In the current meme/off-chain deployment, markets and events are application records served by Gamma, CLOB, and Data APIs.
Markets
Section titled “Markets”A market is the smallest tradable unit on Openfish. Most markets are binary questions with two outcomes:
Will Bitcoin reach 150,000 by December 2026? - Yes - NoEach outcome has a token_id. In this deployment, treat token_id as the API identifier for an outcome in the Openfish CLOB ledger. It is the value used for order books, prices, orders, and positions.
Important identifiers:
| Identifier | Description |
|---|---|
condition_id | Primary market identifier used across Openfish services |
question_id | Question identifier retained for compatibility and market derivation workflows |
token_id | Outcome identifier used by CLOB trading, pricing, balances, and positions |
slug | Human-readable URL/API lookup identifier where available |
Market Fields
Section titled “Market Fields”Common market fields:
| Field | Type | Description |
|---|---|---|
condition_id | string | Primary market ID |
question | string | Display question |
description | string | Longer market context and rules |
clob_token_ids | string[] | Outcome IDs used for trading |
outcomes | string[] | Outcome labels, commonly Yes and No |
active | bool | Whether the market is active |
closed | bool | Whether the market is closed or resolved |
enable_order_book | bool | Whether CLOB trading is enabled |
neg_risk | bool | Whether the market is part of a mutually exclusive event set |
minimum_tick_size | decimal | Minimum allowed price increment |
fee_rate_bps | integer | Fee rate in basis points |
creator_agent | string | Agent address when created by an agent workflow |
game_start_time | integer | Sports market start timestamp, when applicable |
A market can exist in metadata before it is tradable. CLOB trading requires the market to be active and enable_order_book=true.
Events
Section titled “Events”An event groups one or more markets.
Single-market event:
Event: Will Bitcoin reach 150,000 by December 2026? Market: Will Bitcoin reach 150,000 by December 2026? (Yes/No)Multi-market event:
Event: Who will win the 2028 Presidential Election? Market: Candidate A? (Yes/No) Market: Candidate B? (Yes/No) Market: Candidate C? (Yes/No) Market: Other? (Yes/No)For mutually exclusive event sets, neg_risk=true can appear on the market. In the current app, this is metadata and pricing context for the CLOB. Users still trade the displayed markets through normal order flow.
Discovering Markets
Section titled “Discovering Markets”Use Gamma for metadata discovery:
curl "https://gamma.openfish.me/markets?active=true&closed=false&limit=10"curl "https://gamma.openfish.me/events?active=true&closed=false&limit=10"curl "https://gamma.openfish.me/markets/slug/example-market-slug"Use CLOB for trading-specific data:
curl "https://api.openfish.me/browse/markets?limit=20"curl "https://api.openfish.me/tick-size?token_id=YOUR_TOKEN_ID"curl "https://api.openfish.me/fee-rate?condition_id=YOUR_CONDITION_ID"curl "https://api.openfish.me/neg-risk?token_id=YOUR_TOKEN_ID"Use Data API for analytics:
curl "https://data.openfish.me/v1/market-positions?market=0xabc123..."curl "https://data.openfish.me/oi?market=0xabc123..."curl "https://data.openfish.me/live-volume?id=123"Localized Market Text
Section titled “Localized Market Text”Canonical market text is English. Some CLOB browse endpoints can return localized display text when a supported locale parameter is provided.
Example:
curl "https://api.openfish.me/browse/markets?locale=zh&limit=20"If translated text is unavailable, clients should expect English fallback.
Supported locales are zh, ja, ko, fr, and es. See Localization for fallback rules and fixed outcome label mapping.
Sports Markets
Section titled “Sports Markets”Sports markets can include game_start_time. Near game start, the system may cancel open orders and disable trading according to market rules. Schedules can change, so traders should monitor orders close to event start time.
Service Responsibilities
Section titled “Service Responsibilities”| Service | Responsibility |
|---|---|
| Gamma | Events, markets, metadata, tags, comments |
| CLOB | Order books, prices, tick sizes, fees, order execution |
| Data | Positions, value, volume, holders, leaderboard |
Most integrations should discover markets through Gamma or /browse/markets, then use CLOB endpoints for order placement and live trading data.