lib/entities
アカウント
実装
RemoveIndex
<AdapterAccount
>
コンストラクター
new Account(undefined)
new Account(): Account
戻り値
プロパティ
access_token?
optional access_token: string;
実装
RemoveIndex.access_token
expires_at?
optional expires_at: number;
実装
RemoveIndex.expires_at
id
id: string;
id_token?
optional id_token: string;
実装
RemoveIndex.id_token
provider
provider: string;
実装
RemoveIndex.provider
providerAccountId
providerAccountId: string;
実装
RemoveIndex.providerAccountId
refresh_token?
optional refresh_token: string;
実装
RemoveIndex.refresh_token
scope?
optional scope: string;
実装
RemoveIndex.scope
session_state?
optional session_state: JsonValue;
token_type?
optional token_type: Lowercase<string>;
実装
RemoveIndex.token_type
type
type: AdapterAccountType;
実装
RemoveIndex.type
ユーザー
user: User;
userId
userId: string;
実装
RemoveIndex.userId
セッション
セッションは、ユーザーの現在のサインイン状態に関する情報を保持します。
実装
コンストラクター
new Session(undefined)
new Session(): Session
戻り値
プロパティ
expires
expires: Date;
セッションが期限切れになる絶対日付。
セッションが期限切れになる前にアクセスされた場合、SessionOptions.maxAge
で定義されたmaxAge
オプションに基づいて延長されます。 SessionOptions.updateAge
で定義された期間内に複数回延長されることはありません。
セッションが期限切れになった後にアクセスされた場合、アクティブでないセッションをクリーンアップするためにデータベースから削除されます。
実装
id
id: string;
sessionToken
sessionToken: string;
AuthConfig.strategy
オプションで"database"
を使用する場合に、データベース内のセッションを検索するために使用されるランダムに生成された値。この値は、クライアント上のセキュアな HTTP-Only クッキーに保存されます。
実装
ユーザー
user: User;
userId
userId: string;
アクティブなセッションをデータベース内のユーザーに接続します
実装
ユーザー
実装
RemoveIndex
<AdapterUser
>
コンストラクター
new User(undefined)
new User(): User
戻り値
プロパティ
アカウント
accounts: Collection<Account, object>;
メールアドレス
email: string = "";
実装
RemoveIndex.email
メールアドレス確認済み
emailVerified: null | Date = null;
実装
RemoveIndex.emailVerified
ID
id: string;
実装
RemoveIndex.id
画像?
optional image: null | string;
実装
RemoveIndex.image
名前?
optional name: null | string;
実装
RemoveIndex.name
セッション
sessions: Collection<Session, object>;
検証トークン
検証トークンとは、ユーザーがメールアドレス経由でサインインするために使用される一時的なトークンです。これは、ユーザーがメールプロバイダーを使用してサインインするときに作成されます。ユーザーがメール内のリンクをクリックすると、トークンとメールがサーバーに返送され、そこでハッシュ化されてデータベース内の値と比較されます。トークンとメールが一致し、トークンがまだ期限切れになっていない場合、ユーザーはサインインされます。その後、トークンはデータベースから削除されます。
実装
コンストラクタ
new VerificationToken(undefined)
new VerificationToken(): VerificationToken
戻り値
プロパティ
期限切れ
expires: Date;
トークンが期限切れになる絶対日時。
実装
識別子
identifier: string;
ユーザーのメールアドレス。
実装
トークン
token: string;
ハッシュ化されたトークン。 AuthConfig.secret
値を使用します。