Wallet Pregeneration
Pre-generated wallets are a key feature of Web3Auth, aimed at simplifying user onboarding. This functionality enables developers to generate both EOA wallet addresses and Smart Accounts (ERC-4337) for users before their first login. By providing this flexibility, you can tailor when and how users are introduced to wallet functionalities, ultimately enhancing their experience and boosting engagement.
Capabilities of Pre-generated Wallets
The ability to pre-generate wallets unlocks diverse use cases, making it seamless to integrate Web3 features into your application's user journey:
- Early Wallet Creation: Create wallets during the user invite or onboarding process, even before their first login, ensuring a smoother start to their Web3 experience.
- Deferred Login Setup: Postpone wallet access management, such as OAuth logins or passkeys, until the user is ready to perform their first on-chain transaction, reducing initial friction.
- Wallet Prefunding: Incentivize users by preloading wallets with token rewards for off-chain activities, enabling them to easily claim these rewards upon accessing their pre-generated wallet.
Access to Wallet Pregeneration is gated. You can use this feature in sapphire_devnet
for free. The
minimum pricing plan to use this feature in a production
environment is the Scale Plan.
Pre-generate EOA Wallets
Web3Auth provides a straightforward API to facilitate the creation of pre-generated EOA wallets. You can integrate this API into your user signup flow, either after a user verifies their email or independently by supplying their email or unique identifier to the API.
This API only returns the Core Kit Key wallet addresses. To use the wallet addresses with the
Web3Auth SDKs, you will need to either use the useCoreKitKey
flag in our PnP SDKs or use any of
our Single Factor Auth SDKs
Learn more about how keys can change within different Web3Auth Products
Implementation Steps
- Identify Users: Determine the unique identifier or email for the user within your system.
This will be the
verifierId
used to create the wallet. - API Call: Use the provided API to submit the user's identifier. You'll need to specify parameters from the Web3Auth dashboard, specifically the Verifier Name, Web3Auth Network, and Client Id.
- Receive Wallet Address: The API response will include the new wallet address, ready for use by the user upon their first login.
HTTP Request
Response
Pre-generate Smart Accounts
Web3Auth provides a straightforward API to facilitate the creation of pre-generated Smart Accounts. You can integrate this API into your user signup flow, either after a user verifies their email or independently by supplying their email or unique identifier to the API.
Implementation Steps
- Identify Users: Determine the unique identifier or email for the user within your system.
This will be the
verifierId
used to create the wallet. - API Call: Use the provided API to submit the user's identifier. You'll need to specify parameters from the Web3Auth dashboard, specifically the Verifier Name, Web3Auth Network, and Client Id.
- Receive Wallet Address: The API response will include the new wallet address, ready for use by the user upon their first login.