Example JWT payload:

{
  "aud": [ "example.com" ],
  "email": {
    "address": "user@example.com",
    "is_primary": true,
    "is_verified": true
  },
  "exp": "17123108000",
  "iat": "1712307200",
  "sub": "9930ac89-1584-488c-bd63-1607f03ab1e8"
}

The actual values of the fields in the JWT payload will depend on the specific user and the application.

It’s important to note that the aud (Audience) field is set by the Hanko backend based on the configured values when creating a project on the Hanko Cloud.

It contains the following fields:

aud (Audience):

  • Description: The audience for which the JWT was created. It specifies the intended recipient or system that should accept this JWT. When using Hanko Cloud, the aud will be your app URL.
  • Type: Array of Strings

email:

  • Description: An object containing information about the user’s email address.

  • Type: Object

    • Properties:

      address:

      • Description: The current primary email address of the user.
      • Type: String

      is_primary:

      • Description: A boolean field indicating whether the email address is the primary email. Currently, this field is redundant because only the primary email is included in the JWT.
      • Type: Boolean

      is_verified:

      • Description: A boolean field indicating whether the email address has been verified.

exp (Expiration Time):

  • Description: The timestamp indicating when the JWT will expire.
  • Type: Number (UNIX timestamp)

iat (Issued At):

  • Description: The timestamp indicating when the JWT was created.
  • Type: Number (UNIX timestamp)

sub (Subject):

  • Description: The user ID.
  • Type: String