Expand description
Tempo session payment provider with expiring nonces.
Custom implementation that mirrors tempoxyz/walletβs approach: uses
expiring nonces (nonce=0, nonceKey=MAX, validBefore=now+25s) for
channel open transactions instead of fetching sequential nonces via
eth_getTransactionCount. This avoids the chicken-and-egg problem when
the RPC endpoint is itself 402-gated.
StructsΒ§
- Session
Provider - Tempo session provider using expiring nonces.
EnumsΒ§
- Pending
Action π - Tracks uncommitted channel state from the most recent payment.
ConstantsΒ§
- EXPIRING_
NONCE_ πKEY - Expiring nonce key (U256::MAX) β matches the charge flow.
- MAX_
FEE_ πPER_ GAS - Max fee per gas (20 gwei β Tempoβs fixed base fee).
- MAX_
PRIORITY_ πFEE_ PER_ GAS - Max priority fee per gas.
- SESSION_
OPEN_ πGAS_ LIMIT - Default gas limit for session open transactions.
- VALID_
BEFORE_ πSECS - Validity window (in seconds) for expiring nonce transactions.
StaticsΒ§
- GLOBAL_
CHANNELS π - Process-wide channel state registry, keyed by origin URL.
- GLOBAL_
PERSISTED π - Process-wide persisted channel state, shared across ALL origins.
Type AliasesΒ§
- Shared
Channel πState - Shared per-origin in-memory channel state: (channels, key_provisioned).