Skip to content

Principal lookup

Gradle setup

    compile group: "org.http4k", name: "http4k-core", version: "3.241.0"

When authorising requests, it is common to need to store some credentials or a user principal object to be accessible by a further Filter or the eventual HttpHandler.

This can be easily achieved by combining the typesafe RequestContext functionality with one of the built-in authorisation Filters: