SimpleDecodedJwt

data class SimpleDecodedJwt(val subject: String, val claims: Map<String, Any?>) : DecodedJwt

Immutable DecodedJwt implementation created by adapter modules after library-specific verification.

Constructors

Link copied to clipboard
constructor(subject: String, claims: Map<String, Any?>)

Properties

Link copied to clipboard
open override val claims: Map<String, Any?>

All claims from the token payload. Values may be strings, numbers, booleans, lists, or maps.

Link copied to clipboard
open override val subject: String

The sub (subject) claim. Blank string when the token carried no sub claim.

Functions

Link copied to clipboard
open fun <T> claim(name: String): T?

Returns the claim value cast to T, or null when the claim is absent or not of the expected type.