SFT SC Introduction

SFT minter Smart Contract

Be aware that the Smart Contract doesn't have any audits. It has complete functionality for the first version but still needs some improvements. Test it first on the devnet/testnet. And be sure that you know what you are doing.

You are reading about the Smart Contract designed for the MultiversX blockchain. Its primary purpose is to provide a simple logic for minting and buying SFT tokens from a previously configured collection.

It supports:

  • issuing the collection token
  • setting the create role
  • creating SFT
  • changing basic setup where it is possible

In short, you can issue a collection token and then create multiple SFT tokens with different initial supplies, attributes, and assets. Each token will have a different nonce. All that should be done using the owner's wallet. Then other wallets can buy a specific amount of the SFT token with the particular nonce. The operator of the smart contract (owner) can define the price per single token and max tokens to buy per single address. There will be more functionality in the following versions.

Required initial configuration

All are mandatory operations and should be done only once. Make the transactions in this order.

  1. The Smart Contract requires initial configuration to start the minting process. First, you would need to deploy it. Check the description and link to the code in the endpoints section. It is simpler if you are using the Elven Tools CLI.
  2. You would need to issue the collection token using the issueCollection endpoint. With CLI, it is simpler to do that. Again, check it in the endpoints section.
  3. Next is the setLocalRoles endpoint - it is required to set up proper roles for the collection token.
  4. Finally, you need to create the amount of SFT tokens with all attributes and assets. You can do this using createToken endpoint.

Then you are ready to buy. You can use buy endpoint for that.

Remember that everything is more straightforward with the Elven Tools CLI Check the jump start section.

Ways of using it

The best way of using it will be with Elven Tools CLI tool. It has a lot of valuable functions integrated, so deploying or interacting is simple. You can deploy the smart contract directly from its repository. Almost no coding skills are required in this case.

You can also take a more standard path and use mxpy for that. Mxpy CLI is an official CLI SDK for MultiversX blockchain based on Python. It is harded because you would need to take care of all needed data and data formats. You can check snippets in the repository.

Issues and ideas

Please post issues and ideas here.

Contact

Contents