wfz 3 tahun lalu
induk
melakukan
ce43fed476

+ 114 - 85
api/account/account.pb.go

@@ -21,16 +21,17 @@ const (
 	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
 )
 
-type OpenIDRequest struct {
+type OpenIDAndAppIDRequest struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
 
 	OpenId string `protobuf:"bytes,1,opt,name=openId,proto3" json:"openId"`
+	AppId  string `protobuf:"bytes,2,opt,name=appId,proto3" json:"appId"`
 }
 
-func (x *OpenIDRequest) Reset() {
-	*x = OpenIDRequest{}
+func (x *OpenIDAndAppIDRequest) Reset() {
+	*x = OpenIDAndAppIDRequest{}
 	if protoimpl.UnsafeEnabled {
 		mi := &file_account_proto_msgTypes[0]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -38,13 +39,13 @@ func (x *OpenIDRequest) Reset() {
 	}
 }
 
-func (x *OpenIDRequest) String() string {
+func (x *OpenIDAndAppIDRequest) String() string {
 	return protoimpl.X.MessageStringOf(x)
 }
 
-func (*OpenIDRequest) ProtoMessage() {}
+func (*OpenIDAndAppIDRequest) ProtoMessage() {}
 
-func (x *OpenIDRequest) ProtoReflect() protoreflect.Message {
+func (x *OpenIDAndAppIDRequest) ProtoReflect() protoreflect.Message {
 	mi := &file_account_proto_msgTypes[0]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -56,18 +57,25 @@ func (x *OpenIDRequest) ProtoReflect() protoreflect.Message {
 	return mi.MessageOf(x)
 }
 
-// Deprecated: Use OpenIDRequest.ProtoReflect.Descriptor instead.
-func (*OpenIDRequest) Descriptor() ([]byte, []int) {
+// Deprecated: Use OpenIDAndAppIDRequest.ProtoReflect.Descriptor instead.
+func (*OpenIDAndAppIDRequest) Descriptor() ([]byte, []int) {
 	return file_account_proto_rawDescGZIP(), []int{0}
 }
 
-func (x *OpenIDRequest) GetOpenId() string {
+func (x *OpenIDAndAppIDRequest) GetOpenId() string {
 	if x != nil {
 		return x.OpenId
 	}
 	return ""
 }
 
+func (x *OpenIDAndAppIDRequest) GetAppId() string {
+	if x != nil {
+		return x.AppId
+	}
+	return ""
+}
+
 type IdentityInfo struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -302,9 +310,10 @@ type AuthorizationRequest struct {
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
 
-	JsCode string `protobuf:"bytes,1,opt,name=jsCode,proto3" json:"jsCode"`
-	AppId  string `protobuf:"bytes,2,opt,name=appId,proto3" json:"appId"`
-	Type   string `protobuf:"bytes,3,opt,name=type,proto3" json:"type"`
+	JsCode     string `protobuf:"bytes,1,opt,name=jsCode,proto3" json:"jsCode"`
+	AppId      string `protobuf:"bytes,2,opt,name=appId,proto3" json:"appId"`
+	Type       string `protobuf:"bytes,3,opt,name=type,proto3" json:"type"`
+	FromOpenId string `protobuf:"bytes,4,opt,name=fromOpenId,proto3" json:"fromOpenId"`
 }
 
 func (x *AuthorizationRequest) Reset() {
@@ -360,6 +369,13 @@ func (x *AuthorizationRequest) GetType() string {
 	return ""
 }
 
+func (x *AuthorizationRequest) GetFromOpenId() string {
+	if x != nil {
+		return x.FromOpenId
+	}
+	return ""
+}
+
 type TokenReply struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -523,64 +539,75 @@ var file_account_proto_rawDesc = []byte{
 	0x0a, 0x0d, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12,
 	0x0b, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x1a, 0x1c, 0x67, 0x6f,
 	0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74,
-	0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x27, 0x0a, 0x0d, 0x4f, 0x70,
-	0x65, 0x6e, 0x49, 0x44, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x6f,
-	0x70, 0x65, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6f, 0x70, 0x65,
-	0x6e, 0x49, 0x64, 0x22, 0x32, 0x0a, 0x0c, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x49,
-	0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
-	0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
-	0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x96, 0x01, 0x0a, 0x0a, 0x55, 0x73, 0x65, 0x72,
-	0x49, 0x6e, 0x66, 0x6f, 0x44, 0x42, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01,
-	0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61,
-	0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61,
-	0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18,
-	0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c,
-	0x12, 0x14, 0x0a, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52,
-	0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x78, 0x18, 0x05, 0x20,
-	0x01, 0x28, 0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x72, 0x65, 0x64,
-	0x69, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74,
-	0x22, 0x99, 0x01, 0x0a, 0x0d, 0x50, 0x61, 0x72, 0x74, 0x6e, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f,
-	0x44, 0x42, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02,
-	0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1c,
-	0x0a, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28,
-	0x09, 0x52, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x14, 0x0a, 0x05,
-	0x70, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x68, 0x6f,
-	0x6e, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52,
-	0x03, 0x73, 0x65, 0x78, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74, 0x18, 0x06,
-	0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74, 0x22, 0x58, 0x0a, 0x14,
-	0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71,
-	0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x6a, 0x73, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6a, 0x73, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x05,
-	0x61, 0x70, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x61, 0x70, 0x70,
-	0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
-	0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x22, 0x0a, 0x0a, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52,
-	0x65, 0x70, 0x6c, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20,
-	0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x37, 0x0a, 0x11, 0x44, 0x65,
-	0x62, 0x75, 0x67, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12,
-	0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12,
-	0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63,
-	0x6f, 0x64, 0x65, 0x22, 0x32, 0x0a, 0x0a, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x54, 0x6f, 0x6b, 0x65,
-	0x6e, 0x12, 0x10, 0x0a, 0x03, 0x70, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
-	0x70, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
-	0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x32, 0xad, 0x02, 0x0a, 0x07, 0x41, 0x63, 0x63, 0x6f,
-	0x75, 0x6e, 0x74, 0x12, 0x62, 0x0a, 0x0a, 0x44, 0x65, 0x62, 0x75, 0x67, 0x4c, 0x6f, 0x67, 0x69,
-	0x6e, 0x12, 0x1e, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e,
-	0x44, 0x65, 0x62, 0x75, 0x67, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
-	0x74, 0x1a, 0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e,
-	0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93,
-	0x02, 0x15, 0x22, 0x10, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x2f, 0x64,
-	0x65, 0x62, 0x75, 0x67, 0x3a, 0x01, 0x2a, 0x12, 0x70, 0x0a, 0x0d, 0x41, 0x75, 0x74, 0x68, 0x6f,
-	0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61,
-	0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61,
-	0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x61, 0x70,
-	0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52,
-	0x65, 0x70, 0x6c, 0x79, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x22, 0x18, 0x2f, 0x61,
-	0x70, 0x69, 0x2f, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x2f, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69,
-	0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x3a, 0x01, 0x2a, 0x12, 0x4c, 0x0a, 0x13, 0x47, 0x65, 0x74,
-	0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x42, 0x79, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x44,
-	0x12, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x4f,
-	0x70, 0x65, 0x6e, 0x49, 0x44, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x61,
+	0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x45, 0x0a, 0x15, 0x4f, 0x70,
+	0x65, 0x6e, 0x49, 0x44, 0x41, 0x6e, 0x64, 0x41, 0x70, 0x70, 0x49, 0x44, 0x52, 0x65, 0x71, 0x75,
+	0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x70, 0x65, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x06, 0x6f, 0x70, 0x65, 0x6e, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x61,
+	0x70, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x61, 0x70, 0x70, 0x49,
+	0x64, 0x22, 0x32, 0x0a, 0x0c, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x49, 0x6e, 0x66,
+	0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69,
+	0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
+	0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x96, 0x01, 0x0a, 0x0a, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e,
+	0x66, 0x6f, 0x44, 0x42, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65,
+	0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65,
+	0x12, 0x1c, 0x0a, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18, 0x03, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x14,
+	0x0a, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70,
+	0x68, 0x6f, 0x6e, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28,
+	0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74,
+	0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74, 0x22, 0x99,
+	0x01, 0x0a, 0x0d, 0x50, 0x61, 0x72, 0x74, 0x6e, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x44, 0x42,
+	0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64,
+	0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01,
+	0x28, 0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09,
+	0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52,
+	0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x68,
+	0x6f, 0x6e, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65,
+	0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x73,
+	0x65, 0x78, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74, 0x18, 0x06, 0x20, 0x01,
+	0x28, 0x03, 0x52, 0x06, 0x63, 0x72, 0x65, 0x64, 0x69, 0x74, 0x22, 0x78, 0x0a, 0x14, 0x41, 0x75,
+	0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x6a, 0x73, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01,
+	0x28, 0x09, 0x52, 0x06, 0x6a, 0x73, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x61, 0x70,
+	0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x61, 0x70, 0x70, 0x49, 0x64,
+	0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
+	0x74, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x66, 0x72, 0x6f, 0x6d, 0x4f, 0x70, 0x65, 0x6e,
+	0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x66, 0x72, 0x6f, 0x6d, 0x4f, 0x70,
+	0x65, 0x6e, 0x49, 0x64, 0x22, 0x22, 0x0a, 0x0a, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x70,
+	0x6c, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x37, 0x0a, 0x11, 0x44, 0x65, 0x62, 0x75,
+	0x67, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a,
+	0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a,
+	0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64,
+	0x65, 0x22, 0x32, 0x0a, 0x0a, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12,
+	0x10, 0x0a, 0x03, 0x70, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x70, 0x69,
+	0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
+	0x04, 0x74, 0x79, 0x70, 0x65, 0x32, 0x9f, 0x03, 0x0a, 0x07, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e,
+	0x74, 0x12, 0x62, 0x0a, 0x0a, 0x44, 0x65, 0x62, 0x75, 0x67, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x12,
+	0x1e, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x44, 0x65,
+	0x62, 0x75, 0x67, 0x4c, 0x6f, 0x67, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
+	0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x54, 0x6f,
+	0x6b, 0x65, 0x6e, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x15,
+	0x22, 0x10, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x2f, 0x64, 0x65, 0x62,
+	0x75, 0x67, 0x3a, 0x01, 0x2a, 0x12, 0x70, 0x0a, 0x0d, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69,
+	0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63,
+	0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69,
+	0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e,
+	0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x70,
+	0x6c, 0x79, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x22, 0x18, 0x2f, 0x61, 0x70, 0x69,
+	0x2f, 0x6c, 0x6f, 0x67, 0x69, 0x6e, 0x2f, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61,
+	0x74, 0x69, 0x6f, 0x6e, 0x3a, 0x01, 0x2a, 0x12, 0x5c, 0x0a, 0x1b, 0x47, 0x65, 0x74, 0x49, 0x64,
+	0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x42, 0x79, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x44, 0x41, 0x6e,
+	0x64, 0x41, 0x70, 0x70, 0x49, 0x44, 0x12, 0x22, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61, 0x63, 0x63,
+	0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x44, 0x41, 0x6e, 0x64, 0x41, 0x70,
+	0x70, 0x49, 0x44, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x61, 0x70, 0x69,
+	0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74,
+	0x79, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x60, 0x0a, 0x1f, 0x47, 0x65, 0x74, 0x49, 0x64, 0x65, 0x6e,
+	0x74, 0x69, 0x74, 0x79, 0x42, 0x79, 0x46, 0x72, 0x6f, 0x6d, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x44,
+	0x41, 0x6e, 0x64, 0x41, 0x70, 0x70, 0x49, 0x44, 0x12, 0x22, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x61,
+	0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x44, 0x41, 0x6e, 0x64,
+	0x41, 0x70, 0x70, 0x49, 0x44, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x61,
 	0x70, 0x69, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74,
 	0x69, 0x74, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x46, 0x0a, 0x0b, 0x61, 0x70, 0x69, 0x2e, 0x61,
 	0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x50, 0x01, 0x5a, 0x35, 0x67, 0x69, 0x74, 0x2e, 0x69, 0x6b,
@@ -604,24 +631,26 @@ func file_account_proto_rawDescGZIP() []byte {
 
 var file_account_proto_msgTypes = make([]protoimpl.MessageInfo, 8)
 var file_account_proto_goTypes = []interface{}{
-	(*OpenIDRequest)(nil),        // 0: api.account.OpenIDRequest
-	(*IdentityInfo)(nil),         // 1: api.account.IdentityInfo
-	(*UserInfoDB)(nil),           // 2: api.account.UserInfoDB
-	(*PartnerInfoDB)(nil),        // 3: api.account.PartnerInfoDB
-	(*AuthorizationRequest)(nil), // 4: api.account.AuthorizationRequest
-	(*TokenReply)(nil),           // 5: api.account.TokenReply
-	(*DebugLoginRequest)(nil),    // 6: api.account.DebugLoginRequest
-	(*LoginToken)(nil),           // 7: api.account.LoginToken
+	(*OpenIDAndAppIDRequest)(nil), // 0: api.account.OpenIDAndAppIDRequest
+	(*IdentityInfo)(nil),          // 1: api.account.IdentityInfo
+	(*UserInfoDB)(nil),            // 2: api.account.UserInfoDB
+	(*PartnerInfoDB)(nil),         // 3: api.account.PartnerInfoDB
+	(*AuthorizationRequest)(nil),  // 4: api.account.AuthorizationRequest
+	(*TokenReply)(nil),            // 5: api.account.TokenReply
+	(*DebugLoginRequest)(nil),     // 6: api.account.DebugLoginRequest
+	(*LoginToken)(nil),            // 7: api.account.LoginToken
 }
 var file_account_proto_depIdxs = []int32{
 	6, // 0: api.account.Account.DebugLogin:input_type -> api.account.DebugLoginRequest
 	4, // 1: api.account.Account.Authorization:input_type -> api.account.AuthorizationRequest
-	0, // 2: api.account.Account.GetIdentityByOpenID:input_type -> api.account.OpenIDRequest
-	5, // 3: api.account.Account.DebugLogin:output_type -> api.account.TokenReply
-	5, // 4: api.account.Account.Authorization:output_type -> api.account.TokenReply
-	1, // 5: api.account.Account.GetIdentityByOpenID:output_type -> api.account.IdentityInfo
-	3, // [3:6] is the sub-list for method output_type
-	0, // [0:3] is the sub-list for method input_type
+	0, // 2: api.account.Account.GetIdentityByOpenIDAndAppID:input_type -> api.account.OpenIDAndAppIDRequest
+	0, // 3: api.account.Account.GetIdentityByFromOpenIDAndAppID:input_type -> api.account.OpenIDAndAppIDRequest
+	5, // 4: api.account.Account.DebugLogin:output_type -> api.account.TokenReply
+	5, // 5: api.account.Account.Authorization:output_type -> api.account.TokenReply
+	1, // 6: api.account.Account.GetIdentityByOpenIDAndAppID:output_type -> api.account.IdentityInfo
+	1, // 7: api.account.Account.GetIdentityByFromOpenIDAndAppID:output_type -> api.account.IdentityInfo
+	4, // [4:8] is the sub-list for method output_type
+	0, // [0:4] is the sub-list for method input_type
 	0, // [0:0] is the sub-list for extension type_name
 	0, // [0:0] is the sub-list for extension extendee
 	0, // [0:0] is the sub-list for field type_name
@@ -634,7 +663,7 @@ func file_account_proto_init() {
 	}
 	if !protoimpl.UnsafeEnabled {
 		file_account_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
-			switch v := v.(*OpenIDRequest); i {
+			switch v := v.(*OpenIDAndAppIDRequest); i {
 			case 0:
 				return &v.state
 			case 1:

+ 7 - 2
api/account/account.proto

@@ -24,10 +24,14 @@ service Account {
       body:"*"
     };
   };
-  rpc GetIdentityByOpenID (OpenIDRequest) returns (IdentityInfo);
+  // 通过openID和appID查询
+  rpc GetIdentityByOpenIDAndAppID (OpenIDAndAppIDRequest) returns (IdentityInfo);
+  // 通过原公众号openID和appID查询
+  rpc GetIdentityByFromOpenIDAndAppID (OpenIDAndAppIDRequest) returns (IdentityInfo);
 }
-message OpenIDRequest{
+message OpenIDAndAppIDRequest{
   string openId = 1;
+  string appId = 2;
 }
 
 message IdentityInfo{
@@ -57,6 +61,7 @@ message AuthorizationRequest {
   string jsCode = 1;
   string appId = 2;
   string type = 3;
+  string fromOpenId = 4;
 }
 
 message TokenReply {

+ 53 - 13
api/account/account_grpc.pb.go

@@ -20,7 +20,10 @@ const _ = grpc.SupportPackageIsVersion7
 type AccountClient interface {
 	DebugLogin(ctx context.Context, in *DebugLoginRequest, opts ...grpc.CallOption) (*TokenReply, error)
 	Authorization(ctx context.Context, in *AuthorizationRequest, opts ...grpc.CallOption) (*TokenReply, error)
-	GetIdentityByOpenID(ctx context.Context, in *OpenIDRequest, opts ...grpc.CallOption) (*IdentityInfo, error)
+	// 通过openID和appID查询
+	GetIdentityByOpenIDAndAppID(ctx context.Context, in *OpenIDAndAppIDRequest, opts ...grpc.CallOption) (*IdentityInfo, error)
+	// 通过原公众号openID和appID查询
+	GetIdentityByFromOpenIDAndAppID(ctx context.Context, in *OpenIDAndAppIDRequest, opts ...grpc.CallOption) (*IdentityInfo, error)
 }
 
 type accountClient struct {
@@ -49,9 +52,18 @@ func (c *accountClient) Authorization(ctx context.Context, in *AuthorizationRequ
 	return out, nil
 }
 
-func (c *accountClient) GetIdentityByOpenID(ctx context.Context, in *OpenIDRequest, opts ...grpc.CallOption) (*IdentityInfo, error) {
+func (c *accountClient) GetIdentityByOpenIDAndAppID(ctx context.Context, in *OpenIDAndAppIDRequest, opts ...grpc.CallOption) (*IdentityInfo, error) {
 	out := new(IdentityInfo)
-	err := c.cc.Invoke(ctx, "/api.account.Account/GetIdentityByOpenID", in, out, opts...)
+	err := c.cc.Invoke(ctx, "/api.account.Account/GetIdentityByOpenIDAndAppID", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
+func (c *accountClient) GetIdentityByFromOpenIDAndAppID(ctx context.Context, in *OpenIDAndAppIDRequest, opts ...grpc.CallOption) (*IdentityInfo, error) {
+	out := new(IdentityInfo)
+	err := c.cc.Invoke(ctx, "/api.account.Account/GetIdentityByFromOpenIDAndAppID", in, out, opts...)
 	if err != nil {
 		return nil, err
 	}
@@ -64,7 +76,10 @@ func (c *accountClient) GetIdentityByOpenID(ctx context.Context, in *OpenIDReque
 type AccountServer interface {
 	DebugLogin(context.Context, *DebugLoginRequest) (*TokenReply, error)
 	Authorization(context.Context, *AuthorizationRequest) (*TokenReply, error)
-	GetIdentityByOpenID(context.Context, *OpenIDRequest) (*IdentityInfo, error)
+	// 通过openID和appID查询
+	GetIdentityByOpenIDAndAppID(context.Context, *OpenIDAndAppIDRequest) (*IdentityInfo, error)
+	// 通过原公众号openID和appID查询
+	GetIdentityByFromOpenIDAndAppID(context.Context, *OpenIDAndAppIDRequest) (*IdentityInfo, error)
 	mustEmbedUnimplementedAccountServer()
 }
 
@@ -78,8 +93,11 @@ func (UnimplementedAccountServer) DebugLogin(context.Context, *DebugLoginRequest
 func (UnimplementedAccountServer) Authorization(context.Context, *AuthorizationRequest) (*TokenReply, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method Authorization not implemented")
 }
-func (UnimplementedAccountServer) GetIdentityByOpenID(context.Context, *OpenIDRequest) (*IdentityInfo, error) {
-	return nil, status.Errorf(codes.Unimplemented, "method GetIdentityByOpenID not implemented")
+func (UnimplementedAccountServer) GetIdentityByOpenIDAndAppID(context.Context, *OpenIDAndAppIDRequest) (*IdentityInfo, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method GetIdentityByOpenIDAndAppID not implemented")
+}
+func (UnimplementedAccountServer) GetIdentityByFromOpenIDAndAppID(context.Context, *OpenIDAndAppIDRequest) (*IdentityInfo, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method GetIdentityByFromOpenIDAndAppID not implemented")
 }
 func (UnimplementedAccountServer) mustEmbedUnimplementedAccountServer() {}
 
@@ -130,20 +148,38 @@ func _Account_Authorization_Handler(srv interface{}, ctx context.Context, dec fu
 	return interceptor(ctx, in, info, handler)
 }
 
-func _Account_GetIdentityByOpenID_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
-	in := new(OpenIDRequest)
+func _Account_GetIdentityByOpenIDAndAppID_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(OpenIDAndAppIDRequest)
 	if err := dec(in); err != nil {
 		return nil, err
 	}
 	if interceptor == nil {
-		return srv.(AccountServer).GetIdentityByOpenID(ctx, in)
+		return srv.(AccountServer).GetIdentityByOpenIDAndAppID(ctx, in)
 	}
 	info := &grpc.UnaryServerInfo{
 		Server:     srv,
-		FullMethod: "/api.account.Account/GetIdentityByOpenID",
+		FullMethod: "/api.account.Account/GetIdentityByOpenIDAndAppID",
 	}
 	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
-		return srv.(AccountServer).GetIdentityByOpenID(ctx, req.(*OpenIDRequest))
+		return srv.(AccountServer).GetIdentityByOpenIDAndAppID(ctx, req.(*OpenIDAndAppIDRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
+func _Account_GetIdentityByFromOpenIDAndAppID_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(OpenIDAndAppIDRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(AccountServer).GetIdentityByFromOpenIDAndAppID(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/api.account.Account/GetIdentityByFromOpenIDAndAppID",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(AccountServer).GetIdentityByFromOpenIDAndAppID(ctx, req.(*OpenIDAndAppIDRequest))
 	}
 	return interceptor(ctx, in, info, handler)
 }
@@ -164,8 +200,12 @@ var Account_ServiceDesc = grpc.ServiceDesc{
 			Handler:    _Account_Authorization_Handler,
 		},
 		{
-			MethodName: "GetIdentityByOpenID",
-			Handler:    _Account_GetIdentityByOpenID_Handler,
+			MethodName: "GetIdentityByOpenIDAndAppID",
+			Handler:    _Account_GetIdentityByOpenIDAndAppID_Handler,
+		},
+		{
+			MethodName: "GetIdentityByFromOpenIDAndAppID",
+			Handler:    _Account_GetIdentityByFromOpenIDAndAppID_Handler,
 		},
 	},
 	Streams:  []grpc.StreamDesc{},

+ 84 - 45
api/common/common.pb.go

@@ -413,11 +413,15 @@ type AddFriendMessageInfo struct {
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
 
-	Id        string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id"`               // id
-	Nickname  string   `protobuf:"bytes,2,opt,name=nickname,proto3" json:"nickname"`   // 昵称
-	AvatarUrl string   `protobuf:"bytes,3,opt,name=avatarUrl,proto3" json:"avatarUrl"` // 头像链接
-	Sex       int64    `protobuf:"varint,4,opt,name=sex,proto3" json:"sex"`            // 性别
-	Pictures  []string `protobuf:"bytes,5,rep,name=pictures,proto3" json:"pictures"`   // 图片
+	Id         string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id"`                  // id
+	Nickname   string   `protobuf:"bytes,2,opt,name=nickname,proto3" json:"nickname"`      // 昵称
+	AvatarUrl  string   `protobuf:"bytes,3,opt,name=avatarUrl,proto3" json:"avatarUrl"`    // 头像链接
+	Sex        int64    `protobuf:"varint,4,opt,name=sex,proto3" json:"sex"`               // 性别
+	Pictures   []string `protobuf:"bytes,5,rep,name=pictures,proto3" json:"pictures"`      // 图片
+	FromOpenId string   `protobuf:"bytes,6,opt,name=fromOpenId,proto3" json:"fromOpenId"`  // 来源公众号对应的openID
+	IsRegister bool     `protobuf:"varint,7,opt,name=isRegister,proto3" json:"isRegister"` // 是否注册
+	IsChat     bool     `protobuf:"varint,8,opt,name=isChat,proto3" json:"isChat"`         // 是否聊天
+	IsFromUs   bool     `protobuf:"varint,9,opt,name=isFromUs,proto3" json:"isFromUs"`     // 是否是来源我们
 }
 
 func (x *AddFriendMessageInfo) Reset() {
@@ -487,6 +491,34 @@ func (x *AddFriendMessageInfo) GetPictures() []string {
 	return nil
 }
 
+func (x *AddFriendMessageInfo) GetFromOpenId() string {
+	if x != nil {
+		return x.FromOpenId
+	}
+	return ""
+}
+
+func (x *AddFriendMessageInfo) GetIsRegister() bool {
+	if x != nil {
+		return x.IsRegister
+	}
+	return false
+}
+
+func (x *AddFriendMessageInfo) GetIsChat() bool {
+	if x != nil {
+		return x.IsChat
+	}
+	return false
+}
+
+func (x *AddFriendMessageInfo) GetIsFromUs() bool {
+	if x != nil {
+		return x.IsFromUs
+	}
+	return false
+}
+
 type PersonIDList struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -891,7 +923,7 @@ var file_common_proto_rawDesc = []byte{
 	0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65,
 	0x12, 0x26, 0x0a, 0x0e, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x56, 0x6f, 0x69,
 	0x63, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64,
-	0x75, 0x63, 0x65, 0x56, 0x6f, 0x69, 0x63, 0x65, 0x22, 0x8e, 0x01, 0x0a, 0x14, 0x41, 0x64, 0x64,
+	0x75, 0x63, 0x65, 0x56, 0x6f, 0x69, 0x63, 0x65, 0x22, 0x82, 0x02, 0x0a, 0x14, 0x41, 0x64, 0x64,
 	0x46, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x49, 0x6e, 0x66,
 	0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69,
 	0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20,
@@ -900,45 +932,52 @@ var file_common_proto_rawDesc = []byte{
 	0x52, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x10, 0x0a, 0x03, 0x73,
 	0x65, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x12, 0x1a, 0x0a,
 	0x08, 0x70, 0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52,
-	0x08, 0x70, 0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x22, 0x2c, 0x0a, 0x0c, 0x50, 0x65, 0x72,
-	0x73, 0x6f, 0x6e, 0x49, 0x44, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x65, 0x72,
-	0x73, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x70, 0x65,
-	0x72, 0x73, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x22, 0x39, 0x0a, 0x0d, 0x50, 0x65, 0x72, 0x73, 0x6f,
-	0x6e, 0x44, 0x42, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x28, 0x0a, 0x04, 0x6c, 0x69, 0x73, 0x74,
-	0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d,
-	0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x44, 0x42, 0x52, 0x04, 0x6c, 0x69,
-	0x73, 0x74, 0x22, 0xf6, 0x01, 0x0a, 0x08, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x44, 0x42, 0x12,
-	0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12,
-	0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
-	0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61,
-	0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09,
-	0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x78,
-	0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x12, 0x1a, 0x0a, 0x08, 0x70,
-	0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x70,
-	0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x61, 0x67, 0x65, 0x18, 0x06,
-	0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x61, 0x67, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x63, 0x6f, 0x6e,
-	0x73, 0x74, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09,
-	0x52, 0x0d, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12,
-	0x12, 0x0a, 0x04, 0x61, 0x72, 0x65, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x61,
-	0x72, 0x65, 0x61, 0x12, 0x26, 0x0a, 0x0e, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65,
-	0x56, 0x6f, 0x69, 0x63, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x69, 0x6e, 0x74,
-	0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x56, 0x6f, 0x69, 0x63, 0x65, 0x22, 0x41, 0x0a, 0x0f, 0x4c,
-	0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16,
-	0x0a, 0x06, 0x6e, 0x65, 0x78, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06,
-	0x6e, 0x65, 0x78, 0x74, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74,
-	0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0x2c,
-	0x0a, 0x14, 0x53, 0x65, 0x6e, 0x64, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x43, 0x6f, 0x64, 0x65, 0x52,
-	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x18,
-	0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x22, 0x41, 0x0a, 0x15,
-	0x43, 0x68, 0x65, 0x63, 0x6b, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x65,
-	0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x01,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x63,
-	0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x42,
-	0x43, 0x0a, 0x0a, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x50, 0x01, 0x5a,
-	0x33, 0x67, 0x69, 0x74, 0x2e, 0x69, 0x6b, 0x75, 0x62, 0x61, 0x6e, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
-	0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x77, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,
-	0x75, 0x66, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x3b, 0x63, 0x6f,
-	0x6d, 0x6d, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x08, 0x70, 0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x66, 0x72, 0x6f,
+	0x6d, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x66,
+	0x72, 0x6f, 0x6d, 0x4f, 0x70, 0x65, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x73, 0x52,
+	0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69,
+	0x73, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x43,
+	0x68, 0x61, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x43, 0x68, 0x61,
+	0x74, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x73, 0x46, 0x72, 0x6f, 0x6d, 0x55, 0x73, 0x18, 0x09, 0x20,
+	0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x46, 0x72, 0x6f, 0x6d, 0x55, 0x73, 0x22, 0x2c, 0x0a,
+	0x0c, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x49, 0x44, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1c, 0x0a,
+	0x09, 0x70, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09,
+	0x52, 0x09, 0x70, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x49, 0x64, 0x73, 0x22, 0x39, 0x0a, 0x0d, 0x50,
+	0x65, 0x72, 0x73, 0x6f, 0x6e, 0x44, 0x42, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x28, 0x0a, 0x04,
+	0x6c, 0x69, 0x73, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x61, 0x70, 0x69,
+	0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x44, 0x42,
+	0x52, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x22, 0xf6, 0x01, 0x0a, 0x08, 0x50, 0x65, 0x72, 0x73, 0x6f,
+	0x6e, 0x44, 0x42, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
+	0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x18,
+	0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x12,
+	0x1c, 0x0a, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18, 0x03, 0x20, 0x01,
+	0x28, 0x09, 0x52, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x10, 0x0a,
+	0x03, 0x73, 0x65, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x12,
+	0x1a, 0x0a, 0x08, 0x70, 0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28,
+	0x09, 0x52, 0x08, 0x70, 0x69, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x61,
+	0x67, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x61, 0x67, 0x65, 0x12, 0x24, 0x0a,
+	0x0d, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x65, 0x6c, 0x6c, 0x61, 0x74,
+	0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x72, 0x65, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x04, 0x61, 0x72, 0x65, 0x61, 0x12, 0x26, 0x0a, 0x0e, 0x69, 0x6e, 0x74, 0x72, 0x6f,
+	0x64, 0x75, 0x63, 0x65, 0x56, 0x6f, 0x69, 0x63, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52,
+	0x0e, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x56, 0x6f, 0x69, 0x63, 0x65, 0x22,
+	0x41, 0x0a, 0x0f, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x65, 0x78, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01,
+	0x28, 0x03, 0x52, 0x06, 0x6e, 0x65, 0x78, 0x74, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x66,
+	0x66, 0x73, 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x6f, 0x66, 0x66, 0x73,
+	0x65, 0x74, 0x22, 0x2c, 0x0a, 0x14, 0x53, 0x65, 0x6e, 0x64, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x43,
+	0x6f, 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x68,
+	0x6f, 0x6e, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65,
+	0x22, 0x41, 0x0a, 0x15, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x43, 0x6f,
+	0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x68, 0x6f,
+	0x6e, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x68, 0x6f, 0x6e, 0x65, 0x12,
+	0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63,
+	0x6f, 0x64, 0x65, 0x42, 0x43, 0x0a, 0x0a, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
+	0x6e, 0x50, 0x01, 0x5a, 0x33, 0x67, 0x69, 0x74, 0x2e, 0x69, 0x6b, 0x75, 0x62, 0x61, 0x6e, 0x2e,
+	0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x77, 0x2d, 0x70, 0x72,
+	0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
+	0x6e, 0x3b, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (

+ 4 - 0
api/common/common.proto

@@ -55,6 +55,10 @@ message AddFriendMessageInfo{
   string avatarUrl =3;// 头像链接
   int64 sex = 4;// 性别
   repeated string pictures = 5; // 图片
+  string fromOpenId = 6;// 来源公众号对应的openID
+  bool isRegister = 7;// 是否注册
+  bool isChat = 8;// 是否聊天
+  bool isFromUs = 9;// 是否是来源我们
 }
 
 message PersonIDList{

+ 160 - 98
api/user/user.pb.go

@@ -175,6 +175,53 @@ func (x *UpdateUserInformationRequest) GetSex() int64 {
 	return 0
 }
 
+type KeyRequest struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key"`
+}
+
+func (x *KeyRequest) Reset() {
+	*x = KeyRequest{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_user_proto_msgTypes[2]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *KeyRequest) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*KeyRequest) ProtoMessage() {}
+
+func (x *KeyRequest) ProtoReflect() protoreflect.Message {
+	mi := &file_user_proto_msgTypes[2]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use KeyRequest.ProtoReflect.Descriptor instead.
+func (*KeyRequest) Descriptor() ([]byte, []int) {
+	return file_user_proto_rawDescGZIP(), []int{2}
+}
+
+func (x *KeyRequest) GetKey() string {
+	if x != nil {
+		return x.Key
+	}
+	return ""
+}
+
 var File_user_proto protoreflect.FileDescriptor
 
 var file_user_proto_rawDesc = []byte{
@@ -203,8 +250,10 @@ var file_user_proto_rawDesc = []byte{
 	0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4e, 0x69, 0x63, 0x6b, 0x6e, 0x61, 0x6d, 0x65, 0x12,
 	0x1c, 0x0a, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x18, 0x02, 0x20, 0x01,
 	0x28, 0x09, 0x52, 0x09, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x55, 0x72, 0x6c, 0x12, 0x10, 0x0a,
-	0x03, 0x73, 0x65, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x32,
-	0xd5, 0x0c, 0x0a, 0x04, 0x55, 0x73, 0x65, 0x72, 0x12, 0x80, 0x01, 0x0a, 0x15, 0x55, 0x70, 0x64,
+	0x03, 0x73, 0x65, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x73, 0x65, 0x78, 0x22,
+	0x1e, 0x0a, 0x0a, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x10, 0x0a,
+	0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x32,
+	0xcf, 0x0c, 0x0a, 0x04, 0x55, 0x73, 0x65, 0x72, 0x12, 0x80, 0x01, 0x0a, 0x15, 0x55, 0x70, 0x64,
 	0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69,
 	0x6f, 0x6e, 0x12, 0x26, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x75, 0x73, 0x65, 0x72, 0x2e, 0x55, 0x70,
 	0x64, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74,
@@ -257,59 +306,59 @@ var file_user_proto_rawDesc = []byte{
 	0x69, 0x6f, 0x6e, 0x73, 0x68, 0x69, 0x70, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x28, 0x82, 0xd3,
 	0xe4, 0x93, 0x02, 0x22, 0x22, 0x1d, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f,
 	0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x2f, 0x72, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73,
-	0x68, 0x69, 0x70, 0x3a, 0x01, 0x2a, 0x12, 0x76, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x50, 0x61, 0x72,
-	0x74, 0x6e, 0x65, 0x72, 0x43, 0x69, 0x72, 0x63, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1a,
-	0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x61, 0x72, 0x74,
-	0x6e, 0x65, 0x72, 0x49, 0x44, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x1a, 0x20, 0x2e, 0x61, 0x70, 0x69,
-	0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x41, 0x64, 0x64, 0x46, 0x72, 0x69, 0x65, 0x6e,
-	0x64, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x20, 0x82, 0xd3,
-	0xe4, 0x93, 0x02, 0x1a, 0x22, 0x15, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f,
-	0x63, 0x69, 0x72, 0x63, 0x6c, 0x65, 0x2f, 0x69, 0x6e, 0x66, 0x6f, 0x3a, 0x01, 0x2a, 0x12, 0x5b,
-	0x0a, 0x0f, 0x55, 0x73, 0x65, 0x72, 0x47, 0x65, 0x74, 0x48, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66,
-	0x6f, 0x12, 0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50,
-	0x65, 0x72, 0x73, 0x6f, 0x6e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x1a, 0x14, 0x2e, 0x61, 0x70, 0x69,
-	0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x48, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f,
-	0x22, 0x19, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x13, 0x22, 0x0e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75,
-	0x73, 0x65, 0x72, 0x2f, 0x68, 0x6f, 0x6d, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x45, 0x0a, 0x0e, 0x46,
-	0x69, 0x6e, 0x64, 0x55, 0x73, 0x65, 0x72, 0x44, 0x42, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x18, 0x2e,
-	0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f,
-	0x6e, 0x49, 0x44, 0x4c, 0x69, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f,
-	0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x44, 0x42, 0x52, 0x65, 0x70,
-	0x6c, 0x79, 0x12, 0x71, 0x0a, 0x0c, 0x46, 0x69, 0x6e, 0x64, 0x4c, 0x6f, 0x6f, 0x6b, 0x4c, 0x69,
-	0x73, 0x74, 0x12, 0x1b, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e,
-	0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
-	0x24, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73,
-	0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4c, 0x69, 0x73, 0x74,
-	0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x22, 0x13, 0x2f,
-	0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x6c, 0x6f,
-	0x6f, 0x6b, 0x3a, 0x01, 0x2a, 0x12, 0x71, 0x0a, 0x0c, 0x46, 0x69, 0x6e, 0x64, 0x4c, 0x69, 0x6b,
-	0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1b, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d,
-	0x6f, 0x6e, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
-	0x73, 0x74, 0x1a, 0x24, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74,
-	0x69, 0x63, 0x73, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4c,
-	0x69, 0x73, 0x74, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18,
-	0x22, 0x13, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x6c, 0x69, 0x73, 0x74,
-	0x2f, 0x6c, 0x69, 0x6b, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x73, 0x0a, 0x0d, 0x46, 0x69, 0x6e, 0x64,
-	0x4c, 0x69, 0x6b, 0x65, 0x64, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1b, 0x2e, 0x61, 0x70, 0x69, 0x2e,
-	0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52,
-	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x73, 0x74, 0x61,
-	0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c,
-	0x69, 0x6b, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1f, 0x82, 0xd3,
-	0xe4, 0x93, 0x02, 0x19, 0x22, 0x14, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f,
-	0x6c, 0x69, 0x73, 0x74, 0x2f, 0x6c, 0x69, 0x6b, 0x65, 0x64, 0x3a, 0x01, 0x2a, 0x12, 0x87, 0x01,
-	0x0a, 0x1f, 0x47, 0x65, 0x74, 0x4c, 0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65,
-	0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67,
-	0x65, 0x12, 0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50,
-	0x65, 0x72, 0x73, 0x6f, 0x6e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x1a, 0x27, 0x2e, 0x61, 0x70, 0x69,
-	0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b,
-	0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65,
-	0x70, 0x6c, 0x79, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x22, 0x17, 0x2f, 0x61, 0x70,
-	0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x6e, 0x75, 0x6d, 0x2f, 0x6c, 0x69, 0x6b, 0x65, 0x5f,
-	0x6c, 0x6f, 0x6f, 0x6b, 0x3a, 0x01, 0x2a, 0x42, 0x3d, 0x0a, 0x08, 0x61, 0x70, 0x69, 0x2e, 0x75,
-	0x73, 0x65, 0x72, 0x50, 0x01, 0x5a, 0x2f, 0x67, 0x69, 0x74, 0x2e, 0x69, 0x6b, 0x75, 0x62, 0x61,
-	0x6e, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x77, 0x2d,
-	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65,
-	0x72, 0x3b, 0x75, 0x73, 0x65, 0x72, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x68, 0x69, 0x70, 0x3a, 0x01, 0x2a, 0x12, 0x70, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x50, 0x61, 0x72,
+	0x74, 0x6e, 0x65, 0x72, 0x43, 0x69, 0x72, 0x63, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x14,
+	0x2e, 0x61, 0x70, 0x69, 0x2e, 0x75, 0x73, 0x65, 0x72, 0x2e, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x71,
+	0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
+	0x6e, 0x2e, 0x41, 0x64, 0x64, 0x46, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61,
+	0x67, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x20, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1a, 0x22, 0x15,
+	0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x63, 0x69, 0x72, 0x63, 0x6c, 0x65,
+	0x2f, 0x69, 0x6e, 0x66, 0x6f, 0x3a, 0x01, 0x2a, 0x12, 0x5b, 0x0a, 0x0f, 0x55, 0x73, 0x65, 0x72,
+	0x47, 0x65, 0x74, 0x48, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x17, 0x2e, 0x61, 0x70,
+	0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x50,
+	0x61, 0x72, 0x61, 0x6d, 0x1a, 0x14, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
+	0x6e, 0x2e, 0x48, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x19, 0x82, 0xd3, 0xe4, 0x93,
+	0x02, 0x13, 0x22, 0x0e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x68, 0x6f,
+	0x6d, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x45, 0x0a, 0x0e, 0x46, 0x69, 0x6e, 0x64, 0x55, 0x73, 0x65,
+	0x72, 0x44, 0x42, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x18, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f,
+	0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x49, 0x44, 0x4c, 0x69, 0x73,
+	0x74, 0x1a, 0x19, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50,
+	0x65, 0x72, 0x73, 0x6f, 0x6e, 0x44, 0x42, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x71, 0x0a, 0x0c,
+	0x46, 0x69, 0x6e, 0x64, 0x4c, 0x6f, 0x6f, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1b, 0x2e, 0x61,
+	0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61,
+	0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x61, 0x70, 0x69, 0x2e,
+	0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x41,
+	0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22,
+	0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x22, 0x13, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73,
+	0x65, 0x72, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x6c, 0x6f, 0x6f, 0x6b, 0x3a, 0x01, 0x2a, 0x12,
+	0x71, 0x0a, 0x0c, 0x46, 0x69, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12,
+	0x1b, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x4c, 0x69, 0x73,
+	0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x61,
+	0x70, 0x69, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x4c, 0x6f,
+	0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x70,
+	0x6c, 0x79, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x22, 0x13, 0x2f, 0x61, 0x70, 0x69,
+	0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x6c, 0x69, 0x6b, 0x65, 0x3a,
+	0x01, 0x2a, 0x12, 0x73, 0x0a, 0x0d, 0x46, 0x69, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x64, 0x4c,
+	0x69, 0x73, 0x74, 0x12, 0x1b, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e,
+	0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
+	0x1a, 0x24, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63,
+	0x73, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x4c, 0x69, 0x73,
+	0x74, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x19, 0x22, 0x14,
+	0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x6c,
+	0x69, 0x6b, 0x65, 0x64, 0x3a, 0x01, 0x2a, 0x12, 0x87, 0x01, 0x0a, 0x1f, 0x47, 0x65, 0x74, 0x4c,
+	0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b, 0x65, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73,
+	0x74, 0x69, 0x63, 0x73, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x17, 0x2e, 0x61, 0x70,
+	0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x50,
+	0x61, 0x72, 0x61, 0x6d, 0x1a, 0x27, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69,
+	0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x41, 0x6e, 0x64, 0x4c, 0x69, 0x6b,
+	0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x22, 0x82,
+	0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x22, 0x17, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72,
+	0x2f, 0x6e, 0x75, 0x6d, 0x2f, 0x6c, 0x69, 0x6b, 0x65, 0x5f, 0x6c, 0x6f, 0x6f, 0x6b, 0x3a, 0x01,
+	0x2a, 0x42, 0x3d, 0x0a, 0x08, 0x61, 0x70, 0x69, 0x2e, 0x75, 0x73, 0x65, 0x72, 0x50, 0x01, 0x5a,
+	0x2f, 0x67, 0x69, 0x74, 0x2e, 0x69, 0x6b, 0x75, 0x62, 0x61, 0x6e, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
+	0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x77, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,
+	0x75, 0x66, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x3b, 0x75, 0x73, 0x65, 0x72,
+	0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (
@@ -324,55 +373,56 @@ func file_user_proto_rawDescGZIP() []byte {
 	return file_user_proto_rawDescData
 }
 
-var file_user_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
+var file_user_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
 var file_user_proto_goTypes = []interface{}{
 	(*UserInfo)(nil),                                  // 0: api.user.UserInfo
 	(*UpdateUserInformationRequest)(nil),              // 1: api.user.UpdateUserInformationRequest
-	(*emptypb.Empty)(nil),                             // 2: google.protobuf.Empty
-	(*common.SendPhoneCodeRequest)(nil),               // 3: api.common.SendPhoneCodeRequest
-	(*common.CheckPhoneCodeRequest)(nil),              // 4: api.common.CheckPhoneCodeRequest
-	(*common.PartnerIDParam)(nil),                     // 5: api.common.PartnerIDParam
-	(*common.PersonParam)(nil),                        // 6: api.common.PersonParam
-	(*common.PersonIDList)(nil),                       // 7: api.common.PersonIDList
-	(*common.ListPageRequest)(nil),                    // 8: api.common.ListPageRequest
-	(*statistics.LookMessageReply)(nil),               // 9: api.statistics.LookMessageReply
-	(*chat.CheckUserPartnerIsRelationshipReply)(nil),  // 10: api.chat.CheckUserPartnerIsRelationshipReply
-	(*chat.CreateUserPartnerIsRelationshipReply)(nil), // 11: api.chat.CreateUserPartnerIsRelationshipReply
-	(*common.AddFriendMessageInfo)(nil),               // 12: api.common.AddFriendMessageInfo
-	(*common.HomeInfo)(nil),                           // 13: api.common.HomeInfo
-	(*common.PersonDBReply)(nil),                      // 14: api.common.PersonDBReply
-	(*statistics.LookAndLikeListReply)(nil),           // 15: api.statistics.LookAndLikeListReply
-	(*statistics.LookAndLikeMessageReply)(nil),        // 16: api.statistics.LookAndLikeMessageReply
+	(*KeyRequest)(nil),                                // 2: api.user.KeyRequest
+	(*emptypb.Empty)(nil),                             // 3: google.protobuf.Empty
+	(*common.SendPhoneCodeRequest)(nil),               // 4: api.common.SendPhoneCodeRequest
+	(*common.CheckPhoneCodeRequest)(nil),              // 5: api.common.CheckPhoneCodeRequest
+	(*common.PartnerIDParam)(nil),                     // 6: api.common.PartnerIDParam
+	(*common.PersonParam)(nil),                        // 7: api.common.PersonParam
+	(*common.PersonIDList)(nil),                       // 8: api.common.PersonIDList
+	(*common.ListPageRequest)(nil),                    // 9: api.common.ListPageRequest
+	(*statistics.LookMessageReply)(nil),               // 10: api.statistics.LookMessageReply
+	(*chat.CheckUserPartnerIsRelationshipReply)(nil),  // 11: api.chat.CheckUserPartnerIsRelationshipReply
+	(*chat.CreateUserPartnerIsRelationshipReply)(nil), // 12: api.chat.CreateUserPartnerIsRelationshipReply
+	(*common.AddFriendMessageInfo)(nil),               // 13: api.common.AddFriendMessageInfo
+	(*common.HomeInfo)(nil),                           // 14: api.common.HomeInfo
+	(*common.PersonDBReply)(nil),                      // 15: api.common.PersonDBReply
+	(*statistics.LookAndLikeListReply)(nil),           // 16: api.statistics.LookAndLikeListReply
+	(*statistics.LookAndLikeMessageReply)(nil),        // 17: api.statistics.LookAndLikeMessageReply
 }
 var file_user_proto_depIdxs = []int32{
 	1,  // 0: api.user.User.UpdateUserInformation:input_type -> api.user.UpdateUserInformationRequest
-	2,  // 1: api.user.User.GetUserInfo:input_type -> google.protobuf.Empty
-	2,  // 2: api.user.User.GetUserLookNum:input_type -> google.protobuf.Empty
-	3,  // 3: api.user.User.SendPhoneCode:input_type -> api.common.SendPhoneCodeRequest
-	4,  // 4: api.user.User.CheckPhoneCode:input_type -> api.common.CheckPhoneCodeRequest
-	5,  // 5: api.user.User.CheckUserPartnerIsRelationship:input_type -> api.common.PartnerIDParam
-	5,  // 6: api.user.User.CreateUserPartnerIsRelationship:input_type -> api.common.PartnerIDParam
-	5,  // 7: api.user.User.GetPartnerCircleInfo:input_type -> api.common.PartnerIDParam
-	6,  // 8: api.user.User.UserGetHomeInfo:input_type -> api.common.PersonParam
-	7,  // 9: api.user.User.FindUserDBList:input_type -> api.common.PersonIDList
-	8,  // 10: api.user.User.FindLookList:input_type -> api.common.ListPageRequest
-	8,  // 11: api.user.User.FindLikeList:input_type -> api.common.ListPageRequest
-	8,  // 12: api.user.User.FindLikedList:input_type -> api.common.ListPageRequest
-	6,  // 13: api.user.User.GetLookAndLikeStatisticsMessage:input_type -> api.common.PersonParam
-	2,  // 14: api.user.User.UpdateUserInformation:output_type -> google.protobuf.Empty
+	3,  // 1: api.user.User.GetUserInfo:input_type -> google.protobuf.Empty
+	3,  // 2: api.user.User.GetUserLookNum:input_type -> google.protobuf.Empty
+	4,  // 3: api.user.User.SendPhoneCode:input_type -> api.common.SendPhoneCodeRequest
+	5,  // 4: api.user.User.CheckPhoneCode:input_type -> api.common.CheckPhoneCodeRequest
+	6,  // 5: api.user.User.CheckUserPartnerIsRelationship:input_type -> api.common.PartnerIDParam
+	6,  // 6: api.user.User.CreateUserPartnerIsRelationship:input_type -> api.common.PartnerIDParam
+	2,  // 7: api.user.User.GetPartnerCircleInfo:input_type -> api.user.KeyRequest
+	7,  // 8: api.user.User.UserGetHomeInfo:input_type -> api.common.PersonParam
+	8,  // 9: api.user.User.FindUserDBList:input_type -> api.common.PersonIDList
+	9,  // 10: api.user.User.FindLookList:input_type -> api.common.ListPageRequest
+	9,  // 11: api.user.User.FindLikeList:input_type -> api.common.ListPageRequest
+	9,  // 12: api.user.User.FindLikedList:input_type -> api.common.ListPageRequest
+	7,  // 13: api.user.User.GetLookAndLikeStatisticsMessage:input_type -> api.common.PersonParam
+	3,  // 14: api.user.User.UpdateUserInformation:output_type -> google.protobuf.Empty
 	0,  // 15: api.user.User.GetUserInfo:output_type -> api.user.UserInfo
-	9,  // 16: api.user.User.GetUserLookNum:output_type -> api.statistics.LookMessageReply
-	2,  // 17: api.user.User.SendPhoneCode:output_type -> google.protobuf.Empty
-	2,  // 18: api.user.User.CheckPhoneCode:output_type -> google.protobuf.Empty
-	10, // 19: api.user.User.CheckUserPartnerIsRelationship:output_type -> api.chat.CheckUserPartnerIsRelationshipReply
-	11, // 20: api.user.User.CreateUserPartnerIsRelationship:output_type -> api.chat.CreateUserPartnerIsRelationshipReply
-	12, // 21: api.user.User.GetPartnerCircleInfo:output_type -> api.common.AddFriendMessageInfo
-	13, // 22: api.user.User.UserGetHomeInfo:output_type -> api.common.HomeInfo
-	14, // 23: api.user.User.FindUserDBList:output_type -> api.common.PersonDBReply
-	15, // 24: api.user.User.FindLookList:output_type -> api.statistics.LookAndLikeListReply
-	15, // 25: api.user.User.FindLikeList:output_type -> api.statistics.LookAndLikeListReply
-	15, // 26: api.user.User.FindLikedList:output_type -> api.statistics.LookAndLikeListReply
-	16, // 27: api.user.User.GetLookAndLikeStatisticsMessage:output_type -> api.statistics.LookAndLikeMessageReply
+	10, // 16: api.user.User.GetUserLookNum:output_type -> api.statistics.LookMessageReply
+	3,  // 17: api.user.User.SendPhoneCode:output_type -> google.protobuf.Empty
+	3,  // 18: api.user.User.CheckPhoneCode:output_type -> google.protobuf.Empty
+	11, // 19: api.user.User.CheckUserPartnerIsRelationship:output_type -> api.chat.CheckUserPartnerIsRelationshipReply
+	12, // 20: api.user.User.CreateUserPartnerIsRelationship:output_type -> api.chat.CreateUserPartnerIsRelationshipReply
+	13, // 21: api.user.User.GetPartnerCircleInfo:output_type -> api.common.AddFriendMessageInfo
+	14, // 22: api.user.User.UserGetHomeInfo:output_type -> api.common.HomeInfo
+	15, // 23: api.user.User.FindUserDBList:output_type -> api.common.PersonDBReply
+	16, // 24: api.user.User.FindLookList:output_type -> api.statistics.LookAndLikeListReply
+	16, // 25: api.user.User.FindLikeList:output_type -> api.statistics.LookAndLikeListReply
+	16, // 26: api.user.User.FindLikedList:output_type -> api.statistics.LookAndLikeListReply
+	17, // 27: api.user.User.GetLookAndLikeStatisticsMessage:output_type -> api.statistics.LookAndLikeMessageReply
 	14, // [14:28] is the sub-list for method output_type
 	0,  // [0:14] is the sub-list for method input_type
 	0,  // [0:0] is the sub-list for extension type_name
@@ -410,6 +460,18 @@ func file_user_proto_init() {
 				return nil
 			}
 		}
+		file_user_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*KeyRequest); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
 	}
 	type x struct{}
 	out := protoimpl.TypeBuilder{
@@ -417,7 +479,7 @@ func file_user_proto_init() {
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			RawDescriptor: file_user_proto_rawDesc,
 			NumEnums:      0,
-			NumMessages:   2,
+			NumMessages:   3,
 			NumExtensions: 0,
 			NumServices:   1,
 		},

+ 5 - 1
api/user/user.proto

@@ -64,7 +64,7 @@ service User {
     };
   };
   // 获取接待员的确认通过页面信息
-  rpc GetPartnerCircleInfo (common.PartnerIDParam) returns (common.AddFriendMessageInfo){
+  rpc GetPartnerCircleInfo (KeyRequest) returns (common.AddFriendMessageInfo){
     option (google.api.http) = {
       post: "/api/user/circle/info",
       body:"*"
@@ -123,3 +123,7 @@ message UpdateUserInformationRequest {
   string avatarUrl = 2;// 头像
   int64 sex = 3; // 性别
 }
+
+message KeyRequest{
+  string key = 1;
+}

+ 6 - 6
api/user/user_grpc.pb.go

@@ -37,7 +37,7 @@ type UserClient interface {
 	// 创建用户与接待员的关联
 	CreateUserPartnerIsRelationship(ctx context.Context, in *common.PartnerIDParam, opts ...grpc.CallOption) (*chat.CreateUserPartnerIsRelationshipReply, error)
 	// 获取接待员的确认通过页面信息
-	GetPartnerCircleInfo(ctx context.Context, in *common.PartnerIDParam, opts ...grpc.CallOption) (*common.AddFriendMessageInfo, error)
+	GetPartnerCircleInfo(ctx context.Context, in *KeyRequest, opts ...grpc.CallOption) (*common.AddFriendMessageInfo, error)
 	// 用户获取主页信息
 	UserGetHomeInfo(ctx context.Context, in *common.PersonParam, opts ...grpc.CallOption) (*common.HomeInfo, error)
 	// 通过用户IDs查看用户信息列表
@@ -123,7 +123,7 @@ func (c *userClient) CreateUserPartnerIsRelationship(ctx context.Context, in *co
 	return out, nil
 }
 
-func (c *userClient) GetPartnerCircleInfo(ctx context.Context, in *common.PartnerIDParam, opts ...grpc.CallOption) (*common.AddFriendMessageInfo, error) {
+func (c *userClient) GetPartnerCircleInfo(ctx context.Context, in *KeyRequest, opts ...grpc.CallOption) (*common.AddFriendMessageInfo, error) {
 	out := new(common.AddFriendMessageInfo)
 	err := c.cc.Invoke(ctx, "/api.user.User/GetPartnerCircleInfo", in, out, opts...)
 	if err != nil {
@@ -205,7 +205,7 @@ type UserServer interface {
 	// 创建用户与接待员的关联
 	CreateUserPartnerIsRelationship(context.Context, *common.PartnerIDParam) (*chat.CreateUserPartnerIsRelationshipReply, error)
 	// 获取接待员的确认通过页面信息
-	GetPartnerCircleInfo(context.Context, *common.PartnerIDParam) (*common.AddFriendMessageInfo, error)
+	GetPartnerCircleInfo(context.Context, *KeyRequest) (*common.AddFriendMessageInfo, error)
 	// 用户获取主页信息
 	UserGetHomeInfo(context.Context, *common.PersonParam) (*common.HomeInfo, error)
 	// 通过用户IDs查看用户信息列表
@@ -246,7 +246,7 @@ func (UnimplementedUserServer) CheckUserPartnerIsRelationship(context.Context, *
 func (UnimplementedUserServer) CreateUserPartnerIsRelationship(context.Context, *common.PartnerIDParam) (*chat.CreateUserPartnerIsRelationshipReply, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method CreateUserPartnerIsRelationship not implemented")
 }
-func (UnimplementedUserServer) GetPartnerCircleInfo(context.Context, *common.PartnerIDParam) (*common.AddFriendMessageInfo, error) {
+func (UnimplementedUserServer) GetPartnerCircleInfo(context.Context, *KeyRequest) (*common.AddFriendMessageInfo, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method GetPartnerCircleInfo not implemented")
 }
 func (UnimplementedUserServer) UserGetHomeInfo(context.Context, *common.PersonParam) (*common.HomeInfo, error) {
@@ -407,7 +407,7 @@ func _User_CreateUserPartnerIsRelationship_Handler(srv interface{}, ctx context.
 }
 
 func _User_GetPartnerCircleInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
-	in := new(common.PartnerIDParam)
+	in := new(KeyRequest)
 	if err := dec(in); err != nil {
 		return nil, err
 	}
@@ -419,7 +419,7 @@ func _User_GetPartnerCircleInfo_Handler(srv interface{}, ctx context.Context, de
 		FullMethod: "/api.user.User/GetPartnerCircleInfo",
 	}
 	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
-		return srv.(UserServer).GetPartnerCircleInfo(ctx, req.(*common.PartnerIDParam))
+		return srv.(UserServer).GetPartnerCircleInfo(ctx, req.(*KeyRequest))
 	}
 	return interceptor(ctx, in, info, handler)
 }

+ 5 - 5
api/user/user_http.pb.go

@@ -37,7 +37,7 @@ type UserHTTPServer interface {
 	FindLikedList(context.Context, *common.ListPageRequest) (*statistics.LookAndLikeListReply, error)
 	FindLookList(context.Context, *common.ListPageRequest) (*statistics.LookAndLikeListReply, error)
 	GetLookAndLikeStatisticsMessage(context.Context, *common.PersonParam) (*statistics.LookAndLikeMessageReply, error)
-	GetPartnerCircleInfo(context.Context, *common.PartnerIDParam) (*common.AddFriendMessageInfo, error)
+	GetPartnerCircleInfo(context.Context, *KeyRequest) (*common.AddFriendMessageInfo, error)
 	GetUserInfo(context.Context, *emptypb.Empty) (*UserInfo, error)
 	GetUserLookNum(context.Context, *emptypb.Empty) (*statistics.LookMessageReply, error)
 	SendPhoneCode(context.Context, *common.SendPhoneCodeRequest) (*emptypb.Empty, error)
@@ -253,7 +253,7 @@ func _User_CreateUserPartnerIsRelationship0_HTTP_Handler(srv UserHTTPServer) fun
 
 func _User_GetPartnerCircleInfo0_HTTP_Handler(srv UserHTTPServer) func(ctx http.Context) error {
 	return func(ctx http.Context) error {
-		var in common.PartnerIDParam
+		var in KeyRequest
 		if err := ctx.Bind(&in); err != nil {
 			return err
 		}
@@ -262,7 +262,7 @@ func _User_GetPartnerCircleInfo0_HTTP_Handler(srv UserHTTPServer) func(ctx http.
 		}
 		http.SetOperation(ctx, "/api.user.User/GetPartnerCircleInfo")
 		h := ctx.Middleware(func(ctx context.Context, req interface{}) (interface{}, error) {
-			return srv.GetPartnerCircleInfo(ctx, req.(*common.PartnerIDParam))
+			return srv.GetPartnerCircleInfo(ctx, req.(*KeyRequest))
 		})
 		out, err := h(ctx, &in)
 		if err != nil {
@@ -421,7 +421,7 @@ type UserHTTPClient interface {
 	FindLikedList(ctx context.Context, req *common.ListPageRequest, opts ...http.CallOption) (rsp *statistics.LookAndLikeListReply, err error)
 	FindLookList(ctx context.Context, req *common.ListPageRequest, opts ...http.CallOption) (rsp *statistics.LookAndLikeListReply, err error)
 	GetLookAndLikeStatisticsMessage(ctx context.Context, req *common.PersonParam, opts ...http.CallOption) (rsp *statistics.LookAndLikeMessageReply, err error)
-	GetPartnerCircleInfo(ctx context.Context, req *common.PartnerIDParam, opts ...http.CallOption) (rsp *common.AddFriendMessageInfo, err error)
+	GetPartnerCircleInfo(ctx context.Context, req *KeyRequest, opts ...http.CallOption) (rsp *common.AddFriendMessageInfo, err error)
 	GetUserInfo(ctx context.Context, req *emptypb.Empty, opts ...http.CallOption) (rsp *UserInfo, err error)
 	GetUserLookNum(ctx context.Context, req *emptypb.Empty, opts ...http.CallOption) (rsp *statistics.LookMessageReply, err error)
 	SendPhoneCode(ctx context.Context, req *common.SendPhoneCodeRequest, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
@@ -528,7 +528,7 @@ func (c *UserHTTPClientImpl) GetLookAndLikeStatisticsMessage(ctx context.Context
 	return &out, err
 }
 
-func (c *UserHTTPClientImpl) GetPartnerCircleInfo(ctx context.Context, in *common.PartnerIDParam, opts ...http.CallOption) (*common.AddFriendMessageInfo, error) {
+func (c *UserHTTPClientImpl) GetPartnerCircleInfo(ctx context.Context, in *KeyRequest, opts ...http.CallOption) (*common.AddFriendMessageInfo, error) {
 	var out common.AddFriendMessageInfo
 	pattern := "/api/user/circle/info"
 	path := binding.EncodeURL(pattern, in, false)

+ 7 - 0
errors/user.go

@@ -0,0 +1,7 @@
+package errors
+
+import "git.ikuban.com/server/kratos-utils/codes"
+
+var (
+	ErrorUserSelectNotExist = codes.Error(30001, "用户未经过选择")
+)

+ 1 - 1
js/api/account/account_http_pb.ts

@@ -1,6 +1,6 @@
 // @ts-ignore
 import { request } from 'ice';
-import {DebugLoginRequest,TokenReply,AuthorizationRequest,OpenIDRequest,IdentityInfo} from "./account_pb";
+import {DebugLoginRequest,TokenReply,AuthorizationRequest,OpenIDAndAppIDRequest,IdentityInfo} from "./account_pb";
 
 const AccountService = {
   DebugLogin: async (req?: DebugLoginRequest) => {

+ 3 - 1
js/api/account/account_pb.ts

@@ -1,5 +1,6 @@
-export interface OpenIDRequest{
+export interface OpenIDAndAppIDRequest{
     openId?:string;
+    appId?:string;
 }
 export interface IdentityInfo{
     id?:string;
@@ -37,6 +38,7 @@ export interface AuthorizationRequest{
     jsCode?:string;
     appId?:string;
     type?:string;
+    fromOpenId?:string;
 }
 export interface TokenReply{
     token?:string;

+ 8 - 0
js/api/common/common_pb.ts

@@ -53,6 +53,14 @@ export interface AddFriendMessageInfo{
     sex?:number;
     /**  图片 */
     pictures?:Array<string>;
+    /**  来源公众号对应的openID */
+    fromOpenId?:string;
+    /**  是否注册 */
+    isRegister?:boolean;
+    /**  是否聊天 */
+    isChat?:boolean;
+    /**  是否是来源我们 */
+    isFromUs?:boolean;
 }
 export interface PersonIDList{
     personIds?:Array<string>;

+ 2 - 2
js/api/user/user_http_pb.ts

@@ -1,6 +1,6 @@
 // @ts-ignore
 import { request } from 'ice';
-import {UpdateUserInformationRequest,UserInfo} from "./user_pb";
+import {UpdateUserInformationRequest,UserInfo,KeyRequest} from "./user_pb";
 import {LookMessageReply,LookAndLikeListReply,LookAndLikeMessageReply} from "../statistics/statistics_pb";
 import {SendPhoneCodeRequest,CheckPhoneCodeRequest,PartnerIDParam,AddFriendMessageInfo,PersonParam,HomeInfo,PersonIDList,PersonDBReply,ListPageRequest} from "../common/common_pb";
 import {CheckUserPartnerIsRelationshipReply,CreateUserPartnerIsRelationshipReply} from "../chat/chat_pb";
@@ -42,7 +42,7 @@ const UserService = {
     return res.data;
   },
   /**  获取接待员的确认通过页面信息 */
-  GetPartnerCircleInfo: async (req?: PartnerIDParam) => {
+  GetPartnerCircleInfo: async (req?: KeyRequest) => {
 	const res = await request.post<{ data: AddFriendMessageInfo, code: string, message: string }>('/api/user/circle/info', req);
     return res.data;
   },

+ 3 - 0
js/api/user/user_pb.ts

@@ -20,4 +20,7 @@ export interface UpdateUserInformationRequest{
     /**  性别 */
     sex?:number;
 }
+export interface KeyRequest{
+    key?:string;
+}