跳到主要内容

网络 RPC 端点

公开可用的 Conflux Core 空间网络 RPC 端点

1. Confura

Confura是Conflux网络上的一个与以太坊Infura等效的公共JSON-RPC服务,由Conflux基金会开发和维护。

我们的公共RPC服务位于全球不同的地区。 通过利用地理DNS路由,开发者可以请求与他们物理距离最近的区域RPC服务。

公共端点

香港

网络名称链 ID浏览器网址RPC 端点
主网1029https://confluxscan.netHTTP: https://main.confluxrpc.com
Websocket: wss://main.confluxrpc.com/ws
测试网1https://testnet.confluxscan.netHTTP: https://main.confluxrpc.com
Websocket: wss://test.confluxrpc.com/ws

美国东部

网络名称链 ID浏览器网址RPC 端点
主网1029https://confluxscan.ioHTTP: https://main.confluxrpc.org
Websocket: wss://main.confluxrpc.org/ws
测试网1https://testnet.confluxscan.ioHTTP: https://test.confluxrpc.org
Websocket: wss://test.confluxrpc.org/ws

速率限制

不同费率档次和其速率限制的参考。

付费级别价格速率限制购买链接
免费$0每秒 50 次调用,每天最多100,000次 调用-
标准150 美元/月每秒 100 次调用,每天最多 1,000,000 次调用mainnet
testnet
企业用户请发邮件至 bd@confluxnetwork.org按需定制-

说明

  • getLogs调用的结果集最大大小为10,000。
  • 由于数据裁剪,旧的存档事件日志可能无法访问。
  • 请将您的 Api 密钥附加到端点上以获取特权访问(例如:https://main.confluxrpc.com/<api-key>)。
  • 每个RPC方法也有速率限制,请查阅以下规范以了解更多详细信息。
速率限制细则
RPC 方法免费级别标准级别注释
全部每秒请求数< 50;
每日总数 < 100,000
每秒请求数< 100;
每日总数 < 100,0000
RPC 请求总数
cfx_getLogs每秒请求数< 5每秒请求数< 20-
cfx_call每秒请求数< 5每秒请求数< 50-
cfx_getBlockBy*每秒请求数< 5每秒请求数< 20包括:
cfx_getBlockByHash,
cfx_getBlockByEPochNumber
cfx_getTransaction*每秒请求数< 5每秒请求数< 20包括:
cfx_getTransactionByHash,
cfx_getTransactionreceipt
debug RPC暂不支持每秒请求数< 20包括:
cfx_getEpochreceips 等。
trace RPC暂不支持每秒请求数< 20包括:
trace_block, trace_filter, trace_transaction
filter API暂不支持支持包括:
cfx_newFilter, cfx_getFilterChanges 等。
Confura Common Errors

The Confura service have some proprietary errors, these errors are not part of the Conflux-rust client RPC implementation.

common error response format:

{
"id": 123,
"jsonrpc": "2.0",
"error": {
"code": -32000,
"message": "daily request limit exceeded: Too many requests (exceeds 100000)"
}
}

Rate Limit related errors:

messagenote
daily request limit exceeded: Too many requests (exceeds 100000)
access forbidden by allowlistsThe requested method is only available in the VIP service.
allowed qps exceeded: Too many requests, exceeds 50 at a time

Encountering such errors, please purchase a higher-tier service through the web3 paywall.

getLogs related errors:

messagenote
event logs are too stale (already pruned)
Filter must provide one of the following: (1) an epoch range through fromEpoch and toEpoch, (2) a block number range through fromBlock and toBlock, (3) a set of block hashes through blockHashes
invalid block range (from epoch larger than to epoch)
Filter must provide one of the following: (1) a block number range through fromBlock and toBlock, (2) a set of block hashes through blockHash
filter.block_hashes can contain up to 32 hashes; xxx were provided.
filter.address can contain up to 32 addresses; xxx were provided.
filter.topics must be no more than 4-dimensional array; xxx were provided.
filter.topics can contain up to 32 topics per dimension; xxx were provided.
query set is too large, please narrow down your filter condition
result set to be queried is too large with more than 10000 logs, please narrow down your filter condition
filter not found

service errors:

messagenote
no full node available
subscription proxy error
query timeout with duration exceeds 3s
server is too busy, please try again later
RPC middleware crashed

This type of error indicates an issue with the Confura service. Please try again later or contact the service provider.

2. Unifra

Unifra是一个专注于简化区块链开发的Web3开发者平台。 它建立了一套开发者工具,增强了API,以及一个卓越的节点基础设施,以无缝构建和运行区块链应用程序。 Unifra 为多个链提供 API 服务,包括 以太坊、BNB 智能链、Polygon 和 Conflux。

Unifra提供:

  • 开放访问免费的公共端点
  • 通过Notify提供实时的webhook提醒
  • 一流的支持和可靠性/稳定性
  • Unifra的NFT API
  • 带有请求浏览器的仪表板

要使用Unifra的服务,开发者需要先注册一个账户,并在Unifra 控制台中找到RPC端点。 详细信息请查看Unifra的文档

公共端点

网络名称链 ID浏览器网址端点
主网1029https://confluxscan.nethttps://conflux-core-public.unifra.io