| Crates.io | bitcoin-rpc-types |
| lib.rs | bitcoin-rpc-types |
| version | 1.0.0 |
| created_at | 2025-09-24 02:59:29.228526+00 |
| updated_at | 2025-10-01 00:30:02.744828+00 |
| description | Type definitions for Bitcoin Core's JSON-RPC interface |
| homepage | |
| repository | https://github.com/nervana21/bitcoin-rpc-types |
| max_upload_size | |
| id | 1852412 |
| size | 32,144 |
Type definitions for Bitcoin Core's JSON-RPC interface.
Add this to your Cargo.toml:
[dependencies]
bitcoin-rpc-types = "1.0.0"
use bitcoin_rpc_types::{ApiDefinition, BtcMethod, BtcArgument, BtcResult, HashOrHeight};
// Load an API definition from JSON
let api_def: ApiDefinition = serde_json::from_str(json_data)?;
// Access methods
for method in api_def.methods.values() {
println!("Method: {}", method.name);
for arg in &method.arguments {
println!(" Argument: {} ({})", arg.name, arg.type_name);
}
}
MIT OR Apache-2.0
Part of the bitcoin-rpc crate ecosystem, providing type-safe Rust primitives for testing and development at the Bitcoin Core JSON-RPC interface.