Installation
npm install --save @types/passport-cognito
Summary
This package contains type definitions for passport-cognito (https://github.com/kndt84/passport-cognito).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/passport-cognito.
index.d.ts
import passport = require("passport");
import express = require("express");
export interface CognitoStrategyOptions {
userPoolId: string;
clientId: string;
region: string;
}
export type CognitoVerifyFunction = (
accessToken: string,
idToken: string,
refreshToken: string,
user: object,
done: (error: any, user?: any) => void,
) => any;
export class Strategy extends passport.Strategy {
constructor(options: CognitoStrategyOptions, verify: CognitoVerifyFunction);
name: string;
authenticate(req: express.Request, options?: object): void;
}
Additional Details
- Last updated: Tue, 07 Nov 2023 09:09:39 GMT
- Dependencies: @types/express, @types/passport
Credits
These definitions were written by Maksym Butsykin.