validate

fun validate(body: suspend ApplicationCall.(JWTCredential) -> P?)(source)

Sets a validation function for JWTCredential.

Return a principal of type P when authentication succeeds, or null when the verified JWT should not be accepted.

Report a problem

Parameters

body

validation function called after the token is verified.