Methods
# cancelSnapshotRequest(params) → {Promise}
Cancels the specified snapshot request.
Parameters:
Name | Type | Description |
---|---|---|
params |
||
asset_name |
string
|
The asset name for which the snapshot will be taken |
block_height |
number
|
The block height at which the snapshot will be take |
Returns the request status
Promise
# distributeReward(params) → {Promise}
Splits the specified amount of the distribution asset to all owners of asset_name that are not in the optional exclusion_addresses
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
params |
|||
asset_name |
string
|
The reward will be distributed all owners of this asset |
|
snapshot_height |
number
|
The block height of the ownership snapshot |
|
distribution_asset_name |
string
|
The name of the asset that will be distributed, or AVN |
|
gross_distribution_amount |
number
|
The amount of the distribution asset that will be split amongst all owners |
|
exception_addresses |
string
|
<optional> |
Ownership addresses that should be excluded |
change_address |
string
|
<optional> |
If the rewards can't be fully distributed. The change will be sent to this address |
Promise
# getDistributeStatus(params) → {Promise}
Give information about the status of the distribution
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
params |
|||
parasm.asset_name |
string
|
The reward will be distributed all owners of this asset\n" |
|
parasm.snapshot_height |
number
|
The block height of the ownership snapshot\n" |
|
parasm.distribution_asset_name |
string
|
The name of the asset that will be distributed, or AVN\n" |
|
parasm.gross_distribution_amount |
number
|
The amount of the distribution asset that will be split amongst all owners\n" |
|
parasm.exception_addresses |
string
|
<optional> |
Ownership addresses that should be excluded\n" |
Promise
# getSnapshotRequest(params) → {Promise}
Retrieves the specified snapshot request details.
Parameters:
Name | Type | Description |
---|---|---|
params |
||
asset_name |
string
|
The asset name for which the snapshot will be taken |
block_height |
number
|
The block height at which the snapshot will be take |
Returns the asset_name and block_height
Promise
# listSnapshotRequests(params) → {Promise}
List snapshot request details.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
params |
|||
asset_name |
string
|
<optional> |
List only requests for a specific asset (default is "" for ALL) |
block_height |
number
|
<optional> |
List only requests for a particular block height (default is 0 for ALL) |
Array of objects containing asset_name and block_height
Promise
# requestSnapshot(params) → {Promise}
Schedules a snapshot of the specified asset at the specified block height.
Parameters:
Name | Type | Description |
---|---|---|
params |
||
asset_name |
string
|
The asset name for which the snapshot will be taken |
block_height |
number
|
The block height at which the snapshot will be take |
Object - { request_status: 'Added' }
Promise