Documentation ¶
Index ¶
- Variables
- func RegisterPhoneVerificationServer(s grpc.ServiceRegistrar, srv PhoneVerificationServer)
- type CheckVerificationCodeRequest
- func (*CheckVerificationCodeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CheckVerificationCodeRequest) GetCode() *VerificationCode
- func (x *CheckVerificationCodeRequest) GetPhoneNumber() *v1.PhoneNumber
- func (*CheckVerificationCodeRequest) ProtoMessage()
- func (x *CheckVerificationCodeRequest) ProtoReflect() protoreflect.Message
- func (x *CheckVerificationCodeRequest) Reset()
- func (x *CheckVerificationCodeRequest) String() string
- func (m *CheckVerificationCodeRequest) Validate() error
- type CheckVerificationCodeRequestValidationError
- func (e CheckVerificationCodeRequestValidationError) Cause() error
- func (e CheckVerificationCodeRequestValidationError) Error() string
- func (e CheckVerificationCodeRequestValidationError) ErrorName() string
- func (e CheckVerificationCodeRequestValidationError) Field() string
- func (e CheckVerificationCodeRequestValidationError) Key() bool
- func (e CheckVerificationCodeRequestValidationError) Reason() string
- type CheckVerificationCodeResponse
- func (*CheckVerificationCodeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CheckVerificationCodeResponse) GetLinkingToken() *PhoneLinkingToken
- func (x *CheckVerificationCodeResponse) GetResult() CheckVerificationCodeResponse_Result
- func (*CheckVerificationCodeResponse) ProtoMessage()
- func (x *CheckVerificationCodeResponse) ProtoReflect() protoreflect.Message
- func (x *CheckVerificationCodeResponse) Reset()
- func (x *CheckVerificationCodeResponse) String() string
- func (m *CheckVerificationCodeResponse) Validate() error
- type CheckVerificationCodeResponseValidationError
- func (e CheckVerificationCodeResponseValidationError) Cause() error
- func (e CheckVerificationCodeResponseValidationError) Error() string
- func (e CheckVerificationCodeResponseValidationError) ErrorName() string
- func (e CheckVerificationCodeResponseValidationError) Field() string
- func (e CheckVerificationCodeResponseValidationError) Key() bool
- func (e CheckVerificationCodeResponseValidationError) Reason() string
- type CheckVerificationCodeResponse_Result
- func (CheckVerificationCodeResponse_Result) Descriptor() protoreflect.EnumDescriptor
- func (x CheckVerificationCodeResponse_Result) Enum() *CheckVerificationCodeResponse_Result
- func (CheckVerificationCodeResponse_Result) EnumDescriptor() ([]byte, []int)deprecated
- func (x CheckVerificationCodeResponse_Result) Number() protoreflect.EnumNumber
- func (x CheckVerificationCodeResponse_Result) String() string
- func (CheckVerificationCodeResponse_Result) Type() protoreflect.EnumType
- type GetAssociatedPhoneNumberRequest
- func (*GetAssociatedPhoneNumberRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetAssociatedPhoneNumberRequest) GetOwnerAccountId() *v1.SolanaAccountId
- func (x *GetAssociatedPhoneNumberRequest) GetSignature() *v1.Signature
- func (*GetAssociatedPhoneNumberRequest) ProtoMessage()
- func (x *GetAssociatedPhoneNumberRequest) ProtoReflect() protoreflect.Message
- func (x *GetAssociatedPhoneNumberRequest) Reset()
- func (x *GetAssociatedPhoneNumberRequest) String() string
- func (m *GetAssociatedPhoneNumberRequest) Validate() error
- type GetAssociatedPhoneNumberRequestValidationError
- func (e GetAssociatedPhoneNumberRequestValidationError) Cause() error
- func (e GetAssociatedPhoneNumberRequestValidationError) Error() string
- func (e GetAssociatedPhoneNumberRequestValidationError) ErrorName() string
- func (e GetAssociatedPhoneNumberRequestValidationError) Field() string
- func (e GetAssociatedPhoneNumberRequestValidationError) Key() bool
- func (e GetAssociatedPhoneNumberRequestValidationError) Reason() string
- type GetAssociatedPhoneNumberResponse
- func (*GetAssociatedPhoneNumberResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetAssociatedPhoneNumberResponse) GetIsLinked() bool
- func (x *GetAssociatedPhoneNumberResponse) GetPhoneNumber() *v1.PhoneNumber
- func (x *GetAssociatedPhoneNumberResponse) GetResult() GetAssociatedPhoneNumberResponse_Result
- func (*GetAssociatedPhoneNumberResponse) ProtoMessage()
- func (x *GetAssociatedPhoneNumberResponse) ProtoReflect() protoreflect.Message
- func (x *GetAssociatedPhoneNumberResponse) Reset()
- func (x *GetAssociatedPhoneNumberResponse) String() string
- func (m *GetAssociatedPhoneNumberResponse) Validate() error
- type GetAssociatedPhoneNumberResponseValidationError
- func (e GetAssociatedPhoneNumberResponseValidationError) Cause() error
- func (e GetAssociatedPhoneNumberResponseValidationError) Error() string
- func (e GetAssociatedPhoneNumberResponseValidationError) ErrorName() string
- func (e GetAssociatedPhoneNumberResponseValidationError) Field() string
- func (e GetAssociatedPhoneNumberResponseValidationError) Key() bool
- func (e GetAssociatedPhoneNumberResponseValidationError) Reason() string
- type GetAssociatedPhoneNumberResponse_Result
- func (GetAssociatedPhoneNumberResponse_Result) Descriptor() protoreflect.EnumDescriptor
- func (x GetAssociatedPhoneNumberResponse_Result) Enum() *GetAssociatedPhoneNumberResponse_Result
- func (GetAssociatedPhoneNumberResponse_Result) EnumDescriptor() ([]byte, []int)deprecated
- func (x GetAssociatedPhoneNumberResponse_Result) Number() protoreflect.EnumNumber
- func (x GetAssociatedPhoneNumberResponse_Result) String() string
- func (GetAssociatedPhoneNumberResponse_Result) Type() protoreflect.EnumType
- type PhoneLinkingToken
- func (*PhoneLinkingToken) Descriptor() ([]byte, []int)deprecated
- func (x *PhoneLinkingToken) GetCode() *VerificationCode
- func (x *PhoneLinkingToken) GetPhoneNumber() *v1.PhoneNumber
- func (*PhoneLinkingToken) ProtoMessage()
- func (x *PhoneLinkingToken) ProtoReflect() protoreflect.Message
- func (x *PhoneLinkingToken) Reset()
- func (x *PhoneLinkingToken) String() string
- func (m *PhoneLinkingToken) Validate() error
- type PhoneLinkingTokenValidationError
- func (e PhoneLinkingTokenValidationError) Cause() error
- func (e PhoneLinkingTokenValidationError) Error() string
- func (e PhoneLinkingTokenValidationError) ErrorName() string
- func (e PhoneLinkingTokenValidationError) Field() string
- func (e PhoneLinkingTokenValidationError) Key() bool
- func (e PhoneLinkingTokenValidationError) Reason() string
- type PhoneVerificationClient
- type PhoneVerificationServer
- type SendVerificationCodeRequest
- func (*SendVerificationCodeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SendVerificationCodeRequest) GetDeviceToken() *v1.DeviceToken
- func (x *SendVerificationCodeRequest) GetPhoneNumber() *v1.PhoneNumber
- func (*SendVerificationCodeRequest) ProtoMessage()
- func (x *SendVerificationCodeRequest) ProtoReflect() protoreflect.Message
- func (x *SendVerificationCodeRequest) Reset()
- func (x *SendVerificationCodeRequest) String() string
- func (m *SendVerificationCodeRequest) Validate() error
- type SendVerificationCodeRequestValidationError
- func (e SendVerificationCodeRequestValidationError) Cause() error
- func (e SendVerificationCodeRequestValidationError) Error() string
- func (e SendVerificationCodeRequestValidationError) ErrorName() string
- func (e SendVerificationCodeRequestValidationError) Field() string
- func (e SendVerificationCodeRequestValidationError) Key() bool
- func (e SendVerificationCodeRequestValidationError) Reason() string
- type SendVerificationCodeResponse
- func (*SendVerificationCodeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SendVerificationCodeResponse) GetResult() SendVerificationCodeResponse_Result
- func (*SendVerificationCodeResponse) ProtoMessage()
- func (x *SendVerificationCodeResponse) ProtoReflect() protoreflect.Message
- func (x *SendVerificationCodeResponse) Reset()
- func (x *SendVerificationCodeResponse) String() string
- func (m *SendVerificationCodeResponse) Validate() error
- type SendVerificationCodeResponseValidationError
- func (e SendVerificationCodeResponseValidationError) Cause() error
- func (e SendVerificationCodeResponseValidationError) Error() string
- func (e SendVerificationCodeResponseValidationError) ErrorName() string
- func (e SendVerificationCodeResponseValidationError) Field() string
- func (e SendVerificationCodeResponseValidationError) Key() bool
- func (e SendVerificationCodeResponseValidationError) Reason() string
- type SendVerificationCodeResponse_Result
- func (SendVerificationCodeResponse_Result) Descriptor() protoreflect.EnumDescriptor
- func (x SendVerificationCodeResponse_Result) Enum() *SendVerificationCodeResponse_Result
- func (SendVerificationCodeResponse_Result) EnumDescriptor() ([]byte, []int)deprecated
- func (x SendVerificationCodeResponse_Result) Number() protoreflect.EnumNumber
- func (x SendVerificationCodeResponse_Result) String() string
- func (SendVerificationCodeResponse_Result) Type() protoreflect.EnumType
- type UnimplementedPhoneVerificationServer
- func (UnimplementedPhoneVerificationServer) CheckVerificationCode(context.Context, *CheckVerificationCodeRequest) (*CheckVerificationCodeResponse, error)
- func (UnimplementedPhoneVerificationServer) GetAssociatedPhoneNumber(context.Context, *GetAssociatedPhoneNumberRequest) (*GetAssociatedPhoneNumberResponse, error)
- func (UnimplementedPhoneVerificationServer) SendVerificationCode(context.Context, *SendVerificationCodeRequest) (*SendVerificationCodeResponse, error)
- type UnsafePhoneVerificationServer
- type VerificationCode
- func (*VerificationCode) Descriptor() ([]byte, []int)deprecated
- func (x *VerificationCode) GetValue() string
- func (*VerificationCode) ProtoMessage()
- func (x *VerificationCode) ProtoReflect() protoreflect.Message
- func (x *VerificationCode) Reset()
- func (x *VerificationCode) String() string
- func (m *VerificationCode) Validate() error
- type VerificationCodeValidationError
- func (e VerificationCodeValidationError) Cause() error
- func (e VerificationCodeValidationError) Error() string
- func (e VerificationCodeValidationError) ErrorName() string
- func (e VerificationCodeValidationError) Field() string
- func (e VerificationCodeValidationError) Key() bool
- func (e VerificationCodeValidationError) Reason() string
Constants ¶
This section is empty.
Variables ¶
var ( SendVerificationCodeResponse_Result_name = map[int32]string{ 0: "OK", 1: "NOT_INVITED", 2: "RATE_LIMITED", 3: "INVALID_PHONE_NUMBER", 4: "UNSUPPORTED_PHONE_TYPE", } SendVerificationCodeResponse_Result_value = map[string]int32{ "OK": 0, "NOT_INVITED": 1, "RATE_LIMITED": 2, "INVALID_PHONE_NUMBER": 3, "UNSUPPORTED_PHONE_TYPE": 4, } )
Enum value maps for SendVerificationCodeResponse_Result.
var ( CheckVerificationCodeResponse_Result_name = map[int32]string{ 0: "OK", 1: "INVALID_CODE", 2: "NO_VERIFICATION", 3: "RATE_LIMITED", } CheckVerificationCodeResponse_Result_value = map[string]int32{ "OK": 0, "INVALID_CODE": 1, "NO_VERIFICATION": 2, "RATE_LIMITED": 3, } )
Enum value maps for CheckVerificationCodeResponse_Result.
var ( GetAssociatedPhoneNumberResponse_Result_name = map[int32]string{ 0: "OK", 1: "NOT_FOUND", 2: "NOT_INVITED", 3: "UNLOCKED_TIMELOCK_ACCOUNT", } GetAssociatedPhoneNumberResponse_Result_value = map[string]int32{ "OK": 0, "NOT_FOUND": 1, "NOT_INVITED": 2, "UNLOCKED_TIMELOCK_ACCOUNT": 3, } )
Enum value maps for GetAssociatedPhoneNumberResponse_Result.
var File_phone_v1_phone_verification_service_proto protoreflect.FileDescriptor
var PhoneVerification_ServiceDesc = grpc.ServiceDesc{ ServiceName: "code.phone.v1.PhoneVerification", HandlerType: (*PhoneVerificationServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "SendVerificationCode", Handler: _PhoneVerification_SendVerificationCode_Handler, }, { MethodName: "CheckVerificationCode", Handler: _PhoneVerification_CheckVerificationCode_Handler, }, { MethodName: "GetAssociatedPhoneNumber", Handler: _PhoneVerification_GetAssociatedPhoneNumber_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "phone/v1/phone_verification_service.proto", }
PhoneVerification_ServiceDesc is the grpc.ServiceDesc for PhoneVerification service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterPhoneVerificationServer ¶
func RegisterPhoneVerificationServer(s grpc.ServiceRegistrar, srv PhoneVerificationServer)
Types ¶
type CheckVerificationCodeRequest ¶
type CheckVerificationCodeRequest struct { // The phone number being verified. PhoneNumber *v1.PhoneNumber `protobuf:"bytes,1,opt,name=phone_number,json=phoneNumber,proto3" json:"phone_number,omitempty"` // The verification code received via SMS. Code *VerificationCode `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"` // contains filtered or unexported fields }
func (*CheckVerificationCodeRequest) Descriptor
deprecated
func (*CheckVerificationCodeRequest) Descriptor() ([]byte, []int)
Deprecated: Use CheckVerificationCodeRequest.ProtoReflect.Descriptor instead.
func (*CheckVerificationCodeRequest) GetCode ¶
func (x *CheckVerificationCodeRequest) GetCode() *VerificationCode
func (*CheckVerificationCodeRequest) GetPhoneNumber ¶
func (x *CheckVerificationCodeRequest) GetPhoneNumber() *v1.PhoneNumber
func (*CheckVerificationCodeRequest) ProtoMessage ¶
func (*CheckVerificationCodeRequest) ProtoMessage()
func (*CheckVerificationCodeRequest) ProtoReflect ¶
func (x *CheckVerificationCodeRequest) ProtoReflect() protoreflect.Message
func (*CheckVerificationCodeRequest) Reset ¶
func (x *CheckVerificationCodeRequest) Reset()
func (*CheckVerificationCodeRequest) String ¶
func (x *CheckVerificationCodeRequest) String() string
func (*CheckVerificationCodeRequest) Validate ¶
func (m *CheckVerificationCodeRequest) Validate() error
Validate checks the field values on CheckVerificationCodeRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type CheckVerificationCodeRequestValidationError ¶
type CheckVerificationCodeRequestValidationError struct {
// contains filtered or unexported fields
}
CheckVerificationCodeRequestValidationError is the validation error returned by CheckVerificationCodeRequest.Validate if the designated constraints aren't met.
func (CheckVerificationCodeRequestValidationError) Cause ¶
func (e CheckVerificationCodeRequestValidationError) Cause() error
Cause function returns cause value.
func (CheckVerificationCodeRequestValidationError) Error ¶
func (e CheckVerificationCodeRequestValidationError) Error() string
Error satisfies the builtin error interface
func (CheckVerificationCodeRequestValidationError) ErrorName ¶
func (e CheckVerificationCodeRequestValidationError) ErrorName() string
ErrorName returns error name.
func (CheckVerificationCodeRequestValidationError) Field ¶
func (e CheckVerificationCodeRequestValidationError) Field() string
Field function returns field value.
func (CheckVerificationCodeRequestValidationError) Key ¶
func (e CheckVerificationCodeRequestValidationError) Key() bool
Key function returns key value.
func (CheckVerificationCodeRequestValidationError) Reason ¶
func (e CheckVerificationCodeRequestValidationError) Reason() string
Reason function returns reason value.
type CheckVerificationCodeResponse ¶
type CheckVerificationCodeResponse struct { Result CheckVerificationCodeResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=code.phone.v1.CheckVerificationCodeResponse_Result" json:"result,omitempty"` // The token used to associate an owner account to a user using the verified // phone number. LinkingToken *PhoneLinkingToken `protobuf:"bytes,2,opt,name=linking_token,json=linkingToken,proto3" json:"linking_token,omitempty"` // contains filtered or unexported fields }
func (*CheckVerificationCodeResponse) Descriptor
deprecated
func (*CheckVerificationCodeResponse) Descriptor() ([]byte, []int)
Deprecated: Use CheckVerificationCodeResponse.ProtoReflect.Descriptor instead.
func (*CheckVerificationCodeResponse) GetLinkingToken ¶
func (x *CheckVerificationCodeResponse) GetLinkingToken() *PhoneLinkingToken
func (*CheckVerificationCodeResponse) GetResult ¶
func (x *CheckVerificationCodeResponse) GetResult() CheckVerificationCodeResponse_Result
func (*CheckVerificationCodeResponse) ProtoMessage ¶
func (*CheckVerificationCodeResponse) ProtoMessage()
func (*CheckVerificationCodeResponse) ProtoReflect ¶
func (x *CheckVerificationCodeResponse) ProtoReflect() protoreflect.Message
func (*CheckVerificationCodeResponse) Reset ¶
func (x *CheckVerificationCodeResponse) Reset()
func (*CheckVerificationCodeResponse) String ¶
func (x *CheckVerificationCodeResponse) String() string
func (*CheckVerificationCodeResponse) Validate ¶
func (m *CheckVerificationCodeResponse) Validate() error
Validate checks the field values on CheckVerificationCodeResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type CheckVerificationCodeResponseValidationError ¶
type CheckVerificationCodeResponseValidationError struct {
// contains filtered or unexported fields
}
CheckVerificationCodeResponseValidationError is the validation error returned by CheckVerificationCodeResponse.Validate if the designated constraints aren't met.
func (CheckVerificationCodeResponseValidationError) Cause ¶
func (e CheckVerificationCodeResponseValidationError) Cause() error
Cause function returns cause value.
func (CheckVerificationCodeResponseValidationError) Error ¶
func (e CheckVerificationCodeResponseValidationError) Error() string
Error satisfies the builtin error interface
func (CheckVerificationCodeResponseValidationError) ErrorName ¶
func (e CheckVerificationCodeResponseValidationError) ErrorName() string
ErrorName returns error name.
func (CheckVerificationCodeResponseValidationError) Field ¶
func (e CheckVerificationCodeResponseValidationError) Field() string
Field function returns field value.
func (CheckVerificationCodeResponseValidationError) Key ¶
func (e CheckVerificationCodeResponseValidationError) Key() bool
Key function returns key value.
func (CheckVerificationCodeResponseValidationError) Reason ¶
func (e CheckVerificationCodeResponseValidationError) Reason() string
Reason function returns reason value.
type CheckVerificationCodeResponse_Result ¶
type CheckVerificationCodeResponse_Result int32
const ( CheckVerificationCodeResponse_OK CheckVerificationCodeResponse_Result = 0 // The provided verification code is invalid. The user may retry // enterring the code if this is received. When max attempts are // received, NO_VERIFICATION will be returned. CheckVerificationCodeResponse_INVALID_CODE CheckVerificationCodeResponse_Result = 1 // There is no verification in progress for the phone number. Several // reasons this can occur include a verification being expired or having // reached a maximum check threshold. The client must initiate a new // verification using SendVerificationCode. CheckVerificationCodeResponse_NO_VERIFICATION CheckVerificationCodeResponse_Result = 2 // The call is rate limited (eg. by IP, phone number, etc). The code is // not verified. CheckVerificationCodeResponse_RATE_LIMITED CheckVerificationCodeResponse_Result = 3 )
func (CheckVerificationCodeResponse_Result) Descriptor ¶
func (CheckVerificationCodeResponse_Result) Descriptor() protoreflect.EnumDescriptor
func (CheckVerificationCodeResponse_Result) Enum ¶
func (x CheckVerificationCodeResponse_Result) Enum() *CheckVerificationCodeResponse_Result
func (CheckVerificationCodeResponse_Result) EnumDescriptor
deprecated
func (CheckVerificationCodeResponse_Result) EnumDescriptor() ([]byte, []int)
Deprecated: Use CheckVerificationCodeResponse_Result.Descriptor instead.
func (CheckVerificationCodeResponse_Result) Number ¶
func (x CheckVerificationCodeResponse_Result) Number() protoreflect.EnumNumber
func (CheckVerificationCodeResponse_Result) String ¶
func (x CheckVerificationCodeResponse_Result) String() string
func (CheckVerificationCodeResponse_Result) Type ¶
func (CheckVerificationCodeResponse_Result) Type() protoreflect.EnumType
type GetAssociatedPhoneNumberRequest ¶
type GetAssociatedPhoneNumberRequest struct { // The public key of the owner account that is being queried for a linked // phone number. OwnerAccountId *v1.SolanaAccountId `protobuf:"bytes,1,opt,name=owner_account_id,json=ownerAccountId,proto3" json:"owner_account_id,omitempty"` // The signature is of serialize(GetAssociatedPhoneNumberRequest) 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"` // contains filtered or unexported fields }
func (*GetAssociatedPhoneNumberRequest) Descriptor
deprecated
func (*GetAssociatedPhoneNumberRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetAssociatedPhoneNumberRequest.ProtoReflect.Descriptor instead.
func (*GetAssociatedPhoneNumberRequest) GetOwnerAccountId ¶
func (x *GetAssociatedPhoneNumberRequest) GetOwnerAccountId() *v1.SolanaAccountId
func (*GetAssociatedPhoneNumberRequest) GetSignature ¶
func (x *GetAssociatedPhoneNumberRequest) GetSignature() *v1.Signature
func (*GetAssociatedPhoneNumberRequest) ProtoMessage ¶
func (*GetAssociatedPhoneNumberRequest) ProtoMessage()
func (*GetAssociatedPhoneNumberRequest) ProtoReflect ¶
func (x *GetAssociatedPhoneNumberRequest) ProtoReflect() protoreflect.Message
func (*GetAssociatedPhoneNumberRequest) Reset ¶
func (x *GetAssociatedPhoneNumberRequest) Reset()
func (*GetAssociatedPhoneNumberRequest) String ¶
func (x *GetAssociatedPhoneNumberRequest) String() string
func (*GetAssociatedPhoneNumberRequest) Validate ¶
func (m *GetAssociatedPhoneNumberRequest) Validate() error
Validate checks the field values on GetAssociatedPhoneNumberRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type GetAssociatedPhoneNumberRequestValidationError ¶
type GetAssociatedPhoneNumberRequestValidationError struct {
// contains filtered or unexported fields
}
GetAssociatedPhoneNumberRequestValidationError is the validation error returned by GetAssociatedPhoneNumberRequest.Validate if the designated constraints aren't met.
func (GetAssociatedPhoneNumberRequestValidationError) Cause ¶
func (e GetAssociatedPhoneNumberRequestValidationError) Cause() error
Cause function returns cause value.
func (GetAssociatedPhoneNumberRequestValidationError) Error ¶
func (e GetAssociatedPhoneNumberRequestValidationError) Error() string
Error satisfies the builtin error interface
func (GetAssociatedPhoneNumberRequestValidationError) ErrorName ¶
func (e GetAssociatedPhoneNumberRequestValidationError) ErrorName() string
ErrorName returns error name.
func (GetAssociatedPhoneNumberRequestValidationError) Field ¶
func (e GetAssociatedPhoneNumberRequestValidationError) Field() string
Field function returns field value.
func (GetAssociatedPhoneNumberRequestValidationError) Key ¶
func (e GetAssociatedPhoneNumberRequestValidationError) Key() bool
Key function returns key value.
func (GetAssociatedPhoneNumberRequestValidationError) Reason ¶
func (e GetAssociatedPhoneNumberRequestValidationError) Reason() string
Reason function returns reason value.
type GetAssociatedPhoneNumberResponse ¶
type GetAssociatedPhoneNumberResponse struct { Result GetAssociatedPhoneNumberResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=code.phone.v1.GetAssociatedPhoneNumberResponse_Result" json:"result,omitempty"` // The latest phone number associated with the owner account. PhoneNumber *v1.PhoneNumber `protobuf:"bytes,2,opt,name=phone_number,json=phoneNumber,proto3" json:"phone_number,omitempty"` // 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,3,opt,name=is_linked,json=isLinked,proto3" json:"is_linked,omitempty"` // contains filtered or unexported fields }
func (*GetAssociatedPhoneNumberResponse) Descriptor
deprecated
func (*GetAssociatedPhoneNumberResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetAssociatedPhoneNumberResponse.ProtoReflect.Descriptor instead.
func (*GetAssociatedPhoneNumberResponse) GetIsLinked ¶
func (x *GetAssociatedPhoneNumberResponse) GetIsLinked() bool
func (*GetAssociatedPhoneNumberResponse) GetPhoneNumber ¶
func (x *GetAssociatedPhoneNumberResponse) GetPhoneNumber() *v1.PhoneNumber
func (*GetAssociatedPhoneNumberResponse) GetResult ¶
func (x *GetAssociatedPhoneNumberResponse) GetResult() GetAssociatedPhoneNumberResponse_Result
func (*GetAssociatedPhoneNumberResponse) ProtoMessage ¶
func (*GetAssociatedPhoneNumberResponse) ProtoMessage()
func (*GetAssociatedPhoneNumberResponse) ProtoReflect ¶
func (x *GetAssociatedPhoneNumberResponse) ProtoReflect() protoreflect.Message
func (*GetAssociatedPhoneNumberResponse) Reset ¶
func (x *GetAssociatedPhoneNumberResponse) Reset()
func (*GetAssociatedPhoneNumberResponse) String ¶
func (x *GetAssociatedPhoneNumberResponse) String() string
func (*GetAssociatedPhoneNumberResponse) Validate ¶
func (m *GetAssociatedPhoneNumberResponse) Validate() error
Validate checks the field values on GetAssociatedPhoneNumberResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type GetAssociatedPhoneNumberResponseValidationError ¶
type GetAssociatedPhoneNumberResponseValidationError struct {
// contains filtered or unexported fields
}
GetAssociatedPhoneNumberResponseValidationError is the validation error returned by GetAssociatedPhoneNumberResponse.Validate if the designated constraints aren't met.
func (GetAssociatedPhoneNumberResponseValidationError) Cause ¶
func (e GetAssociatedPhoneNumberResponseValidationError) Cause() error
Cause function returns cause value.
func (GetAssociatedPhoneNumberResponseValidationError) Error ¶
func (e GetAssociatedPhoneNumberResponseValidationError) Error() string
Error satisfies the builtin error interface
func (GetAssociatedPhoneNumberResponseValidationError) ErrorName ¶
func (e GetAssociatedPhoneNumberResponseValidationError) ErrorName() string
ErrorName returns error name.
func (GetAssociatedPhoneNumberResponseValidationError) Field ¶
func (e GetAssociatedPhoneNumberResponseValidationError) Field() string
Field function returns field value.
func (GetAssociatedPhoneNumberResponseValidationError) Key ¶
func (e GetAssociatedPhoneNumberResponseValidationError) Key() bool
Key function returns key value.
func (GetAssociatedPhoneNumberResponseValidationError) Reason ¶
func (e GetAssociatedPhoneNumberResponseValidationError) Reason() string
Reason function returns reason value.
type GetAssociatedPhoneNumberResponse_Result ¶
type GetAssociatedPhoneNumberResponse_Result int32
const ( GetAssociatedPhoneNumberResponse_OK GetAssociatedPhoneNumberResponse_Result = 0 // A phone number is not associated with the provided owner account. GetAssociatedPhoneNumberResponse_NOT_FOUND GetAssociatedPhoneNumberResponse_Result = 1 // The phone number exists, but is no longer invited GetAssociatedPhoneNumberResponse_NOT_INVITED GetAssociatedPhoneNumberResponse_Result = 2 // The phone number exists, but at least one timelock account is unlocked GetAssociatedPhoneNumberResponse_UNLOCKED_TIMELOCK_ACCOUNT GetAssociatedPhoneNumberResponse_Result = 3 )
func (GetAssociatedPhoneNumberResponse_Result) Descriptor ¶
func (GetAssociatedPhoneNumberResponse_Result) Descriptor() protoreflect.EnumDescriptor
func (GetAssociatedPhoneNumberResponse_Result) EnumDescriptor
deprecated
func (GetAssociatedPhoneNumberResponse_Result) EnumDescriptor() ([]byte, []int)
Deprecated: Use GetAssociatedPhoneNumberResponse_Result.Descriptor instead.
func (GetAssociatedPhoneNumberResponse_Result) Number ¶
func (x GetAssociatedPhoneNumberResponse_Result) Number() protoreflect.EnumNumber
func (GetAssociatedPhoneNumberResponse_Result) String ¶
func (x GetAssociatedPhoneNumberResponse_Result) String() string
func (GetAssociatedPhoneNumberResponse_Result) Type ¶
func (GetAssociatedPhoneNumberResponse_Result) Type() protoreflect.EnumType
type PhoneLinkingToken ¶
type PhoneLinkingToken struct { // The verified phone number. PhoneNumber *v1.PhoneNumber `protobuf:"bytes,1,opt,name=phone_number,json=phoneNumber,proto3" json:"phone_number,omitempty"` // The code that verified the phone number. Code *VerificationCode `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"` // contains filtered or unexported fields }
A one-time use token that can be provided to the Identity service to link an owner account to a user with the verified phone number. The client should treat this token as opaque.
func (*PhoneLinkingToken) Descriptor
deprecated
func (*PhoneLinkingToken) Descriptor() ([]byte, []int)
Deprecated: Use PhoneLinkingToken.ProtoReflect.Descriptor instead.
func (*PhoneLinkingToken) GetCode ¶
func (x *PhoneLinkingToken) GetCode() *VerificationCode
func (*PhoneLinkingToken) GetPhoneNumber ¶
func (x *PhoneLinkingToken) GetPhoneNumber() *v1.PhoneNumber
func (*PhoneLinkingToken) ProtoMessage ¶
func (*PhoneLinkingToken) ProtoMessage()
func (*PhoneLinkingToken) ProtoReflect ¶
func (x *PhoneLinkingToken) ProtoReflect() protoreflect.Message
func (*PhoneLinkingToken) Reset ¶
func (x *PhoneLinkingToken) Reset()
func (*PhoneLinkingToken) String ¶
func (x *PhoneLinkingToken) String() string
func (*PhoneLinkingToken) Validate ¶
func (m *PhoneLinkingToken) Validate() error
Validate checks the field values on PhoneLinkingToken with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type PhoneLinkingTokenValidationError ¶
type PhoneLinkingTokenValidationError struct {
// contains filtered or unexported fields
}
PhoneLinkingTokenValidationError is the validation error returned by PhoneLinkingToken.Validate if the designated constraints aren't met.
func (PhoneLinkingTokenValidationError) Cause ¶
func (e PhoneLinkingTokenValidationError) Cause() error
Cause function returns cause value.
func (PhoneLinkingTokenValidationError) Error ¶
func (e PhoneLinkingTokenValidationError) Error() string
Error satisfies the builtin error interface
func (PhoneLinkingTokenValidationError) ErrorName ¶
func (e PhoneLinkingTokenValidationError) ErrorName() string
ErrorName returns error name.
func (PhoneLinkingTokenValidationError) Field ¶
func (e PhoneLinkingTokenValidationError) Field() string
Field function returns field value.
func (PhoneLinkingTokenValidationError) Key ¶
func (e PhoneLinkingTokenValidationError) Key() bool
Key function returns key value.
func (PhoneLinkingTokenValidationError) Reason ¶
func (e PhoneLinkingTokenValidationError) Reason() string
Reason function returns reason value.
type PhoneVerificationClient ¶
type PhoneVerificationClient interface { // SendVerificationCode sends a verification code to the provided phone number // over SMS. If an active verification is already taking place, the existing code // will be resent. SendVerificationCode(ctx context.Context, in *SendVerificationCodeRequest, opts ...grpc.CallOption) (*SendVerificationCodeResponse, error) // CheckVerificationCode validates a verification code. On success, a one-time use // token to link an owner account is provided. CheckVerificationCode(ctx context.Context, in *CheckVerificationCodeRequest, opts ...grpc.CallOption) (*CheckVerificationCodeResponse, error) // GetAssociatedPhoneNumber gets the latest verified phone number linked to an owner account. GetAssociatedPhoneNumber(ctx context.Context, in *GetAssociatedPhoneNumberRequest, opts ...grpc.CallOption) (*GetAssociatedPhoneNumberResponse, error) }
PhoneVerificationClient is the client API for PhoneVerification 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 NewPhoneVerificationClient ¶
func NewPhoneVerificationClient(cc grpc.ClientConnInterface) PhoneVerificationClient
type PhoneVerificationServer ¶
type PhoneVerificationServer interface { // SendVerificationCode sends a verification code to the provided phone number // over SMS. If an active verification is already taking place, the existing code // will be resent. SendVerificationCode(context.Context, *SendVerificationCodeRequest) (*SendVerificationCodeResponse, error) // CheckVerificationCode validates a verification code. On success, a one-time use // token to link an owner account is provided. CheckVerificationCode(context.Context, *CheckVerificationCodeRequest) (*CheckVerificationCodeResponse, error) // GetAssociatedPhoneNumber gets the latest verified phone number linked to an owner account. GetAssociatedPhoneNumber(context.Context, *GetAssociatedPhoneNumberRequest) (*GetAssociatedPhoneNumberResponse, error) // contains filtered or unexported methods }
PhoneVerificationServer is the server API for PhoneVerification service. All implementations must embed UnimplementedPhoneVerificationServer for forward compatibility
type SendVerificationCodeRequest ¶
type SendVerificationCodeRequest struct { // The phone number to send a verification code over SMS to. PhoneNumber *v1.PhoneNumber `protobuf:"bytes,1,opt,name=phone_number,json=phoneNumber,proto3" json:"phone_number,omitempty"` // Device token for antispam measures against fake devices DeviceToken *v1.DeviceToken `protobuf:"bytes,2,opt,name=device_token,json=deviceToken,proto3" json:"device_token,omitempty"` // contains filtered or unexported fields }
func (*SendVerificationCodeRequest) Descriptor
deprecated
func (*SendVerificationCodeRequest) Descriptor() ([]byte, []int)
Deprecated: Use SendVerificationCodeRequest.ProtoReflect.Descriptor instead.
func (*SendVerificationCodeRequest) GetDeviceToken ¶
func (x *SendVerificationCodeRequest) GetDeviceToken() *v1.DeviceToken
func (*SendVerificationCodeRequest) GetPhoneNumber ¶
func (x *SendVerificationCodeRequest) GetPhoneNumber() *v1.PhoneNumber
func (*SendVerificationCodeRequest) ProtoMessage ¶
func (*SendVerificationCodeRequest) ProtoMessage()
func (*SendVerificationCodeRequest) ProtoReflect ¶
func (x *SendVerificationCodeRequest) ProtoReflect() protoreflect.Message
func (*SendVerificationCodeRequest) Reset ¶
func (x *SendVerificationCodeRequest) Reset()
func (*SendVerificationCodeRequest) String ¶
func (x *SendVerificationCodeRequest) String() string
func (*SendVerificationCodeRequest) Validate ¶
func (m *SendVerificationCodeRequest) Validate() error
Validate checks the field values on SendVerificationCodeRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type SendVerificationCodeRequestValidationError ¶
type SendVerificationCodeRequestValidationError struct {
// contains filtered or unexported fields
}
SendVerificationCodeRequestValidationError is the validation error returned by SendVerificationCodeRequest.Validate if the designated constraints aren't met.
func (SendVerificationCodeRequestValidationError) Cause ¶
func (e SendVerificationCodeRequestValidationError) Cause() error
Cause function returns cause value.
func (SendVerificationCodeRequestValidationError) Error ¶
func (e SendVerificationCodeRequestValidationError) Error() string
Error satisfies the builtin error interface
func (SendVerificationCodeRequestValidationError) ErrorName ¶
func (e SendVerificationCodeRequestValidationError) ErrorName() string
ErrorName returns error name.
func (SendVerificationCodeRequestValidationError) Field ¶
func (e SendVerificationCodeRequestValidationError) Field() string
Field function returns field value.
func (SendVerificationCodeRequestValidationError) Key ¶
func (e SendVerificationCodeRequestValidationError) Key() bool
Key function returns key value.
func (SendVerificationCodeRequestValidationError) Reason ¶
func (e SendVerificationCodeRequestValidationError) Reason() string
Reason function returns reason value.
type SendVerificationCodeResponse ¶
type SendVerificationCodeResponse struct { Result SendVerificationCodeResponse_Result `protobuf:"varint,1,opt,name=result,proto3,enum=code.phone.v1.SendVerificationCodeResponse_Result" json:"result,omitempty"` // contains filtered or unexported fields }
func (*SendVerificationCodeResponse) Descriptor
deprecated
func (*SendVerificationCodeResponse) Descriptor() ([]byte, []int)
Deprecated: Use SendVerificationCodeResponse.ProtoReflect.Descriptor instead.
func (*SendVerificationCodeResponse) GetResult ¶
func (x *SendVerificationCodeResponse) GetResult() SendVerificationCodeResponse_Result
func (*SendVerificationCodeResponse) ProtoMessage ¶
func (*SendVerificationCodeResponse) ProtoMessage()
func (*SendVerificationCodeResponse) ProtoReflect ¶
func (x *SendVerificationCodeResponse) ProtoReflect() protoreflect.Message
func (*SendVerificationCodeResponse) Reset ¶
func (x *SendVerificationCodeResponse) Reset()
func (*SendVerificationCodeResponse) String ¶
func (x *SendVerificationCodeResponse) String() string
func (*SendVerificationCodeResponse) Validate ¶
func (m *SendVerificationCodeResponse) Validate() error
Validate checks the field values on SendVerificationCodeResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type SendVerificationCodeResponseValidationError ¶
type SendVerificationCodeResponseValidationError struct {
// contains filtered or unexported fields
}
SendVerificationCodeResponseValidationError is the validation error returned by SendVerificationCodeResponse.Validate if the designated constraints aren't met.
func (SendVerificationCodeResponseValidationError) Cause ¶
func (e SendVerificationCodeResponseValidationError) Cause() error
Cause function returns cause value.
func (SendVerificationCodeResponseValidationError) Error ¶
func (e SendVerificationCodeResponseValidationError) Error() string
Error satisfies the builtin error interface
func (SendVerificationCodeResponseValidationError) ErrorName ¶
func (e SendVerificationCodeResponseValidationError) ErrorName() string
ErrorName returns error name.
func (SendVerificationCodeResponseValidationError) Field ¶
func (e SendVerificationCodeResponseValidationError) Field() string
Field function returns field value.
func (SendVerificationCodeResponseValidationError) Key ¶
func (e SendVerificationCodeResponseValidationError) Key() bool
Key function returns key value.
func (SendVerificationCodeResponseValidationError) Reason ¶
func (e SendVerificationCodeResponseValidationError) Reason() string
Reason function returns reason value.
type SendVerificationCodeResponse_Result ¶
type SendVerificationCodeResponse_Result int32
const ( SendVerificationCodeResponse_OK SendVerificationCodeResponse_Result = 0 // The phone number is not invited and cannot use Code. The SMS will not // be sent until the user is invited. This result is only valid during // the invitation stage of the application and won't apply after general // public release. SendVerificationCodeResponse_NOT_INVITED SendVerificationCodeResponse_Result = 1 // SMS is rate limited (eg. by IP, phone number, etc) and was not sent. // These will be set generously such that real users won't actually hit // the limits. SendVerificationCodeResponse_RATE_LIMITED SendVerificationCodeResponse_Result = 2 // The phone number is not real because it fails Twilio lookup. SendVerificationCodeResponse_INVALID_PHONE_NUMBER SendVerificationCodeResponse_Result = 3 // The phone number is valid, but it maps to an unsupported type of phone // like a landline. SendVerificationCodeResponse_UNSUPPORTED_PHONE_TYPE SendVerificationCodeResponse_Result = 4 )
func (SendVerificationCodeResponse_Result) Descriptor ¶
func (SendVerificationCodeResponse_Result) Descriptor() protoreflect.EnumDescriptor
func (SendVerificationCodeResponse_Result) Enum ¶
func (x SendVerificationCodeResponse_Result) Enum() *SendVerificationCodeResponse_Result
func (SendVerificationCodeResponse_Result) EnumDescriptor
deprecated
func (SendVerificationCodeResponse_Result) EnumDescriptor() ([]byte, []int)
Deprecated: Use SendVerificationCodeResponse_Result.Descriptor instead.
func (SendVerificationCodeResponse_Result) Number ¶
func (x SendVerificationCodeResponse_Result) Number() protoreflect.EnumNumber
func (SendVerificationCodeResponse_Result) String ¶
func (x SendVerificationCodeResponse_Result) String() string
func (SendVerificationCodeResponse_Result) Type ¶
func (SendVerificationCodeResponse_Result) Type() protoreflect.EnumType
type UnimplementedPhoneVerificationServer ¶
type UnimplementedPhoneVerificationServer struct { }
UnimplementedPhoneVerificationServer must be embedded to have forward compatible implementations.
func (UnimplementedPhoneVerificationServer) CheckVerificationCode ¶
func (UnimplementedPhoneVerificationServer) CheckVerificationCode(context.Context, *CheckVerificationCodeRequest) (*CheckVerificationCodeResponse, error)
func (UnimplementedPhoneVerificationServer) GetAssociatedPhoneNumber ¶
func (UnimplementedPhoneVerificationServer) GetAssociatedPhoneNumber(context.Context, *GetAssociatedPhoneNumberRequest) (*GetAssociatedPhoneNumberResponse, error)
func (UnimplementedPhoneVerificationServer) SendVerificationCode ¶
func (UnimplementedPhoneVerificationServer) SendVerificationCode(context.Context, *SendVerificationCodeRequest) (*SendVerificationCodeResponse, error)
type UnsafePhoneVerificationServer ¶
type UnsafePhoneVerificationServer interface {
// contains filtered or unexported methods
}
UnsafePhoneVerificationServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PhoneVerificationServer will result in compilation errors.
type VerificationCode ¶
type VerificationCode struct { // A 4-10 digit numerical code. Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*VerificationCode) Descriptor
deprecated
func (*VerificationCode) Descriptor() ([]byte, []int)
Deprecated: Use VerificationCode.ProtoReflect.Descriptor instead.
func (*VerificationCode) GetValue ¶
func (x *VerificationCode) GetValue() string
func (*VerificationCode) ProtoMessage ¶
func (*VerificationCode) ProtoMessage()
func (*VerificationCode) ProtoReflect ¶
func (x *VerificationCode) ProtoReflect() protoreflect.Message
func (*VerificationCode) Reset ¶
func (x *VerificationCode) Reset()
func (*VerificationCode) String ¶
func (x *VerificationCode) String() string
func (*VerificationCode) Validate ¶
func (m *VerificationCode) Validate() error
Validate checks the field values on VerificationCode with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type VerificationCodeValidationError ¶
type VerificationCodeValidationError struct {
// contains filtered or unexported fields
}
VerificationCodeValidationError is the validation error returned by VerificationCode.Validate if the designated constraints aren't met.
func (VerificationCodeValidationError) Cause ¶
func (e VerificationCodeValidationError) Cause() error
Cause function returns cause value.
func (VerificationCodeValidationError) Error ¶
func (e VerificationCodeValidationError) Error() string
Error satisfies the builtin error interface
func (VerificationCodeValidationError) ErrorName ¶
func (e VerificationCodeValidationError) ErrorName() string
ErrorName returns error name.
func (VerificationCodeValidationError) Field ¶
func (e VerificationCodeValidationError) Field() string
Field function returns field value.
func (VerificationCodeValidationError) Key ¶
func (e VerificationCodeValidationError) Key() bool
Key function returns key value.
func (VerificationCodeValidationError) Reason ¶
func (e VerificationCodeValidationError) Reason() string
Reason function returns reason value.