Categorygithub.com/grasp-labs/go-middleware
modulepackage
1.1.3
Repository: https://github.com/grasp-labs/go-middleware.git
Documentation: pkg.go.dev

# README

Go Middlewares

In this package you will find all sharable middlewares for Echo framework.

Available middlewares

AuditCustom ContextJWT AuthorizationTimeoutUsage
Implemented

Usage examples

If you don't know how to implement some of middlewares take a look at examples:

Also you can take a look at code examples attached to documentation. Highlight some middleware function and see examples:

highlight.png

Running middlewares locally

If some of middleware use AWS libs (like JWT Authorization), to run it locally, you need to start Docker container. Information about how to start such container is located here.

# Functions

Dispatch all requests made to api, internal and internet facing, a record will be created on which user, tenant and service, how the service was used, from which IP at what time.
GetJWTKey Get JWT secret from AWS parameter store.
No description provided by the author
NewCustomContextMiddleware creates a middleware that enriches the echo context with custom data that can be found under context.Get("user").
No description provided by the author
UsageWithConfig returns a middleware for tracing service usage in api applications.

# Constants

No description provided by the author
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
No description provided by the author
No description provided by the author
UsageConfig defines the config for UsageWithConfig middleware.