You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you connected your dApp through deep linking to a Wallet app you can launch that wallet app with the following:
22
+
You can open the selected chain's block explorer easily:
23
23
24
24
```javascript
25
-
_appKitModal.launchConnectedWallet();
25
+
_appKitModal.launchBlockExplorer();
26
26
```
27
27
28
-
### - Launch block explorer
28
+
### - Reconnect relay
29
29
30
-
You can open the selected chain's block explorer easily:
30
+
In most cases it shouldn't be needed as it is called internally but this method is useful to reconnect the relay when internet connection is back after inactivity.
31
31
32
32
```javascript
33
-
_appKitModal.launchBlockExplorer();
33
+
await_appKitModal.reconnectRelay();
34
+
```
35
+
36
+
### - Load account data such as balance and identity
37
+
38
+
In most cases it shouldn't be needed as it is called internally but this method is useful to reload account data such as balance and identity. Particularly useful after a transaction.
If you add a new chain on an ongoing session you should call `requestSwitchToChain()` so the wallet can add it as well. Otherwise it will just be not usable.
89
+
`requestAddChain()` is called automatically by `requestSwitchToChain()` in case of failing with the proper error from the wallet.
Copy file name to clipboardExpand all lines: appkit/flutter/core/custom-chains.mdx
+5
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,11 @@ This means that if you intend to support just EVM and Solana networks then no fu
10
10
11
11
However, with extra configuration to `ReownAppKitModalNetworks` and `optionalNamespaces` you can connect to whatever other network you'd like.
12
12
13
+
<Note>
14
+
If you are starting from scratch, you can avoid this by using our [CLI tool](https://pub.dev/packages/reown_cli) and passing the chains you want to support as arguments.
15
+
</Note>
16
+
17
+
13
18
For instance, if you want to support also Polkadot blockchain then first add Polkadot to the supported networks list:
Copy file name to clipboardExpand all lines: appkit/flutter/core/email.mdx
+15-16
Original file line number
Diff line number
Diff line change
@@ -21,15 +21,15 @@ Remember to whitelist your dapp's iOS's bundleId and Android's packageName in yo
21
21
3. Add your iOS Bundle ID and your Android Package Name
22
22
</Warning>
23
23
24
-
<Warning>
24
+
<Note>
25
25
Email and Social login are supported only on EVM networks and Solana.
26
-
</Warning>
26
+
</Note>
27
27
28
28
## Integration
29
29
30
30
In order to support Email and Social Wallets creation just set `featuresConfig:` parameter in `ReownAppKitModal` initialization.
31
31
32
-
```javascript {14-23}
32
+
```javascript {14-27}
33
33
final _appKitModal =ReownAppKitModal(
34
34
context: context,
35
35
projectId:'{YOUR_PROJECT_ID}',
@@ -44,26 +44,29 @@ final _appKitModal = ReownAppKitModal(
44
44
),
45
45
),
46
46
featuresConfig:FeaturesConfig(
47
-
email:true,
48
47
socials: [
49
-
AppKitSocialOption.Farcaster,
48
+
AppKitSocialOption.Email,
50
49
AppKitSocialOption.X,
50
+
AppKitSocialOption.Google,
51
51
AppKitSocialOption.Apple,
52
52
AppKitSocialOption.Discord,
53
+
AppKitSocialOption.GitHub,
54
+
AppKitSocialOption.Facebook,
55
+
AppKitSocialOption.Twitch,
56
+
AppKitSocialOption.Telegram,
53
57
],
54
-
showMainWallets:false,
58
+
showMainWallets:false,// OPTIONAL - true by default
55
59
),
56
60
);
57
61
```
58
62
59
63
## Options
60
64
61
-
-**_email `bool`_** : This boolean defines whether you want to enable email login. Default `true`
62
-
-**_socials `List<AppKitSocialOption>`_** : This list contains the list of social platforms that you want to enable for user authentication. The platforms in the example include Farcaster, X, Discord. Is empty by default, it means that no social options is enabled.
63
-
-**showMainWallets `bool`\_** : This boolean defines whether you want to show the main wallet options on the first connect screen. If this is `false` it will show a button that directs you to a new screen displaying all available wallets. Default `true`.
65
+
-**_socials `List<AppKitSocialOption>`_** : This list contains the list of social platforms that you want to enable for user authentication. Is empty by default, it means that no social options is enabled. The buttons in the modal will be shown in the same order you configure the list.
66
+
-**_showMainWallets `bool`_** : This boolean defines whether you want to show the main wallet options on the first connect screen. If this is `false` it will show a button that directs you to a new screen displaying all available wallets. Default `true`.
64
67
65
68
<Info>
66
-
In order for Email Wallet to work properly, either `AppKitModalConnectButton()` or `AppKitModalAccountButton()` has to be instantiated during the whole lifetime of the app.
69
+
In order for Farcaster to work properly, either `AppKitModalConnectButton()` or `AppKitModalAccountButton()` has to be instantiated during the whole lifetime of the app.
67
70
68
71
If you already use them then nothing else has to be done, but in case you don't use them but still want to support Email & Social Wallets you would have to instantiate and hide them as follows:
69
72
@@ -81,10 +84,6 @@ AppKitModalAccountButton(
81
84
82
85
## User Flow
83
86
84
-
1.Users will be able to connect to you application by simply using an email address. AppKit will send to them a OneTime Password (OTP) to copy and paste in the modal, which will help to verify the user's authenticity. This will create a non-custodial wallet for your user which will be available in any application that integrates AppKit and Email Wallets.
87
+
1.Users can connect to your application using either an email address or a social login option. Upon selecting an option, they will be redirected to a secure login page in the device’s default browser. If the Email option is selected, AppKit will first send an approval link to the user's email, followed by a One-Time Password (OTP) to be used in the login flow. This process helps verify the user’s identity. In both cases, whether using Email or Social login, a non-custodial wallet will be created for the user. This wallet will be accessible across any application that integrates AppKit and Email Wallets.
85
88
86
-
2. Eventually the user can optionally choose to move from a non-custodial wallet to a self-custodial one by pressing "Upgrade Wallet" on AppKit. This will open the (Reown secure website) that will walk your user through the upgrading process.
87
-
88
-
<Note>
89
-
Due to Safari’s strict third-party cookie policies, the SDK is not preserving sessions after the app is terminated (removed from memory). So upon app termination the user will have to re-authenticate themselves through a new OTP code if they want to sign. Our team is working to solve this issue soon.
90
-
</Note>
89
+
2. Eventually, users can optionally choose to upgrade from a non-custodial wallet to a self-custodial one by tapping “Upgrade Wallet” in AppKit. This action opens the Reown secure website, which guides the user through the upgrade process.
Copy file name to clipboardExpand all lines: appkit/flutter/core/installation.mdx
+2-4
Original file line number
Diff line number
Diff line change
@@ -9,9 +9,9 @@ Let's get started with the installation and configuration!
9
9
10
10
## Installation
11
11
12
-
<Info>
12
+
<Note>
13
13
If you are just starting a new project, you can use our [CLI tool](https://pub.dev/packages/reown_cli) to get started quickly.
14
-
</Info>
14
+
</Note>
15
15
16
16
1.- Add `reown_appkit` as dependency in your `pubspec.yaml` and run `flutter pub get` (check out the [latest version](https://pub.dev/packages/reown_appkit/install))
17
17
- Or simply run `flutter pub add reown_appkit`
@@ -79,8 +79,6 @@ Example:
79
79
</Tab>
80
80
</Tabs>
81
81
82
-
<hr />
83
-
84
82
### Coinbase Wallet support
85
83
86
84
Coinbase Wallet does not use the WalletConnect protocol for communication between the dApp and the wallet.
// requiredNamespaces: {}, // OPTIONAL - null by default
31
+
// optionalNamespaces: {}, // OPTIONAL - null by default
32
+
// featuredWalletIds: {}, // OPTIONAL - null by default
33
+
// includedWalletIds: {}, // OPTIONAL - null by default
34
+
// excludedWalletIds: {}, // OPTIONAL - null by default
35
+
// customWallets: [ // OPTIONAL - null by default
36
+
// ReownAppKitModalWalletInfo(
37
+
// listing: AppKitModalWalletListing(
38
+
// ...
39
+
// ),
40
+
// ),
41
+
// ],
34
42
);
35
43
```
36
44
@@ -56,7 +64,7 @@ This callback method will be triggered if getting the balance from our blockchai
56
64
57
65
These are the set of namespaces that will be requested to the wallet you are connecting to.
58
66
59
-
These values are optionals and, in most cases, not required since AppKit already defines every required and optional namespace internally based on configured networks.
67
+
These values are optional and, in most cases, not required, as AppKit already defines all required and optional namespaces internally based on the configured networks (EVM and Solana by default).
60
68
61
69
However, if you would want to override that definition with your own or support more networks than just EVM and Solana (i.e. Polkadot, Kadena, etc...) these are the object you should modify. See [Custom Networks](../core/custom-chains). section.
62
70
@@ -96,3 +104,27 @@ final Set<String> excludedWalletIds = {
0 commit comments