sami7777
|
e133e97f3b
|
Add comprehensive RPC API upgrade: REST, ZMQ, SSE, address index
Phase 1 - New RPC commands (no new deps):
- getblockheader: header data from memory, zero disk reads
- estimatefee: static fee estimation (Bitcoin Core compatible)
- getblockchaininfo: chain state, difficulty, moneysupply
- getwalletinfo: balance, stake, txcount, keypool, encryption
- getnetworkinfo: version, protocol, connections, proxy
- gettxoutsetinfo: height, bestblock, total_amount
Phase 2 - REST API layer (-rest=1):
- /rest/chaininfo.json, /rest/block/<hash>.json|hex
- /rest/blockheader/<hash>.json, /rest/tx/<txid>.json|hex
- /rest/blockhashbyheight/<n>, /rest/mempool.json
- CORS headers for browser-based explorer access
Phase 3 - ZMQ pub/sub notifications (optional, USE_ZMQ=1):
- Topics: hashblock, hashtx, rawblock, rawtx
- Conditional compilation via ENABLE_ZMQ
Phase 4 - SSE real-time notifications (-ssenotify=1):
- GET /events endpoint (authenticated, long-lived)
- Block and transaction event streaming
- 15-second keepalive for proxy compatibility
Phase 5 - Address index (-addressindex=1):
- getaddressbalance, getaddressutxos, getaddresstxids
- LevelDB-backed index updated in ConnectBlock/DisconnectBlock
- Requires -reindex on first use
Also fixes QDesktopServices missing include for Qt5.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
2026-03-12 00:50:34 -07:00 |
|