| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394 |
- syntax = "proto3";
- package api.user;
- import "google/api/annotations.proto";
- //import "google/protobuf/struct.proto";
- import "google/protobuf/empty.proto";
- import "api/chat/chat.proto";
- import "api/partner/partner.proto";
- import "api/base/base.proto";
- option go_package = "git.ikuban.com/server/pw-protobuf/api/user;user";
- option java_multiple_files = true;
- option java_package = "api.user";
- service User {
- rpc DebugLogin (base.DebugLoginRequest) returns (base.TokenReply){
- option (google.api.http) = {
- post: "/api/user/login/debug",
- body:"*"
- };
- };
- rpc Authorization (base.AuthorizationRequest) returns (base.TokenReply){
- option (google.api.http) = {
- post: "/api/user/authorization",
- body:"*"
- };
- };
- rpc UpdateUserInformation (UpdateUserInformationRequest) returns (google.protobuf.Empty){
- option (google.api.http) = {
- post: "/api/user/update/information",
- body:"*"
- };
- };
- rpc GetUserInfo (google.protobuf.Empty) returns (UserInfo){
- option (google.api.http) = {
- post: "/api/user/info",
- body:"*"
- };
- };
- rpc SendPhoneCode (SendPhoneCodeRequest) returns (google.protobuf.Empty){
- option (google.api.http) = {
- post: "/api/user/code/send",
- body:"*"
- };
- };
- rpc CheckPhoneCode (CheckPhoneCodeRequest) returns (google.protobuf.Empty){
- option (google.api.http) = {
- post: "/api/user/code/check",
- body:"*"
- };
- };
- rpc CheckUserPartnerIsRelationship (base.PartnerIDParam) returns (chat.CheckUserPartnerIsRelationshipReply){
- option (google.api.http) = {
- post: "/api/user/check/relationship",
- body:"*"
- };
- };
- rpc CreateUserPartnerIsRelationship (base.PartnerIDParam) returns (chat.CreateUserPartnerIsRelationshipReply){
- option (google.api.http) = {
- post: "/api/user/create/relationship",
- body:"*"
- };
- };
- rpc GetPartnerCircleInfo (base.PartnerIDParam) returns (partner.PartnerCircleInfo){
- option (google.api.http) = {
- post: "/api/partner/info/circle",
- body:"*"
- };
- };
- }
- message UserInfo{
- string id = 1; // id
- string nickname = 2;// 昵称
- string avatarUrl =3;// 头像链接
- string phone = 4;// 手机号
- int64 sex = 5;// 性别
- int64 credit = 6;// 积分
- }
- message UpdateUserInformationRequest {
- string Nickname = 1;
- string avatarUrl = 2;
- int64 sex = 3;
- }
- message SendPhoneCodeRequest {
- string phone = 1;
- }
- message CheckPhoneCodeRequest {
- string phone = 1;
- string code = 2;
- }
|