user

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 24, 2023 License: MIT Imports: 23 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

View Source
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.

View Source
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.

View Source
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.

View Source
var File_user_v1_identity_service_proto protoreflect.FileDescriptor
View Source
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

Cause function returns cause value.

func (GetUserRequestValidationError) Error

Error satisfies the builtin error interface

func (GetUserRequestValidationError) ErrorName

func (e GetUserRequestValidationError) ErrorName() string

ErrorName returns error name.

func (GetUserRequestValidationError) Field

Field function returns field value.

func (GetUserRequestValidationError) Key

Key function returns key value.

func (GetUserRequestValidationError) Reason

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

Cause function returns cause value.

func (GetUserResponseValidationError) Error

Error satisfies the builtin error interface

func (GetUserResponseValidationError) ErrorName

func (e GetUserResponseValidationError) ErrorName() string

ErrorName returns error name.

func (GetUserResponseValidationError) Field

Field function returns field value.

func (GetUserResponseValidationError) Key

Key function returns key value.

func (GetUserResponseValidationError) Reason

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) Enum

func (GetUserResponse_Result) EnumDescriptor deprecated

func (GetUserResponse_Result) EnumDescriptor() ([]byte, []int)

Deprecated: Use GetUserResponse_Result.Descriptor instead.

func (GetUserResponse_Result) Number

func (GetUserResponse_Result) String

func (x GetUserResponse_Result) String() string

func (GetUserResponse_Result) Type

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://pkg.go.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

Cause function returns cause value.

func (LinkAccountRequestValidationError) Error

Error satisfies the builtin error interface

func (LinkAccountRequestValidationError) ErrorName

ErrorName returns error name.

func (LinkAccountRequestValidationError) Field

Field function returns field value.

func (LinkAccountRequestValidationError) Key

Key function returns key value.

func (LinkAccountRequestValidationError) Reason

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 (*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

Cause function returns cause value.

func (LinkAccountResponseValidationError) Error

Error satisfies the builtin error interface

func (LinkAccountResponseValidationError) ErrorName

ErrorName returns error name.

func (LinkAccountResponseValidationError) Field

Field function returns field value.

func (LinkAccountResponseValidationError) Key

Key function returns key value.

func (LinkAccountResponseValidationError) Reason

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) Enum

func (LinkAccountResponse_Result) EnumDescriptor deprecated

func (LinkAccountResponse_Result) EnumDescriptor() ([]byte, []int)

Deprecated: Use LinkAccountResponse_Result.Descriptor instead.

func (LinkAccountResponse_Result) Number

func (LinkAccountResponse_Result) String

func (LinkAccountResponse_Result) Type

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

Cause function returns cause value.

func (PhoneMetadataValidationError) Error

Error satisfies the builtin error interface

func (PhoneMetadataValidationError) ErrorName

func (e PhoneMetadataValidationError) ErrorName() string

ErrorName returns error name.

func (PhoneMetadataValidationError) Field

Field function returns field value.

func (PhoneMetadataValidationError) Key

Key function returns key value.

func (PhoneMetadataValidationError) Reason

Reason function returns reason value.

type UnimplementedIdentityServer

type UnimplementedIdentityServer struct {
}

UnimplementedIdentityServer must be embedded to have forward compatible implementations.

func (UnimplementedIdentityServer) GetUser

func (UnimplementedIdentityServer) LinkAccount

func (UnimplementedIdentityServer) UnlinkAccount

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

Cause function returns cause value.

func (UnlinkAccountRequestValidationError) Error

Error satisfies the builtin error interface

func (UnlinkAccountRequestValidationError) ErrorName

ErrorName returns error name.

func (UnlinkAccountRequestValidationError) Field

Field function returns field value.

func (UnlinkAccountRequestValidationError) Key

Key function returns key value.

func (UnlinkAccountRequestValidationError) Reason

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 (*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

Cause function returns cause value.

func (UnlinkAccountResponseValidationError) Error

Error satisfies the builtin error interface

func (UnlinkAccountResponseValidationError) ErrorName

ErrorName returns error name.

func (UnlinkAccountResponseValidationError) Field

Field function returns field value.

func (UnlinkAccountResponseValidationError) Key

Key function returns key value.

func (UnlinkAccountResponseValidationError) Reason

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) Enum

func (UnlinkAccountResponse_Result) EnumDescriptor deprecated

func (UnlinkAccountResponse_Result) EnumDescriptor() ([]byte, []int)

Deprecated: Use UnlinkAccountResponse_Result.Descriptor instead.

func (UnlinkAccountResponse_Result) Number

func (UnlinkAccountResponse_Result) String

func (UnlinkAccountResponse_Result) Type

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) Descriptor() ([]byte, []int)

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetId

func (x *User) GetId() *v1.UserId

func (*User) GetView

func (x *User) GetView() *View

func (*User) ProtoMessage

func (*User) ProtoMessage()

func (*User) ProtoReflect

func (x *User) ProtoReflect() protoreflect.Message

func (*User) Reset

func (x *User) Reset()

func (*User) String

func (x *User) String() string

func (*User) Validate

func (m *User) Validate() error

Validate checks the field values on User with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

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) Descriptor() ([]byte, []int)

Deprecated: Use View.ProtoReflect.Descriptor instead.

func (*View) GetPhoneNumber

func (x *View) GetPhoneNumber() *v1.PhoneNumber

func (*View) ProtoMessage

func (*View) ProtoMessage()

func (*View) ProtoReflect

func (x *View) ProtoReflect() protoreflect.Message

func (*View) Reset

func (x *View) Reset()

func (*View) String

func (x *View) String() string

func (*View) Validate

func (m *View) Validate() error

Validate checks the field values on View with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL