Documentation
¶
Overview ¶
Package httpserver provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.4.1 DO NOT EDIT.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterHandlers ¶
func RegisterHandlers(router gin.IRouter, si ServerInterface)
RegisterHandlers creates http.Handler with routing matching OpenAPI spec.
func RegisterHandlersWithOptions ¶
func RegisterHandlersWithOptions(router gin.IRouter, si ServerInterface, options GinServerOptions)
RegisterHandlersWithOptions creates http.Handler with additional options
Types ¶
type GinServerOptions ¶
type GinServerOptions struct {
BaseURL string
Middlewares []MiddlewareFunc
ErrorHandler func(*gin.Context, error, int)
}
GinServerOptions provides options for the Gin server.
type MiddlewareFunc ¶
type Response ¶
type Response struct {
Body *map[string]interface{} `json:"body,omitempty"`
CorrelationId *string `json:"correlationId,omitempty"`
Error *ResponseError `json:"error,omitempty"`
RequestId *string `json:"requestId,omitempty"`
Status int `json:"status"`
}
Response defines model for Response.
type ResponseError ¶
type ResponseError struct {
Code *string `json:"code"`
HowToFix *string `json:"howToFix"`
Message string `json:"message"`
}
ResponseError defines model for ResponseError.
type ServerInterface ¶
type ServerInterface interface {
}
ServerInterface represents all server handlers.
type ServerInterfaceWrapper ¶
type ServerInterfaceWrapper struct {
Handler ServerInterface
HandlerMiddlewares []MiddlewareFunc
ErrorHandler func(*gin.Context, error, int)
}
ServerInterfaceWrapper converts contexts to parameters.
Click to show internal directories.
Click to hide internal directories.