Crevents is a decentralized event management system compatible with EVM blockchains and is done using Solidity smart contracts.
Table of Contents
Crevents is an open source project demonstrating a usecase of blockchain for organizing and attending events.
Crevents allows event organizers to create and manage events using a decentralized platform.
The system uses a token-based ticketing system that allows event organizers to sell tickets directly to attendees, eliminating the need for intermediaries.
And attendees will get SBT tokens which are like NFTs, but can not be transferred.
- Create and manage events
- Sell tickets directly to attendees
- Set ticket prices and maximum number of participants
- Whitelist registration to restrict event attendance to approved participants (WIP)
- Check-in attendees using the event's smart contract
- Get event ticket with attendee signature (to then use ecRecover for validating event without transaction)
- Verify event QR code using ecRecover to get the address of attendee and check if he exists in participants list or no
- View event information and attendance records
ezgif.com-crop.1.mp4
To install and run the project locally follow the steps
Project is using nx for monorepo management.
Install dependencies
npm install
- Run local hardhat blockchain
npx nx serve smart-contracts
- Deploy smart contract on local hardhat blockchain
npx nx deploy smart-contracts
- Start front end
npx nx serve events-ui
- Run Cloudflare workers [optional]
npx nx run-many --target=serve --projects="image-uploader,metadata-server"
Then you should change tokenUriServer
in Creator.sol
to http://localhost:8989/
for metadata server.
For image uploader you should update UPLOAD_URL
in FileUpload.tsx
to http://localhost:8787/upload
and HOST
variable in packages/image-uploader/wrangler.toml
There are two workers image-uploader
and metadata-server
Image Uploader Worker
This cloudflare worker is used to store event images. It is using R2 buckets to store images and Google Recaptcha v3 to protect againts spam.
Metadata Server Worker
This cloudflare worker is used to dynamically get data for event SBT tokens. Event smart contract is returning this workers URI + chainId + contractId + tokenId astokenUri
so it will look something likehttps://metadata.crevents.xyz/137/0x05242D4AC717Cdf38C36AF290F2b0DA99AA82c67/1
.
This metadata server will call smart contract from corresponding RPC detected from chainId and take event information.
Then it will constructERC721
standard json returning it to client, so wallets like metamask may show the event image for the token.
The json then will be cached inKV
store.
Some RPCs URIs needs to be stored on secrets, checkwrangler.toml
for more information.
Change network on metamask
- If there's no
localhost:8545
network, click add network and manually set address tolocalhost:8545
- Then import accounts you got when running hardhat blockchain to metamask
To Use recaptcha
cd projects/image-uploader
npx wrangler secret put RECAPTCHA_SECRET
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'feat(my feature): add some amazing feature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request to
develop
branch
Distributed under the MIT License. See LICENSE.txt
for more information.
Varik Matevosyan - @D4RK7ET - [email protected]
Project Link: https://github.com/var77/crevents
ETH: 0xB34F830271Bb5aF65E52D72f8E4E8307A16537E1
BTC: bc1qnxegen679nz6e6854xw89tgfgcd94sadz8yrc7