Node Provisioning API
Dynamically provision nodes and receive staking transactions to sign.
The Node Provisioning API allows partners to programmatically spin-up nodes for staking. Partners specify the number of nodes needed and receive a transaction to sign that stakes with those node/s.
Provision validators with an API request and submit the deposits through a single ETH1 transaction.
Staked supports integration testing on ETH2, as defined below.
Post ETH2 Provisioning Request
ETH2 Testnet - Post Provisioning Request.postman_collection.json
Postman - Provisioning Request
// example post request body
"withdrawalKey": "YOUR ETH2 WITHDRAWAL KEY",
Get ETH2 Delegation Objects
ETH2 Testnet - Get Delegation Objects.postman_collection.json
Postman - Delegation Objects
The canonical ETH2 deposit contract, used to convert ETH1 to ETH2, only supports one deposit transaction at a time. Since 32 ETH is required for each validator, depositors with large amounts of ETH would have to broadcast many deposit transactions.
To simplify submitting deposits, we have created a batching contract which takes up to 185 deposits at once and submits each to the deposit contract. Integrators can therefore stake up to 5920 ETH in one Ethereum transaction, and leave behind the hassle of tracking many individually broadcasted transactions.
The batching contract contains an external payable function,
batchDeposits, which loops over each validator's deposit and sends them to the deposit contract. The function arguments are passed as a 2-d array where the array at
[i]represents the deposit arguments for validator
Automate provisioning of Dash masternodes.
Staked supports integration testing on Dash, as described below.
Each masternode requires an unspent transaction output (UTXO) of exactly 1,000 DASH. The address that owns this UTXO is the collateral address.
Instructions below assume use of the dash command line tool or debug console in the GUI wallet. If using the debug console, please remove
dash-clifrom the beginning of each command.
Create a new address to hold your masternode collateral.
dash-cli getnewaddress <address-alias>
dash-cli getnewaddress masternode_collateral_1
Next, send exactly 1,000 Dash to your collateral address.
dash-cli sendtoaddress <address> <amount>
dash-cli sendtoaddress yTrtvsNuVgezcGmcVyv2n8D2dFeJEHCYhg 1000
Get the transaction id and output index of the transaction you just created (you may need to wait up to 2 minutes until your transaction is added to a block).
dash-cli masternode outputs
"tx id": "collateral index"
A payout address is also needed and can be generated using the
getnewaddresscommand. A single payout address can be shared across masternodes.
Step 1: Post Masternode Provisioning Request
Step 2: Poll Masternode Status
This must be run on the wallet or device that holds collateral key, and can be done completely offline if required.
signMessageis returned in the response of the previous step.
signmessage collateralAddress signMessage
Step 4: Send Us the Signed Delegation Message
The status of the delegation object is now
WaitingToSubmit. When the Masternode is synched, the signedTx will be submitted and the status will be