The Carbon Credits Pool pallet lets users create and manage Carbon Credits pools. A Carbon Credits pool is a collection of Carbon Credits tokens of different types represented by a common pool token. A user holding any Carbon Credits tokens (subject to the Carbon Credits pool config) can deposit Carbon Credits tokens to the pool and receive equivalent pool tokens in return. These pool tokens can be transferred freely and can be retired. When retire function is called, the underlying Carbon Credits credits are retired starting from the oldest in the pool.
A pool creator can setup configs, these configs determine which type of tokens are accepted into the pool. Currently the owner can setup two configs for a pool
- Registry List : This limits the pool to accept Carbon Credits's issued by the given registry's only
- Project List : This limits the pool to accepts Carbon Credits's issued by specific project's only
create
: Creates a new pool with given configdeposit
: Deposit some Carbon Credits tokens to generate pool tokensretire
: Burn a specified amount of pool tokens