The purpose of this SDK is to provide a rapid solution for developers looking to develop custom cryptocurrency wallets and/or dApps. Kesem is a secure mulitisig wallet with advanced transaction risk assessment.
In Buidl we trust
Unlock Kesem backend db.
- error
- Error / exception.
- result[0]
- Not used.
Perform security check of the application environment. Check for malwares, rooting, etc… This API call should be called after UnlockKesemData().
- error
- If contains "Old version" redirect user to Update version screen and stops app execution afterwards.
- If contains "connection timeout" redirect user to no Internet error screen and stops app afterwards.
- If contains "Security violation" redirect use to security error screen and stops app afterwards.
- result[0]
- Not used.
Creates a record for user on Kesem server. Kesem will send back to user SMS code by phone.
- error
- Error / exception
- result[0]
- "ok" for success.
- "error" to indicate error. Result[1] will have the error. In case of "Security violation", default Kesem wallet redirects user to security error screen and exit application afterwards.
This function checks that SMS code is correct by verifing it with backend server. It is used during user registration process.
- error
- Error / exception.
- result[0]
- "ok" for success.
- Otherwise - invalid code.
This function returns user-id in hash format to be used by external systems. For example as part of utm tokens or for tracking with external analytics systems.
- error
- Error / exception.
- result[0]
- User hash.
Kesem is using multiple backend systems for testing and for production. It can be production, or development.
- error
- Error / exception.
- result[0]
- production or development value
This function return boolean value that indicate that user is registered, meaning:
- User accepted terms of service.
- User provided his phone number.
- User send correct SMS code.
- API backend finished init of the transaction database on the mobile phone.
- error
- Error / exception.
- result[0]
- True / False to indicate registered user.
Check if the mobile device has fingerprint hardware support and it can be used.
- error
- Error / exception.
- result[0]
- True / False to indicate that fingerprint can be used.
Check if application password is encrypted with fingerprint.
- error
- Error / exception.
- result[0]
- True / False to indicate that password is encrypted with fingerprint code.
This function shows a popup screen asking user to provide fingerprint. This API call returns user password.
- error
- Error / exception.
- result[0]
- Return application' user password in clear text.
This function checks if user password is correct. Default Kesem Wallet ask performs user password check before showing user wallet balance.
- error
- Error / exception. Indicated bad password
- result[0]
- Not used.
This functions is in charge to change user password.
- error
- Error / exception.
- result[0]
- Not used.
This API call shows to user system popup to give application access to location permission if it is not already given. This is an optional step. It is recommended to enable lcoation tracking only if user has meaningful amount of crypto currencies on his account.
- error
- Error / exception.
- result[0]
- Not used.
This function removes second backup key seed for the database. It is done to improve security. In default Kesem app, user needs to confirm seed delation.
- error
- Error / exception.
- result[0]
- Not used.
Returns backup seed in hex format to the user to be used to be backuped.
- error
- Error / exception.
- result[0]
- Backup seed.
This function check if database has no backup seed - meaning it was already backuped.
- error
- Error / exception.
- result[0]
- True / False to indicate that backup was saved.
This API call check Kesem server for all new user transactions for all supported coins at once.
Create wallet for user. User can create just one wallet for specific coin. Password is required only for first wallet command.
- error
- Error / exception.
- result[0]
- True / False to indicate that wallet was created.
This function returns JSON with all user wallets information.
- error
- Error / exception.
- result[0]
- All user wallets info in JSON format.
[ { coinDetails: { coinCode: 1, shortName: 'BTC', title: 'BitCoin' },
confirmedBalance: 0, unconfirmedBalance: 0 } ]
Returns a JSON with a list of supported wallets the system can create for user. For example BTC, ETC, XTN, etc..
- error
- Error / exception.
- result[0]
- A list of supported wallets in JSON format.
[ { coinCode: 0, shortName: 'XTN', title: 'BitCoinTest' },
{ coinCode: 1, shortName: 'BTC', title: 'BitCoin' },
{ coinCode: 2, shortName: 'ETH', title: 'Ethereum' } ]
This function checks that SMS code is correct by connection the backend server. It is used as a part of the user security challenge validation when user is sending funds out. For example if the sum of transaction is big.
- error
- Error / exception.
- result[0]
- "ok" for success.
- Otherwise - invalid code.
Perform internal operation to open specific wallet. After opening the wallet, the following API calls can be used: GetAddress(), IsValidAddress(), RefreshAddress(), GetBalance(), SendCoins(), GetTransactiosData(). No need to run OpenWallet several time, only when you change active wallet.
- error
- Error / exception.
- result[0]
- Not used.
Get current address of the wallet previously opened with OpenWallet()
- error
- Error / exception.
- result[0]
- Wallet address.
This API all checks that the arbitrary wallet address has correct formation. It is used as part of sanity check when sending out funds. Wallet should be opened state when calling this API call.
- error
- Error / exception.
- result[0]
- True / False to indicate that address has correct format.
Refreshes wallet address with Kesem server and returns a new address. Wallet should be in opened state when calling this API call.
- error
- Error / exception.
- result[0]
- New wallet address.
Returns balance of the current wallet opened with OpenWallet() API call.
- error
- Error / exception.
- result[0]
- Confirmed balance.
- result[1]
- Unconfirmed balance.
Creates a transaction and sends it to Kesem server. Wallet should be in opened state when calling this API call.
- Amount - sum of coins to send.
- Address - destination address to send
- Fee - mining fees to pay - X coins for 1000 bytes of transactions.
- Password - user wallet password.
Returns a list of all user transactions for current wallet.
- error
- Error / exception.
- result[0]
- A list of transactions JSON format.
[ { timestamp: 1549287849,
remark: '',
confirmInBlock: 1455569,
transactionID: '4a28a9aa7d4c17cf4c9d8fc47ff41ca82828395853c1896e1397a7d4768ba9f0',
confirmations: 1,
amountInCryptoCurrency: 0.11907588,
amountInDollars: 0 } ]