Skip to main content

Parameters

chainId
string
default:"bitcoin-testnet4"
required
Unique identifier for a blockchain network.
id
number
default:1
required
Request identifier used to match responses.
jsonrpc
string
default:"2.0"
required
JSON-RPC version.
method
string
default:"getblock"
required
JSON-RPC method name.
params
object
required
Parameters: [blockHash, verbosity?].Positional parameters for getblock:
  • params[0]: 32 Bytes - hash of the transaction.
  • params[1]: Verbosity level (0-3) controlling JSON detail.

Returns

result
object
Block data or raw hex depending on verbosity.
curl --request POST \
  --url https://api.uniblock.dev/uni/v1/json-rpc?chainId=bitcoin-testnet4 \
  --header 'content-type: application/json' \
  --data '{
    "id": 1,
    "jsonrpc": "2.0",
    "method": "getblock",
    "params": [
      "",
      0
    ]
  }'
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {}
}