OPN Ticketing Contracts

Token Addresses - Polygon

The token addresses of OPN across each chain are:

OPN Contract Address Sophon - 0xA96aD8EC6A83F23e0A75E5d8c9cE13C1042c4295

OPN Contract Address Ethereum - 0xc28eb2250d1AE32c7E74CFb6d6b86afC9BEb6509

OPN Contract Address Solana - J1YnyKzmxBwFkPftvZexnHTm4Am7JnmWydhxtXdwEmMv

OPN Contract Address Polygon - 0x7844F79FC841E4F92d974C417031c76F8578c2D5

OPN Contract Address Base - 0x9A6d24c02eC35ad970287eE8296D4D6552a31DbE

Ticketing Addresses - Polygon

At the moment we are in the process of moving all our ticketing volume to the Sophon blockchain.

Polygon: Economics

Responsible for managing the internal balances and accounting within the protocol. Manages available and reserved fuel balances for each integrator as well as the protocol-wide spent fuel balances. The billing rates for each integrator is held within the integratorRates mapping and each integrator's metadata can be found within integratorData.

Since each integrator can have one or more relayers, Economics.sol also tracks a mapping of relayerAddress to the integrator allowing accounting operations to happen only using the relayer address.

Auth

Handles access control and permissions for protected methods used within the protocol such as updating the price oracle, creating integrators, and performing custodial top-ups. Also permissions contracts to each-other so that only certain contracts can talk to protected methods.

EventFactory

EventFactory.sol is responsible for creating new events and assigning them an index in which they can be referenced using. Because each event is its own independent smart contract, the EventFactory is only responsible for creating each event and setting the initial event metadata. Future updates to metadata must be made directly to the event's contract address.

EventImplementation

Never accessed directly, this is the implementation contract used for each event using the BeaconProxy pattern. Each event is a separate contract but uses the same implementation for consistency, and this is the implementation. Contains all of the lifecycle methods for ticket interaction and the ERC-721 implementation. Implements the OpenZeppelin's IERC721 and IERC721Metadata, but not IERC721Enumerable.

FuelCollector

Defines and distributes the collected spent fuel from the Economics contract. Economics is only responsible for tracking the total amount of protocol-spent-fuel and total-spent-fuel but not for the distribution. Exposes a public collect() function that can be used to distribute the protocol-spent-fuel to the assigned destination addresses, and then the remainder to the remainder addresses.

PriceOracle

Used as an on-chain oracle for the price of OPN in USD to 18 decimal places. This is necessary for valuing direct non-custodial OPN top-ups and is driven using an off-chain worker.

Registry

Tracks all of the other contract addresses in use by the protocol. This allows each contract to hold only a reference to the deployed Registry.sol contract and then use this to reference any other contract as needed at runtime. If in doubt, check the registry for the currently active addresses for all other contracts listed here.

TopUp

Entrypoint for topping up an integrator account. Contains one public method for non-custodial top-ups using OPN held within the sender's wallet and one protected method for topping-up the available fuel using USDC via a swap using the Sushi pools. Routes transfers via a path of [baseToken, weth, Economics.fuelToken()].

Relayers

A relayer is responsible for minting the NFTs for an integrator and is linked to an integrator's account in order to track OPN fuel balances and accounting per-relayer-address. These relayer addresses have indepenedent rate configurations depending on the products used. See integrators for more.

A relayer belongs-to an integrator and this means that an integrator can have more than one relayer as necessary should multiple be needed to additional scale, although at present each integrator only has a single active relayer.

You can query for the active relayer addresses using the subgraph:

{
  relayers {
    id
    isEnabled
    integrator {
      name
    }
  }
}