@greenpress/auth
Version:
Express Passport authentication service
16 lines (15 loc) • 651 B
TypeScript
import { Response } from 'express';
export declare function verifyToken(token: string, tenant: string): Promise<unknown>;
export declare function verifyRefreshToken(refreshToken: string, tenant: string): Promise<unknown>;
export declare function getUniqueId(creationTime?: string): string;
export declare function setCookie(res: Response, cookieId: string, maxAge?: number): Response<any, Record<string, any>>;
export declare function getSignedToken(user: any, tokenIdentifier: string, expiresIn?: string): {
payload: {
sub: any;
tenant: any;
email: any;
name: any;
roles: any;
};
token: string;
};