Try the live demo
This is a project submitted to the 2023 Flow Hackaton by BlockBidders.
Flowwery πΊ aims to revolutionize the lottery industry by offering a decentralized lottery platform on the Flow Blockchain for everyone.
This platform allows any user to create their own lottery by setting the number of tickets, the price, the type of currency, the expiration date and the royalties over the prize. One of the mind-blowing thing is that you can create a lottery with just two tickets or with millions of them, you can even set your own cut π€― Flowwery ensures transparency and fairness by leveraging the decentralized nature of the Flow Blockchain, ensuring that all lottery results are tamper-proof and publicly verifiable.
One of the key advantages of Flowwery is its flexibility in terms of the tokens that can be used to create lotteries. The platform allows users to set up lotteries using any type of fungible token, including the native Flow token and FUSD.
Another significant benefit of Flowwery is its accessibility. Any user with a Flow Blockchain wallet can easily participate in any lottery or create it, without the need for any additional software or technical knowledge. The platform ensures that lottery results are fair and transparent, providing a level playing field for all participants.
- Decentralized lottery platform on the Flow Blockchain
- User-friendly interface for creating and participating in lotteries
- Flexibility to create lotteries using any type of fungible token, including the native Flow token (default)
- Option to add multiple addresses to receive a cut of the prize, useful for charity lotteries or other beneficent causes
- Transparent and tamper-proof lottery results thanks to the decentralized nature of the Flow Blockchain
- Small percentage fees charged on every lottery created and played on the platform, generating revenue for the project and for the maxi-lottery
- Accessibility to any user with a Flow Blockchain wallet, no additional software or technical knowledge required. The Walletless experience is also possible
The business plan for Flowwery focuses on building a sustainable and scalable decentralized lottery platform on the Flow Blockchain. The platform aims to generate revenue through a small percentage of fees charged on every lottery created and played on the platform. The plan also includes marketing strategies to attract new users and partnerships with other projects on the Flow Blockchain to expand the platform's reach. (i.e. Flowverse π, .find, Flovatar, flowty.io, Niftory, Flowns)
The team behind Flowwery will focus on continuously improving the platform's user experience, security, and transparency to build a loyal user base and ensure the long-term success of the project. Ultimately, the business plan aims to position Flowwery as the leading decentralized lottery platform on the Flow Blockchain and beyond π.
We are also planning to create a Lottery as a Service type of business plan. We will be able to provide the creation for lotteries
This is a Next.js project bootstrapped with create-next-app
.
First, run the development server:
npm install
npm run dev
Open https://localhost:3000 with your browser to see the result.
The smart contract is called LotteryX and it's already on Testnet. We will surf the Mainnet soon ...
Network | Contract Address |
---|---|
Testnet | 0x5f303d043c0b938c |
Mainnet | - |
Install Flow CLI. Follow the instructions
Remember to install the Cadence VS Code Extension for a better development experience. Follow the step here
Open a terminal and run:
flow emulator start
Open a new terminal and run:
flow dev-wallet
Open a new terminal and run:
flow project deploy --network=emulator
flow transactions send src/flow/cadence/transactions/setup_account.cdc
flow transactions send src/flow/cadence/transactions/create_simple_lottery.cdc 1.0 2 1708996932 0.01
flow transactions send src/flow/cadence/transactions/purchase_ticket.cdc 0 f8d6e0586b0a20c7
Now you've a working local enviroment where you can create your lotteries. Let's surf on the testnet with the command:
flow accounts update-contract LotteryX ./src/flow/cadence/contracts/LotteryX.cdc --network=testnet --signer=testnet-account
We are integrating the Walletless login usign the Niftory API.
- use Niftory API for the Walletless onboarding
- receive an NFT when you purchase the ticket (check contracts/lottery_experimental.cdc)
- create a Non Fungible Ticket collection by uploading an image while creating the lottery. The image will be the ticket image and we will use the Niftory API to create the NFT collection
- add an NFT in the prize pool resource
- see on frontend the tickets I've already purchased and total wins (new User page)
- charity addresses picker: when creating the lottery the owner will be able to pick NGO and entities that will receive a percentage of the lottery. There will be shown a logo-list and the values will be the verified NGO's blockchain addresses
- improve the style
- stripe API
- see how many tickets are left in a lottery β
- android apk with Flutter
- iOS app
- PseudoRandomNumberGenerator by justjoolz - the way we select the winner of the lottery
- StoreFrontV2 - official implementation by the Flow team
- Auction by OxAlchemist - Auction Smart Contract
- EmeraldCity and Jacob Tucker - just a legend
- Niftory Sample App - for the Walletless onboarding