LogoLogo
  • Koi Overview
    • Overview
      • About
      • The Team
      • Resources
  • Protocol
    • Introduction
    • Liquidity Pools
      • Concentrated Liquidity Pools (v3)
      • Stable Pool (v2)
      • Normal Pool (v2)
      • Dynamic Fees
      • Governance
      • Protocol Fees
    • Koi Farming Pools
    • Koi Bonds
    • Limit Orders
    • Swap Widget
    • VWAP Oracles
    • Koi Paymaster Service
    • veRewards
  • Koi DAO
    • veKOI
    • Governor
  • Koi Contracts
    • Contracts
    • ABIs
    • Audits
  • Accessory
    • Locking v3 Positions
  • Project Information
    • Koi Website
    • Roadmap
    • KOI Tokenomics and Contracts
    • Social Media
    • Branding and Logos
    • Known Bugs
Powered by GitBook

2023 mute.io

On this page
  • Integration
  • Supported Tokens

Was this helpful?

  1. Protocol

Koi Paymaster Service

Integrate the Mute Paymaster into your dApp

PreviousVWAP OraclesNextveRewards

Last updated 10 months ago

Was this helpful?

By utilizing , Mute allows for gas to be paid with other tokens instead of ETH.

Instead of paying a transaction fee of $0.40 with ETH, the user can opt in to use any of the supported tokens below. The conversion price is based on the token/ETH LP pool on the Mute Switch.

This is a free to use service.

Integration

You can easily integrate the Mute Paymaster into your dApp -

const PAYMASTER_ADDRESS = '0x4ae2Ba9A5C653038C6d2F5D9F80B28011A454597'
...
// approve the token for spending via the paymaster
... 
const greeting = "a new greeting";
const tx = await greeter.populateTransaction.setGreeting(greeting);
const gasPrice = await sender.provider.getGasPrice();
const gasLimit = await greeter.estimateGas.setGreeting(greeting);

const paymasterParams = utils.getPaymasterParams(testnetPaymaster, {
  type: "ApprovalBased",
  TOKEN_ADDRESS,
  minimalAllowance: ethers.BigNumber.from(1),,
  innerInput: new Uint8Array(),
});

const sentTx = await sender.sendTransaction({
  ...tx,
  maxFeePerGas: gasPrice,
  maxPriorityFeePerGas: BigNumber.from(0),
  gasLimit,
  customData: {
    gasPerPubdata: utils.DEFAULT_GAS_PER_PUBDATA_LIMIT,
    paymasterParams,
  },
});

Supported Tokens

zkSync Era account abstraction paymasters
Official documentation
Official Paymaster Address
USDC
WBTC
MUTE