Skip to content

five-on-it / apps/api/src/store / OAuthCode

Interface: OAuthCode ​

Defined in: apps/api/src/store.ts:716

An authorization code the sign-in page gave a client: single use, ten minutes, kept by the SHA-256 of its value (the value itself is never stored).

Properties ​

account ​

account: Account

Defined in: apps/api/src/store.ts:728

Who signed in.


challenge ​

challenge: string

Defined in: apps/api/src/store.ts:726

The PKCE challenge (S256).


client ​

client: string

Defined in: apps/api/src/store.ts:720

The client it was given to.


expiresAt ​

expiresAt: string

Defined in: apps/api/src/store.ts:735

ISO times: when it expires, and when it was used.


grant ​

grant: string

Defined in: apps/api/src/store.ts:733

The grant its tokens belong to: revoked when the code is used twice.


hash ​

hash: string

Defined in: apps/api/src/store.ts:718

The SHA-256 of the code (hex).


redirectUri ​

redirectUri: string

Defined in: apps/api/src/store.ts:722

The redirect URI it was sent to.


redirectUriSent ​

redirectUriSent: boolean

Defined in: apps/api/src/store.ts:724

Whether the authorization request named it (the token request must then repeat it).


resource? ​

optional resource?: string

Defined in: apps/api/src/store.ts:731


scope? ​

optional scope?: string

Defined in: apps/api/src/store.ts:730

The scope and the resource (RFC 8707) the client asked for.


usedAt? ​

optional usedAt?: string

Defined in: apps/api/src/store.ts:736