Documentation ¶
Index ¶
- func DefaultSkipper(*fiber.Ctx) bool
- func GetFiberContext(c context.Context) *fiber.Ctx
- func GetUserData(c context.Context) interface{}
- func OapiRequestValidator(swagger *openapi3.T) fiber.Handler
- func OapiRequestValidatorWithOptions(swagger *openapi3.T, options *Options) fiber.Handler
- func OapiValidatorFromYamlFile(path string) (fiber.Handler, error)
- func ValidateRequestFromContext(ctx *fiber.Ctx, router routers.Router, options *Options) error
- type Options
- type Skipper
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultSkipper ¶
func DefaultSkipper(*fiber.Ctx) bool
DefaultSkipper returns false which processes the middleware.
func GetFiberContext ¶
Helper function to get the fiber context from within requests. It returns nil if not found or wrong type.
func GetUserData ¶
func OapiRequestValidator ¶
Create a validator from a swagger object.
func OapiRequestValidatorWithOptions ¶
Create a validator from a swagger object, with validation options
func OapiValidatorFromYamlFile ¶
Create validator middleware from a YAML file path
Types ¶
type Options ¶
type Options struct { Options openapi3filter.Options ParamDecoder openapi3filter.ContentParameterDecoder UserData interface{} Skipper Skipper }
Options to customize request validation. These are passed through to openapi3filter.
Click to show internal directories.
Click to hide internal directories.