Token Swap Technicality

Calvin Hsieh
StormX
Published in
6 min readMay 28, 2020

--

TL; DR: We’ve rebranded our apps to StormX and our token to STMX so that we have one cohesive brand. Our updated token will allow for staking and our users will be able to earn even more when they sign up for our rewards program. The token swap has just been initialized and the swap start date is set for June 8th, 2020.If you’re holding your STORM tokens on any exchanges, more detailed information will be out shortly, but know that we are working with Kyber Network, Binance, Bittrex and Upbit to make the transition as seamless as possible.

The new STMX Token

In our previous blog post, we briefly talked about our upcoming token swap, so I want to take this time to expand a bit more on the subject.

When can I swap? And when does the swap window close?

We will allow about 4 months from the start of the contract initialization for users to swap their tokens.

The contract was initialized at timestamp 1,589,485,972 and will allow at least 9,676,800 seconds (about 4 months) to do the swap. This means that the swap window will be opened until September 3, 2020 7:52:52 PM UTC, at the very minimum (1,589,485,972 + 9,676,800 = 1,599,162,772 UNIX). You can read more about the contract initialization here.

To give users a safety period, the official swap will start June 8, 2020 and end 11:59:59 PM UTC October 8, 2020.

Why are we doing a token swap?

Removing God Mode

We have a function on our STORM token contract that allows us to destroy or create tokens. Though, we never had any intention of using this. This code was originally built in case of hacks or emergencies. This feature has been removed in our new STMX token contract which makes us one step closer to decentralization!

Staking

We want to make sure our users benefit from the swap, so we are introducing StormX staking! This feature will allow users who own STMX tokens to receive additional benefits. In addition, our users will still receive Reward Program benefits for holding STMX such as increased crypto back, faster reward times and more. We will have a separate blog post regarding this so stay tuned!

Rebranding

It’s all about SEO and brand-awareness. Managing the STORM token, StormPlay, StormShop, and StormX itself was already a headache. By reconsolidating our apps to StormX and rebranding our token to STMX, we are creating a more cohesive brand that we can continue to build off of.

Ok, so what is the new STMX token and what is it made of?

The STMX token is an ERC-20 token on the Ethereum blockchain, written in Solidity. The STMX token is very much like the STORM token with 18 decimals and a maximum total supply of 10,000,000,000.

I’d also like to use this chance to give a special thanks to Quantstamp who helped us build and audit our smart contracts. We take security very seriously, so we want to ensure that the contracts deployed on the mainnet are flawless. By having such a reputable company like Quantstamp helping us on our smart contracts, you can rest comfortably knowing your tokens are safe.

How do I swap my STORM token to STMX token?

We built a very convenient decentralized app (dapp) to let you swap the tokens. You can swap them by using any web3 wallet (MetaMask, Trust Wallet, etc), Ledger, Keystore, or manually on MyEtherWallet or MyCrypto. Lots of options here. You can find the details on how to do so in our FAQ.

What if I don’t have any Ethereum to do the swap?

I’m glad you asked! In order to do the token swap, you’ll have to write something to the blockchain and have it mined. We want to ensure we provide the least friction possible to our beloved token holders while doing the swap; therefore, you can pay the gas fee by using STORM! Oh yeah, you heard that right. You do not need to have Ethereum in your wallet to do the swap. You can easily use STORM to pay for the cost and let us take care of the rest for you. Full disclosure, you must use our dapp in order to benefit from this.

How do you make it so that I don’t need to spend Ethereum for gas?

In the world of Ethereum blockchain, Ether is required to make transactions on the blockchain. This is a hurdle for new crypto enthusiasts who don’t own Ether. How do we solve this issue? Meta-transaction. A meta-transaction sends a user- signed message to a relayer with information about the actual transaction. The relayer then signs the Ethereum transaction, pays the gas fee, and sends it to the blockchain. This allows our dapp users to perform the swap without having Ether in their wallet. This further reduces any friction and improves the UX for our users so it’s a seamless experience.

What about my STORM tokens on the exchanges?

If you have your tokens on the exchanges, rest assured that we have them taken care of as well. We are working closely with Kyber Network, Bittrex, Binance, and Upbit to determine the timeline and effort to do the swap for our holders. When the time comes, these exchanges will have detailed information on how to do the swap on their specific network, but we will have more updates on this later!

How does the swap work?

STORM to STMX will be a 1:1 token swap. You have two options to pay for the gas: STORM or ETH

Scenario 1 — paying with STORM for gas

If you pay for the gas with STORM, you’ll see your final STMX balance as the original STORM balance minus the gas fee.

For example:

  • Your STORM balance: 50
  • STORM fee for gas: 20

In this scenario, you see the STORM required for processing the swap is 20. Therefore, after the swap is completed, your resulting STMX will be 30.

Scenario 2 — paying with ETH for gas

Gas fee in ETH is calculated in real-time based on how congested the network is. Please make sure you have some ETH in your wallet if you’d like to pay with ETH.

For example:

  • Your STORM balance: 50
  • Your ETH balance: 0.1
  • ETH fee for gas: 0.0006

In this scenario, your resulting STMX amount will be 50 and the gas fee will be deducted from your ETH balance giving you 0.094 ETH left.

What happens to my STORM tokens after the swap?

After your STORM is successfully converted to the STMX token, the smart contract will mint the same amount of STMX tokens (increasing the total supply of STMX) on the blockchain and destroy the same amount of STORM tokens on the blockchain (decreasing the total supply of STORM).

What would happen to the leftover STORM that aren’t converted to STMX after the swap window is closed?

We want to ensure that there are as few tokens remaining as possible, but if for any reason there are leftover STORM tokens in the circulating supply, the remaining tokens will be converted to STMX, and will be used for the user pool.

Where can I find all the relevant resources regarding this swap?

Source code: https://github.com/stormxio/stormx-token
Dapp: https://swap.stormx.io
STMX token: https://etherscan.io/token/0xbE9375C6a420D2eEB258962efB95551A5b722803
Token swap: https://etherscan.io/address/0x617592b603a57B88dC4d2D9cFf180669390134bF
FAQ: https://help.stormx.io/hc/en-us/articles/360048712853

Primarily, we want to make sure our StormX users are being taken care of and well informed, which is why we not only want to make sure the smart contracts are secured, but also provide new, exciting features to our beloved community.

I hope you found this article helpful and it clarified any questions you may have had in terms of the swap.

Yours Truly,
Calvin Hsieh
CTO & Cofounder of StormX

--

--

Co-Founder & CTO ofStormX. Entrepreneur, engineer. Blockchain enthusiast