bch

Bitcoin Cash (BCH)

Method: POST submitblocklight

dropdown

POST submitblocklight

Method not allowed

Attempts to submit a new block to network, based on a previous call to getblocktemplatelight.

See the getblocktemplatelight spec in the doc folder for full specification.

Parameters

hexdata - string, required

The hex-encoded block data to submit. The block must have exactly 1 transaction (coinbase). Additional transactions (if any) are appended from the light template.

job_id - string, required

Identifier of the light template from which to retrieve the non-coinbase transactions. This job_id must be obtained from a previous call to getblocktemplatelight.

Request

curl --location --request POST 'https://bch.getblock.io/mainnet/' 
--header 'x-api-key: YOUR-API-KEY' 
--header 'Content-Type: application/json' 
--data-raw '{"jsonrpc": "2.0",
"method": "submitblocklight",
"params": [null, null],
"id": "getblock.io"}'


Response

{
    "result": "null",
    "id": "getblock.io",
    "status_code": 405,
    "message": "Method not allowed"
}