Draws & refunds
How the draw works
Rafflor uses publicly verifiable randomness generated after entries have ended.
The randomness used for a raffle is fixed only after the raffle is closed. Once it becomes available, the contract verifies it onchain and selects the winning ticket.
Neither Rafflor nor the creator can replace the randomness or choose the winning ticket.
Anyone can submit the information required to settle the raffle.
For protocol-level details:
Technical randomness details →
How settlement works
A raffle becomes ready for settlement after:
- entries have ended;
- the raffle has been closed;
- the required randomness becomes available.
A raffle that reaches its deadline may therefore briefly remain in a Waiting to be closed state.
Once settled, the winner and claimable amounts are fixed.
An unfilled raffle still draws
A raffle does not need to sell every ticket.
If its deadline passes with unsold tickets, entries stop and the raffle can still be closed and drawn normally.
The winner receives the full advertised prize.
The creator receives proceeds only from tickets that were actually sold.
If a draw cannot be completed
After closing, there is a limited window in which the draw can be completed.
If no valid settlement occurs within the protocol's escape window, the raffle can enter refund mode.
In refund mode:
- ticket buyers can reclaim their ticket payments;
- the creator can reclaim the prize;
- no ticket proceeds are paid to the creator.
The current escape window is read from the deployed randomness resolver.
escape window 7 days
How claiming works
After settlement:
- the winner can claim the prize;
- the creator can claim their ticket proceeds.
Prize and revenue claims are separate.
A problem with one claim does not automatically block the other.
Claim window
Claims remain available for 365 days after settlement.
After that window, unclaimed funds and prizes may be swept to the protocol treasury and are no longer claimable by the winner or creator.
[unavailable] above rather than as a number from memory:
- treasuryAddress — TREASURY_ADDRESS is not configured
- explorer — no block explorer is configured for this chain