Import
Usage
Properties
initiateCreditCardCheckout
(settings: CreditCardCheckoutSettings) => void
Opens the Credit Card Checkout modal with the specified parameters.
Parameters:
The settings object can include the following properties:
| Parameter | Type | Description |
|---|---|---|
chainId | number | The blockchain network ID |
contractAddress | string | The address of the contract to interact with |
recipientAddress | string | The address to receive the purchased item |
currencyQuantity | string | The quantity of currency to use for payment |
currencySymbol | string | The symbol of the currency (e.g., ‘USDC’) |
currencyAddress | string | The address of the currency token contract |
currencyDecimals | string | The number of decimals for the currency |
nftId | string | The ID of the NFT being purchased |
nftAddress | string | The address of the NFT contract |
nftQuantity | string | The quantity of NFTs to purchase |
approvedSpenderAddress | string | The address allowed to spend tokens |
calldata | string | The encoded function call data for the transaction |
onSuccess | (txHash: string) => void | Callback when transaction succeeds |
closeCreditCardCheckout
() => void
Closes the Credit Card Checkout modal.
settings
CreditCardCheckoutSettings | undefined
The current settings configuration for the Credit Card Checkout modal.