5 ms·
Protobuf has a JSON canonicalization [0]. All our gRPC servers automatically accept HTTP/JSON traffic with the procedure name specified in a header. That's what
by closeparen 3y ago
Protobuf has a JSON canonicalization [0]. All our gRPC servers automatically accept HTTP/JSON traffic with the procedure name specified in a header. That's what I use when I'm writing a script.
https://protobuf.dev/programming-guides/proto3/#json https://protobuf.dev/programming-guides/proto3/#json
- dontlaugh 3y agoTwirp has this built-in https://twitchtv.github.io/twirp/docs/curl.html https://twitchtv.github.io/twirp/docs/curl.html It's very handy in some situations.
- arein3 3y agoCould you provide an example of json request to a grpc endpoint (url + headers + body)? Can it be done via http (ex. Postman) or it needs http2?
- closeparen 3y agoYou can check the Twirp doc in the sibling comment. Ours is similar. Works on regular HTTP, curl or Postman is fine.