Upload block

RPC node

Upload a block to the node.

POST

Parameters

Query Parameters

broadcast
string If set to `"1"` the node will broadcast the uploaded block to peers. When present the request must include a valid `Authorization` header.

Body

application/octet-stream
string (binary)
Binary SIP-003 encoding of a `NakamotoBlock`
Status codeDescription
200Block upload result.
400Bad request
401Unauthorized. Invalid or missing authentication token.
500Internal Server Error
cURL
curl -L -X POST \
"https://api.hiro.so/v3/blocks/upload?broadcast={broadcast}" \
-H 'Accept: application/json'
Response
{
"stacks_block_id": "abc123...",
"accepted": true
}

How is this guide?