The messages used by Weenit are as follows:

EIP-712 Domain

To optimize transaction costs, messages are not stored on the EVM but hashes of these messages are stored. The protocol uses the EIP-712 definition for structuring messages and hashing its data (see EIP-712). The EIP-712 domain follows the Deelit protocol schema: see EIP712Domain.

Lottery

Lottery.sol
struct Lottery {
    address from_address;
    bytes32 product_hash;
    uint256 nb_tickets;
    uint256 ticket_price;
    address token_address;
    LibFee.Fee fee;
    LibFee.Fee protocol_fee;
    uint256 expiration_time;
}
from_address
address
The address of the lottery creator.
product_hash
bytes32
The hash of the product related to the lottery. see Product.
nb_tickets
uint256
The number of tickets available for the lottery.
ticket_price
uint256
The price of a ticket.
token_address
address
The address of the token used for the lottery.
fee
LibFee.Fee
The fee of the lottery. see Fee.
protocol_fee
LibFee.Fee
The fee of the protocol. see Fee.
expiration_time
uint256
The expiration timestamp of the lottery.

Fee

Fee.sol
    struct Fee {
        address recipient;
        uint48 amount_bp;
    }
recipient
address
The address of the fee recipient.
amount_bp
uint48
The percentage of the payment to be paid as fee by the payer. (eg. 1000 = 10%)

Transaction

Transaction.sol
struct Transaction {
  Offer offer;
  Payment payment;
}
offer
Offer
The offer associated with the transaction. see Offer.
payment
Payment
The payment associated with the transaction. see Payment.