Bundle client
- Getting started
- API
- Validate hexadecimal string
- Validate Bitcoin address
- Validate Ethereum address
- Generate mnemonic phrase
- Generate a new random signing key pair
- Register a new user
- Transfer tokens
- Get user refund addresses
- Get user balances and investment addresses
- Get user token balance
- Get wallet and transactions as cryptographic proof
- Changelog
Getting started
Install exonum-bundle-client package into your project.
npm install exonum-bundle-client
To include in Node.JS:
var ExonumBundle =
To use in browser:
API
Validate hexadecimal string
ExonumBundle
Argument | Description | Type |
---|---|---|
hash | Hash as hexadecimal string. | String |
bytes | Expected length in bytes. Optional, 32 by default. | Number |
Returns boolean
.
Validate Bitcoin address
ExonumBundle
Argument | Description | Type |
---|---|---|
address | Bitcoin address as string. | String |
networkType | prod , testnet or both . Optional, prod by default. |
String |
Returns boolean
.
Validate Ethereum address
ExonumBundle
Argument | Description | Type |
---|---|---|
address | Ethereum address as string. | String |
Returns boolean
.
Generate mnemonic phrase
ExonumBundle
Returns String
.
Generate a new random signing key pair
ExonumBundle
Argument | Description | Type |
---|---|---|
passphrase | Mnemonic phrase as string. | String |
password | Password as string. | String |
Returns promise.
Fulfilled response:
Register a new user
ExonumBundle
Argument | Description | Type |
---|---|---|
apiRoot | Root URL for node public API. | String |
keyPair | Signing key pair. | Object |
BTCAddress | Bitcoin address as string. | String |
ETHAddress | Ethereum address as string. | String |
Returns promise.
Fulfilled response:
Transfer tokens
ExonumBundle
Argument | Description | Type |
---|---|---|
apiRoot | Root URL for node public API. | String |
keyPair | Signing key pair. | Object |
to | Receiver's public key as hexadecimal string. | String |
amount | Uint64 number as string. |
String |
Returns promise.
Fulfilled response:
Get user refund addresses
ExonumBundle
Argument | Description | Type |
---|---|---|
apiRoot | Root URL for node public API. | String |
publicKey | Public key as hexadecimal string. | String |
Returns promise.
Fulfilled response:
Get user balances and investment addresses
ExonumBundle
Argument | Description | Type |
---|---|---|
apiRoot | Root URL for node public API. | String |
publicKey | Public key as hexadecimal string. | String |
Returns promise.
Fulfilled response:
Get user token balance
ExonumBundle
Argument | Description | Type |
---|---|---|
apiRoot | Root URL for node public API. | String |
publicKey | Public key as hexadecimal string. | String |
Returns promise.
Fulfilled response:
Get wallet and transactions as cryptographic proof
ExonumBundle
Argument | Description | Type |
---|---|---|
apiRoot | Root URL for node public API. | String |
publicKey | Public key as hexadecimal string. | String |
Returns promise.
Fulfilled response:
Changelog
Detailed changes for each release are documented in the CHANGELOG file.