Smart Contracts
Last updated
Last updated
There are in total three smart contracts as seen in the image below. The owners of an NFT from the TimePiecePassport contract have the ability to transfer it wherever they want. Just like a normal ERC-721 NFT.
The TimePieceEscrow contract is meant to be used during the step of an order via the OpenChrono website.
The TimePiecePayments contract is meant to be used for crypto payments and to set the Royalties of an NFT.
Each smart contract has several roles to determine who can perform what actions.
Role | Description |
---|---|
Role | Description |
---|---|
Role | Description |
---|---|
DEFAULT_ADMIN_ROLE
Can update the role assignments.
ROLE_MINTER
The only one that is allowed to mint new NFTs.
ROLE_CONFIGURATOR
Can update the base URI of the token URL.
ROLE_ROYALTY_CONFIGURATOR
Can set and delete ERC-2981 fee data. Must be at least the TimePiecePayments contract.
ROLE_REDEEMER
Can set the redeem flag in the contract. Must be at least the TimePieceEscrow contract.
ROLE_UPDATER
Can upgrade the contract.
DEFAULT_ADMIN_ROLE
Can update the role assignments.
ROLE_CONFIGURATOR
Update the configuration of contract addresses and escrow data.
ROLE_ESCROWER
Can start an escrow.
DEFAULT_ADMIN_ROLE
Can update the role assignments.
ROLE_CONFIGURATOR
Can configure the contract addresses. Can (un)pause the contract.
ROLE_ROYALTY_CONFIGURATOR
Can set and delete the default and token fee structure.
ROLE_FUNDS_MANAGER
Can split the received fee and withdraw tokens from the contract.
ROLE_UPDATER
Can upgrade the contract.