auth-vir - v1.3.1
    Preparing search index...

    Type Alias CookieParams

    CookieParams: {
        cookieDuration: AnyDuration;
        cookieName?: string;
        hostOrigin: string;
        jwtParams: Readonly<CreateJwtParams>;
    } & PartialWithUndefined<{ isDev: boolean }>

    Parameters for generateAuthCookie.

    Type Declaration

    • cookieDuration: AnyDuration

      The max duration of this cookie. Or, in other words, the max user session duration before they're logged out.

    • OptionalcookieName?: string
    • hostOrigin: string

      The origin of the host (backend) service that cookies will be included in all requests to. This should be restricted to just your host (backend) origin for security purposes.

      'https://www.example.com'
      
    • jwtParams: Readonly<CreateJwtParams>

      All JWT parameters required for generating the encrypted JWT that will be embedded in the Cookie. Note that all JWT keys contained herein should never shared with any frontend, client, etc.