Usage
How to use NEOPIN Connect SDK
Last updated
How to use NEOPIN Connect SDK
Last updated
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
How to run NeopinConnect Dapp Sample App for iOS version is as follows.
Run Example/NeopinConnect.xcworkspace to load the project.
Note: the extension is xcworkspace, not xcodeproj.
Make sure the schema (box area) is neopin-connect-iOS-DApp. If the schema is not neopin-connect-iOS-DApp, click neopin-connect-iOS-DApp to change.
To run NEOPIN Wallet and NEOPIN Connect Sample Wallet via iOS SDK on iOS 9.0 or higher, you need to set the app Allowlist in the Info.plist file.
This setting is required according to the OS policy for user information protection. For details, see Privacy and Your App.
In [Info] > [Custom iOS Target Properties], add LSApplicationQueriesSchemes, which is an Array type key, and “nptwc” and “examplewalletwc”, which are values to be used for custom URL schemes as [Item] of the key.
After opening the ConnectManager.swift file, modify the ClientMeta as shown below.
name
The name that will be displayed in the NEOPIN Wallet.
description
The description to be displayed along with the name (Optional)
icons
The icon address to be displayed in the NEOPIN Wallet.
url
The URL to be displayed along with the name.
appId
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.
deepLink
deepLink is required when connecting to the NEOPIN Wallet or returning to the service app after making a transaction.
You must enter the value set in URL Schemes, please refer to the setting method.
Run the project through the Run feature.
After running the project, most of the code associated with NEOPIN Wallet runs in ConnectManager. Please refer to ConnectManager for details.
DApp and Wallet App must all be installed to proceed with the test. If WalletApp is not installed, please check how to install WalletApp.
The URL Schemes used by NEOPIN are as follows:
Configure [URL Schemes] for NEOPIN Wallet connection and transaction. In [Info] > [URL Types] > [URL Schemes], register the Native App Name in neopinconnectto${NATIVE_APP_name} format. For example, if your Native App Name is "123456789", enter "neopinconnectto123456789" in [URL Schemes].
DApp | Wallet | |
---|---|---|
Sample App
neopinconnecttosampledapp
examplewalletwc
NEOPIN App
your *URL Schemes
nptwc