Skip to content

Protobuf and gRPC

zhttp decodes protobuf bodies in the Pretty and Tree views of the Body tab.

These content types are read as protobuf on their own:

  • application/grpc and its variants such as application/grpc-web, except the +json ones
  • application/x-protobuf, application/protobuf, application/x-protobuffer, application/vnd.google.protobuf, application/x-google-protobuf

gRPC, gRPC-Web and gRPC-Web-text bodies are read frame by frame.

A body with no content type, or application/octet-stream, could be anything. It gets a Decode as protobuf button. Not protobuf in the schema menu takes that back.

Each field shows its number, wire type and value. Strings are quoted and bytes are in hex. Nested messages are decoded where the bytes allow it.

  1. Click the Schema button in the body’s toolbar.
  2. Click Add schema files… and pick .proto files or descriptor sets (.desc, .binpb, .pb).
  3. Under Read as, search for the message type and click it. No schema goes back to field numbers.

Fields then show by name and type. The schema files you’ve added are listed under Settings → Protobuf, where Add files… adds more.

  • The request and response of a gRPC method your schemas define are read by name without choosing a type.
  • The type you choose is remembered for that endpoint, request and response separately.
  • A file that won’t load shows why under its name. The × beside a file removes it.
  • Schemas are kept between restarts and apply to every session. AI agents read bodies with them too.