Skip to content

Raffle mode #20

@prusnak

Description

@prusnak

There is a lnurld project that primarily functions as a basic lnurlp server, but it has a unique Raffle feature that caught my eye.

Here's how it works.

  1. The admin activates 'raffle mode' for a specific lnurlp account.
  2. Once activated, every time someone makes a payment using this lnurlp, they receive a success message like "Ticket ABCDEF." Here, 'ABCDEF' is an alphanumeric string derived from the preimage of the payment.
  3. The admin can access the raffle screen to:
  • Select winners at random by clicking the 'DRAW' button. Each time it's pressed, the 'ABCDEF' token and the corresponding payment preimage are displayed. This is usually shown on big screen so everyone in the room can see it. We show the preimage because some LN wallets might not display success messages in their transaction history/details, but many do show the preimage.
  • After the raffle concludes, admin can clear the database of all issued tickets. This is useful so admin can start a new raffle the other day.

We have a blast with this Raffle at our meetups, and it'd be awesome to see it integrated into LNbits!

P.S.: If you feel this might be beyond the scope of the lnurlp extension, please let me know. But considering a separate raffle extension would likely duplicate about 80% of what lnurlp already accomplishes, I thought it could be a good fit to add it directly to this one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions