The ReProto project is a language-neutral protocol specification, aimed towards describing and generating code for handling messages exchanged through JSON-based APIs.
See Specification for details on what the syntax of .reproto
files is.
See Examples for some example API specifications.
Note: This project is in an Alpha-stage.
Make you have gotten started with Rust.
Install reproto through cargo:
bash
$> cargo install reproto
This will install the command into ~/.cargo/bin
, make sure it is in your $PATH
.
Using the FasterXML backend for Java:
bash
$> reproto --debug compile -b java -m fasterxml -o target/java \
--path examples \
--package heroic.v1
Multiple paths can be included, and the same declarations will extend each other:
bash
$> reproto --debug compile -b java -m fasterxml -o target/java \
--path examples \
--path examples/ext \
--package heroic.v1
This will generate code for the plain python backend:
bash
$> reproto --debug compile -b python -o target/python \
--path examples \
heroic.v1
A Maven plugin that integrates reproto into the build lifecycle of a maven project.
A VIM plugin that provides syntax highlighting.