Skip to content

Prediction Market Development for Event Market Venues

Protofire's prediction market development covers the contracts between an event market's question and its payout, including an adapter that reports the result once. Teams that run or build a venue keep its rules, oracle choice and admin keys. We built Gnosis's Conditional Tokens Explorer in 2020 and 2021.

Luis Medeiros

Reviewed by Luis Medeiros, Field CTO at ProtofireLast reviewed: November 2026

On this page
  1. Overview
  2. Changing a result
  3. What you get
  4. Why Protofire
  5. How the work goes
  6. Terms
  7. Not the right fit
  8. Related services and pages
  9. FAQ

Work shipped for 60+ networks and 95+ protocols, including

  • Chainlink
  • Ethereum
  • Solana
  • Safe
  • Ripple
  • Aave

The first payout report decides an event market

On Gnosis's ConditionalTokens contract, a market's first payout report is final. A second reportPayouts call reverts with "payout denominator already set", and redeemPositions reverts until the first report arrives. So all disputes have to finish inside the oracle before the first reportPayouts call, and a wrong report remains in the contract. Prediction market development covers the contracts between the question and that payout, and Protofire builds them.

For example, your market closed at noon and the oracle proposed an answer. A trader holding a large position says the answer is wrong. Your adapter will report the result when the dispute window ends. Your head of product asks what happens if the oracle gets it wrong. Once the adapter has reported, the contract will not accept a correction.

Who builds and holds each part of an event market

The venue writes the rules and holds the admin keys. Oracle networks and the collateral issuer act under their own rules.

The venue

Market rules and listings

The venue writes the question text, the resolution source and the closing time, and decides which markets to list.

Admin keys

The factory owner, the adapter admin and the treasury Safe each act under the venue's approval rule.
Protofire builds

Market factory and conditions

The factory prepares each condition from a question ID and its outcome slots.

Resolution adapter

The adapter reads the oracle, maps the answer to a payout vector and reports it once.

Trading and redemption

Order settlement or an AMM handles trades, and the claim flow calls redeemPositions after the report.

Indexer and position views

The indexer turns condition, split, merge, resolution and redemption events into market state.
Oracle networks and the collateral issuer

Oracle answer and disputes

The answer comes from UMA proposals and votes, Reality.eth bonds with Kleros arbitration, or a Chainlink or Pyth price.

Collateral token

An ERC-20 token backs each position, and its issuer controls any pause.

Who can change a result before the payout report

Before the adapter reports, the oracle's dispute process or the holder of the adapter's admin key can change a result.After the reportPayouts call, nothing in the framework can change it.

A published UMA CTF adapter contract shows which powers such an adapter gives its admin. The admin can flag a market, wait a SAFETY_PERIOD of one hour, then call resolveManually with payouts the admin chooses. The same admin can pause, unpause and reset a question. On the oracle side, UMA's ManagedOptimisticOracleV2 lets a request manager set the proposer whitelist for each request. If these powers are left unwritten, the rules text can promise one thing while an admin key allows another. So each power needs a named holder, an approval rule on a Safe the venue controls and a public record of each use.

Open positions are a second source of exposure. The positions remain in the contract until some payout vector is reported, and the rules text decides which vector that is. UMA's documentation says that when a second or later request resolves as "TOO EARLY", a new request is created and "the market stays open". An even split reports equal numerators, so each side redeems for half. If the collateral issuer pauses transfers, the transfer inside redeemPositions fails, whatever the oracle said. The venue's rules text should name each of these cases before trading opens.

Regulators read event contracts in different ways. A venue's front end and market list follow the reading that applies where the venue takes users. On 19 October 2026, the CFTC proposed defining "swap" to "explicitly include event contracts". The comment deadline is 18 November 2026. In Great Britain, the Gambling Commission's Director of Strategy wrote about prediction market operators on 4 February 2026.

If a prediction market operator was to launch here in Great Britain, we do not believe they would be able to classify themselves as non-gambling products.
UK Gambling Commission, Blog post by its Director of Strategy, Gambling regulator for Great Britain · Blog, 4 February 2026

What prediction market development gives a venue

A venue gets markets it can explain from the written question to the payout.Each admin power is held by a named owner.

Market conditions that match the published rules

A trader or auditor can check what the oracle was asked, because each condition and question ID points back to the published rules text. Protofire builds the factory that prepares each condition with the adapter as its oracle. The build also includes a design for outcomes that are added after trading opens.

A resolution adapter that reports each result once

The adapter reports each market's payout once, and its admin functions answer to your keys. Protofire builds an adapter for UMA, for Reality.eth with Kleros, or for a price feed. The adapter maps all the answers your rules allow to a payout vector, including an even split and "too early". Each admin function is listed with its holder and deployed onto a Safe you control.

Trading and settlement in contracts the venue owns

Positions trade against collateral in contracts you control. A holder of all sides of a market can merge those positions back into collateral. Protofire builds settlement for an order book that matches off chain, or an LMSR or constant-product market maker. Your own liquidity account funds that market maker. With off-chain matching, a fill cannot go beyond the order the trader signed. Protofire's DEX development page covers those contracts.

Price-settled markets with a named feed and round

A market on a price settles at the number its rules name. The rules also name the feed and the round or publish time. A Chainlink feed updates on a deviation threshold or a heartbeat, so the rules say which round counts. That round is read with getRoundData. A Pyth update is checked inside a publish-time window with parsePriceFeedUpdates. Protofire's Oracle integration service covers the checks on each read.

An indexer for open interest and unclaimed payouts

Your front end and your accountants can see open interest, holdings and unclaimed payouts for each market. Protofire builds an indexer over the condition, split, merge, resolution and redemption events and the ERC-1155 transfers. Each row is keyed by its transaction hash plus the log's index. A row is written once its block is final on that chain. The location and eligibility checks that your counsel specifies are part of the front end, and the venue enforces them. Protofire's subgraph development page covers the indexing work.

Tests and a second firm's audit before the first mainnet market

Protofire's tests try to report twice and to report from the wrong address. They also try to report all zeros and to redeem before the result. Then a second firm that wrote none of the code audits the factory, the adapter and the AMM. Protofire's smart contract audit service prepares the code and fixes what the audit finds. An audit lists findings. It does not promise that the code is free of faults.

Our record: the Conditional Tokens Explorer for Gnosis

In 2020 and 2021, Protofire built the Conditional Tokens Explorer for Gnosis.The web app worked with Gnosis's Conditional Tokens Framework on Ethereum and Gnosis Chain. Users could prepare conditions, split and merge positions, report payouts and redeem. Gnosis designed the framework and its contracts. Gnosis's announcement of 9 December 2020 points readers to Protofire's account of its contribution to developing the Explorer. The Explorer's source is public in the Gnosis GitHub organization.

Because the Explorer ran the framework's operations from preparing a condition to redeeming, Protofire has worked with the calls that an adapter must make.

Two more parts of Protofire's record apply to the oracle reads and the indexer. Protofire is a Chainlink core contributor and helps maintain Chainlink CCIP. From 2020 to 2024, Protofire was a top-3 Graph indexer by indexing rewards. Our guide to blockchain indexers sets out the method.

How the work goes, from one market to monitoring

The work starts from one of your markets.

  1. Step 1

    You send one market

    You send one market's rules text, your oracle choice and the repository or deployed addresses. You share them under NDA, with user data removed.
  2. Step 2

    You receive a written proposal

    The proposal sizes the factory, adapter and redemption contracts. It also suggests a holder for each admin function.
  3. Step 3

    You deploy from your own keys

    Your keys run each deployment. Once your markets launch, Protofire holds no adapter admin, proposer, disputer or voting role on those markets, the factory or the treasury.
  4. Step 4

    Monitoring under a scope

    An indexer or monitor that Protofire maintains reads the oracle and RPC with credentials your staff issue. Its scope names, call by call, what that service may write.

How work with Protofire starts

Your procurement team can read the shared terms before the first call.

Proposal
In writing, one business day after the discovery call: findings, a plan in phases and the first step we recommend.
Price
Fixed per phase when you commission it, against written acceptance criteria. Overruns inside them are ours to absorb, invoices follow delivered milestones, and you can stop at any phase boundary. Anything we operate after launch is priced in the proposal as its own recurring line, with the notice to end it.
Ownership
Code we write for you, contracts, the keys and credentials this work creates and the accounts your infrastructure runs in are yours by contract, within the license of any third-party software involved. Keys that a custody platform or a staking provider holds under its own key model stay with it under your contract; every other custody key stays with you or the custodian you appoint. Where the scope places something on servers we rent, it says what moves to you and when. An NDA is available from your first message, and we sign a data processing agreement (DPA) together with it.
After launch
Delivery closes with a hypercare window and a defect warranty, with their terms written into the proposal. A service we operate continues under its written scope until that scope ends.
Access
Read-only by default. A role that can start requests only if your written scope names one; never a signer, approver, administrator, key holder or recovery role on your contracts, wallets or custody platform. Services we build call each platform on credentials your staff issue and keep in your vault. Anything that approves or moves funds runs in your environment, and a scope under which we operate a service lists every write call it makes. Where the scope has us operate nodes, validators, monitors, explorers or indexers, it names the role and any key we hold on those servers, and in your own cloud account you can remove it.
Licenses
Protofire is an engineering firm and holds no financial or crypto-asset license; licensed activity stays with you and your providers.

How we work shows a worked proposal.

Roles an event market needs from other parties

Other parties hold the roles that decide a result or put capital at risk.

  • You need a license, a registration or a legal opinion on event contracts. Protofire holds no license and gives no legal opinion.
  • You want someone to answer or vote on results. UMA voters, Reality.eth answerers, Kleros jurors and your own admin do that.
  • You want liquidity and a venue run for you. The venue's own liquidity account funds the AMM that Protofire writes. The operator runs the matching engine and customer support.
  • Your venue runs outside the EVM. The Conditional Tokens Framework and the adapters Protofire builds are Solidity contracts. Other chains need a different build.

A venue is ready for a first proposal when it has chosen its oracle and where it takes users. What it needs from us is the conditions, adapter, settlement and indexing, built and reviewed.

FAQ

What is prediction market development?
Prediction market development is the engineering between an event market's question and its payout. It covers conditions and outcome tokens, a resolution adapter for the chosen oracle, and order settlement or an AMM. It also covers redemption and indexing. Protofire builds these parts on the Conditional Tokens Framework or on a venue's own ledger. The venue keeps the rules and the admin keys.
Who can build the contracts for an event market venue?
Protofire builds the contracts for event market venues on the EVM. We build the market factory, the resolution adapter and the settlement or AMM contracts. We also build the redemption flow and the indexer. The contracts read the oracle that the venue picks: UMA, Reality.eth with Kleros, or a Chainlink or Pyth price. The venue sets the rules and holds the keys. Protofire does not operate the market.
Who reports the result on a Conditional Tokens market?
The oracle address named in the condition reports the result. The condition ID hashes that address with the question ID and the outcome count. So a report from another address finds no prepared condition and reverts. In this design, that oracle address is an adapter contract.
Can a reported result be corrected, and who holds the adapter's admin key?
No, not in the Conditional Tokens contract, where a second reportPayouts call reverts. Corrections happen before the report, in the oracle's dispute process or through an adapter function such as a flag followed by manual resolution. Those adapter functions answer to an address the venue controls, such as a Safe with its own approval rule. The factory owner and treasury roles also belong to the venue. Protofire's indexer and monitors read chain data. Any service that sends a transaction signs with a key your staff hold.
Should a venue keep the Conditional Tokens Framework or run its own position ledger?
Either choice works, and each has a cost. Keeping the framework means keeping its single-report rule. The last commit on the master branch of the Conditional Tokens contracts dates from September 2020, as the repository showed in November 2026. A venue's own ledger brings its own audit scope, indexer and wallet support. Polymarket's Protocol V2 migration guide, read in November 2026, says V2 balances "live in PositionManager". The same guide says "Existing CTF holdings are not converted". So a venue on that path runs two sets of position contracts while its old markets are still running.
Are event contracts legal, and who decides for a venue?
The answer depends on the event and on where the users are, and it is a question for the venue's counsel. US registered exchanges list event contracts under CFTC Part 40. The CFTC bars these exchanges from listing a contract on an excluded commodity that "involves, relates to, or references terrorism, assassination, war, gaming" (Rule 40.11(a)(1)). The same bar covers a contract that involves an activity unlawful under State or Federal law. ESMA wrote on 3 July 2026 that event contracts that are financial instruments fall under national product intervention measures on binary options. Those measures prohibit marketing, distribution or sale to retail clients.
Does Protofire work with licensed exchanges or venue front ends?
Yes, Protofire works on the parts that are code. For a licensed exchange, those parts are an onchain record of positions, data feeds or settlement contracts where the exchange's regulator allows them. For a front end over another venue, those parts are order routing, position and history views, and an indexer over the host venue's events. The exchange keeps its rulebook, clearing, surveillance and customer accounts.

Get a proposal

Tell us what you are building. An engineer reads it, we have a short call, and the written proposal follows within one business day.

Luis MedeirosField CTO, reads every request · LinkedIn

A demo or repository link also works.