Documentation
¶
Index ¶
- Variables
- func RegisterIdentityServer(s grpc.ServiceRegistrar, srv IdentityServer)
- type GetUserRequest
- func (*GetUserRequest) Descriptor() ([]byte, []int)deprecated
- func (m *GetUserRequest) GetIdentifyingFeature() isGetUserRequest_IdentifyingFeature
- func (x *GetUserRequest) GetOwnerAccountId() *v1.SolanaAccountId
- func (x *GetUserRequest) GetPhoneNumber() *v1.PhoneNumber
- func (x *GetUserRequest) GetSignature() *v1.Signature
- func (*GetUserRequest) ProtoMessage()
- func (x *GetUserRequest) ProtoReflect() protoreflect.Message
- func (x *GetUserRequest) Reset()
- func (x *GetUserRequest) String() string
- func (m *GetUserRequest) Validate() error
- type GetUserRequestValidationError
- func (e GetUserRequestValidationError) Cause() error
- func (e GetUserRequestValidationError) Error() string
- func (e GetUserRequestValidationError) ErrorName() string
- func (e GetUserRequestValidationError) Field() string
- func (e GetUserRequestValidationError) Key() bool
- func (e GetUserRequestValidationError) Reason() string
- type GetUserRequest_PhoneNumber
- type GetUserResponse
- func (*GetUserResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetUserResponse) GetDataContainerId() *v1.DataContainerId
- func (x *GetUserResponse) GetEligibleAirdrops() []v2.AirdropType
- func (x *GetUserResponse) GetEnableInternalFlags() bool
- func (m *GetUserResponse) GetMetadata() isGetUserResponse_Metadata
- func (x *GetUserResponse) GetPhone() *PhoneMetadata
- func (x *GetUserResponse) GetResult() GetUserResponse_Result
- func (x *GetUserResponse) GetUser() *User
- func (*GetUserResponse) ProtoMessage()
- func (x *GetUserResponse) ProtoReflect() protoreflect.Message
- func (x *GetUserResponse) Reset()
- func (x *GetUserResponse) String() string
- func (m *GetUserResponse) Validate() error
- type GetUserResponseValidationError
- func (e GetUserResponseValidationError) Cause() error
- func (e GetUserResponseValidationError) Error() string
- func (e GetUserResponseValidationError) ErrorName() string
- func (e GetUserResponseValidationError) Field() string
- func (e GetUserResponseValidationError) Key() bool
- func (e GetUserResponseValidationError) Reason() string
- type GetUserResponse_Phone
- type GetUserResponse_Result
- func (GetUserResponse_Result) Descriptor() protoreflect.EnumDescriptor
- func (x GetUserResponse_Result) Enum() *GetUserResponse_Result
- func (GetUserResponse_Result) EnumDescriptor() ([]byte, []int)deprecated
- func (x GetUserResponse_Result) Number() protoreflect.EnumNumber
- func (x GetUserResponse_Result) String() string
- func (GetUserResponse_Result) Type() protoreflect.EnumType
- type IdentityClient
- type IdentityServer
- type LinkAccountRequest
- func (*LinkAccountRequest) Descriptor() ([]byte, []int)deprecated
- func (x *LinkAccountRequest) GetOwnerAccountId() *v1.SolanaAccountId
- func (x *LinkAccountRequest) GetPhone() *v11.PhoneLinkingToken
- func (x *LinkAccountRequest) GetSignature() *v1.Signature
- func (m *LinkAccountRequest) GetToken() isLinkAccountRequest_Token
- func (*LinkAccountRequest) ProtoMessage()
- func (x *LinkAccountRequest) ProtoReflect() protoreflect.Message
- func (x *LinkAccountRequest) Reset()
- func (x *LinkAccountRequest) String() string
- func (m *LinkAccountRequest) Validate() error
- type LinkAccountRequestValidationError
- func (e LinkAccountRequestValidationError) Cause() error
- func (e LinkAccountRequestValidationError) Error() string
- func (e LinkAccountRequestValidationError) ErrorName() string
- func (e LinkAccountRequestValidationError) Field() string
- func (e LinkAccountRequestValidationError) Key() bool
- func (e LinkAccountRequestValidationError) Reason() string
- type LinkAccountRequest_Phone
- type LinkAccountResponse
- func (*LinkAccountResponse) Descriptor() ([]byte, []int)deprecated
- func (x *LinkAccountResponse) GetDataContainerId() *v1.DataContainerId
- func (m *LinkAccountResponse) GetMetadata() isLinkAccountResponse_Metadata
- func (x *LinkAccountResponse) GetPhone() *PhoneMetadata
- func (x *LinkAccountResponse) GetResult() LinkAccountResponse_Result
- func (x *LinkAccountResponse) GetUser() *User
- func (*LinkAccountResponse) ProtoMessage()
- func (x *LinkAccountResponse) ProtoReflect() protoreflect.Message
- func (x *LinkAccountResponse) Reset()
- func (x *LinkAccountResponse) String() string
- func (m *LinkAccountResponse) Validate() error
- type LinkAccountResponseValidationError
- func (e LinkAccountResponseValidationError) Cause() error
- func (e LinkAccountResponseValidationError) Error() string
- func (e LinkAccountResponseValidationError) ErrorName() string
- func (e LinkAccountResponseValidationError) Field() string
- func (e LinkAccountResponseValidationError) Key() bool
- func (e LinkAccountResponseValidationError) Reason() string
- type LinkAccountResponse_Phone
- type LinkAccountResponse_Result
- func (LinkAccountResponse_Result) Descriptor() protoreflect.EnumDescriptor
- func (x LinkAccountResponse_Result) Enum() *LinkAccountResponse_Result
- func (LinkAccountResponse_Result) EnumDescriptor() ([]byte, []int)deprecated
- func (x LinkAccountResponse_Result) Number() protoreflect.EnumNumber
- func (x LinkAccountResponse_Result) String() string
- func (LinkAccountResponse_Result) Type() protoreflect.EnumType
- type PhoneMetadata
- func (*PhoneMetadata) Descriptor() ([]byte, []int)deprecated
- func (x *PhoneMetadata) GetIsLinked() bool
- func (*PhoneMetadata) ProtoMessage()
- func (x *PhoneMetadata) ProtoReflect() protoreflect.Message
- func (x *PhoneMetadata) Reset()
- func (x *PhoneMetadata) String() string
- func (m *PhoneMetadata) Validate() error
- type PhoneMetadataValidationError
- func (e PhoneMetadataValidationError) Cause() error
- func (e PhoneMetadataValidationError) Error() string
- func (e PhoneMetadataValidationError) ErrorName() string
- func (e PhoneMetadataValidationError) Field() string
- func (e PhoneMetadataValidationError) Key() bool
- func (e PhoneMetadataValidationError) Reason() string
- type UnimplementedIdentityServer
- func (UnimplementedIdentityServer) GetUser(context.Context, *GetUserRequest) (*GetUserResponse, error)
- func (UnimplementedIdentityServer) LinkAccount(context.Context, *LinkAccountRequest) (*LinkAccountResponse, error)
- func (UnimplementedIdentityServer) UnlinkAccount(context.Context, *UnlinkAccountRequest) (*UnlinkAccountResponse, error)
- type UnlinkAccountRequest
- func (*UnlinkAccountRequest) Descriptor() ([]byte, []int)deprecated
- func (m *UnlinkAccountRequest) GetIdentifyingFeature() isUnlinkAccountRequest_IdentifyingFeature
- func (x *UnlinkAccountRequest) GetOwnerAccountId() *v1.SolanaAccountId
- func (x *UnlinkAccountRequest) GetPhoneNumber() *v1.PhoneNumber
- func (x *UnlinkAccountRequest) GetSignature() *v1.Signature
- func (*UnlinkAccountRequest) ProtoMessage()
- func (x *UnlinkAccountRequest) ProtoReflect() protoreflect.Message
- func (x *UnlinkAccountRequest) Reset()
- func (x *UnlinkAccountRequest) String() string
- func (m *UnlinkAccountRequest) Validate() error
- type UnlinkAccountRequestValidationError
- func (e UnlinkAccountRequestValidationError) Cause() error
- func (e UnlinkAccountRequestValidationError) Error() string
- func (e UnlinkAccountRequestValidationError) ErrorName() string
- func (e UnlinkAccountRequestValidationError) Field() string
- func (e UnlinkAccountRequestValidationError) Key() bool
- func (e UnlinkAccountRequestValidationError) Reason() string
- type UnlinkAccountRequest_PhoneNumber
- type UnlinkAccountResponse
- func (*UnlinkAccountResponse) Descriptor() ([]byte, []int)deprecated
- func (x *UnlinkAccountResponse) GetResult() UnlinkAccountResponse_Result
- func (*UnlinkAccountResponse) ProtoMessage()
- func (x *UnlinkAccountResponse) ProtoReflect() protoreflect.Message
- func (x *UnlinkAccountResponse) Reset()
- func (x *UnlinkAccountResponse) String() string
- func (m *UnlinkAccountResponse) Validate() error
- type UnlinkAccountResponseValidationError
- func (e UnlinkAccountResponseValidationError) Cause() error
- func (e UnlinkAccountResponseValidationError) Error() string
- func (e UnlinkAccountResponseValidationError) ErrorName() string
- func (e UnlinkAccountResponseValidationError) Field() string
- func (e UnlinkAccountResponseValidationError) Key() bool
- func (e UnlinkAccountResponseValidationError) Reason() string
- type UnlinkAccountResponse_Result
- func (UnlinkAccountResponse_Result) Descriptor() protoreflect.EnumDescriptor
- func (x UnlinkAccountResponse_Result) Enum() *UnlinkAccountResponse_Result
- func (UnlinkAccountResponse_Result) EnumDescriptor() ([]byte, []int)deprecated
- func (x UnlinkAccountResponse_Result) Number() protoreflect.EnumNumber
- func (x UnlinkAccountResponse_Result) String() string
- func (UnlinkAccountResponse_Result) Type() protoreflect.EnumType
- type UnsafeIdentityServer
- type User
- type UserValidationError
- type View
- type ViewValidationError
Constants ¶
This section is empty.
Variables ¶
var ( LinkAccountResponse_Result_name = map[int32]string{ 0: "OK", 1: "INVALID_TOKEN", 2: "RATE_LIMITED", } LinkAccountResponse_Result_value = map[string]int32{ "OK": 0, "INVALID_TOKEN": 1, "RATE_LIMITED": 2, } )
Enum value maps for LinkAccountResponse_Result.
var ( UnlinkAccountResponse_Result_name = map[int32]string{ 0: "OK", 1: "NEVER_ASSOCIATED", } UnlinkAccountResponse_Result_value = map[string]int32{ "OK": 0, "NEVER_ASSOCIATED": 1, } )
Enum value maps for UnlinkAccountResponse_Result.
var ( GetUserResponse_Result_name = map[int32]string{ 0: "OK", 1: "NOT_FOUND", 2: "NOT_INVITED", 3: "UNLOCKED_TIMELOCK_ACCOUNT", } GetUserResponse_Result_value = map[string]int32{ "OK": 0, "NOT_FOUND": 1, "NOT_INVITED": 2, "UNLOCKED_TIMELOCK_ACCOUNT": 3, } )
Enum value maps for GetUserResponse_Result.
var File_user_v1_identity_service_proto protoreflect.FileDescriptor
var Identity_ServiceDesc = grpc.ServiceDesc{ ServiceName: "code.user.v1.Identity", HandlerType: (*IdentityServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "LinkAccount", Handler: _Identity_LinkAccount_Handler, }, { MethodName: "UnlinkAccount", Handler: _Identity_UnlinkAccount_Handler, }, { MethodName: "GetUser", Handler: _Identity_GetUser_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "user/v1/identity_service.proto", }
Identity_ServiceDesc is the grpc.ServiceDesc for Identity service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterIdentityServer ¶
func RegisterIdentityServer(s grpc.ServiceRegistrar, srv IdentityServer)
Types ¶
type GetUserRequest ¶
type GetUserRequest struct { // The public key of the owner account that signed this request message. OwnerAccountId *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=owner_account_id,json=ownerAccountId,proto3" json:"owner_account_id,omitempty"` // The signature is of serialize(GetUserRequest) without this field set // using the private key of owner_account_id. This provides an authentication // mechanism to the RPC. Signature *v1.Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` // The user's indentifying feature, which maps to an instance of a view. // // Types that are assignable to IdentifyingFeature: // // *GetUserRequest_PhoneNumber IdentifyingFeature isGetUserRequest_IdentifyingFeature `protobuf_oneof:"identifying_feature"` // contains filtered or unexported fields }
func (*GetUserRequest) Descriptor
deprecated
func (*GetUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetUserRequest.ProtoReflect.Descriptor instead.
func (*GetUserRequest) GetIdentifyingFeature ¶
func (m *GetUserRequest) GetIdentifyingFeature() isGetUserRequest_IdentifyingFeature
func (*GetUserRequest) GetOwnerAccountId ¶
func (x *GetUserRequest) GetOwnerAccountId() *v1.SolanaAccountId
func (*GetUserRequest) GetPhoneNumber ¶
func (x *GetUserRequest) GetPhoneNumber() *v1.PhoneNumber
func (*GetUserRequest) GetSignature ¶
func (x *GetUserRequest) GetSignature() *v1.Signature
func (*GetUserRequest) ProtoMessage ¶
func (*GetUserRequest) ProtoMessage()
func (*GetUserRequest) ProtoReflect ¶
func (x *GetUserRequest) ProtoReflect() protoreflect.Message
func (*GetUserRequest) Reset ¶
func (x *GetUserRequest) Reset()
func (*GetUserRequest) String ¶
func (x *GetUserRequest) String() string
func (*GetUserRequest) Validate ¶
func (m *GetUserRequest) Validate() error
Validate checks the field values on GetUserRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type GetUserRequestValidationError ¶
type GetUserRequestValidationError struct {
// contains filtered or unexported fields
}
GetUserRequestValidationError is the validation error returned by GetUserRequest.Validate if the designated constraints aren't met.
func (GetUserRequestValidationError) Cause ¶
func (e GetUserRequestValidationError) Cause() error
Cause function returns cause value.
func (GetUserRequestValidationError) Error ¶
func (e GetUserRequestValidationError) Error() string
Error satisfies the builtin error interface
func (GetUserRequestValidationError) ErrorName ¶
func (e GetUserRequestValidationError) ErrorName() string
ErrorName returns error name.
func (GetUserRequestValidationError) Field ¶
func (e GetUserRequestValidationError) Field() string
Field function returns field value.
func (GetUserRequestValidationError) Key ¶
func (e GetUserRequestValidationError) Key() bool
Key function returns key value.
func (GetUserRequestValidationError) Reason ¶
func (e GetUserRequestValidationError) Reason() string
Reason function returns reason value.
type GetUserRequest_PhoneNumber ¶
type GetUserRequest_PhoneNumber struct {
PhoneNumber *v1.PhoneNumber `protobuf:"bytes,3,opt,name=phone_number,json=phoneNumber,proto3,oneof"`
}
type GetUserResponse ¶
type GetUserResponse struct { Result GetUserResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=code.user.v1.GetUserResponse_Result" json:"result,omitempty"` // The user associated with the identifier User *User `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"` // The data container where the user can store a copy of their data DataContainerId *v1.DataContainerId `protobuf:"bytes,3,opt,name=data_container_id,json=dataContainerId,proto3" json:"data_container_id,omitempty"` // Metadata about the user based for the instance of their view // // Types that are assignable to Metadata: // // *GetUserResponse_Phone Metadata isGetUserResponse_Metadata `protobuf_oneof:"metadata"` // Whether client internal flags are enabled for this user EnableInternalFlags bool `protobuf:"varint,6,opt,name=enable_internal_flags,json=enableInternalFlags,proto3" json:"enable_internal_flags,omitempty"` // Set of which airdrops the user is eligible to receive EligibleAirdrops []v2.AirdropType `` /* 154-byte string literal not displayed */ // contains filtered or unexported fields }
func (*GetUserResponse) Descriptor
deprecated
func (*GetUserResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetUserResponse.ProtoReflect.Descriptor instead.
func (*GetUserResponse) GetDataContainerId ¶
func (x *GetUserResponse) GetDataContainerId() *v1.DataContainerId
func (*GetUserResponse) GetEligibleAirdrops ¶
func (x *GetUserResponse) GetEligibleAirdrops() []v2.AirdropType
func (*GetUserResponse) GetEnableInternalFlags ¶
func (x *GetUserResponse) GetEnableInternalFlags() bool
func (*GetUserResponse) GetMetadata ¶
func (m *GetUserResponse) GetMetadata() isGetUserResponse_Metadata
func (*GetUserResponse) GetPhone ¶
func (x *GetUserResponse) GetPhone() *PhoneMetadata
func (*GetUserResponse) GetResult ¶
func (x *GetUserResponse) GetResult() GetUserResponse_Result
func (*GetUserResponse) GetUser ¶
func (x *GetUserResponse) GetUser() *User
func (*GetUserResponse) ProtoMessage ¶
func (*GetUserResponse) ProtoMessage()
func (*GetUserResponse) ProtoReflect ¶
func (x *GetUserResponse) ProtoReflect() protoreflect.Message
func (*GetUserResponse) Reset ¶
func (x *GetUserResponse) Reset()
func (*GetUserResponse) String ¶
func (x *GetUserResponse) String() string
func (*GetUserResponse) Validate ¶
func (m *GetUserResponse) Validate() error
Validate checks the field values on GetUserResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type GetUserResponseValidationError ¶
type GetUserResponseValidationError struct {
// contains filtered or unexported fields
}
GetUserResponseValidationError is the validation error returned by GetUserResponse.Validate if the designated constraints aren't met.
func (GetUserResponseValidationError) Cause ¶
func (e GetUserResponseValidationError) Cause() error
Cause function returns cause value.
func (GetUserResponseValidationError) Error ¶
func (e GetUserResponseValidationError) Error() string
Error satisfies the builtin error interface
func (GetUserResponseValidationError) ErrorName ¶
func (e GetUserResponseValidationError) ErrorName() string
ErrorName returns error name.
func (GetUserResponseValidationError) Field ¶
func (e GetUserResponseValidationError) Field() string
Field function returns field value.
func (GetUserResponseValidationError) Key ¶
func (e GetUserResponseValidationError) Key() bool
Key function returns key value.
func (GetUserResponseValidationError) Reason ¶
func (e GetUserResponseValidationError) Reason() string
Reason function returns reason value.
type GetUserResponse_Phone ¶
type GetUserResponse_Phone struct { // Metadata that corresponds to a phone-based identifying feature. Phone *PhoneMetadata `protobuf:"bytes,5,opt,name=phone,proto3,oneof"` }
type GetUserResponse_Result ¶
type GetUserResponse_Result int32
const ( GetUserResponse_OK GetUserResponse_Result = 0 // The user doesn't exist GetUserResponse_NOT_FOUND GetUserResponse_Result = 1 // The user is no longer invited GetUserResponse_NOT_INVITED GetUserResponse_Result = 2 // The user exists, but at least one of their timelock accounts is unlocked GetUserResponse_UNLOCKED_TIMELOCK_ACCOUNT GetUserResponse_Result = 3 )
func (GetUserResponse_Result) Descriptor ¶
func (GetUserResponse_Result) Descriptor() protoreflect.EnumDescriptor
func (GetUserResponse_Result) Enum ¶
func (x GetUserResponse_Result) Enum() *GetUserResponse_Result
func (GetUserResponse_Result) EnumDescriptor
deprecated
func (GetUserResponse_Result) EnumDescriptor() ([]byte, []int)
Deprecated: Use GetUserResponse_Result.Descriptor instead.
func (GetUserResponse_Result) Number ¶
func (x GetUserResponse_Result) Number() protoreflect.EnumNumber
func (GetUserResponse_Result) String ¶
func (x GetUserResponse_Result) String() string
func (GetUserResponse_Result) Type ¶
func (GetUserResponse_Result) Type() protoreflect.EnumType
type IdentityClient ¶
type IdentityClient interface { // LinkAccount links an owner account to the user identified and authenticated // by a one-time use token. // // Notably, this RPC has the following side effects: // - A new user is automatically created if one doesn't exist. // - Server will create a new data container for at least every unique // owner account linked to the user. LinkAccount(ctx context.Context, in *LinkAccountRequest, opts ...grpc.CallOption) (*LinkAccountResponse, error) // UnlinkAccount removes links from an owner account. It will NOT remove // existing associations between users, owner accounts and identifying // features. // // The following associations will remain intact to ensure owner accounts // can continue to be used with a consistent login experience: // - the user continues to be associated to existing owner accounts and // identifying features // // Client can continue mainting their current login session. Their current // user and data container will remain the same. // // The call is guaranteed to be idempotent. It will not fail if the link is // already removed by either a previous call to this RPC or by a more recent // call to LinkAccount. A failure will only occur if the link between a user // and the owner accout or identifying feature never existed. UnlinkAccount(ctx context.Context, in *UnlinkAccountRequest, opts ...grpc.CallOption) (*UnlinkAccountResponse, error) // GetUser gets user information given a user identifier and an owner account. GetUser(ctx context.Context, in *GetUserRequest, opts ...grpc.CallOption) (*GetUserResponse, error) }
IdentityClient is the client API for Identity service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkgo.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewIdentityClient ¶
func NewIdentityClient(cc grpc.ClientConnInterface) IdentityClient
type IdentityServer ¶
type IdentityServer interface { // LinkAccount links an owner account to the user identified and authenticated // by a one-time use token. // // Notably, this RPC has the following side effects: // - A new user is automatically created if one doesn't exist. // - Server will create a new data container for at least every unique // owner account linked to the user. LinkAccount(context.Context, *LinkAccountRequest) (*LinkAccountResponse, error) // UnlinkAccount removes links from an owner account. It will NOT remove // existing associations between users, owner accounts and identifying // features. // // The following associations will remain intact to ensure owner accounts // can continue to be used with a consistent login experience: // - the user continues to be associated to existing owner accounts and // identifying features // // Client can continue mainting their current login session. Their current // user and data container will remain the same. // // The call is guaranteed to be idempotent. It will not fail if the link is // already removed by either a previous call to this RPC or by a more recent // call to LinkAccount. A failure will only occur if the link between a user // and the owner accout or identifying feature never existed. UnlinkAccount(context.Context, *UnlinkAccountRequest) (*UnlinkAccountResponse, error) // GetUser gets user information given a user identifier and an owner account. GetUser(context.Context, *GetUserRequest) (*GetUserResponse, error) // contains filtered or unexported methods }
IdentityServer is the server API for Identity service. All implementations must embed UnimplementedIdentityServer for forward compatibility
type LinkAccountRequest ¶
type LinkAccountRequest struct { // The public key of the owner account that will be linked to a user. OwnerAccountId *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=owner_account_id,json=ownerAccountId,proto3" json:"owner_account_id,omitempty"` // The signature is of serialize(LinkAccountRequest) without this field set // using the private key of owner_account_id. This validates that the client // actually owns the account. Signature *v1.Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` // A one-time use token that identifies and authenticates the user. // // Types that are assignable to Token: // // *LinkAccountRequest_Phone Token isLinkAccountRequest_Token `protobuf_oneof:"token"` // contains filtered or unexported fields }
func (*LinkAccountRequest) Descriptor
deprecated
func (*LinkAccountRequest) Descriptor() ([]byte, []int)
Deprecated: Use LinkAccountRequest.ProtoReflect.Descriptor instead.
func (*LinkAccountRequest) GetOwnerAccountId ¶
func (x *LinkAccountRequest) GetOwnerAccountId() *v1.SolanaAccountId
func (*LinkAccountRequest) GetPhone ¶
func (x *LinkAccountRequest) GetPhone() *v11.PhoneLinkingToken
func (*LinkAccountRequest) GetSignature ¶
func (x *LinkAccountRequest) GetSignature() *v1.Signature
func (*LinkAccountRequest) GetToken ¶
func (m *LinkAccountRequest) GetToken() isLinkAccountRequest_Token
func (*LinkAccountRequest) ProtoMessage ¶
func (*LinkAccountRequest) ProtoMessage()
func (*LinkAccountRequest) ProtoReflect ¶
func (x *LinkAccountRequest) ProtoReflect() protoreflect.Message
func (*LinkAccountRequest) Reset ¶
func (x *LinkAccountRequest) Reset()
func (*LinkAccountRequest) String ¶
func (x *LinkAccountRequest) String() string
func (*LinkAccountRequest) Validate ¶
func (m *LinkAccountRequest) Validate() error
Validate checks the field values on LinkAccountRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type LinkAccountRequestValidationError ¶
type LinkAccountRequestValidationError struct {
// contains filtered or unexported fields
}
LinkAccountRequestValidationError is the validation error returned by LinkAccountRequest.Validate if the designated constraints aren't met.
func (LinkAccountRequestValidationError) Cause ¶
func (e LinkAccountRequestValidationError) Cause() error
Cause function returns cause value.
func (LinkAccountRequestValidationError) Error ¶
func (e LinkAccountRequestValidationError) Error() string
Error satisfies the builtin error interface
func (LinkAccountRequestValidationError) ErrorName ¶
func (e LinkAccountRequestValidationError) ErrorName() string
ErrorName returns error name.
func (LinkAccountRequestValidationError) Field ¶
func (e LinkAccountRequestValidationError) Field() string
Field function returns field value.
func (LinkAccountRequestValidationError) Key ¶
func (e LinkAccountRequestValidationError) Key() bool
Key function returns key value.
func (LinkAccountRequestValidationError) Reason ¶
func (e LinkAccountRequestValidationError) Reason() string
Reason function returns reason value.
type LinkAccountRequest_Phone ¶
type LinkAccountRequest_Phone struct { // A token received after successfully verifying a phone number via a // SMS code using the phone verification service. Phone *v11.PhoneLinkingToken `protobuf:"bytes,3,opt,name=phone,proto3,oneof"` }
type LinkAccountResponse ¶
type LinkAccountResponse struct { Result LinkAccountResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=code.user.v1.LinkAccountResponse_Result" json:"result,omitempty"` // The user that was linked to the owner account User *User `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"` // The data container where the user can store a copy of their data DataContainerId *v1.DataContainerId `protobuf:"bytes,3,opt,name=data_container_id,json=dataContainerId,proto3" json:"data_container_id,omitempty"` // Metadata about the user based for the instance of their view // // Types that are assignable to Metadata: // // *LinkAccountResponse_Phone Metadata isLinkAccountResponse_Metadata `protobuf_oneof:"metadata"` // contains filtered or unexported fields }
func (*LinkAccountResponse) Descriptor
deprecated
func (*LinkAccountResponse) Descriptor() ([]byte, []int)
Deprecated: Use LinkAccountResponse.ProtoReflect.Descriptor instead.
func (*LinkAccountResponse) GetDataContainerId ¶
func (x *LinkAccountResponse) GetDataContainerId() *v1.DataContainerId
func (*LinkAccountResponse) GetMetadata ¶
func (m *LinkAccountResponse) GetMetadata() isLinkAccountResponse_Metadata
func (*LinkAccountResponse) GetPhone ¶
func (x *LinkAccountResponse) GetPhone() *PhoneMetadata
func (*LinkAccountResponse) GetResult ¶
func (x *LinkAccountResponse) GetResult() LinkAccountResponse_Result
func (*LinkAccountResponse) GetUser ¶
func (x *LinkAccountResponse) GetUser() *User
func (*LinkAccountResponse) ProtoMessage ¶
func (*LinkAccountResponse) ProtoMessage()
func (*LinkAccountResponse) ProtoReflect ¶
func (x *LinkAccountResponse) ProtoReflect() protoreflect.Message
func (*LinkAccountResponse) Reset ¶
func (x *LinkAccountResponse) Reset()
func (*LinkAccountResponse) String ¶
func (x *LinkAccountResponse) String() string
func (*LinkAccountResponse) Validate ¶
func (m *LinkAccountResponse) Validate() error
Validate checks the field values on LinkAccountResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type LinkAccountResponseValidationError ¶
type LinkAccountResponseValidationError struct {
// contains filtered or unexported fields
}
LinkAccountResponseValidationError is the validation error returned by LinkAccountResponse.Validate if the designated constraints aren't met.
func (LinkAccountResponseValidationError) Cause ¶
func (e LinkAccountResponseValidationError) Cause() error
Cause function returns cause value.
func (LinkAccountResponseValidationError) Error ¶
func (e LinkAccountResponseValidationError) Error() string
Error satisfies the builtin error interface
func (LinkAccountResponseValidationError) ErrorName ¶
func (e LinkAccountResponseValidationError) ErrorName() string
ErrorName returns error name.
func (LinkAccountResponseValidationError) Field ¶
func (e LinkAccountResponseValidationError) Field() string
Field function returns field value.
func (LinkAccountResponseValidationError) Key ¶
func (e LinkAccountResponseValidationError) Key() bool
Key function returns key value.
func (LinkAccountResponseValidationError) Reason ¶
func (e LinkAccountResponseValidationError) Reason() string
Reason function returns reason value.
type LinkAccountResponse_Phone ¶
type LinkAccountResponse_Phone struct { // Metadata that corresponds to a phone-based identifying feature. Phone *PhoneMetadata `protobuf:"bytes,5,opt,name=phone,proto3,oneof"` }
type LinkAccountResponse_Result ¶
type LinkAccountResponse_Result int32
const ( LinkAccountResponse_OK LinkAccountResponse_Result = 0 // The provided token is invalid. A token may be invalid for a number of // reasons including: it's already been used, has been modified by the // client or has expired. LinkAccountResponse_INVALID_TOKEN LinkAccountResponse_Result = 1 // The client is rate limited (eg. by IP, user ID, etc). The client should // retry at a later time. LinkAccountResponse_RATE_LIMITED LinkAccountResponse_Result = 2 )
func (LinkAccountResponse_Result) Descriptor ¶
func (LinkAccountResponse_Result) Descriptor() protoreflect.EnumDescriptor
func (LinkAccountResponse_Result) Enum ¶
func (x LinkAccountResponse_Result) Enum() *LinkAccountResponse_Result
func (LinkAccountResponse_Result) EnumDescriptor
deprecated
func (LinkAccountResponse_Result) EnumDescriptor() ([]byte, []int)
Deprecated: Use LinkAccountResponse_Result.Descriptor instead.
func (LinkAccountResponse_Result) Number ¶
func (x LinkAccountResponse_Result) Number() protoreflect.EnumNumber
func (LinkAccountResponse_Result) String ¶
func (x LinkAccountResponse_Result) String() string
func (LinkAccountResponse_Result) Type ¶
func (LinkAccountResponse_Result) Type() protoreflect.EnumType
type PhoneMetadata ¶
type PhoneMetadata struct { // State that determines whether a phone number is linked to the owner // account. A phone number is linked if we can treat it as an alias. // This is notably different from association, which answers the question // of whether the number was linked at any point in time. IsLinked bool `protobuf:"varint,1,opt,name=is_linked,json=isLinked,proto3" json:"is_linked,omitempty"` // contains filtered or unexported fields }
func (*PhoneMetadata) Descriptor
deprecated
func (*PhoneMetadata) Descriptor() ([]byte, []int)
Deprecated: Use PhoneMetadata.ProtoReflect.Descriptor instead.
func (*PhoneMetadata) GetIsLinked ¶
func (x *PhoneMetadata) GetIsLinked() bool
func (*PhoneMetadata) ProtoMessage ¶
func (*PhoneMetadata) ProtoMessage()
func (*PhoneMetadata) ProtoReflect ¶
func (x *PhoneMetadata) ProtoReflect() protoreflect.Message
func (*PhoneMetadata) Reset ¶
func (x *PhoneMetadata) Reset()
func (*PhoneMetadata) String ¶
func (x *PhoneMetadata) String() string
func (*PhoneMetadata) Validate ¶
func (m *PhoneMetadata) Validate() error
Validate checks the field values on PhoneMetadata with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type PhoneMetadataValidationError ¶
type PhoneMetadataValidationError struct {
// contains filtered or unexported fields
}
PhoneMetadataValidationError is the validation error returned by PhoneMetadata.Validate if the designated constraints aren't met.
func (PhoneMetadataValidationError) Cause ¶
func (e PhoneMetadataValidationError) Cause() error
Cause function returns cause value.
func (PhoneMetadataValidationError) Error ¶
func (e PhoneMetadataValidationError) Error() string
Error satisfies the builtin error interface
func (PhoneMetadataValidationError) ErrorName ¶
func (e PhoneMetadataValidationError) ErrorName() string
ErrorName returns error name.
func (PhoneMetadataValidationError) Field ¶
func (e PhoneMetadataValidationError) Field() string
Field function returns field value.
func (PhoneMetadataValidationError) Key ¶
func (e PhoneMetadataValidationError) Key() bool
Key function returns key value.
func (PhoneMetadataValidationError) Reason ¶
func (e PhoneMetadataValidationError) Reason() string
Reason function returns reason value.
type UnimplementedIdentityServer ¶
type UnimplementedIdentityServer struct { }
UnimplementedIdentityServer must be embedded to have forward compatible implementations.
func (UnimplementedIdentityServer) GetUser ¶
func (UnimplementedIdentityServer) GetUser(context.Context, *GetUserRequest) (*GetUserResponse, error)
func (UnimplementedIdentityServer) LinkAccount ¶
func (UnimplementedIdentityServer) LinkAccount(context.Context, *LinkAccountRequest) (*LinkAccountResponse, error)
func (UnimplementedIdentityServer) UnlinkAccount ¶
func (UnimplementedIdentityServer) UnlinkAccount(context.Context, *UnlinkAccountRequest) (*UnlinkAccountResponse, error)
type UnlinkAccountRequest ¶
type UnlinkAccountRequest struct { // The public key of the owner account that will be unliked. OwnerAccountId *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=owner_account_id,json=ownerAccountId,proto3" json:"owner_account_id,omitempty"` // The signature is of serialize(UnlinkAccountRequest) without this field set // using the private key of owner_account_id. This provides an authentication // mechanism to the RPC. Signature *v1.Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` // Types that are assignable to IdentifyingFeature: // // *UnlinkAccountRequest_PhoneNumber IdentifyingFeature isUnlinkAccountRequest_IdentifyingFeature `protobuf_oneof:"identifying_feature"` // contains filtered or unexported fields }
func (*UnlinkAccountRequest) Descriptor
deprecated
func (*UnlinkAccountRequest) Descriptor() ([]byte, []int)
Deprecated: Use UnlinkAccountRequest.ProtoReflect.Descriptor instead.
func (*UnlinkAccountRequest) GetIdentifyingFeature ¶
func (m *UnlinkAccountRequest) GetIdentifyingFeature() isUnlinkAccountRequest_IdentifyingFeature
func (*UnlinkAccountRequest) GetOwnerAccountId ¶
func (x *UnlinkAccountRequest) GetOwnerAccountId() *v1.SolanaAccountId
func (*UnlinkAccountRequest) GetPhoneNumber ¶
func (x *UnlinkAccountRequest) GetPhoneNumber() *v1.PhoneNumber
func (*UnlinkAccountRequest) GetSignature ¶
func (x *UnlinkAccountRequest) GetSignature() *v1.Signature
func (*UnlinkAccountRequest) ProtoMessage ¶
func (*UnlinkAccountRequest) ProtoMessage()
func (*UnlinkAccountRequest) ProtoReflect ¶
func (x *UnlinkAccountRequest) ProtoReflect() protoreflect.Message
func (*UnlinkAccountRequest) Reset ¶
func (x *UnlinkAccountRequest) Reset()
func (*UnlinkAccountRequest) String ¶
func (x *UnlinkAccountRequest) String() string
func (*UnlinkAccountRequest) Validate ¶
func (m *UnlinkAccountRequest) Validate() error
Validate checks the field values on UnlinkAccountRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type UnlinkAccountRequestValidationError ¶
type UnlinkAccountRequestValidationError struct {
// contains filtered or unexported fields
}
UnlinkAccountRequestValidationError is the validation error returned by UnlinkAccountRequest.Validate if the designated constraints aren't met.
func (UnlinkAccountRequestValidationError) Cause ¶
func (e UnlinkAccountRequestValidationError) Cause() error
Cause function returns cause value.
func (UnlinkAccountRequestValidationError) Error ¶
func (e UnlinkAccountRequestValidationError) Error() string
Error satisfies the builtin error interface
func (UnlinkAccountRequestValidationError) ErrorName ¶
func (e UnlinkAccountRequestValidationError) ErrorName() string
ErrorName returns error name.
func (UnlinkAccountRequestValidationError) Field ¶
func (e UnlinkAccountRequestValidationError) Field() string
Field function returns field value.
func (UnlinkAccountRequestValidationError) Key ¶
func (e UnlinkAccountRequestValidationError) Key() bool
Key function returns key value.
func (UnlinkAccountRequestValidationError) Reason ¶
func (e UnlinkAccountRequestValidationError) Reason() string
Reason function returns reason value.
type UnlinkAccountRequest_PhoneNumber ¶
type UnlinkAccountRequest_PhoneNumber struct { // The phone number associated with the owner account. PhoneNumber *v1.PhoneNumber `protobuf:"bytes,4,opt,name=phone_number,json=phoneNumber,proto3,oneof"` }
type UnlinkAccountResponse ¶
type UnlinkAccountResponse struct { Result UnlinkAccountResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=code.user.v1.UnlinkAccountResponse_Result" json:"result,omitempty"` // contains filtered or unexported fields }
func (*UnlinkAccountResponse) Descriptor
deprecated
func (*UnlinkAccountResponse) Descriptor() ([]byte, []int)
Deprecated: Use UnlinkAccountResponse.ProtoReflect.Descriptor instead.
func (*UnlinkAccountResponse) GetResult ¶
func (x *UnlinkAccountResponse) GetResult() UnlinkAccountResponse_Result
func (*UnlinkAccountResponse) ProtoMessage ¶
func (*UnlinkAccountResponse) ProtoMessage()
func (*UnlinkAccountResponse) ProtoReflect ¶
func (x *UnlinkAccountResponse) ProtoReflect() protoreflect.Message
func (*UnlinkAccountResponse) Reset ¶
func (x *UnlinkAccountResponse) Reset()
func (*UnlinkAccountResponse) String ¶
func (x *UnlinkAccountResponse) String() string
func (*UnlinkAccountResponse) Validate ¶
func (m *UnlinkAccountResponse) Validate() error
Validate checks the field values on UnlinkAccountResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type UnlinkAccountResponseValidationError ¶
type UnlinkAccountResponseValidationError struct {
// contains filtered or unexported fields
}
UnlinkAccountResponseValidationError is the validation error returned by UnlinkAccountResponse.Validate if the designated constraints aren't met.
func (UnlinkAccountResponseValidationError) Cause ¶
func (e UnlinkAccountResponseValidationError) Cause() error
Cause function returns cause value.
func (UnlinkAccountResponseValidationError) Error ¶
func (e UnlinkAccountResponseValidationError) Error() string
Error satisfies the builtin error interface
func (UnlinkAccountResponseValidationError) ErrorName ¶
func (e UnlinkAccountResponseValidationError) ErrorName() string
ErrorName returns error name.
func (UnlinkAccountResponseValidationError) Field ¶
func (e UnlinkAccountResponseValidationError) Field() string
Field function returns field value.
func (UnlinkAccountResponseValidationError) Key ¶
func (e UnlinkAccountResponseValidationError) Key() bool
Key function returns key value.
func (UnlinkAccountResponseValidationError) Reason ¶
func (e UnlinkAccountResponseValidationError) Reason() string
Reason function returns reason value.
type UnlinkAccountResponse_Result ¶
type UnlinkAccountResponse_Result int32
const ( UnlinkAccountResponse_OK UnlinkAccountResponse_Result = 0 // The client attempted to unlink an owner account or identifying feature // that never had a valid association. UnlinkAccountResponse_NEVER_ASSOCIATED UnlinkAccountResponse_Result = 1 )
func (UnlinkAccountResponse_Result) Descriptor ¶
func (UnlinkAccountResponse_Result) Descriptor() protoreflect.EnumDescriptor
func (UnlinkAccountResponse_Result) Enum ¶
func (x UnlinkAccountResponse_Result) Enum() *UnlinkAccountResponse_Result
func (UnlinkAccountResponse_Result) EnumDescriptor
deprecated
func (UnlinkAccountResponse_Result) EnumDescriptor() ([]byte, []int)
Deprecated: Use UnlinkAccountResponse_Result.Descriptor instead.
func (UnlinkAccountResponse_Result) Number ¶
func (x UnlinkAccountResponse_Result) Number() protoreflect.EnumNumber
func (UnlinkAccountResponse_Result) String ¶
func (x UnlinkAccountResponse_Result) String() string
func (UnlinkAccountResponse_Result) Type ¶
func (UnlinkAccountResponse_Result) Type() protoreflect.EnumType
type UnsafeIdentityServer ¶
type UnsafeIdentityServer interface {
// contains filtered or unexported methods
}
UnsafeIdentityServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to IdentityServer will result in compilation errors.
type User ¶
type User struct { // The user's ID Id *v1.UserId `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // The identifying features that are associated with the user View *View `protobuf:"bytes,2,opt,name=view,proto3" json:"view,omitempty"` // contains filtered or unexported fields }
User is the highest order of a form of identity.
func (*User) Descriptor
deprecated
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) ProtoReflect ¶
func (x *User) ProtoReflect() protoreflect.Message
type UserValidationError ¶
type UserValidationError struct {
// contains filtered or unexported fields
}
UserValidationError is the validation error returned by User.Validate if the designated constraints aren't met.
func (UserValidationError) Cause ¶
func (e UserValidationError) Cause() error
Cause function returns cause value.
func (UserValidationError) Error ¶
func (e UserValidationError) Error() string
Error satisfies the builtin error interface
func (UserValidationError) ErrorName ¶
func (e UserValidationError) ErrorName() string
ErrorName returns error name.
func (UserValidationError) Field ¶
func (e UserValidationError) Field() string
Field function returns field value.
func (UserValidationError) Key ¶
func (e UserValidationError) Key() bool
Key function returns key value.
func (UserValidationError) Reason ¶
func (e UserValidationError) Reason() string
Reason function returns reason value.
type View ¶
type View struct { // The phone number associated with a user. // // Note: This field is mandatory as of right now, since it's the only one // // supported to date. PhoneNumber *v1.PhoneNumber `protobuf:"bytes,1,opt,name=phone_number,json=phoneNumber,proto3" json:"phone_number,omitempty"` // contains filtered or unexported fields }
View is a well-defined set of identifying features. It is contrained to having exactly one feature set at a time, for now.
func (*View) Descriptor
deprecated
func (*View) GetPhoneNumber ¶
func (x *View) GetPhoneNumber() *v1.PhoneNumber
func (*View) ProtoMessage ¶
func (*View) ProtoMessage()
func (*View) ProtoReflect ¶
func (x *View) ProtoReflect() protoreflect.Message
type ViewValidationError ¶
type ViewValidationError struct {
// contains filtered or unexported fields
}
ViewValidationError is the validation error returned by View.Validate if the designated constraints aren't met.
func (ViewValidationError) Cause ¶
func (e ViewValidationError) Cause() error
Cause function returns cause value.
func (ViewValidationError) Error ¶
func (e ViewValidationError) Error() string
Error satisfies the builtin error interface
func (ViewValidationError) ErrorName ¶
func (e ViewValidationError) ErrorName() string
ErrorName returns error name.
func (ViewValidationError) Field ¶
func (e ViewValidationError) Field() string
Field function returns field value.
func (ViewValidationError) Key ¶
func (e ViewValidationError) Key() bool
Key function returns key value.
func (ViewValidationError) Reason ¶
func (e ViewValidationError) Reason() string
Reason function returns reason value.