jsonrpc
JSON-RPC 2.0 implementation for Rust.
Features
- Transport Agnostic: Decouples protocol logic from I/O. Comes with
StdioandInMemorytransports out of the box. - Type-Safe Handlers: Handlers are just Rust functions. Parameters are automatically deserialized, and results are serialized.
Demo
Let's build a simple calculator server over Stdio:
use Deserialize;
use ;
Compile and run it, then pipe in some JSON-RPC commands:
|
Output:
Installation
TODO: add installation via git
Usage
TODO: add usage
License
MIT