I am using web3auth modal for a webapp to interface with Ethereum and Arbitrum. Currently the web3 login methods like metmask work fine, but all web2 methods (e.g. email, google) give the following error:
Invalid params, {“code”:1002,“error”:“Client network mismatch, clientId belongs to network: sapphire_mainnet, and app is configured on network: mainnet”,“success”:false}
I am using the following chainConfig for ethereum:
{
chainNamespace: CHAIN_NAMESPACES.EIP155,
chainId: “0x1”, // Ethereum Mainnet
rpcTarget: https://mainnet.infura.io/v3/${infura_api_key}
, // Mainnet RPC
displayName: “Ethereum Mainnet”, // Corrected from Sepolia to Mainnet
blockExplorerUrl: “https://etherscan.io”, // Correct URL for Mainnet
ticker: “ETH”,
tickerName: “Ethereum”,
logo: “https://cryptologos.cc/logos/ethereum-eth-logo.png”,
}
The project is configured for sapphire_mainnet. I do not see any option for ethereum mainnet when creating a project. I think this is because of the migration from ethereum to sapphire, but i am unsure.
Using the following package versions:
"@web3auth/base": "^9.0.2",
"@web3auth/coinbase-adapter": "^9.0.2",
"@web3auth/ethereum-provider": "^9.0.2",
"@web3auth/metamask-adapter": "^8.12.4",
"@web3auth/modal": "^9.1.0",
"@web3auth/wallet-connect-v2-adapter": "^9.1.0",
Does web3auth still support web2 logins to ethereum after the sapphire migration? If so, what can I do to fix this error? Thanks.