TopUp
New site!
All content has been migrated to docs.dash.org. You will be automatically redirected momentarily.
Usage: client.platform.identities.topUp(identity, amount)
Description: This method will topup the provided identity's balance.
The identity balance might slightly vary from the topped up amount because of the transaction fee estimation.
Parameters:
parameters | type | required | Description |
---|---|---|---|
identity | Identity | yes | A valid registered identity |
amount | number | yes | A duffs (satoshis) value corresponding to the amount you want to top up to the identity. |
Example:
const identityId = '';// Your identity identifier
const identity = await client.platform.identities.get(identityId);
await client.platform.identities.topUp(identity.getId(), 10000);
console.log(`New identity balance: ${identity.balance}`)
Returns: Boolean.
Updated about 1 year ago