getPaymasterAndData
Get paymaster and data details for a user operation.
import { getPaymasterAndData } from "thirdweb/wallets/smart"; const userOp = createUnsignedUserOp(...); const paymasterAndData = await getPaymasterAndData({ userOp, client, chain,});
function getPaymasterAndData(args: { chain: { readonly blockExplorers?: Array<{ apiUrl?: string; name: string; url: string; }>; readonly experimental?: { increaseZeroByteCount?: boolean }; readonly faucets?: Array<string>; readonly icon?: Icon; readonly id: number; readonly name?: string; readonly nativeCurrency?: { decimals?: number; name?: string; symbol?: string; }; readonly rpc: string; readonly testnet?: true; }; entrypointAddress?: string; paymasterOverride?: (
The userOp and options
let args: { chain: { readonly blockExplorers?: Array<{ apiUrl?: string; name: string; url: string; }>; readonly experimental?: { increaseZeroByteCount?: boolean }; readonly faucets?: Array<string>; readonly icon?: Icon; readonly id: number; readonly name?: string; readonly nativeCurrency?: { decimals?: number; name?: string; symbol?: string; }; readonly rpc: string; readonly testnet?: true; }; entrypointAddress?: string; paymasterOverride?: (};
The paymaster and data details for the user operation.