C++ client with GRPC

How can I use official c++ client with grpc technology (not rest api)?
The official c++ client docs seems describe rest api connection:
‘‘The createDefaultClient will create HTTP/1.1 client to use REST API.’’

I want better performance by using grpc client.

@nkadd The official CPP client sdk supports both the REST API and the GRPC API in the server. @Dimon4eg can share an example on how to build and use the GRPC version of the SDK.

Please follow documentation from Readme https://github.com/heroiclabs/nakama-cpp/blob/master/README.md#build-configuration

And how can I use it?
I could’nt see any api document or example for grpc client.

There are these two options; either will work:

  1. Just disable Rest client in config, then re-build sdk
  2. Use createGrpcClient instead of createDefaultClient

So are these steps enough:

  1. disable rest client
  2. enable grpc client
  3. rebuild sdk
  4. use createDefaultClient
    or should I use createGrpcClient in step 4?

Q 2: Are all other apis (authentication,ssl,storage,custom rpc) same as official c++ client document?

Q 3: How to use ssl encryption at the client side with grpc cpp client?

Any should work createDefaultClient
or createGrpcClient.

A 2: Yes, API the same

A 3: The same way as for Rest client - enable ssl in NClientParameters and then create client with it.

Could you please build a grpc version of c++ client for android?
I’m not a build expert!

You don’t have to be build expert.
Please follow https://github.com/heroiclabs/nakama-cpp#building-for-android
That 's not that hard.
If you have questions you can ask me directly.