Building a Decentralized betting platform (DEVELOPMENT UPDATE Feb 1, 2018)
About a week ago we introduced our project to the world. A platform that lives on the blockchain, controlled by no one, enabling fans to wager on outcomes of their favourite team’s games. Following the footsteps of a lot of other crypto initiatives we created our social presence, opened a Telegram group in case people want to chat in real time, and wrote a bunch of FAQ’s to make sure that people know what we do, how and more.
But that’s not what this post is about. This post is about the meaty stuff; blockchain and overall technology/product.
We initially wanted to launch for the Champions League playoffs, but the Super Bowl is such a big sporting event that we pushed up our BETA to Friday Feb 2nd, 2018. The beta (as all betas go) will be a limited experience. Something that allows us to test out the overall experience, contract, etc. on something other than test Ethereum networks.
So what will we be testing?
Lots of stuff! CryptoSportz is a P2P platform. This means we aren’t a bookie or a house or anything but a nice user friendly interface that enables people to come together inside the blockchain and challenge each other on how a sporting event might turn out. In order to facilitate that, we needed to build out a framework for these smart contracts. And we did. In lay-mans terms, the following is what has been done:
- A user can now visit CryptoSportz and the site will automatically know if that user has an ETH wallet (via MetaMask), a logic based on which users will proceed.
- Users that have a wallet will be able to view individual contract games and make a prediction… which for now because of the Super Bowl frenzy, we kept only to head to head predictions (i.e. who wins the game, total points scored, etc.)
- When you chose your prediction (i.e. New England will win & 44+ points in total for the game) you will be “buying a ticket”. This ticket will come in the form of a non-fungible token (based on CryptoKitties standard #721 of ETH) which will contain in it the info about your position
- The contract will allow people to take up as many of the various positions in it as they want. Our main beta contract will have 4 categories with 2 options (who will win, who wins by halftime, total points, points at half time). This creates 16 possible numbers of positions (2⁴=16). So on average if everyone sort of bets evenly across all 16 possibilities, then the odds any one player gets will be 16:1 on their individual ticket. There will also be other contracts with 3, 2, and a single head to head category
- Value of every ticket purchased will be sent to the contract minus a small platform fee (4–5%) and another tiny fee (1%) for The Captains. “ Who the hell are they?” do we hear you say?
- Captains are leaders or influencers that know other fans and players and want to have a little WHIFM (what’s in it for me) before they encourage their friends and peers to join. Anyone can be a captain, you just need to add your ETH wallet address at the end of www.cryptosportz.com/captains. And now the contract will always send you 1% of the wagers from anyone that you refered to the platform (as long as they didn’t clear their c0okies).
- The rest of the 95% of the ticket fee will be stored in the contract and in exchange you will recieve your non fungible token that contains the outcome selection you’ve made.
- At some point, the superbowl will start and the contract will stop accepting new entrants. It will change states and wait for a resolution from the Oracle service. This is the hardest part of the contract and although we hope that within the next week or two we will switch to a sports scores API to feed the resolution data, we will be manually pushing the result to the contract during the coming weekend. This is the number 1 priority for our team right now and a fast follow will be implemented so that we can genuinely say that Crypto Sportz is a decentralized application. We’ve found a few APIs that work but if anyone knows of a good one, shout it on Telegram or here.
- Last but not least, when the game results are entered into the contract it will recognize tickets with the correct prediction as winning tickets and divide its ETH balance by the number of winning tickets.
- You will see a big “REDEEM” button on your ticket and will be able to exchange it with the contract for the winning value
More to come, this is just the beginning. Thank you for following us along this journey.