Skip to content

Commit 721929c

Browse files
Merge branch 'master' into scw-lookup
2 parents 9d2233f + ca95444 commit 721929c

File tree

6 files changed

+72
-25
lines changed

6 files changed

+72
-25
lines changed

docs/features/account-dashboard.mdx

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,26 @@ description: "Account Dashboard | Documentation - Web3Auth"
55

66
# Account Dashboard
77

8-
Web3Auth's Account Dashboard provides a unified platform for users to manage their Multi-Factor
9-
Authentication (MFA) and account security with ease. This document provides an overview of its
10-
features and how to integrate it seamlessly into your application.
8+
Web3Auth's [Account Dashboard](https://account.web3auth.io) provides a unified platform for users to
9+
manage their Multi-Factor Authentication (MFA) and account security with ease. This document
10+
provides an overview of its features and how to integrate it seamlessly into your application.
11+
12+
Try now: [https://account.web3auth.io](https://account.web3auth.io)
13+
14+
:::tip
15+
16+
To implement the Account Dashboard in your custom verifier-based dApp, please refer to the
17+
[Manage MFA for No Modal SDK](/sdk/pnp/web/no-modal/usage#manage-multi-factor-authentication-mfa)
18+
and [Manage MFA for Modal SDK](/sdk/pnp/web/modal/usage#manage-multi-factor-authentication-mfa)
19+
sections.
20+
21+
:::
1122

1223
![Unified Recovery Management Screenshot](/images/account-dashboard/unified-recovery-management.jpg)
1324

1425
### 1. Unified Recovery Management
1526

16-
The Account Dashboard allows users to:
27+
The [Account Dashboard](https://account.web3auth.io) allows users to:
1728

1829
- Set up recovery factors such as Password, Social Recovery, Authenticator App, and Recovery Phrase.
1930
- Manage and modify existing recovery factors.

docs/sdk/mpc-core-kit/mpc-core-kit-js/authentication/login-jwt.mdx

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ login function.
3737
| `additionalParams?` | Any additional parameter (key-value pair) you'd like to pass to the login function. |
3838
| `importTssKey?` | Key to import key into TSS during first time login. For secp256k1 curve, you need to pass the private key, and for ed25519 curve you need to pass the seed. The ed25519 seed is hashed to generate 64 bytes, where first 32 bytes are used to generate the public key, and last 32 bytes are used as private key. |
3939
| `prefetchTssPublicKeys?` | Defines the number of TSS public keys to prefetch.The SDK by default starts with 2/2 flow, and this parameter should be used in the flow where you want to generate the recovery factor during first time login. The parameters helps you to reduce the operation time by pre-fetching the TSS public key and use it during generating new shares. For existing user you can set it to `0`. Default is `1`, maximum is `3` |
40-
| `registerExistingSFAKey?` | Allows to import the Single Factor Auth(SFA) Key into the MPC Core Kit SDK. Default value is `false`. Please note: <ul><li>Once SFA Key is imported, users won't be able to access their account using the SFA SDK.</li><li>SFA import can only be done for the Web3Auth SFA v2 users, and doesn't work for old(v1) users of SFA.</li></ul> |
40+
| `registerExistingSFAKey?` | Allows to import the [Single Factor Auth(SFA) SDK](/docs/sdk/sfa/sfa-js/) key into the MPC Core Kit SDK. Default value is `false`. Please note, once SFA Key is imported, users won't be able to access their account using the SFA SDK. |
4141

4242
</TabItem>
4343
<TabItem value="type">
@@ -167,8 +167,8 @@ await coreKitInstance.loginWithJWT(jwtLoginParams);
167167

168168
## Importing an existing Single Factor Auth(SFA) Key.
169169

170-
When logging in for the first time, you can import an existing SFA key using the
171-
`registerExistingSFAKey` parameter. By default, the value of this parameter is `false`.
170+
When logging in for the first time, you can import an existing [SFA SDK](/docs/sdk/sfa/sfa-js/) key
171+
using the `registerExistingSFAKey` parameter. By default, the value of this parameter is `false`.
172172

173173
Additionally, this parameter allows you to leverage the
174174
[wallet pregeneration API](/docs/features/wallet-pregeneration) to pre-generate a wallet address.
@@ -180,12 +180,8 @@ SDK/ Wallet Pregeneration API and MPC Core Kit SDK.
180180

181181
:::info
182182

183-
Please keep the following points in mind when using this feature:
184-
185-
1. Once the SFA Key is imported, users will no longer be able to access their account through the
186-
SFA SDK.
187-
2. SFA import is available exclusively for Web3Auth SFA v2 users and is not compatible with older
188-
users (v1) of SFA.
183+
Please note, once the SFA Key is imported, users will no longer be able to access their account
184+
through the SFA SDK.
189185

190186
:::
191187

docs/sdk/mpc-core-kit/mpc-core-kit-js/authentication/login-oauth.mdx

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@ genetate the same account across both authentication method, you need to use an
3636
The `OAuthLoginParams` has two additional properties which can be used to customize the login flow.
3737
Please check the table below for more details.
3838

39-
| Parameter | Description |
40-
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
41-
| `importTssKey?` | The TSS key to import an existing account. |
42-
| `registerExistingSFAKey?` | Allows to import the Single Factor Auth(SFA) Key into the MPC Core Kit SDK. Default value is `false`. Please note: <ul><li>Once SFA Key is imported, users won't be able to access their account using the SFA SDK.</li><li>SFA import can only be done for the Web3Auth SFA v2 users, and doesn't work for old(v1) users of SFA.</li></ul> |
39+
| Parameter | Description |
40+
| ------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
41+
| `importTssKey?` | The TSS key to import an existing account. |
42+
| `registerExistingSFAKey?` | Allows to import the [Single Factor Auth(SFA) SDK](/docs/sdk/sfa/sfa-js/) key into the MPC Core Kit SDK. Default value is `false`. Please note, once SFA Key is imported, users won't be able to access their account using the SFA SDK. |
4343

4444
### SubVerifierDetailsParams
4545

@@ -220,8 +220,8 @@ await coreKitInstance.loginWithOAuth(verifierConfig);
220220

221221
## Importing an existing Single Factor Auth(SFA) Key.
222222

223-
When logging in for the first time, you can import an existing SFA key using the
224-
`registerExistingSFAKey` parameter. By default, the value of this parameter is `false`.
223+
When logging in for the first time, you can import an existing [SFA SDK](/docs/sdk/sfa/sfa-js/) key
224+
using the `registerExistingSFAKey` parameter. By default, the value of this parameter is `false`.
225225

226226
Additionally, this parameter allows you to leverage the
227227
[wallet pregeneration API](/docs/features/wallet-pregeneration) to pre-generate a wallet address.
@@ -233,12 +233,8 @@ SDK/ Wallet Pregeneration API and MPC Core Kit SDK.
233233

234234
:::info
235235

236-
Please keep the following points in mind when using this feature:
237-
238-
1. Once the SFA Key is imported, users will no longer be able to access their account through the
239-
SFA SDK.
240-
2. SFA import is available exclusively for Web3Auth SFA v2 users and is not compatible with older
241-
users (v1) of SFA.
236+
Please note, once the SFA Key is imported, users will no longer be able to access their account
237+
through the SFA SDK.
242238

243239
:::
244240

docs/sdk/pnp/web/modal/usage.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import ConnectBlockchain from "@site/src/common/sdk/pnp/web/_connect-blockchain.
1111
import GetIdTokenInfo from "@site/src/common/sdk/pnp/web/_get-idtoken-info.mdx";
1212
import GetUserInfo from "@site/src/common/sdk/pnp/web/_get-user-info.mdx";
1313
import EnableMFA from "@site/src/common/sdk/pnp/web/_enable-mfa.mdx";
14+
import ManageMFA from "@site/src/common/sdk/pnp/web/_manage-mfa.mdx";
1415
import LogOut from "@site/src/common/sdk/pnp/web/_logout.mdx";
1516
import SwitchChain from "@site/src/common/sdk/pnp/web/_switch-chain.mdx";
1617
import Status from "@site/src/common/sdk/pnp/web/_status-method.mdx";
@@ -28,6 +29,7 @@ following functions:
2829
- `connect()` - Showing the Modal and Logging in the User
2930
- `getUserInfo()` - Getting the User's Information
3031
- `enableMFA()` - Enable Multi Factor Authentication for the user
32+
- `manageMFA()` - Redirect the user to manage their MFA settings in the Web3Auth Account Dashboard
3133
- `authenticateUser()` - Getting the idToken from Web3Auth
3234
- `addChain()` - Add chain config details to the connected adapter.
3335
- `switchChain()` - Switch chain as per chainId already added to chain config.
@@ -100,6 +102,10 @@ Read more about connecting your users with the selected blockchain in the
100102

101103
<EnableMFA />
102104

105+
## Manage Multi Factor Authentication (MFA)
106+
107+
<ManageMFA />
108+
103109
## Get idToken for Backend Verification
104110

105111
<GetIdTokenInfo />

docs/sdk/pnp/web/no-modal/usage.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import Provider from "@site/src/common/sdk/pnp/web/_provider-method.mdx";
1313
import ConnectedAdapterName from "@site/src/common/sdk/pnp/web/_connected-adapter-name-method.mdx";
1414
import Connected from "@site/src/common/sdk/pnp/web/_connected-method.mdx";
1515
import EnableMFA from "@site/src/common/sdk/pnp/web/_enable-mfa.mdx";
16+
import ManageMFA from "@site/src/common/sdk/pnp/web/_manage-mfa.mdx";
1617
import ExtraLoginOptions from "@site/src/common/sdk/pnp/web/_extra-login-options.mdx";
1718
import GetIdTokenInfo from "@site/src/common/sdk/pnp/web/_get-idtoken-info.mdx";
1819
import GetUserInfo from "@site/src/common/sdk/pnp/web/_get-user-info.mdx";
@@ -33,6 +34,7 @@ the following functions:
3334
- `connectTo()` - Logging in the User with the given Wallet Adapter and respective Login Parameters.
3435
- `getUserInfo()` - Getting the User's Information.
3536
- `enableMFA()` - Enable Multi Factor Authentication for the user.
37+
- `manageMFA()` - Redirect users to the Web3Auth Account Dashboard to manage their MFA settings.
3638
- `authenticateUser()` - Getting the idToken from Web3Auth.
3739
- `addChain()` - Add chain config details to the connected adapter.
3840
- `switchChain()` - Switch chain as per chainId already added to the chain config.
@@ -144,6 +146,10 @@ options.
144146

145147
<EnableMFA />
146148

149+
## Manage Multi Factor Authentication (MFA)
150+
151+
<ManageMFA />
152+
147153
## Get idToken
148154

149155
<GetIdTokenInfo />
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
import TabItem from "@theme/TabItem";
2+
import Tabs from "@theme/Tabs";
3+
4+
#### `manageMFA()`
5+
6+
You can redirect users to the Web3Auth Account Dashboard to manage their MFA settings by calling the
7+
`manageMFA()` function. This method ensures that identity details are injected into the dashboard
8+
internally for custom verifier-based dApps. In order to see what's present on the account dashboard,
9+
please refer to the [Account Dashboard](/features/account-dashboard).
10+
11+
```javascript
12+
await web3auth.manageMFA();
13+
```
14+
15+
#### Interface
16+
17+
```typescript
18+
manageMFA<T>(loginParams?: T): Promise<void>;
19+
```
20+
21+
- **`loginParams`** (optional): Optional parameters to include during the MFA management process.
22+
- **Returns**: A `Promise<void>` indicating successful redirection to the Account Dashboard.
23+
24+
:::tip
25+
26+
If MFA is not already enabled, the `manageMFA()` method will throw an error. Ensure you use
27+
`enableMFA()` before calling `manageMFA()`.
28+
29+
If your dApp uses default verifiers, users can directly log in to the Account Dashboard to manage
30+
MFA. For custom verifier-based dApps, the `manageMFA()` method must be used.
31+
32+
:::

0 commit comments

Comments
 (0)