Skip to content

Latest commit

 

History

History
72 lines (40 loc) · 7.1 KB

json-rpc-relay.md

File metadata and controls

72 lines (40 loc) · 7.1 KB

JSON-RPC Relay

The Hedera JSON-RPC Relay is an open-source project implementing the Ethereum JSON-RPC standard. It allows developers to interact with Hedera nodes using familiar Ethereum tools, allowing Ethereum developers and users to deploy, query, and execute contracts as they usually would. Check out the interactive OpenRPC Specification and a simple list of endpoints.

HBAR decimal places

The Hedera JSON RPC Relay msg.value uses 18 decimals when it returns HBAR. As a result, the gasPrice value returns 18 decimal places since it is only utilized from the JSON RPC Relay. Refer to the HBAR page for a list of Hedera APIs and the decimal places they return.

Community Hosted JSON-RPC Relays

Anyone in the community can set up their own JSON RPC relay that applications can use to deploy, query, and execute smart contracts. The list of community-hosted Hedera JSON RPC relays and endpoints for previewnet, testnet, and mainnet can be found in the table below, as well as their associated docs or websites.

JSON-RPC Relay Endpoints

NetworkChain IDHashio RPC URLthirdweb RPC URL
Mainnet295https://mainnet.hashio.io/api **https://295.rpc.thirdweb.com
Testnet296https://testnet.hashio.io/api**https://296.rpc.thirdweb.com
Previewnet297https://previewnet.hashio.io/api**https://297.rpc.thirdweb.com

**��Please note: Hashio is For development and testing purposes only. Production use cases are strongly encouraged to use commercial-grade JSON-RPC relays or host their own instance of the Hedera JSON-RPC Relay.

Hashiohashio-new-hashgraph.pnghttps://www.hashgraph.com/hashio/
Arkhiaarkhia-logo.pnghttps://www.arkhia.io/features/#api-services
Validation Cloudvalidation-cloud-black-logo-card.pnghttps://docs.validationcloud.io/about/hedera/json-rpc-relay-api
thirdwebthirdweb-logo.jpghttps://thirdweb.com/hedera
QuickNodequicknode-logo-card-black.pnghttps://www.quicknode.com/docs/hedera
Run Your Own Relay05-Hedera-Icon-Lockup-Dark.jpghttps://github.com/hashgraph/hedera-json-rpc-relay?tab=readme-ov-file#hedera-json-rpc-relay

{% hint style="info" %} Note: If you want to add your hosted JSON-RPC relay to this list, please open an issue in the Hedera docs GitHub repository. Please visit the community-hosted websites to review any limitations specific to their instance. {% endhint %}

{% content-ref url="../../tutorials/more-tutorials/json-rpc-connections/" %} json-rpc-connections {% endcontent-ref %}

FAQ

Are there Community hosted relays?
How do I connect to the Hedera Network over RPC?

The configuration guide to connect to the Hedera Network over RPC can be found here.

Where can I find the Hedera JSON-RPC relay endpoints?

The endpoints for previewnet, testnet, and mainnet can be found on Hashio, accessible through the Hashgraph website. Feel free to join the discussion on Stack Overflow for more questions.

How does Hedera handle decimals in HBAR and gas prices?

The JSON-RPC Relay msg.value uses 18 decimals when it returns HBAR. The gasPrice value also returns 18 decimal places. Check out the HBAR page for the full list of Hedera APIs and their decimal representation.

How can I contribute or log errors?

To contribute or log errors, please refer to the Contributing Guide and submit them as issues in the GitHub repository.