Lock and Unlock Tokens
Challenge pool information
Use cp-info
command to get the challenge pool brief information.
allocation
yes
allocation id
string
json
no
print result in json format
false
boolean
Example:
Response:
Balance is the current challenge pool balance. Start,Expire time and the finalization are allocations related.
Create Read Pool
Use rp-create
to create a read pool, rp-create
has no parameters.
Collect rewards
Use collect-reward
to transfer reward tokens from a stake pool in which you have invested to your wallet.
You earn rewards for: Blobbers
File space used by allocation owners and associates.
A min lock demand for each allocation.
Block rewards. Each block a reward gets paid out to blobber stakeholders in the form of a random lottery. Validators
Payment for validating blobber challenge responses.
The stake pool keeps an account for all stakeholders to maintain accrued rewards. These rewards can be accessed using this collect-reward
command.
provider_type
no
blobber or validator
blobber
string
Read pool info
Use rp-info
to get read pool information.
json
no
print result in json format
false
boolean
Lock tokens into read pool
Lock some tokens in read pool. ReadPool is not linked to specific allocations anymore. Each wallet has a singular, non-expiring, untethered ReadPool. Locked tokens in ReadPool can be unlocked at any time and returned to the original wallet balance.
If the user does not have a pre-existing read pool, then the smart-contract creates one.
Locked tokens can be used to pay for read access to file(s) stored with different allocations. To use these tokens the user must be the allocation owner, collaborator or have an auth ticket.
fee
transaction fee
0
int
tokens
yes
tokens to lock
int
Unlock tokens from read pool
Use rp-unlock
to unlock tokens from `read pool by ownership.
fee
no
transaction fee
0
float
Unlocked tokens get returned to the original wallet balance.
Storage SC configurations
Show storage SC configuration.
allocation
yes
allocation id
string
json
no
print result in json format
false
boolean
Stake pool info
Use sp-info
to get your stake pool information and settings.
blobber_id
yes
current client
string
json
no
print result in json format
false
boolean
Lock tokens into stake pool
Lock creates delegate pool for current client and a given provider (blobber or validator). The tokens locked for the provider stake can be unlocked any time, excluding times when the tokens held by opened offers. These tokens will earn rewards depending on the actions of the linked provider.
sp-lock
returns the id of the new stake pool, this will be needed to reference to stake pool later.
blobber_id
id of blobber
n/a
string
validator_id
id of validator
n/a
string
fee
no
transaction fee
0
float
tokens
yes
tokens to lock
float
To stake tokens for blobbers:
To stake tokens for validators:
Unlock tokens from stake pool
Unlock a stake pool by pool owner. If the stake pool cannot be unlocked as it would leave insufficient funds for opened offers, then sp-unlock
tags the stake pool to be unlocked later. This tag prevents the stake pool affecting blobber allocation for any new allocations.
blobber_id
id of blobber
n/a
string
validator_id
id of validator
n/a
string
fee
no
transaction fee
0
float
To unstake blobber tokens:
To unstake validator tokens:
Stake pools info of user
Get information about all stake pools of current user.
json
no
print result in json format
false
boolean
Write pool info
Write pool information. Use allocation id to filter results to a singe allocation.
allocation id
no
allocation id
string
json
no
print result in json format
false
boolean
For all write pools.
Filtering by allocation.
Lock tokens into write pool
wp-lock
can be used to lock tokens in a write pool associated with an allocation. All tokens will be divided between allocation blobbers depending on their write price.
Uses two different formats, you can either define a specific blobber to lock all tokens, or spread across all the allocations blobbers automatically.
If the user does not have a pre-existing read pool, then the smart-contract creates one.
Anyone can lock tokens with a write pool attached an allocation. These tokens can be used to pay for the allocation updates and min lock demand as needed. Any tokens moved into the challenge pool to underwrite blobbers' min lock demands return to the allocation's owner on closing the allocation.
allocation id
no
allocation id
string
blobber
no
blobber id
string
duration
yes
duration for which to lock tokens
duration
fee
no
transaction fee
0
float
tokens
yes
number of tokens to lock
float
Unlock tokens from write pool
wp-unlock
unlocks an expired write pool. An expired write pool, associated with an allocation, can be locked until allocation finalization even if it's expired. It possible in cases where related blobber doesn't give their min lock demands. The finalization will pay the demand and unlock the pool.
fee
no
transaction fee
0
float
Last updated