Skip to content

Graphorin API reference v0.4.0


Graphorin API reference / @graphorin/security / / CreateTokenOptions

Interface: CreateTokenOptions

Defined in: packages/security/src/auth/crud.ts:29

Options for createToken(...).

Stable

Properties

PropertyModifierTypeDescriptionDefined in
envreadonlystring-packages/security/src/auth/crud.ts:32
expiresAt?readonlynumber | DateOptional explicit expiry as a Date or epoch ms.packages/security/src/auth/crud.ts:39
expiresInMs?readonlynumberOptional millisecond-precision expiry. Mutually exclusive with expiresAt.packages/security/src/auth/crud.ts:37
idOverride?readonlystringOptional id override (used by rotateToken); defaults to a random UUID.packages/security/src/auth/crud.ts:41
label?readonlystring-packages/security/src/auth/crud.ts:34
now?readonly() => numberWall-clock provider for tests. Defaults to Date.now.packages/security/src/auth/crud.ts:43
pepperreadonlySecretValue-packages/security/src/auth/crud.ts:31
prefix?readonlystring-packages/security/src/auth/crud.ts:35
scopesreadonlyreadonly string[]-packages/security/src/auth/crud.ts:33
tokenStorereadonlyAuthTokenStore-packages/security/src/auth/crud.ts:30