Delegate VID Tokens to Secure VideoCoin Network and get rewarded
VID Token holders can actively participate in securing the VideoCoin network by delegating portion of their tokens to transcode workers. The transcoding work is distributed to workers in proportion to the total stake on each worker. The total stake of a worker includes the self stake and delegated stake by one or more delegators. The delegated stake can be withdrawn. However the VID tokens are transferred to the holder's account after expiry of the unbonding time which is currently set at 21 days.
Delegation and withdraw can be performed through a command line tool called staker that is currently supported on Linux platforms. Follow the below steps:
- Download the command line tool staker (Contact VideoCoin support for the download link)
- Setup a configuration file in the format of Ethereum key store file that contains private key and public key (password protected)
- Run the delegate or withdraw commands as shown in the following sections.
The staker tool needs to communicate with the Ethereum mainnet to access VID tokens. You can use a free or paid subscription from Infura to access Ethereum through web interace. Please visit the Infura website (https://infura.io/product) and obtain a your ID and make it available to the staker tool using an environment variable as follows.
export ETH_RPC_URL=https://mainnet.infura.io/v3/<Your Project ID>
Prepare an Ethereum key file that contains your private key in encrypted form. Following is a sample key file
Currently the delegation is a two step process. First step is to move the erc-20 VID tokens form Ethereum main net to VideoCoin network. The second step is to stake native VID on the worker that you choose. Use the following command to transfer VID tokens from Ethereum main net to VideoCoin network:
$ videocoin fund amount -k <key file> -s <password>
Use the following command to delegate VID to a worker:
$ staker delegate add worker.PuK amount -k <key file> -s <password>ParameDescription
If the worker is not registered with the VideoCoin, the command fails. VideoCoin explorer can be used to obtain the list of workers registered with the VideoCoin Network
Use the following command to withdraw stake from a worker:
$ staker delegate withdraw worker.PuK -k <key file> -s <password>
Use the following command to complete pending unbonding requests that are initialted in the previous step:
$ staker withdraw complete -k <key file> -s <password>
Use the following command to transfer VID from VideoCoin network ERC-20 VID tokens on Ethereum main net:
$ staker withdraw <amount> -k <key file> -s <password>