LogoLogo
  • General
    • 👋Welcome to Kinto
    • 📔Terminology
    • 📃Litepaper
    • 📄One Pager
    • 🔗Links
    • 🤝Partners and Collaborators
    • ❓FAQ
  • User Guides
    • 🌟Sign Up Walkthrough
    • 🗝️KYC Walkthrough
      • 🔑Synaps Walkthrough
      • 🔑Plaid Walkthrough
    • 📄KYB Walkthrough
    • 🪟Passkeys on Windows Walkthrough
    • Setting up a 1Password Passkey
    • ❔Troubleshooting/Help
    • 💰Kinto Deposits
      • Onramp on Kinto
    • 💸Kinto Withdrawals
      • 🗝️Recover funds from my Passkey address
      • 🎁Wrapping ETH in your Kinto Wallet
      • Offramp on Kinto
    • Swap on Kinto
    • Lending & Borrowing
    • Hyperliquid
      • Fees
      • Deposits
      • Creating Orders
      • Closing an Order
      • Withdrawals
    • Send to other Kinto Wallets
    • Token Sale Participation
    • Full Account Recovery
    • $K Transfer
      • Withdraw $K
      • Send $K on Kinto
      • Deposit $K
      • Swap $K on Kinto
    • Recover Funds from an X Signer
    • $K Lend and Borrow Market
      • Supply USDC to $K Lending Market
      • Withdraw USDC from $K Lending Market
      • Add $K and Borrow USDC
      • Repay USDC and Withdraw $K
  • Security/KYC/AML
    • 🔑Securing Kinto
    • 📃Security One Pager
    • 🔐Security and Risk Management
    • 🛡️Wallet Insurance
    • ⚙️User Owned KYC
    • 🏳️Enabled Countries
    • 🔒Beware of Scams
    • ✅Kinto Validators
    • 🤺Security Council
  • Building on Kinto
    • ℹ️Network Information
    • 🧱Kinto Rollup Architecture
    • ❕Differences with other rollups
    • 🤖Rollup Features
      • ⚙️Create2
      • 🔥Kinto Account Abstraction
      • 🛡️KintoWallet
      • 🪢Musubi - Chain Abstraction
    • 💻Development guide
      • 1️⃣1️⃣ Setup your Deployer EOA
      • 2️⃣2️⃣ Environment setup
      • 3️⃣3️⃣ Creating your Kinto App
    • ⛩️Interacting with your Kinto App
      • 🤖Interacting with contracts
      • 👩‍🏭Create a Web Dapp
    • 📗Smart Contract Reference
      • KintoAppRegistry
      • KintoID
      • KintoWalletFactory
      • Kinto Wallet
      • SponsorPaymaster
      • Kinto EntryPoint
      • KYCViewer
      • Faucet
      • EngenCredits
      • EngenGovernance
    • 🌍Kinto Wallet Web SDK
    • 🏪Running kinto nodes
    • ⚒️Tools
      • ⛈️Node RPC
      • 🏗️Build Tools
      • 🗺️Block Explorer
      • 🐞Debugging and monitoring
      • 🔮Oracle - Pyth
      • Firewall - Venn
    • 🚀ICO Platform
  • Governance
    • 🧠Introduction to the Kinto DAO
    • 📓Kinto Constitution
    • 📃KIP Proposal Template
    • 🌄Engen Proto-Governance
    • ⛩️Kinto Token
      • Information, addresses and links
  • 💧Liquidity Programs
    • 🛠️Mining Program
    • ⚫Engen - Launch Program
    • 🪙K Token Sale
  • Sakura Mining Season
Powered by GitBook
On this page
  • Basics
  • State functions
  • View functions
  • Constants
  1. Building on Kinto
  2. Smart Contract Reference

SponsorPaymaster

PreviousKinto WalletNextKinto EntryPoint

Last updated 9 months ago

Deployment Address

Mainnet:

Interface:


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

function addDepositFor(address account) external payable override

function unlockTokenDeposit() public override

function lockTokenDeposit() public override

function withdrawTokensTo(address target, uint256 amount) external override nonReentrant

function setAppRegistry(address _newRegistry) external override onlyOwner

function setUserOpMaxCost(uint256 _newUserOpMaxCost) external onlyOwner
  1. addDepositFor

Deposits ETH for a specific account, allowing it to be used to pay for gas.

function addDepositFor(address account) external payable override;
Parameter
Type
Explanation

account

address

The account for which to deposit.

  1. unlockTokenDeposit

Unlocks the deposit, enabling it to be withdrawn.

function unlockTokenDeposit() public override;

No parameters.

  1. lockTokenDeposit

Locks the ETH deposited for an account so they can be used to pay for gas.

function lockTokenDeposit() public override;

No parameters.

  1. withdrawTokensTo

Withdraws ETH to a specified target address.

function withdrawTokensTo(address target, uint256 amount) external override nonReentrant;
Parameter
Type
Explanation

target

address

Address to send ETH to.

amount

uint256

Amount of ETH to withdraw.

  1. setAppRegistry

Sets the app registry address. Can only be called by the owner.

function setAppRegistry(address _newRegistry) external override onlyOwner;
Parameter
Type
Explanation

_newRegistry

address

New app registry address.

  1. setUserOpMaxCost

Sets the maximum cost allowed for a user operation. Can only be called by the owner.

function setUserOpMaxCost(uint256 _newUserOpMaxCost) external onlyOwner;
Parameter
Type
Explanation

_newUserOpMaxCost

uint256

New maximum cost for user operations.


View functions

function depositInfo(address account) external view returns (uint256 amount, uint256 _unlockBlock)

function appUserLimit(address wallet, address app) external view override returns (uint256, uint256, uint256, uint256)

function walletFactory() external view override returns (IKintoWalletFactory)

function appRegistry() external view override returns (IKintoAppRegistry)
  1. depositInfo

Returns deposit information for a specific account.

function depositInfo(address account) external view returns (uint256 amount, uint256 _unlockBlock);
Parameter
Type
Explanation

account

address

The account to query deposit info.

  1. appUserLimit

Returns current user limits for an app.

function appUserLimit(address wallet, address app) external view override returns (uint256, uint256, uint256, uint256);
Parameter
Type
Explanation

wallet

address

The wallet address.

app

address

The app contract.

  1. walletFactory

Returns the address of the KintoWalletFactory contract.

function walletFactory() external view override returns (IKintoWalletFactory);

No parameters.

  1. appRegistry

Returns the address of the KintoAppRegistry contract.

function appRegistry() external view override returns (IKintoAppRegistry);

No parameters.


Constants

  • COST_OF_POST: 200,000

  • MAX_COST_OF_VERIFICATION: 530,000

  • MAX_COST_OF_PREVERIFICATION: 2,500,000

  • RATE_LIMIT_PERIOD: 1 minute

  • RATE_LIMIT_THRESHOLD_TOTAL: 50

These constants are used for various limits and calculations within the contract.

📗
0x1842a4EFf3eFd24c50B63c3CF89cECEe245Fc2bd
ISponsorPaymaster.sol