Documentation
¶
Index ¶
- Constants
- type Healthcheck
- type HealthcheckHandler
- type HealthcheckHandlerFunc
- type HealthcheckOK
- type HealthcheckParams
- type HealthcheckURL
- func (o *HealthcheckURL) Build() (*url.URL, error)
- func (o *HealthcheckURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *HealthcheckURL) Must(u *url.URL, err error) *url.URL
- func (o *HealthcheckURL) SetBasePath(bp string)
- func (o *HealthcheckURL) String() string
- func (o *HealthcheckURL) StringFull(scheme, host string) string
- func (o *HealthcheckURL) WithBasePath(bp string) *HealthcheckURL
- type Login
- type LoginBadRequest
- type LoginHandler
- type LoginHandlerFunc
- type LoginInternalServerError
- type LoginOK
- type LoginParams
- type LoginURL
- func (o *LoginURL) Build() (*url.URL, error)
- func (o *LoginURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *LoginURL) Must(u *url.URL, err error) *url.URL
- func (o *LoginURL) SetBasePath(bp string)
- func (o *LoginURL) String() string
- func (o *LoginURL) StringFull(scheme, host string) string
- func (o *LoginURL) WithBasePath(bp string) *LoginURL
- type LoginUnauthorized
Constants ¶
const HealthcheckOKCode int = 200
HealthcheckOKCode is the HTTP code returned for type HealthcheckOK
const LoginBadRequestCode int = 400
LoginBadRequestCode is the HTTP code returned for type LoginBadRequest
const LoginInternalServerErrorCode int = 500
LoginInternalServerErrorCode is the HTTP code returned for type LoginInternalServerError
const LoginOKCode int = 200
LoginOKCode is the HTTP code returned for type LoginOK
LoginUnauthorizedCode is the HTTP code returned for type LoginUnauthorized
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Healthcheck ¶
type Healthcheck struct {
Context *middleware.Context
Handler HealthcheckHandler
}
Healthcheck swagger:route GET /health general healthcheck
Healthcheck ¶
Health check endpoint
func NewHealthcheck ¶
func NewHealthcheck(ctx *middleware.Context, handler HealthcheckHandler) *Healthcheck
NewHealthcheck creates a new http.Handler for the healthcheck operation
func (*Healthcheck) ServeHTTP ¶
func (o *Healthcheck) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type HealthcheckHandler ¶
type HealthcheckHandler interface {
Handle(HealthcheckParams) middleware.Responder
}
HealthcheckHandler interface for that can handle valid healthcheck params
type HealthcheckHandlerFunc ¶
type HealthcheckHandlerFunc func(HealthcheckParams) middleware.Responder
HealthcheckHandlerFunc turns a function with the right signature into a healthcheck handler
func (HealthcheckHandlerFunc) Handle ¶
func (fn HealthcheckHandlerFunc) Handle(params HealthcheckParams) middleware.Responder
Handle executing the request and returning a response
type HealthcheckOK ¶
type HealthcheckOK struct {
/*
In: Body
*/
Payload string `json:"body,omitempty"`
}
HealthcheckOK Ok
swagger:response healthcheckOK
func NewHealthcheckOK ¶
func NewHealthcheckOK() *HealthcheckOK
NewHealthcheckOK creates HealthcheckOK with default headers values
func (*HealthcheckOK) SetPayload ¶
func (o *HealthcheckOK) SetPayload(payload string)
SetPayload sets the payload to the healthcheck o k response
func (*HealthcheckOK) WithPayload ¶
func (o *HealthcheckOK) WithPayload(payload string) *HealthcheckOK
WithPayload adds the payload to the healthcheck o k response
func (*HealthcheckOK) WriteResponse ¶
func (o *HealthcheckOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type HealthcheckParams ¶
HealthcheckParams contains all the bound params for the healthcheck operation typically these are obtained from a http.Request
swagger:parameters Healthcheck
func NewHealthcheckParams ¶
func NewHealthcheckParams() HealthcheckParams
NewHealthcheckParams creates a new HealthcheckParams object
There are no default values defined in the spec.
func (*HealthcheckParams) BindRequest ¶
func (o *HealthcheckParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.
To ensure default values, the struct must have been initialized with NewHealthcheckParams() beforehand.
type HealthcheckURL ¶
type HealthcheckURL struct {
// contains filtered or unexported fields
}
HealthcheckURL generates an URL for the healthcheck operation
func (*HealthcheckURL) Build ¶
func (o *HealthcheckURL) Build() (*url.URL, error)
Build a url path and query string
func (*HealthcheckURL) BuildFull ¶
func (o *HealthcheckURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*HealthcheckURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*HealthcheckURL) SetBasePath ¶
func (o *HealthcheckURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*HealthcheckURL) String ¶
func (o *HealthcheckURL) String() string
String returns the string representation of the path with query string
func (*HealthcheckURL) StringFull ¶
func (o *HealthcheckURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*HealthcheckURL) WithBasePath ¶
func (o *HealthcheckURL) WithBasePath(bp string) *HealthcheckURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type Login ¶
type Login struct {
Context *middleware.Context
Handler LoginHandler
}
Login swagger:route POST /login general login
Login ¶
Returns JWT token for authorized user
func NewLogin ¶
func NewLogin(ctx *middleware.Context, handler LoginHandler) *Login
NewLogin creates a new http.Handler for the login operation
type LoginBadRequest ¶
LoginBadRequest Bad Request
swagger:response loginBadRequest
func NewLoginBadRequest ¶
func NewLoginBadRequest() *LoginBadRequest
NewLoginBadRequest creates LoginBadRequest with default headers values
func (*LoginBadRequest) SetPayload ¶
func (o *LoginBadRequest) SetPayload(payload *models.Error)
SetPayload sets the payload to the login bad request response
func (*LoginBadRequest) WithPayload ¶
func (o *LoginBadRequest) WithPayload(payload *models.Error) *LoginBadRequest
WithPayload adds the payload to the login bad request response
func (*LoginBadRequest) WriteResponse ¶
func (o *LoginBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type LoginHandler ¶
type LoginHandler interface {
Handle(LoginParams) middleware.Responder
}
LoginHandler interface for that can handle valid login params
type LoginHandlerFunc ¶
type LoginHandlerFunc func(LoginParams) middleware.Responder
LoginHandlerFunc turns a function with the right signature into a login handler
func (LoginHandlerFunc) Handle ¶
func (fn LoginHandlerFunc) Handle(params LoginParams) middleware.Responder
Handle executing the request and returning a response
type LoginInternalServerError ¶
type LoginInternalServerError struct {
/*
In: Body
*/
Payload *models.Error `json:"body,omitempty"`
}
LoginInternalServerError Internal Server Error
swagger:response loginInternalServerError
func NewLoginInternalServerError ¶
func NewLoginInternalServerError() *LoginInternalServerError
NewLoginInternalServerError creates LoginInternalServerError with default headers values
func (*LoginInternalServerError) SetPayload ¶
func (o *LoginInternalServerError) SetPayload(payload *models.Error)
SetPayload sets the payload to the login internal server error response
func (*LoginInternalServerError) WithPayload ¶
func (o *LoginInternalServerError) WithPayload(payload *models.Error) *LoginInternalServerError
WithPayload adds the payload to the login internal server error response
func (*LoginInternalServerError) WriteResponse ¶
func (o *LoginInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type LoginOK ¶
type LoginOK struct {
/*
In: Body
*/
Payload *models.LoginSuccess `json:"body,omitempty"`
}
LoginOK Successful login
swagger:response loginOK
func (*LoginOK) SetPayload ¶
func (o *LoginOK) SetPayload(payload *models.LoginSuccess)
SetPayload sets the payload to the login o k response
func (*LoginOK) WithPayload ¶
func (o *LoginOK) WithPayload(payload *models.LoginSuccess) *LoginOK
WithPayload adds the payload to the login o k response
func (*LoginOK) WriteResponse ¶
func (o *LoginOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type LoginParams ¶
type LoginParams struct {
// HTTP Request Object
HTTPRequest *http.Request `json:"-"`
/*Login Payload
In: body
*/
Login *models.LoginInfo
}
LoginParams contains all the bound params for the login operation typically these are obtained from a http.Request
swagger:parameters Login
func NewLoginParams ¶
func NewLoginParams() LoginParams
NewLoginParams creates a new LoginParams object
There are no default values defined in the spec.
func (*LoginParams) BindRequest ¶
func (o *LoginParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.
To ensure default values, the struct must have been initialized with NewLoginParams() beforehand.
type LoginURL ¶
type LoginURL struct {
// contains filtered or unexported fields
}
LoginURL generates an URL for the login operation
func (*LoginURL) SetBasePath ¶
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*LoginURL) StringFull ¶
StringFull returns the string representation of a complete url
func (*LoginURL) WithBasePath ¶
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type LoginUnauthorized ¶
LoginUnauthorized Unauthorized
swagger:response loginUnauthorized
func NewLoginUnauthorized ¶
func NewLoginUnauthorized() *LoginUnauthorized
NewLoginUnauthorized creates LoginUnauthorized with default headers values
func (*LoginUnauthorized) SetPayload ¶
func (o *LoginUnauthorized) SetPayload(payload *models.Error)
SetPayload sets the payload to the login unauthorized response
func (*LoginUnauthorized) WithPayload ¶
func (o *LoginUnauthorized) WithPayload(payload *models.Error) *LoginUnauthorized
WithPayload adds the payload to the login unauthorized response
func (*LoginUnauthorized) WriteResponse ¶
func (o *LoginUnauthorized) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client