A Solidity smart contract for managing advertisement spots using Superfluid Protocol. The ad spot is taken by the highest bidder who can showcase their NFT, while previous advertisers become members of a distribution pool and receive a share of the new advertiser's flow.
- Bidding system using Superfluid money streams
- NFT showcase functionality for the highest bidder
- Fair distribution pool for previous advertisers
- Built with Superfluid Protocol for real-time finance
- Clone the repository:
git clone https://github.com/superfluid-finance/ad-auction-example
cd ad-auction-example
- Install dependencies:
forge install
Run all tests:
forge test
Run a specific test:
forge test --match-test testFlowCreation
Add verbosity levels for more detailed output:
forge test -vv # Shows logs
forge test -vvv # Shows stack traces
The AdSpot Contract consists of three main components:
- Bidding System: Uses Superfluid's Constant Flow Agreement (CFA) to manage real-time money streams as bids.
- NFT Showcase: Allows the highest bidder to display their NFT.
- Distribution Pool: Manages the fair distribution of new bidder's streams to previous advertisers.
- Deploy the contract with a supported Super Token
- Users can start bidding by creating Superfluid streams
- Highest bidder can set their NFT to showcase
- Previous bidders automatically receive their share of new streams
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
GPL-3.0
- Built with Superfluid Protocol
- Developed using Foundry