Options
All
  • Public
  • Public/Protected
  • All
Menu

An IDP storage adapter that uses an ExpiringStorage to persist data.

Hierarchy

  • ExpiringAdapter

Implements

  • Adapter

Index

Constructors

constructor

Properties

Protected Readonly logger

logger: Logger = ...

Private Readonly name

name: string

Private Readonly storage

storage: ExpiringStorage<string, unknown>

Private Readonly storageName

storageName: string

Methods

consume

  • consume(id: string): Promise<void>

destroy

  • destroy(id: string): Promise<void>

find

  • find(id: string): Promise<void | AdapterPayload>

findByUid

  • findByUid(uid: string): Promise<void | AdapterPayload>

findByUserCode

  • findByUserCode(userCode: string): Promise<void | AdapterPayload>

Private grantKeyFor

  • grantKeyFor(id: string): string

Private keyFor

  • keyFor(id: string): string

revokeByGrantId

  • revokeByGrantId(grantId: string): Promise<void>

Private uidKeyFor

  • uidKeyFor(uid: string): string

upsert

  • upsert(id: string, payload: AdapterPayload, expiresIn?: number): Promise<void>

Private userCodeKeyFor

  • userCodeKeyFor(userCode: string): string