package middleware import "net/http" // loggingMiddleware is an example that logs each incoming request. // Replace with your logger of choice. func LoggingMiddleware(next http.Handler) http.Handler { return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { // log.Printf("[%s] %s", r.Method, r.URL.Path) next.ServeHTTP(w, r) }) }