Bitcoin
Bitcoin
Bitcoin
免费套餐涵盖个人项目。按量付费,无需绑卡即可扩展。
getnetworkinfo is a Bitcoin Core JSON-RPC method that reports how the node sees the Bitcoin peer-to-peer network along with its own software identity and relay policy. The response carries the Core version and subversion, the P2P protocolversion, whether networking is active, inbound and outbound connections, the list of reachable networks, and the relayfee and incrementalfee that govern which BTC transactions the node will accept and forward. Call it against https://bitcoin.therpc.io/YOUR_API_KEY to get the node's view of the P2P network plus its version and relay settings.
version and subversion strings to learn which Bitcoin Core build the endpoint runs, useful for feature gating.relayfee and incrementalfee to set sensible fee floors so your BTC transactions clear the node's mempool and relay rules.networkactive and the inbound/outbound connections counts as a quick health signal for the upstream node.此方法不需要任何参数,传入空数组 [] 即可。
| 类型 | 描述 |
|---|---|
| object | version, subversion, protocolversion, localservices, localrelay, timeoffset, networkactive, connections (in/out), networks[], relayfee, incrementalfee, localaddresses[], warnings. |
connections count and localaddresses belong to that node, so do not treat them as your client's network state.relayfee and incrementalfee are quoted in BTC per kvB. For sat/vB fee math, multiply by 1e8 to get satoshis and divide by 1000 — e.g. a relayfee of 0.00001 BTC/kvB is 1 sat/vB.