1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
use serde::{Serialize, Deserialize}; use serde_json::Value; pub mod methods; #[derive(Serialize, Deserialize, Debug)] pub struct Request { pub jsonrpc: String, pub id: i32, pub method: String, pub params: Value } #[derive(Serialize, Deserialize, Debug)] pub struct Response { pub jsonrpc: String, pub id: i32, pub result: Value }