A formal RPC description for type-safe Rust clients
Recent discussion has suggested a renewed interest in a formal description of the RPC API surface. The Bitcoin Core RPC surface is the predominant means through which external clients query the blockchain. As tooling continues to depend on RPC behavior, the need for and benefits from a behavioral specification are likely to increase.
Ethos is a PoC for the capabilities of such a specification. Other comprehensive specifications may be adapted to.
- Rust (edition 2021, rust-version 1.70+)
- just command runner (install with
cargo install just) - Protocol executable (for integration tests):
bitcoind(Bitcoin Core)
Run the complete code generation workflow:
just generateThis will generate a Bitcoin Core client library from the IR file (resources/ir/bitcoin.ir.json).
Contributors are warmly welcome, see CONTRIBUTING.md.
CC0-1.0
This is experimental software in active development. Please use appropriate caution.