Blame view

protos/account.proto 586 Bytes
ee23102d   zhangqijia   支持mongo, grpc接服务器
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
  syntax = "proto3";
  option go_package = "./pb;pb";
  
  package account;
  import "public.proto";
  
  message ServiceInfo {
    string id = 1;
    string name = 2;
    string address = 3;
  }
  
  message AccountInfo{
    string phone = 2;
    string password = 3;
    int64 uid = 4;
    string device = 5;
  }
  
  message CreateTokenRsp {
    string token = 1;
    ServiceInfo game_service = 2;
  }
  
  message Register {
    string phone = 1;
    string password = 2;
    int32 code = 3;
  }
  
  service Account{
    rpc RegisterHandler(Register) returns (public.PubRsp) {}
    rpc CreateTokenHandler(AccountInfo) returns (CreateTokenRsp) {}
  }