Dev Quickstart: Connecting Your App
This guide is intended for application developers who wish to connect their applications to an Obi web-based wallet using WalletConnect. By following this guide, you can enable users to seamlessly onboard and interact with your app on any blockchain, using a secure and recoverable non-custodial account.
This guide focuses on how to generate and handle WalletConnect URIs that will allow users to establish connections with our wallet.
Quickstart Code Snippet: Enable Obi connection in your app
Understanding the WalletConnect URI
WalletConnect uses a URI scheme to initiate connections between applications (dApps) and wallets. This URI contains all the necessary information to establish a session and communicate securely.
Example WalletConnect URI:
To generate a WalletConnect URI, you can use the WalletConnect client libraries.
Step 1: Install WalletConnect Client
For JavaScript/TypeScript applications:
Step 2: Initialize the WalletConnect Client
Step 3: Create a Session and Generate the URI
Step 4: Present the URI to the User
You can display the URI as a link, automatically open the link when the user clicks an Obi button or text, or show a QR code.
We recommend against forcing a QR code default, as users may be using a desktop wallet. However, it is the easiest way to accomodate users preferring to use Obi on a mobile device.
Example deep link:
Encode the URI component properly to ensure it is correctly parsed by the web wallet.
Last updated