Skip to content

btn-group/btn_distributor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Button Distributor

This is a smart contract to facilitate the safe distribution of Button ($BTN) on Aleph Zero. It is the final step of the Button ($BUTT) migration from Secret Network. All minted $BTN will be initially sent to this smart contract. With the amount and address details collected from the Secret Network migration contract, we will increase the account allowances accordingly.

Features

  1. Initialise with admin and $BTN smart contract details.
  2. Allow admin to increase_allowance for an account and store the details. The key for details is a String as it will be an encryption of the corresponding Secret Network migration order id.
  3. Allow admin to decrease_allowance for an order and remove the details. This is in case the user has entered the wrong address.
  4. Allow user to collect their $BTN.
  5. Allow retrieving order details.

Getting Started

Prerequisites

cargo install --force --locked cargo-contract --version 2.0.1

Checking code

cargo checkmate
cargo sort

Deployment

  1. Build contract:
cargo contract build --release
  1. If setting up locally, start a local development chain.
substrate-contracts-node --dev
  1. Upload, initialise and interact with contract at Contracts UI.

References

About

Button ($BTN) distributor smart contract for Aleph Zero

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages