WalletConnect- Open protocol for connecting Wallets to Dapps

in #utopian-io5 years ago

ds00.png

GitHub Repository- https://github.com/WalletConnect

Introduction

The emergence of blockchain technology and its ecosystem is scaling up new heights every day. As on date we don't just e technology, but also we do have smart contracts, dapps ecosystem where many types of platform, communities grow and make the ecosystem much more better and interactive with many types of use-cases. So many sub-domains of the economy have been created over last couple of years and the volume is really increasing as along with that the mass adoption factor is also adding value to the ecosystem and the economy is on the rise for sure.

Whenever a new user gets an exposure to blockchain today, then the immediate exposure of the user is through a dapp and a wallet. These are first essential things the user came across before getting into further details about the project or the types of use-cases. If we consider this fact then we must understand that the immediate interface of the user must be essentially user-friendly that can make a smooth transition for the user to the blockchain world.

In the wallet part, the user either goes with a desktop wallet or with a mobile wallet. Although both the form of wallet store tokens and have the primary objective mostly the same but the use-case may be different and may vary based on the type of wallet. A Metamask plugin wallet may have different use-case as compared to a mobile wallet. Further a mobile wallet may not be able to interact with a dapp on desktop if there is no relay communication between them.

Therefore it is imperative to say that the immediate exposure like mobile wallets, dapps must become inter-operable to make the user experience smooth and friction-less.

Problem Interface

With the blockchain technology and cryptocurrency, a user on a day to day basis come across with various dapps. So the interaction of the user with the dapps happens in various types of use cases and that all depends on the requirement of the user. The specific requirement may vary with the types of dapp. But in all most all dapps, the use cases also constitute the interaction with the wallet of the user too. In the wallet there are various types of wallets. However broadly the user either goes with a mobile wallet or may go with a desktop wallet like Metamask plugin or Cipher etc.

So the real problem emerge for a user when he tries to interact with a dapp of desktop version based on his mobile wallet. If there is no relay protocol to bridge the mobile wallets upon the desktop version of the dapp, then the user can not be able to use his mobile wallets for the dapps on desktop. The user has to separately create a desktop wallet like Metamask. So we need to understand that there exist a gap between "what we use in mobile wallet" and "when we try to interact with a dapp in desktop". So this existing state of problem interface require further development to bridge the gap between the two so as to--- make it "friction-less", make it "inter-operable" when the dapp on desktop and mobile wallets are under consideration, make it "secure" through proper encryption and make it "user-friendly" for the users.

Walletconnect

Walletconnect is one such protocol and probably a viable open source solution to securely connect wallets and dapps. Through relay payloads, a remote connection can be established between the two devices and/or apps in a secured manner through symmetrical encryption. The connection can be initiated by one device displaying the QR code and the counter-party device can approve that connection to establish the bridge between the two and can make it inter-operable. Additionally, it also includes an optional push server to allow Native applications to notify the user of incoming payloads for establishes connections.

The Core Architecture

Walletconnect establishes a connection between two devices/peers(dapp & wallet) in which it requires requesting a connection by one peer and responding to that connection by the other peer and finally the connection gets established.

Requesting a connection

  • The initiator(dapp) requests a connection by posting an encrypted payload.
  • The connection details to the bridge server.
  • In order to establish a connection Walletconnect standard URI format is used and the dapp assembles together the required parameters such as topic, bridge, key, etc.

ds08.png

Establishing a connection

  • The other peer(wallet) reads the URI using the QR code.
  • It decrypts the connection request payload.
  • The wallet displays the user request details provided by the dapp.
  • It will either approve or reject. In case of rejection, the bridge will be disconnected immediately and in case of approval, the dapp will receive the provided account from the wallet.

ds09.png

Once the connection/bridging between the two peers(wallet & dapp) gets established, the dapp can send RPC call request to be handled by the wallet which includes: read data, sign messages/transactions etc.

Getting started with Walletconnect

Before getting started you may require a virtual mobile wallet. In case you don't have, you can get it from Google Play Store. I have downloaded and installed (Trust Wallet)[https://play.google.com/store/apps/details?id=com.wallet.crypto.trustapp] (you can choose any other wallet too which supports walletconnect) to test the interface and make use of Walletconnect protocol. After you have your virtual mobile wallet in your phone, then go through the following steps:-

(1) Go to your desktop browser and then visit https://example.walletconnect.org/

(2) You can see "Connect to Walletconnect", just click on that.
ds01.png

(3) It will then display the QR code right in front of you. This code must be scanned with another device to make that device interactive with the dapp on desktop.
ds02.png

(4) Now go to Trust Wallet which is already installed in your mobile, then you can see an option on the right of Collectibles(as shown in the screenshot below),upon clicking on it will display QR code scan and under that you can see "Walletconnect". Click on wallet connect now to scan the QR code.

ds03.png

ds04.jpg

(5) After scanning the QR code, a pop up message will appear which will ask you to Approve. So click on "Approve".

ds05.jpg

(6) Now the mobile device is connected with Walletconnect and it will display the basic information.

ds06.jpg

(7) You can now see your balance, actions right on the desktop.

ds07.png

Pros of Walletconnect

  • Without downloading any desktop wallet or an extension or plugin, you can interact with the dapp. Walletconnect makes it possible for the two devices to become inter-operable.

  • It is secured as the connection is established through symmetrical encryption.

  • It makes the blockchain exposure to a new user more friendly and gives an easy access to interact with the dapps. That means it lowers the barriers to entry and can enhance mass adoption.

  • In order to interact with a dapp or a specific use-case it may not necessarily require for a user to download Metamask plugin or any such extension. With the mobile wallets also, it can be made possible through Walletconnect.

  • It is open-source, so any one can participate and make the development even better than the current one.

  • The application is available in both Android and iOS.

  • It does not require any hardware or software.

Cons of Walletconnect

  • Timely updation in the forum is needed.

Conclusion

The capability to make mobile wallet with dapps on desktop interactive and inter-operable makes Walletconnect unique and it can really makes the user experience friction-less and can save a lot of time. It is so simple & easy that it can be set up by any developer. With the rise of dapps ecosystem it is really an essential protocol and I personally would like to see more development in it and I am certain that in near future we can see a lot out of it. It can also add simplicity and easiness to many use-cases to the people in the blockchain domain.

References used:-


Image Courtesy:-

  • WalletConnect Resources

Coin Marketplace

STEEM 0.29
TRX 0.12
JST 0.033
BTC 63464.16
ETH 3111.33
USDT 1.00
SBD 3.98