|
1 | | -import { Callout} from "@doc"; |
| 1 | +import { Callout } from "@doc"; |
| 2 | +import { createMetadata, ArticleIconCard } from "@doc"; |
2 | 3 |
|
3 | | -# Pregenerate User Wallets |
| 4 | +export const metadata = createMetadata({ |
| 5 | + image: { |
| 6 | + title: "Pregenerate Wallets", |
| 7 | + icon: "wallets", |
| 8 | + }, |
| 9 | + title: "Pregenerate Wallets | thirdweb", |
| 10 | + description: "Learn how to pregenerate wallets for improved user onboarding", |
| 11 | +}); |
| 12 | + |
| 13 | +# Pregenerate Wallets |
| 14 | + |
| 15 | +## What is Wallet Pregeneration? |
| 16 | + |
| 17 | +Wallet pregeneration is a technique where you create wallets for users before they actually sign up or authenticate. This allows you to: |
| 18 | + |
| 19 | +1. Pre assign wallets to users before they sign up |
| 20 | +2. Reduce the time users spend waiting during the onboarding process |
| 21 | +3. Pre-fund wallets with tokens or NFTs before users claim them |
| 22 | +4. Create smoother user experiences for gaming and other applications |
| 23 | + |
| 24 | +## Why Use Wallet Pregeneration? |
| 25 | + |
| 26 | +### Pre-funding Capability |
| 27 | +You can distribute assets to wallets before users claim them, enabling: |
| 28 | +- Pre-loaded game assets |
| 29 | +- Welcome bonus tokens |
| 30 | +- Promotional NFTs |
| 31 | +- Airdrops |
| 32 | + |
| 33 | +### Better User Experience |
| 34 | +- Users don't have to wait for wallet to be created during signup |
| 35 | +- Reduced failed wallet creation due to network issues |
4 | 36 |
|
5 | 37 | To pregenerate an in-app or ecosystem wallet wallet, you can make a `POST` request to the following endpoint: |
6 | 38 |
|
7 | 39 | ``` |
8 | 40 | https://in-app-wallet.thirdweb.com/api/v1/pregenerate |
9 | 41 | ``` |
10 | 42 |
|
11 | | -This allows you to safely create wallet addresses for your users before they login to your app. |
12 | | - |
13 | 43 | ## Request Body |
14 | 44 |
|
15 | 45 | The request body should be a JSON object with the following parameters: |
@@ -84,3 +114,12 @@ A successful API call returns a JSON object in the following format: |
84 | 114 | } |
85 | 115 | } |
86 | 116 | ``` |
| 117 | + |
| 118 | + |
| 119 | +## What's Next |
| 120 | + |
| 121 | +Pre-generating is independent and doesn't change the user's experience. |
| 122 | + |
| 123 | +Your users can continue to login as per usual. When they do, they will be assigned the pregenerated wallet. |
| 124 | + |
| 125 | +For more information on signing in, see [Sign In](/connect/wallet/sign-in-methods/overview). |
0 commit comments