The cryptocurrency market saw a dramatic fallout throughout 2018. With Bitcoin falling from a value of $17,000 per coin in January of 2018 to around $3,500, many traders incurred losses since the start of the year. Whether you are a trader or an investor, your objective is to make money. Your secondary objective is to do so with the minimum acceptable level of risk. Now Derivatives are financial instruments that aim to increase returns and reduce risk. A Derivative is a financial instrument that derives its value from an underlying asset, in this case, cryptocurrencies. An Option is a contract that gives an investor the right — but not the obligation — to buy/sell an asset at a certain price within a certain period of time. The idea behind ETHOptions is to introduce options contracts over the blockchain, for traders to hedge against their crypto investments beyond Bitcoin. Bitcoin Options do exist, however as the market share of ERC20 tokens have grown to 91% due to the daily trading volumes and number of projects existing on the Ethereum Blockchain, Options contract for ERC20 tokens will have a huge market outreach. All the major crypto players are getting into Bitcoin derivatives. Whereas, derivatives for Ethereum based tokens is still an untouched market. We’re providing a new Crypto Asset class that can potentially have a market size of $42 Billion.
What it does & how we made it?
We have created a decentralized ERC20 Options Trading platform. On our platform, the option Maker can create an order, filling out the details which are added as an order to our Orderbook making it available for everyone to access. Along with the details, he must also give the allowance to transfer the BaseTokens to the escrow to be released when the option is exercised. The Taker can choose the most profitable option in the Orderbook according to his judgement and fill it. To do so, he would be prompted to pay the premium for that option in the QuoteToken. Using Kyber, traders can swap the required ERC20 at the time of payment and pay with whichever ERC20 tokens they have. They receive the ERC721 OptionTokens for the corresponding option order filled. Before the expiry time, the Taker can choose to exercise his Option by giving his OptionTokens to purchase the locked BaseTokens at the Strike Price, in terms of QuoteTokens. This will be possible after verification by the smart contract wrt to expiry time and Market Price of the BaseToken according to a Chainlink Oracle which takes the price through a Coinmarketcap API. Using Chainlink, we were able to ensure the integrity of data sensitive to the trading. Taker can then sell BaseTokens in the market, thereby making a profit of (MarketPrice - StrikePrice) per locked BaseToken.
Challenges we ran into
One of the major challenges while conceptualising the platform was that it would be difficult to make the platform popular as people would need the corresponding ERC20 token for the option they choose, restricting scalability. While exploring Kyber, we realised this problem will be solved successfully by integrating Kyber with our platform and allowing users to pay through it. One of the implementation challenges was writing the contracts such that no bad user input can get through, i.e., learning basic auditing to create a secure implementation. Also, another challenge was testing on public networks since we needed data from public networks like Kyber and Chainlink.
Accomplishments that we're proud of
We’re proud that we have managed to create a seamless user interface on top of the complicated smart contracts to successfully implement our vision. We believe our platform can help propel the mass adoption of ERC20 tokens and hence of blockchain by encouraging investment in more tokens. We are thus proud of having positively impacted the DeFi and Web3.0 space.
What we learned
Making this project has been a truly amazing learning experience, from learning about the decentralised finance space and how options work to learning about decentralised oracles and swapping protocols. Moreover, we learnt how to successfully write multiple inter-dependent smart contracts in sync with each other. We also learnt to properly use the Truffle Suite, to deploy contracts and write tests, and hence create a robust DApp.
What's next for EthOptions
For the future of EthOptions, we intend to extend the functionality by also introducing Put Options. We want to make the OptionTokens tradable so that one can sell their position. Also, we intend to extend the asset class our platform caters to, beyond ERC20 tokens by using the Synthetix platform. Besides the longing and shorting of Call and Put options, we intend on integrating popular Option strategies such as Covered/Married Call, Bull & Bear Call/Put Spreads, Iron Condor, etc. to benefit from all sorts of market movements. The platform will allow for a Plug-n-Play approach to easily form option strategies. For amateur traders, ETHOptions will show the possible strategies based on the market conditions that the trader can benefit from. Traders can implement trading strategies based on their trading style, goals, risk-taking capabilities, etc.