pm_uma_oracle_events), with from / to ranges, cursor paging and resolution_source provenance. Only Polymarket’s UMA adapters asking the YES_OR_NO_QUERY identifier are included; other protocols that use the same oracle are not.
Read the UMA overview for the lifecycle and coverage.
UMA REST is part of the Data API: sign every request with your Data API credential (
analytics.read) using HMAC authentication. Each successful response costs 1 API credit, and the surface has its own per-key rate bucket. The UMA WebSocket is different: it stays on the Market Data credential (stream.read) — see UMA WebSocket. There is no separate UMA key.Make a signed request
Use your Data API key and secret from Console. This example makes one REST request. A successful response costs 1 API credit. Keep the secret on your server.Node.js
200 with questions confirms that your authenticated REST read succeeded. An empty questions array reports no matching records in the range. A 401 only confirms an authentication refusal, not a successful read of resolution data.
Base URL: https://partner-api.bravadotrade.com. Sign every REST request with HMAC, including its sorted query parameters. JSON; ids are hex, payout is an integer micro-USDC string.
The history routes serve the same fields as the live routes, from the complete on-chain record rather than the retained live window. updated_ms is the on-chain time of the latest event, and seen_pending is never present: history has no mempool pre-image.
GET /uma/history/question
GET /uma/question, plus:
How
condition_id was established. derived: computed from the question and confirmed against the condition map. derived_unverified: the same computation, not confirmed, and wrong for NegRisk markets; use /uma/history/market for the real condition id.How many lifecycles of this question have proposal, dispute or settlement events in the window.
1 is normal. A question that is re-requested after it finished has more than one, and the latest is served. A dispute re-requests the price in the same transaction and stays one lifecycle, so a disputed question keeps its disputed stage and the final settlement that follows the token-holder vote.On-chain block time (unix ms) of each stage event — the authoritative event time. The
request_ts on each stage is the UMA request key, not a clock: across a dispute re-request it can read earlier than a later stage, so order stages by block_ms, not request_ts.The time window actually scanned, returned on every response — success as well as
unknown — so a result is never silently truncated. With no from/to, the search reaches the present.404 with code not_found means no proposal, dispute or settlement for that id exists in the window.
GET /uma/history/market
The same body, looked up by the market’s CTF condition id.
condition_id is always the real condition id, including for NegRisk markets. resolution_source says how the market was tied to its oracle request:
When the answer is
unknown, the response is HTTP 200 with an explicit marker, not an empty success and not a 404:
Unknown example
reason is one of condition_not_in_pm_tokens, market_time_unknown, no_oo_request_found, ambiguous_gamma_candidate (more than one oracle request names the market’s Gamma id, so none is served rather than guessing), gamma_requester_not_negrisk (the sole match was not a NegRisk adapter), requester_family_mismatch (a negrisk_exact map entry was found but its requester is not a NegRisk adapter) or no_stage_events (an oracle request exists but nothing has been proposed yet; question_id is then set). An unknown carries no settled, answer or stage field: do not read it as an unsettled market.
GET /uma/history/recent
Questions with proposal, dispute or settlement activity in a time range, newest activity first, one entry per question, paged with a cursor.
Filter on the question’s state within the range:
proposed (proposed, not disputed or settled) · disputed (disputed, not settled) · settled. Omit for all.Question records (same shape as
GET /uma/history/question). Each carries resolution_source: "derived_unverified".400 range_too_large rather than silently shortened, so page a long period with consecutive from / to windows. Paging is keyset-based on the block time, block number and log index of each question’s latest event in the range, so a page never repeats or skips a question.
For stable paging, pin
to (an explicit timestamp) on every page request. With the default to=now the window moves between requests, and a question can be skipped across a page boundary. Each response echoes the resolved to_ms so you can reuse it.Errors
Recover after a disconnect
After consuming the live WebSocket, call/uma/history/recent with from set to your last event to recover the questions that changed while you were away, in order, with no gap. For the lowest-latency reads of what is resolving right now, use the live window instead.
Related
- UMA live window (REST) — lowest-latency reads of the realtime feed’s retained window.
- UMA WebSocket — the live
stream.readstream of new proposals, disputes and settlements. - UMA overview — lifecycle, identifiers and coverage limits.