@nkadd The questions aren’t clear to me. I’m not sure what exactly you want to use Protobuf for? I’ll try to answer as much as I can anyway.
How nakama use protobuf and rest api together?
Nakama can use Protobuf direct with the GRPC API we provide already if the client sdk supports it but for wider compatibility we also provide support for REST (with JSON messages).
How clients connect by rest api while they dont serialize requests as protobuf?
The client sdks which connect over port 7350 use the REST API but if 7349 is used it’s expected to be GRPC (which is Protobuf and HTTP/2). What we do internally is take the JSON message on the 7350 port and convert it to the Protobuf message to process it. The server logic always uses protocol buffers within the core engine.
For realtime multiplayer (both client-relayed and authoritative multiplayer) your data protocol can be developed as binary code or whatever format you prefer. We usually use Protobuf but you can use JSON, FlatBuffers, or any other format you want to use.