← all modules

Sky.Http.Middleware

Sky.Http.Middleware
  Sky.Http.Middleware — request/response middleware composers

Values
  withBasicAuth : String -> String -> Handler -> Handler
      `withBasicAuth username password handler` — require HTTP
  withCors : List String -> Handler -> Handler
      `withCors allowedOrigins handler` — add CORS headers for the
  withCsrf : Handler -> Handler
      `withCsrf handler` — CSRF protection via the double-submit
  withLogging : Handler -> Handler
      `withLogging handler` — log each request as `method path
  withRateLimit : String -> Int -> Int -> Handler -> Handler
      `withRateLimit key requestsPerWindow windowSeconds handler`