SponsorPaymaster
Deployment Address
Mainnet: 0x1842a4EFf3eFd24c50B63c3CF89cECEe245Fc2bd
Interface: ISponsorPaymaster.sol
Basics
An ETH-based paymaster contract for handling ETH deposits.
Ensures that the user pays for transactions with their ETH deposited at the entry point.
Features deposit management functions like adding, locking, unlocking, and withdrawing deposits.
Implements global, per-app, and per-user rate and cost-limiting features to control gas usage and prevent abuse.
Includes view functions to provide information about user limits and deposit statuses.
Integrates with KintoID for KYC verification and KintoAppRegistry for app-specific limits.
State functions
addDepositFor
Deposits ETH for a specific account, allowing it to be used to pay for gas.
account
address
The account for which to deposit.
unlockTokenDeposit
Unlocks the deposit, enabling it to be withdrawn.
No parameters.
lockTokenDeposit
Locks the ETH deposited for an account so they can be used to pay for gas.
No parameters.
withdrawTokensTo
Withdraws ETH to a specified target address.
target
address
Address to send ETH to.
amount
uint256
Amount of ETH to withdraw.
setAppRegistry
Sets the app registry address. Can only be called by the owner.
_newRegistry
address
New app registry address.
setUserOpMaxCost
Sets the maximum cost allowed for a user operation. Can only be called by the owner.
_newUserOpMaxCost
uint256
New maximum cost for user operations.
View functions
depositInfo
Returns deposit information for a specific account.
account
address
The account to query deposit info.
appUserLimit
Returns current user limits for an app.
wallet
address
The wallet address.
app
address
The app contract.
walletFactory
Returns the address of the KintoWalletFactory contract.
No parameters.
appRegistry
Returns the address of the KintoAppRegistry contract.
No parameters.
Constants
COST_OF_POST
: 200,000MAX_COST_OF_VERIFICATION
: 530,000MAX_COST_OF_PREVERIFICATION
: 2,500,000RATE_LIMIT_PERIOD
: 1 minuteRATE_LIMIT_THRESHOLD_TOTAL
: 50
These constants are used for various limits and calculations within the contract.
Last updated