modulepackage
1.6.1
Repository: https://github.com/wolfeidau/echo-middleware.git
Documentation: pkg.go.dev
# README
echo-middleware
This project provides a collection of echo middleware used in API / Web projects.
License
This code was authored by Mark Wolfe and licensed under the Apache 2.0 license.
# Functions
NoCache returns a middleware which sets the no cache headers with default configuration.
NoCacheWithConfig returns a middleware which sets a number of http headers to ensure the resource is not cached.
OriginVerifierWithConfig returns a middleware which verifies requests include a `X-Origin-Verify` header containing the token configured, requests which fail will be rejected with a 400 bad request status code.
ZeroLogRequestLog returns a request logger middleware with default config.
ZeroLogRequestLogWithConfig returns a request logger middleware with config.
ZeroLogWithConfig setup and return an echo middleware with zerolog logger available from the context.Context.
# Constants
No description provided by the author
# Structs
NoCacheConfig used to configure the no cache middleware.
OriginVerifierConfig used to configure the origin authentication middleware.
ZeroLogConfig used to configure the zerolog echo middleware.
ZeroLogRequestLogConfig defines the config for the request logger middleware.