v1

package
v0.0.53 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2025 License: MIT Imports: 17 Imported by: 0

Documentation

Overview

Package v1 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	AuthService_Authenticate_FullMethodName  = "/auth.v1.AuthService/Authenticate"
	AuthService_RefreshToken_FullMethodName  = "/auth.v1.AuthService/RefreshToken"
	AuthService_ValidateToken_FullMethodName = "/auth.v1.AuthService/ValidateToken"
	AuthService_PackToken_FullMethodName     = "/auth.v1.AuthService/PackToken"
	AuthService_ClearToken_FullMethodName    = "/auth.v1.AuthService/ClearToken"
	AuthService_Delete_FullMethodName        = "/auth.v1.AuthService/Delete"
	AuthService_AddBlocked_FullMethodName    = "/auth.v1.AuthService/AddBlocked"
)

Variables

View Source
var AuthService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "auth.v1.AuthService",
	HandlerType: (*AuthServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Authenticate",
			Handler:    _AuthService_Authenticate_Handler,
		},
		{
			MethodName: "RefreshToken",
			Handler:    _AuthService_RefreshToken_Handler,
		},
		{
			MethodName: "ValidateToken",
			Handler:    _AuthService_ValidateToken_Handler,
		},
		{
			MethodName: "PackToken",
			Handler:    _AuthService_PackToken_Handler,
		},
		{
			MethodName: "ClearToken",
			Handler:    _AuthService_ClearToken_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _AuthService_Delete_Handler,
		},
		{
			MethodName: "AddBlocked",
			Handler:    _AuthService_AddBlocked_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "auth/auth.proto",
}

AuthService_ServiceDesc is the grpc.ServiceDesc for AuthService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_auth_auth_proto protoreflect.FileDescriptor

Functions

func RegisterAuthServiceHandler

func RegisterAuthServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterAuthServiceHandler registers the http handlers for service AuthService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterAuthServiceHandlerClient

func RegisterAuthServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client AuthServiceClient) error

RegisterAuthServiceHandlerClient registers the http handlers for service AuthService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "AuthServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "AuthServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "AuthServiceClient" to call the correct interceptors. This client ignores the HTTP middlewares.

func RegisterAuthServiceHandlerFromEndpoint

func RegisterAuthServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterAuthServiceHandlerFromEndpoint is same as RegisterAuthServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterAuthServiceHandlerServer

func RegisterAuthServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server AuthServiceServer) error

RegisterAuthServiceHandlerServer registers the http handlers for service AuthService to "mux". UnaryRPC :call AuthServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterAuthServiceHandlerFromEndpoint instead. GRPC interceptors will not work for this type of registration. To use interceptors, you must use the "runtime.WithMiddlewares" option in the "runtime.NewServeMux" call.

func RegisterAuthServiceServer

func RegisterAuthServiceServer(s grpc.ServiceRegistrar, srv AuthServiceServer)

Types

type AddBlockedRequest

type AddBlockedRequest struct {
	Uid      string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"`
	IsBlock  bool   `protobuf:"varint,2,opt,name=is_block,json=isBlock,proto3" json:"is_block,omitempty"` // true: block, false: unblock
	Duration int64  `protobuf:"varint,3,opt,name=duration,proto3" json:"duration,omitempty"`              // block duration(Seconds) (if is_block is true)
	LogId    string `protobuf:"bytes,4,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*AddBlockedRequest) Descriptor deprecated

func (*AddBlockedRequest) Descriptor() ([]byte, []int)

Deprecated: Use AddBlockedRequest.ProtoReflect.Descriptor instead.

func (*AddBlockedRequest) GetDuration

func (x *AddBlockedRequest) GetDuration() int64

func (*AddBlockedRequest) GetIsBlock

func (x *AddBlockedRequest) GetIsBlock() bool

func (*AddBlockedRequest) GetLogId added in v0.0.44

func (x *AddBlockedRequest) GetLogId() string

func (*AddBlockedRequest) GetUid

func (x *AddBlockedRequest) GetUid() string

func (*AddBlockedRequest) ProtoMessage

func (*AddBlockedRequest) ProtoMessage()

func (*AddBlockedRequest) ProtoReflect

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

func (*AddBlockedRequest) Reset

func (x *AddBlockedRequest) Reset()

func (*AddBlockedRequest) String

func (x *AddBlockedRequest) String() string

type AddBlockedResponse

type AddBlockedResponse struct {
	ErrCode int32 `protobuf:"varint,1,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*AddBlockedResponse) Descriptor deprecated

func (*AddBlockedResponse) Descriptor() ([]byte, []int)

Deprecated: Use AddBlockedResponse.ProtoReflect.Descriptor instead.

func (*AddBlockedResponse) GetErrCode added in v0.0.44

func (x *AddBlockedResponse) GetErrCode() int32

func (*AddBlockedResponse) ProtoMessage

func (*AddBlockedResponse) ProtoMessage()

func (*AddBlockedResponse) ProtoReflect

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

func (*AddBlockedResponse) Reset

func (x *AddBlockedResponse) Reset()

func (*AddBlockedResponse) String

func (x *AddBlockedResponse) String() string

type AuthServiceClient

type AuthServiceClient interface {
	// Authenticate request a jwt token by id
	// return a jwt token and a refresh token
	// 请求一个 jwt token,用于身份认证
	Authenticate(ctx context.Context, in *AuthenticateRequest, opts ...grpc.CallOption) (*AuthenticateResponse, error)
	// RefreshToken request a new jwt token by refresh token
	// return a jwt token and a refresh token
	// 刷新jwt token 过期时间
	RefreshToken(ctx context.Context, in *RefreshTokenRequest, opts ...grpc.CallOption) (*RefreshTokenResponse, error)
	// ValidateToken validate a jwt token
	// return a uid and data
	// 验证jwt token是否合法
	ValidateToken(ctx context.Context, in *ValidateTokenRequest, opts ...grpc.CallOption) (*ValidateTokenResponse, error)
	// PacketToken pack some custom data to a jwt token, suitable for game room auth
	// 将一些自定义数据打包到jwt token中,适用于游戏房间验证
	PackToken(ctx context.Context, in *PackTokenRequest, opts ...grpc.CallOption) (*PackTokenResponse, error)
	// ClearToken clear the uid's token
	// 清除uid对应的token
	ClearToken(ctx context.Context, in *ClearTokenRequest, opts ...grpc.CallOption) (*ClearTokenResponse, error)
	// Delete delete the id and uid info from db
	// 删除id对应的uid信息
	Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*DeleteResponse, error)
	// AddBlocked add a uid to block list
	// if is_block is true, will block the uid for duration seconds
	// 添加到黑名单
	AddBlocked(ctx context.Context, in *AddBlockedRequest, opts ...grpc.CallOption) (*AddBlockedResponse, error)
}

AuthServiceClient is the client API for AuthService 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.

type AuthServiceServer

type AuthServiceServer interface {
	// Authenticate request a jwt token by id
	// return a jwt token and a refresh token
	// 请求一个 jwt token,用于身份认证
	Authenticate(context.Context, *AuthenticateRequest) (*AuthenticateResponse, error)
	// RefreshToken request a new jwt token by refresh token
	// return a jwt token and a refresh token
	// 刷新jwt token 过期时间
	RefreshToken(context.Context, *RefreshTokenRequest) (*RefreshTokenResponse, error)
	// ValidateToken validate a jwt token
	// return a uid and data
	// 验证jwt token是否合法
	ValidateToken(context.Context, *ValidateTokenRequest) (*ValidateTokenResponse, error)
	// PacketToken pack some custom data to a jwt token, suitable for game room auth
	// 将一些自定义数据打包到jwt token中,适用于游戏房间验证
	PackToken(context.Context, *PackTokenRequest) (*PackTokenResponse, error)
	// ClearToken clear the uid's token
	// 清除uid对应的token
	ClearToken(context.Context, *ClearTokenRequest) (*ClearTokenResponse, error)
	// Delete delete the id and uid info from db
	// 删除id对应的uid信息
	Delete(context.Context, *DeleteRequest) (*DeleteResponse, error)
	// AddBlocked add a uid to block list
	// if is_block is true, will block the uid for duration seconds
	// 添加到黑名单
	AddBlocked(context.Context, *AddBlockedRequest) (*AddBlockedResponse, error)
}

AuthServiceServer is the server API for AuthService service. All implementations should embed UnimplementedAuthServiceServer for forward compatibility.

type AuthenticateRequest

type AuthenticateRequest struct {
	AppId string `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"`
	// account id
	Id    string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
	LogId string `protobuf:"bytes,3,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*AuthenticateRequest) Descriptor deprecated

func (*AuthenticateRequest) Descriptor() ([]byte, []int)

Deprecated: Use AuthenticateRequest.ProtoReflect.Descriptor instead.

func (*AuthenticateRequest) GetAppId

func (x *AuthenticateRequest) GetAppId() string

func (*AuthenticateRequest) GetId

func (x *AuthenticateRequest) GetId() string

func (*AuthenticateRequest) GetLogId added in v0.0.44

func (x *AuthenticateRequest) GetLogId() string

func (*AuthenticateRequest) ProtoMessage

func (*AuthenticateRequest) ProtoMessage()

func (*AuthenticateRequest) ProtoReflect

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

func (*AuthenticateRequest) Reset

func (x *AuthenticateRequest) Reset()

func (*AuthenticateRequest) String

func (x *AuthenticateRequest) String() string

type AuthenticateResponse

type AuthenticateResponse struct {
	AccessToken  string `protobuf:"bytes,1,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	RefreshToken string `protobuf:"bytes,2,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"`
	Uid          string `protobuf:"bytes,3,opt,name=uid,proto3" json:"uid,omitempty"`
	// if is_override is true means already has an active token
	// it is suitable for different device login logic
	// 如果is_override为true表示已经有一个活跃的token
	// 适用于不同设备登录逻辑
	IsOverride bool  `protobuf:"varint,4,opt,name=is_override,json=isOverride,proto3" json:"is_override,omitempty"`
	ErrCode    int32 `protobuf:"varint,5,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*AuthenticateResponse) Descriptor deprecated

func (*AuthenticateResponse) Descriptor() ([]byte, []int)

Deprecated: Use AuthenticateResponse.ProtoReflect.Descriptor instead.

func (*AuthenticateResponse) GetAccessToken

func (x *AuthenticateResponse) GetAccessToken() string

func (*AuthenticateResponse) GetErrCode added in v0.0.44

func (x *AuthenticateResponse) GetErrCode() int32

func (*AuthenticateResponse) GetIsOverride

func (x *AuthenticateResponse) GetIsOverride() bool

func (*AuthenticateResponse) GetRefreshToken

func (x *AuthenticateResponse) GetRefreshToken() string

func (*AuthenticateResponse) GetUid

func (x *AuthenticateResponse) GetUid() string

func (*AuthenticateResponse) ProtoMessage

func (*AuthenticateResponse) ProtoMessage()

func (*AuthenticateResponse) ProtoReflect

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

func (*AuthenticateResponse) Reset

func (x *AuthenticateResponse) Reset()

func (*AuthenticateResponse) String

func (x *AuthenticateResponse) String() string

type ClearTokenRequest

type ClearTokenRequest struct {
	Uid         string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"`
	AccessToken string `protobuf:"bytes,2,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	LogId       string `protobuf:"bytes,3,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*ClearTokenRequest) Descriptor deprecated

func (*ClearTokenRequest) Descriptor() ([]byte, []int)

Deprecated: Use ClearTokenRequest.ProtoReflect.Descriptor instead.

func (*ClearTokenRequest) GetAccessToken

func (x *ClearTokenRequest) GetAccessToken() string

func (*ClearTokenRequest) GetLogId added in v0.0.44

func (x *ClearTokenRequest) GetLogId() string

func (*ClearTokenRequest) GetUid

func (x *ClearTokenRequest) GetUid() string

func (*ClearTokenRequest) ProtoMessage

func (*ClearTokenRequest) ProtoMessage()

func (*ClearTokenRequest) ProtoReflect

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

func (*ClearTokenRequest) Reset

func (x *ClearTokenRequest) Reset()

func (*ClearTokenRequest) String

func (x *ClearTokenRequest) String() string

type ClearTokenResponse

type ClearTokenResponse struct {
	ErrCode int32 `protobuf:"varint,1,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*ClearTokenResponse) Descriptor deprecated

func (*ClearTokenResponse) Descriptor() ([]byte, []int)

Deprecated: Use ClearTokenResponse.ProtoReflect.Descriptor instead.

func (*ClearTokenResponse) GetErrCode added in v0.0.44

func (x *ClearTokenResponse) GetErrCode() int32

func (*ClearTokenResponse) ProtoMessage

func (*ClearTokenResponse) ProtoMessage()

func (*ClearTokenResponse) ProtoReflect

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

func (*ClearTokenResponse) Reset

func (x *ClearTokenResponse) Reset()

func (*ClearTokenResponse) String

func (x *ClearTokenResponse) String() string

type DeleteRequest

type DeleteRequest struct {
	AppId string `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"`
	Id    string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
	LogId string `protobuf:"bytes,3,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteRequest) Descriptor deprecated

func (*DeleteRequest) Descriptor() ([]byte, []int)

Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead.

func (*DeleteRequest) GetAppId

func (x *DeleteRequest) GetAppId() string

func (*DeleteRequest) GetId

func (x *DeleteRequest) GetId() string

func (*DeleteRequest) GetLogId added in v0.0.44

func (x *DeleteRequest) GetLogId() string

func (*DeleteRequest) ProtoMessage

func (*DeleteRequest) ProtoMessage()

func (*DeleteRequest) ProtoReflect

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

func (*DeleteRequest) Reset

func (x *DeleteRequest) Reset()

func (*DeleteRequest) String

func (x *DeleteRequest) String() string

type DeleteResponse

type DeleteResponse struct {
	ErrCode int32 `protobuf:"varint,1,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteResponse) Descriptor deprecated

func (*DeleteResponse) Descriptor() ([]byte, []int)

Deprecated: Use DeleteResponse.ProtoReflect.Descriptor instead.

func (*DeleteResponse) GetErrCode added in v0.0.44

func (x *DeleteResponse) GetErrCode() int32

func (*DeleteResponse) ProtoMessage

func (*DeleteResponse) ProtoMessage()

func (*DeleteResponse) ProtoReflect

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

func (*DeleteResponse) Reset

func (x *DeleteResponse) Reset()

func (*DeleteResponse) String

func (x *DeleteResponse) String() string

type PackTokenRequest

type PackTokenRequest struct {
	Uid        string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"`                                 // user id or room id etc.(optional)
	CustomData []byte `protobuf:"bytes,2,opt,name=custom_data,json=customData,proto3" json:"custom_data,omitempty"` // custom data will be packed to token (optional)
	Duration   int64  `protobuf:"varint,3,opt,name=duration,proto3" json:"duration,omitempty"`                      // token duration(minute),default: 60 minutes (optional)
	LogId      string `protobuf:"bytes,4,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*PackTokenRequest) Descriptor deprecated

func (*PackTokenRequest) Descriptor() ([]byte, []int)

Deprecated: Use PackTokenRequest.ProtoReflect.Descriptor instead.

func (*PackTokenRequest) GetCustomData

func (x *PackTokenRequest) GetCustomData() []byte

func (*PackTokenRequest) GetDuration

func (x *PackTokenRequest) GetDuration() int64

func (*PackTokenRequest) GetLogId added in v0.0.44

func (x *PackTokenRequest) GetLogId() string

func (*PackTokenRequest) GetUid

func (x *PackTokenRequest) GetUid() string

func (*PackTokenRequest) ProtoMessage

func (*PackTokenRequest) ProtoMessage()

func (*PackTokenRequest) ProtoReflect

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

func (*PackTokenRequest) Reset

func (x *PackTokenRequest) Reset()

func (*PackTokenRequest) String

func (x *PackTokenRequest) String() string

type PackTokenResponse

type PackTokenResponse struct {
	AccessToken string `protobuf:"bytes,1,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	ErrCode     int32  `protobuf:"varint,2,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*PackTokenResponse) Descriptor deprecated

func (*PackTokenResponse) Descriptor() ([]byte, []int)

Deprecated: Use PackTokenResponse.ProtoReflect.Descriptor instead.

func (*PackTokenResponse) GetAccessToken

func (x *PackTokenResponse) GetAccessToken() string

func (*PackTokenResponse) GetErrCode added in v0.0.44

func (x *PackTokenResponse) GetErrCode() int32

func (*PackTokenResponse) ProtoMessage

func (*PackTokenResponse) ProtoMessage()

func (*PackTokenResponse) ProtoReflect

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

func (*PackTokenResponse) Reset

func (x *PackTokenResponse) Reset()

func (*PackTokenResponse) String

func (x *PackTokenResponse) String() string

type RefreshTokenRequest

type RefreshTokenRequest struct {
	RefreshToken string `protobuf:"bytes,1,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"`
	LogId        string `protobuf:"bytes,2,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*RefreshTokenRequest) Descriptor deprecated

func (*RefreshTokenRequest) Descriptor() ([]byte, []int)

Deprecated: Use RefreshTokenRequest.ProtoReflect.Descriptor instead.

func (*RefreshTokenRequest) GetLogId added in v0.0.44

func (x *RefreshTokenRequest) GetLogId() string

func (*RefreshTokenRequest) GetRefreshToken

func (x *RefreshTokenRequest) GetRefreshToken() string

func (*RefreshTokenRequest) ProtoMessage

func (*RefreshTokenRequest) ProtoMessage()

func (*RefreshTokenRequest) ProtoReflect

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

func (*RefreshTokenRequest) Reset

func (x *RefreshTokenRequest) Reset()

func (*RefreshTokenRequest) String

func (x *RefreshTokenRequest) String() string

type RefreshTokenResponse

type RefreshTokenResponse struct {
	AccessToken  string `protobuf:"bytes,1,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	RefreshToken string `protobuf:"bytes,2,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"`
	ErrCode      int32  `protobuf:"varint,3,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*RefreshTokenResponse) Descriptor deprecated

func (*RefreshTokenResponse) Descriptor() ([]byte, []int)

Deprecated: Use RefreshTokenResponse.ProtoReflect.Descriptor instead.

func (*RefreshTokenResponse) GetAccessToken

func (x *RefreshTokenResponse) GetAccessToken() string

func (*RefreshTokenResponse) GetErrCode added in v0.0.44

func (x *RefreshTokenResponse) GetErrCode() int32

func (*RefreshTokenResponse) GetRefreshToken

func (x *RefreshTokenResponse) GetRefreshToken() string

func (*RefreshTokenResponse) ProtoMessage

func (*RefreshTokenResponse) ProtoMessage()

func (*RefreshTokenResponse) ProtoReflect

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

func (*RefreshTokenResponse) Reset

func (x *RefreshTokenResponse) Reset()

func (*RefreshTokenResponse) String

func (x *RefreshTokenResponse) String() string

type UnimplementedAuthServiceServer

type UnimplementedAuthServiceServer struct{}

UnimplementedAuthServiceServer should be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedAuthServiceServer) AddBlocked

func (UnimplementedAuthServiceServer) Authenticate

func (UnimplementedAuthServiceServer) ClearToken

func (UnimplementedAuthServiceServer) Delete

func (UnimplementedAuthServiceServer) PackToken

func (UnimplementedAuthServiceServer) RefreshToken

func (UnimplementedAuthServiceServer) ValidateToken

type UnsafeAuthServiceServer

type UnsafeAuthServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeAuthServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AuthServiceServer will result in compilation errors.

type ValidateTokenRequest

type ValidateTokenRequest struct {
	AccessToken string `protobuf:"bytes,1,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	LogId       string `protobuf:"bytes,2,opt,name=log_id,json=logId,proto3" json:"log_id,omitempty"`
	// contains filtered or unexported fields
}

func (*ValidateTokenRequest) Descriptor deprecated

func (*ValidateTokenRequest) Descriptor() ([]byte, []int)

Deprecated: Use ValidateTokenRequest.ProtoReflect.Descriptor instead.

func (*ValidateTokenRequest) GetAccessToken

func (x *ValidateTokenRequest) GetAccessToken() string

func (*ValidateTokenRequest) GetLogId added in v0.0.44

func (x *ValidateTokenRequest) GetLogId() string

func (*ValidateTokenRequest) ProtoMessage

func (*ValidateTokenRequest) ProtoMessage()

func (*ValidateTokenRequest) ProtoReflect

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

func (*ValidateTokenRequest) Reset

func (x *ValidateTokenRequest) Reset()

func (*ValidateTokenRequest) String

func (x *ValidateTokenRequest) String() string

type ValidateTokenResponse

type ValidateTokenResponse struct {
	Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"`
	// custom data from token
	CustomData []byte `protobuf:"bytes,2,opt,name=custom_data,json=customData,proto3" json:"custom_data,omitempty"`
	ErrCode    int32  `protobuf:"varint,3,opt,name=errCode,proto3" json:"errCode,omitempty"`
	// contains filtered or unexported fields
}

func (*ValidateTokenResponse) Descriptor deprecated

func (*ValidateTokenResponse) Descriptor() ([]byte, []int)

Deprecated: Use ValidateTokenResponse.ProtoReflect.Descriptor instead.

func (*ValidateTokenResponse) GetCustomData

func (x *ValidateTokenResponse) GetCustomData() []byte

func (*ValidateTokenResponse) GetErrCode added in v0.0.44

func (x *ValidateTokenResponse) GetErrCode() int32

func (*ValidateTokenResponse) GetUid

func (x *ValidateTokenResponse) GetUid() string

func (*ValidateTokenResponse) ProtoMessage

func (*ValidateTokenResponse) ProtoMessage()

func (*ValidateTokenResponse) ProtoReflect

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

func (*ValidateTokenResponse) Reset

func (x *ValidateTokenResponse) Reset()

func (*ValidateTokenResponse) String

func (x *ValidateTokenResponse) String() string

Jump to

Keyboard shortcuts

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