NexusEventGate
NexusEventGate Contract Address: 0x996eFcF698c4a15C7CA48b55d280D0849C658Da2
About
The NexusEventGate contract is a core part of the ChilizNexus platform, designed to manage events, event ticketing, and token distribution using blockchain technology. It allows sports clubs and event organizers to create, manage, and register events in a decentralized, transparent manner while offering fans a unique and engaging experience. Here's a detailed explanation of the contract's purpose and features:
Key Features:
Event Registration and Management:
NexusEventGate enables the creation of multiple event types (LIVE, VIRTUAL, and COMMUNITY events), allowing clubs and event managers to register events with various access levels, ticket limits, and prices.
The contract supports dynamic event management where event organizers can specify different tiers of access (e.g., VIP, Event Manager, Viewer), each associated with specific privileges, prices, and availability.
Soulbound Tickets (ERC1155 with SBTs):
Tickets are Soulbound Tokens (SBTs), meaning they cannot be transferred once issued, ensuring that the ticket ownership and event participation are bound to a specific individual. These tickets are represented as ERC1155 tokens.
Fans can mint tickets for events, with each ticket represented by a unique token ID. The tickets are linked to an event's specific access level (e.g., VIP or regular viewer) and have associated prices and limits.
Token Drop Mechanism:
NexusEventGate features a token drop mechanism, where funds can be collected for an event and distributed among participants (ticket holders). Event organizers can deposit native tokens (Ether) into the contract, which are later distributed equally to fans holding event tickets, providing an incentive for participation.
Event Types and Access Levels:
The contract allows different event types (LIVE, COMMUNITY), and each event can have various access levels with unique token IDs, prices, and limits. This gives organizers the flexibility to offer different experiences based on ticket type, such as VIP access or general admission.
Event End Timestamps and Withdrawals:
Every event has an end timestamp, ensuring that ticket minting and event-related activities stop after a certain period. Event managers can also withdraw the collected funds from ticket sales after the event has ended.
Role of Event Managers:
Event Managers are assigned roles within each event, and they hold specific permissions, such as the ability to mint tickets and manage the event. They also have the ability to withdraw collected amounts for their events.
Event managers are issued a unique token (managed through token IDs) that identifies them as the official event manager for a particular event.
Fan Token Integration:
The contract integrates with fan tokens on the Chiliz blockchain. Before registering or participating in an event, it checks whether the user holds the required fan tokens, ensuring only genuine club fans can participate in exclusive events.
This integration strengthens the club's connection with fans and incentivizes holding fan tokens.
Transparency and Security:
All activities, such as event creation, ticket minting, and token drop distribution, are fully recorded on the blockchain, ensuring transparency and security. The use of Soulbound Tokens (SBTs) prevents ticket reselling or misuse, ensuring fair participation.
The contract uses OpenZeppelin's ReentrancyGuard to prevent reentrancy attacks, further enhancing security.
How It Works:
Event Registration: Event managers can register events (LIVE or COMMUNITY) by providing an event ID, fan token address, access levels, ticket prices, and limits. Once registered, tickets can be minted by the fans or by event managers themselves.
Minting Tickets: Fans can mint their tickets by paying the appropriate price. For COMMUNITY events, tickets may be free, allowing broader participation.
Token Drop: Organizers or anyone else can contribute to an event's Nexus drop. These funds are distributed among participants holding tickets after the event.
Withdrawal of Funds: After the event concludes, the event manager can withdraw the collected ticket sales and token drops for that specific event.
Benefits for Fans and Clubs:
Fans can engage with their favorite clubs by participating in exclusive events and receiving rewards via token drops. The platform ensures that fans have an on-chain proof of attendance and participation.
Clubs and Event Managers benefit from a decentralized, transparent system that ensures only genuine fans can attend events. The platform supports seamless ticketing, event management, and fan engagement while ensuring security and transparency through blockchain.
In conclusion, NexusEventGate serves as the backbone of the ChilizNexus ecosystem, facilitating secure and transparent fan engagement through event ticketing, token distribution, and event management, all while leveraging blockchain technology to create a unique and verifiable fan experience.
Contract Details on Chiliz
State Update Functions:
setBaseURI(string memory newuri): Updates the base URI for token metadata, only callable by the contract owner.
nexusDrop(uint64 eventId): Adds native tokens to the Nexus drop for a specific event.
distributeDrop(uint64 eventId, address[] calldata userAddresses): Distributes the collected Nexus drop amount equally among event participants.
registerLiveEvent(uint64 eventId, address fanTokenAddress, address to, uint64 endTimestamp, string[] calldata accessLevels, uint256[] calldata ticketPrices, uint8[] calldata ticketLimits): Registers a live event with multiple access levels and ticket prices.
registerCommunityEvent(uint64 eventId, address fanTokenAddress, address to, uint64 endTimestamp, uint8 ticketLimit): Registers a community event with a single ticket limit.
mintLiveTicket(uint64 eventId, uint256 tokenId, address to): Mints a live event ticket for a user, ensuring the correct ticket price is paid.
mintCommunityTicket(uint64 eventId, uint256 tokenId, address to): Mints a community event ticket for a user (free ticket).
mintLiveTicketByEventManager(uint64 eventId, uint256 tokenId, address to): Allows the event manager to mint live event tickets for specific users.
registerNewAccessLevel(uint64 eventId, string calldata newAccessLevel, uint256 newTicketPrice, uint8 newTicketLimit): Registers a new access level for an event with its associated ticket price and limit.
withdrawCollectedAmountForEventId(uint64 eventId): Allows the event manager to withdraw the collected ticket sales for an event.
updateNexusTokenContractAddress(address newNexusTokenAddress): Updates the Nexus Token contract address.
Helper Functions:
generateTokenId(uint64 eventId, string memory accessLevel): Generates a unique token ID based on the event ID and access level.
validateMint(address to, uint256 tokenId, uint64 eventId): Validates the conditions for minting a ticket for an event.
getTokenIdOfAnEventManager(uint64 eventId): Retrieves the token ID of the event manager for a specific event.
getTokenIdOfAccessLevel(uint64 eventId, string calldata accessLevel): Retrieves the token ID associated with a specific access level for an event.
isSupportedFanToken(address fanTokenAddress): Checks whether a fan token is supported by the Nexus platform.
checkUserOwnFanTokens(address fanTokenAddress, address userAddress): Verifies whether a user owns the necessary fan tokens to participate.
checkIfCallerIsEventManager(uint64 eventId, address callerAddress): Checks if the caller is the event manager of a specific event.
checkTokenIdExistsForEventId(uint64 eventId, uint256 tokenId): Verifies whether a token ID exists for a specific event.
checkAccessLevelExists(uint64 eventId, string calldata accessLevel): Checks if a particular access level exists for an event.
Getter Functions:
getNexusTokenAddress(): Retrieves the current Nexus Token contract address.
getCollectedAmountForNexusDrop(uint64 eventId): Gets the total amount collected for the Nexus drop for a specific event.
getTokenIdsFromEventId(uint64 eventId): Retrieves all token IDs for a particular event.
getAccessLevelsFromEventId(uint64 eventId): Retrieves all access levels for a particular event.
getTicketPriceFromTokenId(uint256 tokenId): Gets the ticket price for a specific token ID.
getTicketPricesFromEventId(uint64 eventId): Retrieves ticket prices for all token IDs of a specific event.
getCollectedAmountForEventId(uint64 eventId): Retrieves the collected ticket sales amount for an event.
getEventEndTimestamp(uint64 eventId): Gets the end timestamp for a specific event.
getTicketLimit(uint256 tokenId): Retrieves the ticket limit for a specific token ID.
Overrides:
uri(uint256 tokenId): Retrieves the URI for a specific token ID, including metadata.
safeTransferFrom(address, address, uint256, uint256, bytes memory): Prevents transfers of Soulbound tickets (SBTs).
safeBatchTransferFrom(address, address, uint256[] memory, uint256[] memory, bytes memory): Prevents batch transfers of Soulbound tickets (SBTs).
This contract enables transparent and efficient management of live and community events, ticket distribution, and token drops, enhancing fan engagement on the ChilizNexus platform.
Last updated