Skip to main content

Paymaster SDK

ERC-4337 gas sponsorship — sponsor transactions, estimate fees, check rates

Operations

Generated Reference

Overview

ERC-4337 gas sponsorship — sponsor transactions, estimate fees, check rates

Available Operations

lucidSponsorUserOp

Sponsor an ERC-4337 UserOperation by paying the gas cost in LUCID tokens. The paymaster signs the UserOp and deducts LUCID from the sender’s balance at the current exchange rate.

Example Usage

Standalone function

The standalone function version of this method:

Parameters

Response

Promise<models.SuccessResponse>

Errors

lucidGetPaymasterRate

Retrieve the current LUCID-per-ETH exchange rate used for gas sponsoring on a specific EVM chain. The rate determines how much LUCID is charged per gas unit.

Example Usage

Standalone function

The standalone function version of this method:

Parameters

Response

Promise<models.PaymasterRateResponse>

Errors

lucidEstimateGasLucid

Estimate the LUCID token cost for a UserOperation before submitting it. Returns the estimated gas in ETH and the equivalent LUCID amount at the current exchange rate.

Example Usage

Standalone function

The standalone function version of this method:

Parameters

Response

Promise<models.SuccessResponse>

Errors