andrew
August 17, 2023, 12:57am
1
Archived Content from Web3Auth Community
This topic was originally posted by andrew on 8/17/2023.
This content has been migrated from our previous community forum to preserve valuable discussions.
Hi,
Your demo app currently doesn’t have coinbase as an option. We’ve tried to incorporate the coinbase wallet extension using the suggested modalConfig but it doesn’t seem to recognize it. Has support for coinbase been deprecated? Is there a reason it isn’t on the demo app as well?
thanks!
<a href="https://demo-app.web3auth.io/" target="_blank" rel="noopener">demo-app.web3auth.io</a>
Web3Auth Demo App - Web3Auth is a simple, non-custodial auth infrastructure that enables Web3 wallets and applications to provide seamless user logins to both mainstream and native Web3 users.
Please provide the following details too when asking for help in this category:
SDK Version:
Platform:
Browser Console Screenshots:
Related to Custom Authentication? Please provide the following info too: (Optional)
Verifier Name:
JWKS Endpoint:
Sample idToken(JWT)
Please provide the Web3Auth initialization and login code snippet below:
andrew
August 17, 2023, 1:02am
2
adding SDK and platform details
andrew:
SDK Version: 6.1.7
Platform: windows 11, chrome desktop with metamask and coinbase extensions installed
Browser Console Screenshots:
Related to Custom Authentication? Please provide the following info too: (Optional)
Verifier Name:
JWKS Endpoint:
Sample idToken(JWT)
vjgee
August 17, 2023, 3:57am
3
@andrew Thanks for your recent post.
Coinbase is not available by default in Modal. You need to include the Coinbase Adapter following this: Coinbase Wallet Adapter | Documentation | Web3Auth
andrew
August 17, 2023, 4:31am
4
thanks we are doing a client side implementation but we are including the minified version of coinbase adapter via <script src=…
when trying to initialize CoinbaseAdapter, getting an error that CoinbaseAdapter is not a constructor, is there a reference that is using coinbase that works? Was hoping demo would have that but it’s not implemented looks like.
Thanks!
vjgee
August 17, 2023, 11:47am
5
You can refer to this example:
<a href="https://github.com/Web3Auth/web3auth-pnp-examples/blob/main/web-modal-sdk/blockchain-connection-examples/evm-modal-example/src/App.tsx#L136" target="_blank" rel="noopener">github.com</a>
<pre class="onebox"><code class="lang-tsx">
<ol class="start lines" start="126" style="counter-reset: li-counter 125 ;">
<li> "04309ed1007e77d1f119b85205bb779d"</li>
<li>);</li>
<li>const walletConnectV2Adapter = new WalletConnectV2Adapter({</li>
<li> adapterSettings: { ...defaultWcSettings.adapterSettings },</li>
<li> loginSettings: { ...defaultWcSettings.loginSettings },</li>
<li>});</li>
<li></li>
<li>web3auth.configureAdapter(walletConnectV2Adapter);</li>
<li></li>
<li>// adding metamask adapter</li>
<li class="selected">const metamaskAdapter = new MetamaskAdapter({</li>
<li> clientId,</li>
<li> sessionTime: 3600, // 1 hour in seconds</li>
<li> web3AuthNetwork: "cyan",</li>
<li> chainConfig: {</li>
<li> chainNamespace: CHAIN_NAMESPACES.EIP155,</li>
<li> chainId: "0x1",</li>
<li> rpcTarget: "https://rpc.ankr.com/eth", // This is the public RPC we have added, please pass on your own endpoint while creating an app</li>
<li> },</li>
<li>});</li>
<li>// we can change the above settings using this function</li>
</ol>
</code></pre>
Replace MetamaskAdapter with Coinbase Adapter