Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
- type AuthClient
- type AuthServer
- type SignInReq
- func (*SignInReq) Descriptor() ([]byte, []int)
- func (m *SignInReq) GetCode() string
- func (m *SignInReq) GetName() string
- func (*SignInReq) ProtoMessage()
- func (m *SignInReq) Reset()
- func (m *SignInReq) String() string
- func (m *SignInReq) XXX_DiscardUnknown()
- func (m *SignInReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SignInReq) XXX_Merge(src proto.Message)
- func (m *SignInReq) XXX_Size() int
- func (m *SignInReq) XXX_Unmarshal(b []byte) error
- type SignInRes
- func (*SignInRes) Descriptor() ([]byte, []int)
- func (m *SignInRes) GetAccessToken() string
- func (*SignInRes) ProtoMessage()
- func (m *SignInRes) Reset()
- func (m *SignInRes) String() string
- func (m *SignInRes) XXX_DiscardUnknown()
- func (m *SignInRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SignInRes) XXX_Merge(src proto.Message)
- func (m *SignInRes) XXX_Size() int
- func (m *SignInRes) XXX_Unmarshal(b []byte) error
- type SignOutReq
- func (*SignOutReq) Descriptor() ([]byte, []int)
- func (*SignOutReq) ProtoMessage()
- func (m *SignOutReq) Reset()
- func (m *SignOutReq) String() string
- func (m *SignOutReq) XXX_DiscardUnknown()
- func (m *SignOutReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SignOutReq) XXX_Merge(src proto.Message)
- func (m *SignOutReq) XXX_Size() int
- func (m *SignOutReq) XXX_Unmarshal(b []byte) error
- type SignOutRes
- func (*SignOutRes) Descriptor() ([]byte, []int)
- func (*SignOutRes) ProtoMessage()
- func (m *SignOutRes) Reset()
- func (m *SignOutRes) String() string
- func (m *SignOutRes) XXX_DiscardUnknown()
- func (m *SignOutRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SignOutRes) XXX_Merge(src proto.Message)
- func (m *SignOutRes) XXX_Size() int
- func (m *SignOutRes) XXX_Unmarshal(b []byte) error
- type SignUpReq
- func (*SignUpReq) Descriptor() ([]byte, []int)
- func (m *SignUpReq) GetUser() *User
- func (*SignUpReq) ProtoMessage()
- func (m *SignUpReq) Reset()
- func (m *SignUpReq) String() string
- func (m *SignUpReq) XXX_DiscardUnknown()
- func (m *SignUpReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SignUpReq) XXX_Merge(src proto.Message)
- func (m *SignUpReq) XXX_Size() int
- func (m *SignUpReq) XXX_Unmarshal(b []byte) error
- type SignUpRes
- func (*SignUpRes) Descriptor() ([]byte, []int)
- func (*SignUpRes) ProtoMessage()
- func (m *SignUpRes) Reset()
- func (m *SignUpRes) String() string
- func (m *SignUpRes) XXX_DiscardUnknown()
- func (m *SignUpRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SignUpRes) XXX_Merge(src proto.Message)
- func (m *SignUpRes) XXX_Size() int
- func (m *SignUpRes) XXX_Unmarshal(b []byte) error
- type UnimplementedAuthServer
- func (UnimplementedAuthServer) SignIn(context.Context, *SignInReq) (*SignInRes, error)
- func (UnimplementedAuthServer) SignOut(context.Context, *SignOutReq) (*SignOutRes, error)
- func (UnimplementedAuthServer) SignUp(context.Context, *SignUpReq) (*SignUpRes, error)
- func (UnimplementedAuthServer) VerifyEmail(context.Context, *VerifyEmailReq) (*VerifyEmailRes, error)
- type UnsafeAuthServer
- type User
- func (*User) Descriptor() ([]byte, []int)
- func (m *User) GetCode() string
- func (m *User) GetEmails() []string
- func (m *User) GetFullName() string
- func (m *User) GetName() string
- func (m *User) GetNationalCode() string
- func (m *User) GetPhones() []string
- func (*User) ProtoMessage()
- func (m *User) Reset()
- func (m *User) String() string
- func (m *User) XXX_DiscardUnknown()
- func (m *User) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *User) XXX_Merge(src proto.Message)
- func (m *User) XXX_Size() int
- func (m *User) XXX_Unmarshal(b []byte) error
- type VerifyEmailReq
- func (*VerifyEmailReq) Descriptor() ([]byte, []int)
- func (m *VerifyEmailReq) GetEmail() string
- func (m *VerifyEmailReq) GetVerificationCode() string
- func (*VerifyEmailReq) ProtoMessage()
- func (m *VerifyEmailReq) Reset()
- func (m *VerifyEmailReq) String() string
- func (m *VerifyEmailReq) XXX_DiscardUnknown()
- func (m *VerifyEmailReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *VerifyEmailReq) XXX_Merge(src proto.Message)
- func (m *VerifyEmailReq) XXX_Size() int
- func (m *VerifyEmailReq) XXX_Unmarshal(b []byte) error
- type VerifyEmailRes
- func (*VerifyEmailRes) Descriptor() ([]byte, []int)
- func (*VerifyEmailRes) ProtoMessage()
- func (m *VerifyEmailRes) Reset()
- func (m *VerifyEmailRes) String() string
- func (m *VerifyEmailRes) XXX_DiscardUnknown()
- func (m *VerifyEmailRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *VerifyEmailRes) XXX_Merge(src proto.Message)
- func (m *VerifyEmailRes) XXX_Size() int
- func (m *VerifyEmailRes) XXX_Unmarshal(b []byte) error
Constants ¶
const ( Auth_SignUp_FullMethodName = "/pb.Auth/SignUp" Auth_SignIn_FullMethodName = "/pb.Auth/SignIn" Auth_SignOut_FullMethodName = "/pb.Auth/SignOut" Auth_VerifyEmail_FullMethodName = "/pb.Auth/VerifyEmail" )
Variables ¶
var Auth_ServiceDesc = grpc.ServiceDesc{ ServiceName: "pb.Auth", HandlerType: (*AuthServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "SignUp", Handler: _Auth_SignUp_Handler, }, { MethodName: "SignIn", Handler: _Auth_SignIn_Handler, }, { MethodName: "SignOut", Handler: _Auth_SignOut_Handler, }, { MethodName: "VerifyEmail", Handler: _Auth_VerifyEmail_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "auth_service.proto", }
Auth_ServiceDesc is the grpc.ServiceDesc for Auth service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterAuthServer ¶
func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
Types ¶
type AuthClient ¶
type AuthClient interface { SignUp(ctx context.Context, in *SignUpReq, opts ...grpc.CallOption) (*SignUpRes, error) SignIn(ctx context.Context, in *SignInReq, opts ...grpc.CallOption) (*SignInRes, error) SignOut(ctx context.Context, in *SignOutReq, opts ...grpc.CallOption) (*SignOutRes, error) VerifyEmail(ctx context.Context, in *VerifyEmailReq, opts ...grpc.CallOption) (*VerifyEmailRes, error) }
AuthClient is the client API for Auth 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 NewAuthClient ¶
func NewAuthClient(cc grpc.ClientConnInterface) AuthClient
type AuthServer ¶
type AuthServer interface { SignUp(context.Context, *SignUpReq) (*SignUpRes, error) SignIn(context.Context, *SignInReq) (*SignInRes, error) SignOut(context.Context, *SignOutReq) (*SignOutRes, error) VerifyEmail(context.Context, *VerifyEmailReq) (*VerifyEmailRes, error) // contains filtered or unexported methods }
AuthServer is the server API for Auth service. All implementations must embed UnimplementedAuthServer for forward compatibility
type SignInReq ¶
type SignInReq struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Code string `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SignInReq) Descriptor ¶
func (*SignInReq) ProtoMessage ¶
func (*SignInReq) ProtoMessage()
func (*SignInReq) XXX_DiscardUnknown ¶
func (m *SignInReq) XXX_DiscardUnknown()
func (*SignInReq) XXX_Marshal ¶
func (*SignInReq) XXX_Unmarshal ¶
type SignInRes ¶
type SignInRes struct { AccessToken string `protobuf:"bytes,1,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SignInRes) Descriptor ¶
func (*SignInRes) GetAccessToken ¶
func (*SignInRes) ProtoMessage ¶
func (*SignInRes) ProtoMessage()
func (*SignInRes) XXX_DiscardUnknown ¶
func (m *SignInRes) XXX_DiscardUnknown()
func (*SignInRes) XXX_Marshal ¶
func (*SignInRes) XXX_Unmarshal ¶
type SignOutReq ¶
type SignOutReq struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SignOutReq) Descriptor ¶
func (*SignOutReq) Descriptor() ([]byte, []int)
func (*SignOutReq) ProtoMessage ¶
func (*SignOutReq) ProtoMessage()
func (*SignOutReq) Reset ¶
func (m *SignOutReq) Reset()
func (*SignOutReq) String ¶
func (m *SignOutReq) String() string
func (*SignOutReq) XXX_DiscardUnknown ¶
func (m *SignOutReq) XXX_DiscardUnknown()
func (*SignOutReq) XXX_Marshal ¶
func (m *SignOutReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SignOutReq) XXX_Merge ¶
func (m *SignOutReq) XXX_Merge(src proto.Message)
func (*SignOutReq) XXX_Size ¶
func (m *SignOutReq) XXX_Size() int
func (*SignOutReq) XXX_Unmarshal ¶
func (m *SignOutReq) XXX_Unmarshal(b []byte) error
type SignOutRes ¶
type SignOutRes struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SignOutRes) Descriptor ¶
func (*SignOutRes) Descriptor() ([]byte, []int)
func (*SignOutRes) ProtoMessage ¶
func (*SignOutRes) ProtoMessage()
func (*SignOutRes) Reset ¶
func (m *SignOutRes) Reset()
func (*SignOutRes) String ¶
func (m *SignOutRes) String() string
func (*SignOutRes) XXX_DiscardUnknown ¶
func (m *SignOutRes) XXX_DiscardUnknown()
func (*SignOutRes) XXX_Marshal ¶
func (m *SignOutRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SignOutRes) XXX_Merge ¶
func (m *SignOutRes) XXX_Merge(src proto.Message)
func (*SignOutRes) XXX_Size ¶
func (m *SignOutRes) XXX_Size() int
func (*SignOutRes) XXX_Unmarshal ¶
func (m *SignOutRes) XXX_Unmarshal(b []byte) error
type SignUpReq ¶
type SignUpReq struct { User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SignUpReq) Descriptor ¶
func (*SignUpReq) ProtoMessage ¶
func (*SignUpReq) ProtoMessage()
func (*SignUpReq) XXX_DiscardUnknown ¶
func (m *SignUpReq) XXX_DiscardUnknown()
func (*SignUpReq) XXX_Marshal ¶
func (*SignUpReq) XXX_Unmarshal ¶
type SignUpRes ¶
type SignUpRes struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SignUpRes) Descriptor ¶
func (*SignUpRes) ProtoMessage ¶
func (*SignUpRes) ProtoMessage()
func (*SignUpRes) XXX_DiscardUnknown ¶
func (m *SignUpRes) XXX_DiscardUnknown()
func (*SignUpRes) XXX_Marshal ¶
func (*SignUpRes) XXX_Unmarshal ¶
type UnimplementedAuthServer ¶
type UnimplementedAuthServer struct { }
UnimplementedAuthServer must be embedded to have forward compatible implementations.
func (UnimplementedAuthServer) SignOut ¶
func (UnimplementedAuthServer) SignOut(context.Context, *SignOutReq) (*SignOutRes, error)
func (UnimplementedAuthServer) VerifyEmail ¶
func (UnimplementedAuthServer) VerifyEmail(context.Context, *VerifyEmailReq) (*VerifyEmailRes, error)
type UnsafeAuthServer ¶
type UnsafeAuthServer interface {
// contains filtered or unexported methods
}
UnsafeAuthServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AuthServer will result in compilation errors.
type User ¶
type User struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Code string `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"` FullName string `protobuf:"bytes,3,opt,name=full_name,json=fullName,proto3" json:"full_name,omitempty"` NationalCode string `protobuf:"bytes,4,opt,name=national_code,json=nationalCode,proto3" json:"national_code,omitempty"` Phones []string `protobuf:"bytes,5,rep,name=phones,proto3" json:"phones,omitempty"` Emails []string `protobuf:"bytes,6,rep,name=emails,proto3" json:"emails,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*User) Descriptor ¶
func (*User) GetFullName ¶
func (*User) GetNationalCode ¶
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) XXX_DiscardUnknown ¶
func (m *User) XXX_DiscardUnknown()
func (*User) XXX_Unmarshal ¶
type VerifyEmailReq ¶
type VerifyEmailReq struct { Email string `protobuf:"bytes,1,opt,name=email,proto3" json:"email,omitempty"` VerificationCode string `protobuf:"bytes,2,opt,name=verification_code,json=verificationCode,proto3" json:"verification_code,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*VerifyEmailReq) Descriptor ¶
func (*VerifyEmailReq) Descriptor() ([]byte, []int)
func (*VerifyEmailReq) GetEmail ¶
func (m *VerifyEmailReq) GetEmail() string
func (*VerifyEmailReq) GetVerificationCode ¶
func (m *VerifyEmailReq) GetVerificationCode() string
func (*VerifyEmailReq) ProtoMessage ¶
func (*VerifyEmailReq) ProtoMessage()
func (*VerifyEmailReq) Reset ¶
func (m *VerifyEmailReq) Reset()
func (*VerifyEmailReq) String ¶
func (m *VerifyEmailReq) String() string
func (*VerifyEmailReq) XXX_DiscardUnknown ¶
func (m *VerifyEmailReq) XXX_DiscardUnknown()
func (*VerifyEmailReq) XXX_Marshal ¶
func (m *VerifyEmailReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*VerifyEmailReq) XXX_Merge ¶
func (m *VerifyEmailReq) XXX_Merge(src proto.Message)
func (*VerifyEmailReq) XXX_Size ¶
func (m *VerifyEmailReq) XXX_Size() int
func (*VerifyEmailReq) XXX_Unmarshal ¶
func (m *VerifyEmailReq) XXX_Unmarshal(b []byte) error
type VerifyEmailRes ¶
type VerifyEmailRes struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*VerifyEmailRes) Descriptor ¶
func (*VerifyEmailRes) Descriptor() ([]byte, []int)
func (*VerifyEmailRes) ProtoMessage ¶
func (*VerifyEmailRes) ProtoMessage()
func (*VerifyEmailRes) Reset ¶
func (m *VerifyEmailRes) Reset()
func (*VerifyEmailRes) String ¶
func (m *VerifyEmailRes) String() string
func (*VerifyEmailRes) XXX_DiscardUnknown ¶
func (m *VerifyEmailRes) XXX_DiscardUnknown()
func (*VerifyEmailRes) XXX_Marshal ¶
func (m *VerifyEmailRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*VerifyEmailRes) XXX_Merge ¶
func (m *VerifyEmailRes) XXX_Merge(src proto.Message)
func (*VerifyEmailRes) XXX_Size ¶
func (m *VerifyEmailRes) XXX_Size() int
func (*VerifyEmailRes) XXX_Unmarshal ¶
func (m *VerifyEmailRes) XXX_Unmarshal(b []byte) error