A decentralized event ticketing platform that leverages blockchain technology to issue NFT-based tickets, ensuring transparency, security, and ownership.
This project is currently a work in progress. Features and functionality may change as development continues.
- Next.js β For building the UI and handling server-side rendering.
- Tailwind CSS β For styling the application.
- Ethers.js β For interacting with the Ethereum blockchain.
- Wagmi β Simplifies Ethereum wallet integration.
- Smart Contracts β Written in Solidity for ticket issuance and transactions.
- Hardhat β For smart contract development, deployment, and testing.
- OpenZeppelin β Secure contract development library.
- Pinata IPFS β For storing event metadata (name, description, image, etc.).
- The Graph β For querying blockchain data efficiently.
- Ethereum / Sepolia Testnet β Smart contracts deployed on Ethereum for scalability and security.
- MetaMask β For users to connect their wallets and manage NFT tickets.
- NFT-Based Tickets β Each ticket is minted as an NFT, ensuring ownership and uniqueness.
- Event Creation β Organizers can create events, set ticket prices, and ticket supply.
- Ticket Purchase β Users can buy tickets using ETH, and NFTs are transferred to their wallets.
- Resale Marketplace β Users can resell tickets in a decentralized manner.
- Ticket Verification β Organizers can verify ticket ownership at event entry.
- EventFactory: Manages event creation, cancellation, and tracking.
- TicketNFT: Mints and manages NFT tickets tied to events.
- TicketSale: Handles ticket purchases and refunds, integrating with EventFactory and TicketNFT.
- TicketVerification: Verifies ownership of NFT tickets.
- TicketMarketplace: Allows secondary market trading of NFT tickets.
git clone https://github.com/gazamba/nft-ticketing-dapp.git
cd nft-ticketing-dappcd frontend
npm install # or yarn installcd backend
npm install # or yarn installCreate a .env file inside backend/ and frontend/ with the following variables:
INFURA_RPC_URL=https://sepolia.infura.io/v3/YOUR_INFURA_API_KEY
INFURA_PRIVATE_KEY=YOUR_WALLET_PRIVATE_KEY
ETHERSCAN_API_KEY=YOUR_ETHERSCAN_API_KEY
PINATA_PUBLIC_GATEWAY_URL=<Pinata-gateway>
PINATA_JWT_TOKEN=<JWT-FROM-Pinata>
INFURA_RPC_URL=https://sepolia.infura.io/v3/YOUR_INFURA_API_KEY
cd backend
npx hardhat compile
Local blockchain with hardhat node
npx hardhat ignition deploy ignition/modules/<contract-module>.ts --network localhost
cd frontend
npm run dev # or yarn devThe application will be available at: http://localhost:3000
To run unit tests for your smart contracts:
cd backend
npx hardhat testOnce tested, deploy the smart contracts on Ethereum Sepolia:
npx hardhat ignition deploy ./ignition/modules/FullDeployment.ts --network sepolia- Use OpenZeppelin libraries to prevent vulnerabilities.
- Audit contracts before deploying
- Keep private keys secure and never expose them in code.
This project is licensed under the MIT License.
Pull requests are welcome!