RPC API Endpoints
The Stacks Node RPC API is exposed by every running Stacks node. It allows you to query the Stacks blockchain and interact with smart contracts. It was built to maintain pageable materialized views of the Stacks network.
If you run a local Stacks node, it exposes an HTTP server on port 20443. The info endpoint would be localhost:20443/v2/info.
Note that the Stacks Node RPC API and the Hiro Stacks Blockchain API are two different things. The Hiro API is a centralized service run by Hiro, a developer tooling company, that makes it easy to get onboarded and begin interacting with the Stacks blockchain in a RESTful way. The Hiro API is a proxy for the Stacks Node RPC API that makes it a bit easier to work with by providing additional functionality.
The Stacks Node RPC API is generated by every Stacks node and allows developers to self-host their own node and API for a more decentralized architecture.
The RPC API can be used without any authorization. The basepath for the hosted API is:
# for mainnet, replace `testnet` with `mainnet`
https://api.testnet.hiro.so/The Stacks Node RPC API endpoints can also be accessed via Hiro's docs here.
Last updated
Was this helpful?