Documentation ¶
Index ¶
- Constants
- Variables
- func MakeAdminEndpoint(svc service.Service) endpoint.Endpoint
- func MakeAuthorityAuthorizationMiddleware(authority string, logger log.Logger) endpoint.Middleware
- func MakeHealthCheckEndpoint(svc service.Service) endpoint.Endpoint
- func MakeIndexEndpoint(svc service.Service) endpoint.Endpoint
- func MakeOAuth2AuthorizationMiddleware(logger log.Logger) endpoint.Middleware
- func MakeSampleEndpoint(svc service.Service) endpoint.Endpoint
- type AdminRequest
- type AdminResponse
- type HealthRequest
- type HealthResponse
- type IndexRequest
- type IndexResponse
- type OAuth2Endpoints
- type SampleRequest
- type SampleResponse
Constants ¶
View Source
const ( OAuth2DetailsKey = "OAuth2Details" OAuth2ErrorKey = "OAuth2Error" )
Variables ¶
Functions ¶
func MakeAuthorityAuthorizationMiddleware ¶
func MakeAuthorityAuthorizationMiddleware(authority string, logger log.Logger) endpoint.Middleware
func MakeHealthCheckEndpoint ¶
MakeHealthCheckEndpoint 创建健康检查Endpoint
func MakeOAuth2AuthorizationMiddleware ¶
func MakeOAuth2AuthorizationMiddleware(logger log.Logger) endpoint.Middleware
Types ¶
type AdminRequest ¶
type AdminRequest struct { }
type AdminResponse ¶
type HealthResponse ¶
type HealthResponse struct {
Status bool `json:"status"`
}
HealthResponse 健康检查响应结构
type IndexRequest ¶
type IndexRequest struct { }
type IndexResponse ¶
type OAuth2Endpoints ¶
type OAuth2Endpoints struct { IndexEndpoint endpoint.Endpoint SampleEndpoint endpoint.Endpoint AdminEndpoint endpoint.Endpoint HealthCheckEndpoint endpoint.Endpoint }
CalculateEndpoint define endpoint
type SampleRequest ¶
type SampleRequest struct { }
type SampleResponse ¶
Click to show internal directories.
Click to hide internal directories.