CookieOptions
Defined in: siwx-server/src/types.ts:212
Attributes of the session cookie, used by createSessionCookie, createClearCookie and the
@tuwaio/siwx-server/next handlers. The cookie is always HttpOnly.
Properties
domain?
optionaldomain?:string
Defined in: siwx-server/src/types.ts:232
The cookie domain.
maxAge?
optionalmaxAge?:number
Defined in: siwx-server/src/types.ts:223
Max-Age in seconds. createSessionCookie defaults to 604800 (7 days). The handlers use their
ttlSeconds instead, and fall back to this value when ttlSeconds is not set.
Default
604800name?
optionalname?:string
Defined in: siwx-server/src/types.ts:217
The name of the cookie.
Default
"siwx-session-v2"path?
optionalpath?:string
Defined in: siwx-server/src/types.ts:228
The cookie path.
Default
"/"sameSite?
optionalsameSite?:"Strict"|"Lax"|"None"
Defined in: siwx-server/src/types.ts:242
The SameSite policy.
Default
"Strict"secure?
optionalsecure?:boolean
Defined in: siwx-server/src/types.ts:237
Whether to set the Secure flag.
Default
true