The schema is described in a .proto file, from which client and server code is generated for any supported language. The binary format is more compact and faster than JSON.
message User {
int32 id = 1;
string name = 2;
}
service UserService {
rpc GetUser (UserRequest) returns (User);
}gRPC is poorly suited for public APIs (browsers require a grpc-web proxy). Ideal for internal communication between microservices.