| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 |
- 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/common/common.proto";
- import "api/statistics/statistics.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 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 (common.SendPhoneCodeRequest) returns (google.protobuf.Empty){
- option (google.api.http) = {
- post: "/api/user/code/send",
- body:"*"
- };
- };
- // 用户验证验证码
- rpc CheckPhoneCode (common.CheckPhoneCodeRequest) returns (google.protobuf.Empty){
- option (google.api.http) = {
- post: "/api/user/code/check",
- body:"*"
- };
- };
- // 检查用户是否与接待员关联
- rpc CheckUserPartnerIsRelationship (common.PartnerIDParam) returns (chat.CheckUserPartnerIsRelationshipReply){
- option (google.api.http) = {
- post: "/api/user/check/relationship",
- body:"*"
- };
- };
- // 创建用户与接待员的关联
- rpc CreateUserPartnerIsRelationship (common.PartnerIDParam) returns (chat.CreateUserPartnerIsRelationshipReply){
- option (google.api.http) = {
- post: "/api/user/create/relationship",
- body:"*"
- };
- };
- // 获取接待员的确认通过页面信息
- rpc GetPartnerCircleInfo (common.PartnerIDParam) returns (common.AddFriendMessageInfo){
- option (google.api.http) = {
- post: "/api/user/circle/info",
- body:"*"
- };
- };
- // 用户获取主页信息
- rpc UserGetHomeInfo (common.PersonParam) returns (common.HomeInfo){
- option (google.api.http) = {
- post: "/api/user/home",
- body:"*"
- };
- };
- // 通过用户IDs查看用户信息列表
- rpc FindUserDBList (common.PersonIDList) returns (common.PersonDBReply);
- // 查看看过我的列表
- rpc FindLookList (common.ListPageRequest) returns (statistics.LookAndLikeListReply){
- option (google.api.http) = {
- post: "/api/user/list/look",
- body:"*"
- };
- };
- // 查看我喜欢的列表
- rpc FindLikeList (common.ListPageRequest) returns (statistics.LookAndLikeListReply){
- option (google.api.http) = {
- post: "/api/user/list/like",
- body:"*"
- };
- };
- // 查看喜欢我的列表
- rpc FindLikedList (common.ListPageRequest) returns (statistics.LookAndLikeListReply){
- option (google.api.http) = {
- post: "/api/user/list/liked",
- body:"*"
- };
- };
- }
- message UserInfo{
- string id = 1; // id
- string nickname = 2;// 昵称
- string avatarUrl =3;// 头像链接
- int64 age = 4;// 年龄
- int64 sex = 5;// 性别
- int64 credit = 6;// 积分
- int64 likeNum = 7;// 我喜欢
- int64 likedNum = 8;// 喜欢我
- int64 likedUnreadNum = 9; // 喜欢我的未读数
- int64 lookNum = 10;// 看过我
- int64 lookUnreadNum = 11;// 看过我的未读数
- }
- message UpdateUserInformationRequest {
- string Nickname = 1; // 昵称
- string avatarUrl = 2;// 头像
- int64 sex = 3; // 性别
- }
|