Skip to content

Randomly selecting winning transactions for the GIVbacks V2 raffle

License

Notifications You must be signed in to change notification settings

Giveth/givbacks-picker

 
 

Repository files navigation

GIVbacksV2 Winners Picker

A Next.js application for selecting and displaying GIVbacksV2 Raffle winners.

Features

  • Randomly fetches 5 winning transacton hashed from the list of eligible donations from a GIVbacks Round
  • Each transaction hash inputted has a proportional proportional chance of winning, determined by its "USDvalueafterGIVbacksfactor" (i.e. the odds of winning are affected by the donation size & the givbacks % of the project donated to)
  • A single donor address can only win once (even if they are associated with multiple transaction hashes)
  • Displays winners in a stylish Twitter-like interface)
  • Allows copying all winners to clipboard
  • Responsive design with loading and error states

Quick Start

  1. Install dependencies:

    npm install
  2. Run the development server:

    npm run dev
  3. Open http://localhost:3000 in your browser.

API

The application expects a /api/raffle endpoint that returns winner data in the following format:

About

Randomly selecting winning transactions for the GIVbacks V2 raffle

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • CSS 50.5%
  • TypeScript 47.4%
  • JavaScript 2.1%