Can protoc or any tool do JSON-protobuf conversion?

Viewed 1353

Protobuf is in binary format, and it has also equivalent text format and JSON format.

protoc has --encode and --decode option to do text-binary conversion.

But is there a small tool to do JSON-binary conversion? like below:

tool --encode input.json def.proto  > pb-output.bin

and

tool --decode pb-input.bin def.proto > output.json

Thanks!

0 Answers
Related