Archived Content from Web3Auth Community
This topic was originally posted by silver on 8/19/2025.
This content has been migrated from our previous community forum to preserve valuable discussions.
Hi,
Getting âInvalid params for jwt login. Missing domainâ when calling enableMFA() and tapping âcontinue with JWTâ.
this.web3authInstance = new Web3Auth(WebBrowser, secureStoreWrapper, { clientId: WEB3AUTH_CLIENT_ID, network: (WEB3AUTH_NETWORK_ENV as any) || WEB3AUTH_NETWORK.SAPPHIRE_DEVNET, redirectUrl: REDIRECT_URL, // matches app.json scheme privateKeyProvider, loginConfig: { jwt: { verifier: WEB3AUTH_VERIFIER, verifierSubIdentifier: WEB3AUTH_SUB_VERIFIER, typeOfLogin: 'jwt', clientId: WEB3AUTH_CLIENT_ID, }, }, useCoreKitKey:true, enableLogging: true, }); await this.web3authInstance.init(); await this.web3authInstance.login({ loginProvider: LOGIN_PROVIDER.JWT, mfaLevel: 'optional', extraLoginOptions: { id_token: userJwtToken, verifierIdField: 'sub', domain: WEB3AUTH_DOMAIN, // <- tried also without this parameter isUserIdCaseSensitive: false }, curve: 'secp256k1', dappShare: 'true',}); await this.web3authInstance.enableMFA()
I also tried with this, but it seems to want to visit the domain for some reason in the WebView (web3auth webview opens the given domain):
// Call login AGAIN even if already logged in, to inject jwt, before calling enableMfa await this.web3authInstance.login({ loginProvider: LOGIN_PROVIDER.JWT, mfaLevel: 'optional' as any, extraLoginOptions: { id_token: idToken, verifierIdField: 'sub', domain: WEB3AUTH_DOMAIN, isUserIdCaseSensitive: false, }, curve: 'secp256k1', dappShare: 'true', })await this.web3authInstance.enableMFA()
I can set up MFA in the login flow (when mfa set to âoptionalâ), but I dont want to have the setup in the login flow, I want to add a button in Settings to âEnable MFAâ.