Dinero
Dinero is a stablecoin issued by Interest Protocol.

Open Zeppelin Contracts

MINTER_ROLE

function MINTER_ROLE() external view returns(bytes32);
Summary
It returns the hash assigned to the MINTER_ROLE. Addresses with this role can mint and burn Dinero.

DEVELOPER_ROLE

function DEVELOPER_ROLE() external view returns(bytes32);
Summary
It returns the hash assigned to the DEVELOPER_ROLE. Addresses with this role can upgrade the Dinero contract.

mint

function mint(address account, uint256 amount) external;
Parameters
  1. 1.
    Account - address: The address that will receive the new-minted tokens.
  2. 2.
    Amount - uint256: The amount of new tokens.
Restrictions
  • onlyRole modifier: Callers must have the MINTER_ROLE to call this function.
Event
event Transfer(address indexed from, address indexed to, uint256 value);
Summary
This function allows authorized contracts to mint Dinero to create loans and other investment strategies. The caller must have the MINTER_ROLE.

burn

function burn(address account, uint256 amount) external;
Parameters
  1. 1.
    Account - address: The address that will have its tokens burned.
  2. 2.
    Amount - uint256: The amount of tokens to burn.
Restrictions
  • onlyRole modifier: Callers must have the MINTER_ROLE to call this function.
Event
event Transfer(address indexed from, address indexed to, uint256 value);
Summary
This function allows authorized contracts to burn Dinero directly from any account. It is an alternative to the burnFrom function. However, since it does not require approval, it improves the user's experience but needs an access control modifier to be secure. The caller must have the MINTER_ROLE.
This contract uses the UUPS upgradeable pattern. Therefore, the interfaces and functionalities can change in the future.
Export as PDF
Copy link
On this page
Open Zeppelin Contracts
MINTER_ROLE
DEVELOPER_ROLE
mint
burn