Files
full/module/base/passport/proto/account.proto

82 lines
2.5 KiB
Protocol Buffer
Raw Normal View History

syntax = "proto3";
package passport;
option go_package = "bsm/full/module/base/passport/pb;passport";
import "module/base/passport/proto/const.proto";
// assport通行证模块-帐号数据
service Account{
// 通过会员所有信息
rpc Get(blocks.Empty) returns (GetFullReply) {}
// 更新会员的信息数据,字段值为空或是0将不更新此数据
rpc SetData(SetDataRequest) returns (blocks.StatusReply) {}
// 更新会员的密码
rpc SetPassword(SetPasswordRequest) returns (blocks.StatusReply) {}
// 新增标签
rpc TagCreate(TagItem) returns (blocks.StatusReply) {}
// 删除标签
rpc TagRemove(blocks.IdentRequest) returns (blocks.StatusReply) {}
// 获取会员的相关统计数据
rpc Statistics(StatisticsRequest) returns (StatisticsReply) {}
}
// 获取会员的完整信息
message GetFullReply {
string identity = 1; // 唯一标识
string account = 2; // 帐号
string phone = 3; // 手机号码 必填
string email = 4; // 验证码
string rights = 5; // 权限
string nickname = 6; // 昵称
string avatar = 7; // 头像
string birthday = 8; // 生日
int32 sex = 9; // 性别1为男性2为女性
string country = 10; // 国家
string province = 11; // 省
string city = 12; // 市
string area = 13; // 区
string sign = 14; // 签名
string cover = 15; // 背景&封面
int32 score = 16; // 积分
int32 level = 17; // 等级
blocks.VerifyStatus verify_status = 18; // 用户验证状态
repeated TagItem tags = 19; // 用户标签
}
message TagItem {
string name = 1;
string icon = 2;
}
message SetDataRequest {
string nickname = 1; //昵称
string avatar = 2; //头像
string birthday = 3; //生日
int32 sex = 4; //性别1为男性2为女性
string country = 5; // 国家
string province = 6; //省
string city = 7; //市
string area = 8; //区
string sign = 9; //签名
string cover = 10; // 背景&封面
int32 score = 11; // 积分
int32 level = 12; // 等级
}
message SetPasswordRequest {
string old_password = 3; // 旧密码
string new_password = 4;// 新密码
}
message StatisticsRequest {
repeated string field = 1; //要获取的统计数据字段。
}
message StatisticsReply {
map<string,int64> Data=1; //数据以Map格式输出
}