We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I just want to know how to switch the network in MetaMask mobile using code
The text was updated successfully, but these errors were encountered:
You can try "wallet_switchEthereumChain" or "wallet_addEthereumChain"
Sorry, something went wrong.
Can you please Give me any example how can i use this?
await connector.sendCustomRequest( method: 'wallet_switchEthereumChain', params: [ {'chainId': '0x${chainId.toRadixString(16)}'} ], )
or
await connector.sendCustomRequest( method: 'wallet_addEthereumChain', params: [ { 'chainId': '0x${chainId.toRadixString(16)}', 'chainName': "xxx", 'nativeCurrency': { "name": "xxx", "symbol": "xxx", "decimals": xxx }, 'rpcUrls': [url,xxx], 'blockExplorerUrls': [url,xxx] } ], )
chain_info: https://chainid.network/chains.json
No branches or pull requests
I just want to know how to switch the network in MetaMask mobile using code
The text was updated successfully, but these errors were encountered: