Skip to Content
ReferenceREST API

REST API

Tidecoin Core inherits Bitcoin Core’s unauthenticated read-only REST interface. Enable it with -rest=1. It runs on the same HTTP service as JSON-RPC.

This page is a reference summary. The source document is ../tidecoin/doc/REST-interface.md.

Security Posture

REST is read-only, but it is unauthenticated and can leak node privacy. Bind it to localhost or a private interface and protect it with firewall rules or a trusted reverse proxy.

Do not expose REST directly to the public internet.

Enablement

server=1 rest=1 rpcbind=127.0.0.1

Example query:

curl "http://127.0.0.1:8754/rest/chaininfo.json"

Use the configured RPC/HTTP port for your network and node.

Endpoint Groups

EndpointPurpose
/rest/tx/TXID.FORMATReturn a transaction. Confirmed lookup requires txindex=1.
/rest/block/BLOCKHASH.FORMATReturn a block.
/rest/block/notxdetails/BLOCKHASH.FORMATReturn block data without full transaction details in JSON.
/rest/headers/BLOCKHASH.FORMAT?count=NReturn block headers from a starting block.
/rest/blockfilterheaders/TYPE/BLOCKHASH.FORMAT?count=NReturn compact block filter headers.
/rest/blockfilter/TYPE/BLOCKHASH.FORMATReturn a compact block filter.
/rest/blockhashbyheight/HEIGHT.FORMATReturn block hash by height.
/rest/spenttxouts/BLOCKHASH.FORMATReturn spent output data for a block when undo data is available.
/rest/chaininfo.jsonReturn blockchain state.
/rest/deploymentinfo.jsonReturn deployment state at the current tip.
/rest/deploymentinfo/BLOCKHASH.jsonReturn deployment state at a specific block.
/rest/getutxos/...Query UTXO set entries.
/rest/mempool/info.jsonReturn mempool state.
/rest/mempool/contents.jsonReturn mempool contents.

Formats

Most endpoints support:

  • .json;
  • .hex;
  • .bin.

Use JSON for service integration unless you intentionally need raw binary or hex.

Operational Notes

  • REST consistency follows the same model as RPC.
  • Very high concurrent HTTP request counts can exhaust file descriptors.
  • Browser access to localhost REST can leak private node data through malicious pages, so avoid browsing untrusted sites from a node host.
  • Use RPC for authenticated control operations; REST is for read-only queries.

See also: ZMQ Notifications, Node & Operations / REST and ZMQ, RPC Security.

Last updated on