A multi-send smart contract can simultaneously send XDC cryptocurrency tokens to several wallet addresses. Using this smart contract, you may distribute your digital assets quickly and efficiently.
This smart contract allows users to send XDC tokens to multiple wallet addresses in a single transaction. This makes it easy for any bounty organizers to distribute their XDC tokens efficiently. The smart contract code is open source in a motto to help and contribute towards the web3 communities.
Anyone can fork the distribution contract on GitHub to distribute the XDC cryptocurrency balance of the contract to multiple addresses based on the address and percent struct of the array.
Below are the steps to use the Token Multi sender smart contract to distribute your XDC tokens to multiple addresses.
- Deploy the contract.
- Add the address and percent array using the addAddress function, which will create a mapping regarding the transfers to the address. Note: The owner of the contract can only call this function. When adding the address map, if the total exceeds 100% at any point, it won't allow adding the address and percent to the map. Use 0x prefix address instead of xdc prefix address and checksum verified address to avoid any failures.
- You can check the address mapping one by one by calling the addressArr variable with the index to get the value of the address and the percent defined for that index.
- Once all the addresses have been added, transfer the desired amount of the cryptocurrency you want to the contract address.
- Call the withdrawFunds functions, which will transfer the currency balance of the contract address to the defined address and percent map. Note: The owner of the contract can only call this function.
If you have any questions or feedback write them in the comments.