Terminology
- Channel: A modified ERC-1155 collection. The foundational entity of the protocol.
- Transport Layer: Application specific contracts sitting on top of channels.
- Interaction Logic: Custom logic which governs who is allowed to create and mint tokens in a channel.
Channel Factory
Channels are created by calling the channel factory contract. The factory creates a new ERC1967Proxy to one of the channel type implementations (Infinite or Finite). Anyone can create a channel by interacting with the factory.
Channels
Channel.sol calls to 2 external contracts to manage mint fees and interaction logic. Any fee or logic contract can be passed to the channel. The initial protocol release comes with: CustomFees.sol - Custom incentive structure which allows admins / managers to define how mint fees (if any) are distributed to different parties. Mint fees can be set in ETH or ERC20. DynamicLogic.sol - Logic which governs the interaction power (num creations / num mints) allotted to users in a channel based on results of external calls to other contracts at runtime.
Channel fees
Mint fees and protocol reward splits are set at the channel level for all tokens. By default, the channel has no fees. Fees are set by calling the setFees function on the channel either during initialization insetupActions[]
or after the channel is created.
Fees can be disabled by setting the fee contract to address 0.
Channel logic
Interaction logic is set at the channel level for all tokens. By default, the channel has no logic, meaning everyone can create and mint an unlimited number of tokens. The interaction logic is set by calling the setLogic function on the channel either during initialization insetupActions[]
or after the channel is created.
All logic can be disabled by setting the logic contract to address 0. Logic for each actor (creator / minter) can be set independently by passing 0 bytes respectively.
Rewards
Protocol rewards and escrowed finite channel rewards are managed by Rewards.sol. Each channel has its own instance of Rewards.sol which is created during channel initialization. Protocol rewards are pushed to recipients on every mint.Access control
Channels have 1 admin and 0 or more managers. Admins can add and remove managers, but otherwise have the same authority as managers. Both roles can:- update the channel fees, logic, and metadata
- cancel finite channels
- authorize channel upgrades

Upgrades
Over time, we expect the protocol to evolve. When we upgrade the protocol, we register the new implementation address in the global UpgradePath.sol contract. This gives admins / managers a choice to either upgrade their channel to the new implementation, or keep using the old version. The SDK provides a methodgetOptimalUpgradePath
that operators can use to determine if upgrades are available.
Transport Layers
The transport layer is the home of application specific functionality that site on top of channels. The transport layer receives messages from the channel on each creation or mint event and does some amount of extra processing.