@privy-io/expo
and on the web through @privy-io/react-auth
.
This guide will walk you through setting up Privy’s funding flows, allowing your users to fund their wallets quickly and easily in under two minutes.
@privy-io/react-auth
fundWallet
Parameter | Type | Description |
---|---|---|
chain | Chain | Optional. A viem/chains object for the network on which users should fund their accounts. Defaults to the network you configured in the Privy Dashboard. |
asset | 'native-currency' | 'USDC' | {erc20: string} | Optional. The asset you’d like the user to fund their accounts with. Set 'native-currency' to fund with the chain ’s native currency (e.g. ETH), 'USDC' to fund with USDC, or a token address in the erc20 field to fund with an arbitrary ERC20. Defaults to 'native-currency' . |
amount | string | Required if asset is set, optional otherwise. The amount of the asset to fund as a decimal string. Defaults to the amount you configured in the Privy Dashboard. |
@privy-io/expo
Parameter | Type | Description |
---|---|---|
address | string | The destination address to fund. |
chain | Chain | Optional. A viem/chains object for the network on which users should fund their accounts. Defaults to the network you configured in the Privy Dashboard. |
asset | 'native-currency' | 'USDC' | {erc20: string} | Optional. The asset you’d like the user to fund their accounts with. Set 'native-currency' to fund with the chain ’s native currency (e.g. ETH), 'USDC' to fund with USDC, or a token address in the erc20 field to fund with an arbitrary ERC20. Defaults to 'native-currency' . |
amount | string | Required if asset is set, optional otherwise. The amount of the asset to fund as a decimal string. Defaults to the amount you configured in the Privy Dashboard. |