Skip to content

Documentation / react-auth / UseFundWalletInterface

Interface: UseFundWalletInterface

Method to fund a user's wallet via Privy's fiat on-ramp integration by inputting a valid wallet address. You can access the fields and methods documented here via the useFundWallet hook.

Properties

fundWallet

fundWallet: (address, fundWalletConfig?) => Promise<void>

Prompt the user to go through the fiat onramp flow and fund the specified wallet.

This will open the modal with a prompt for the user to navigate to a third-party on-ramp provider.

Once the user continues to the on-ramp flow, Privy will display the on-ramp status screen, and wait for the transaction to complete.

Note: Even after a successful funding, funds can take a few minutes to arrive in the user's wallet.

The current supported provider is Moonpay.

Parameters

address: string

typed data payload to be signed

fundWalletConfig?: FundWalletConfig

FundWalletConfig (optional) options to customize the wallet fund modal

Returns

Promise<void>