Usage

How to use NEOPIN Connect SDK

The following information is deprecated and may limit its use. Please refer to the WalletConnect 2.0 tab for the latest version of NEOPIN wallet integration: WalletConnect 2.0

1. Open Sample Project

Load the DAppSample project through Android Studio.

2. Change WCPeerMeta settings

Change the WCPeerMeta settings with reference to the following.

  • The name, icon, etc. put in WCPeerMeta will be displayed in Wallet.

  • icon supports only png and jpg in url format.

  • appId is issued by NEOPIN, and consists of a 32 digit string.

    • ex) NWC1004HS6VFTPPPLUGFQBQ5SFNWB79B

    • The Wallet will reject connection of any appId that were not issued normally.

  • The name, icon, etc. put in WCPeerMeta will be displayed in Wallet.

ConnectManager.setClient(
    wcSession = WCSession(
        bridge = "https://wc-bridge.neopin.io/",           // Bridge Sever
    ),
    peerMeta = WCPeerMeta(
        appId = "NWC1004HS6VFTPPPLUGFQBQ5SFNWB79B",        // Used as Dapp storage delimiter
        name = "Dapp Sample",                              // Dapp name to display on the screen
        url = "https://www.sample.com/",                   // Dapp introduction URL to display on the screen
        description = "Dapp Platform",                     // Brief introduction
        icons = listOf(""),                                // Dapp icon URL to display on the screen
    )
)

3. Run Project

Run project through Android Studio's Run feature.

4. Precautions

  • DAppSample and WalletSample App must both be installed to proceed with the test. If you do not have the WalletSample App installed, please check the WalletSample App installation instructions in the Wallets section.

  • The URL Schemes used by NEOPIN are as follows. (Android displays a list of choices as follows when using the same Scheme.)

DApp
Wallet

Sample App

X

nptwc

NEOPIN App

your *URL Schemes

nptwc

Last updated