Skip to content

Reputation

fabianschu edited this page Aug 23, 2021 · 5 revisions

Reputation

Reputation (REP) is a non-transferable token that can be used for governance.

The Prime Multisig Gnosis Safe is the owner of the non-transferable Reputation token.

As an owner, the safe can mint REP to specific addresses or burn REP from specific addresses. This can be done via the mint, burn, batchMint, batchBurn functions.

Functions

mint

The mint function takes two inputs:

  • _repRecipient: The address of the recipient who shall receive the minted REP.
  • _repAmount: The amount of REP to be minted to the address. The REP will be added to the balance of the recipient address. The amount of REP needs to be specified in WEI => if you want to mint 2 REP to a specific address, you would need to convert this into WEI which would be 2000000000000000000. Ethereum Unit Converter is helpful for conversions.

burn

The burn function takes two inputs:

  • _repRecipient: The address of the recipient whose REP shall be burnt. The REP will be added to the balance of the recipient address.
  • _repAmount: The amount of REP to be minted to the address in WEI. The REP will be subtracted from the balance of the recipient address.

batchMint

The batchMint function takes two inputs:

  • _repRecipients: An array of recipient addresses. These are the addresses that will receive the minted REP tokens.
  • _repAmounts: An array of reputation amounts, that is the amounts of REP tokens to be minted to each address in WEI. REP will be added to the balance of each recipient address.

Important: The order is important for both arrays. The first address in _repRecipients will receive the first amount in _repAmounts. The second address in _repRecipients will receive the second amount in _repAmounts and so forth.

Managing Reputation from the GnosisSafe UI

The batchBurn function takes two inputs:

  • _repRecipients: An array of recipient addresses. These are the addresses whose REP tokens will be burnt.
  • _repAmounts: An array of reputation amounts, that is the amounts of REP tokens to be burnt from each address in WEI. The REP will be subtracted from the balance of each recipient address.

Important: The order is important for both arrays. The first amount specified in _repAmounts will be subtracted from the balance of the first address specified in _repRecipients. The second amount specified in _repAmounts will be subtracted from the balance of the second address specified in _repRecipients and so forth.

Calling the functions from the Gnosis Safe UI

batchMint

  1. As an Gnosis Safe owner click on New Transaction:

  1. Click on Contract Interaction:

  1. In the field Contract address paste the address of the Reputation contract. For mainnet the address is 0x3ba4ECfb611c9694e7c35D3baf90aB137AFF137b. The field ABI should be filled automatically after the correct address has been pasted. If this is done, the UI should extend automatically and show additional input fields.

  1. Choose function from method dropdown. In this example we'll use the batchMint function:

  1. Insert function parameters. You want to specify the addresses that shall receive REP and how much REP each address shall receive. These information need to be provided as follows

_repRecipients: ["<address1>", "<address2>"] => a set of curly brackets encapsulates a list of addresses that are separated by commas. Each address is encapsulated by a set of double quotation marks.

_repAmounts: [<rep_amount_in_wei_for_address1>, <rep_amount_in_wei_for_address2>] => a set of curly brackets encapsulates a list of numbers that are separated by commas. The amounts are specified in WEI and there are no quotation marks.

The first address receives the first REP amount, the second address receives the second REP amount and so forth.

Click on Review. The UI should change and show a summary of the transaction.

(The new lines and empty spaces in the screenshot are not necessary and are solely meant to improve readibility. You can add additional whitespaces/new lines as you wish and it will not hurt the functionality.)

  1. Click on submit. Congratz, you created a transaction request to batchMint reputation. Now the other Safe owners need to confirm the transaction according to the configuration of the Multisig. When that is done, the batchMint function will be executed.

Other functions (mint, burn, batchBurn)

  • batchBurn works exactly like batchMint
  • mint and burn are somewhat more straightforward - you only need to provide one address without quotation marks and the amount of REP in WEI (no curly brackets, no commas, no quotation marks)