import jwt, { JwtPayload } from 'jsonwebtoken'; export interface PSJwtPayload extends JwtPayload { UserInfo: { id: string; email: string; displayName: string; }; clientId?: string; exp: number; iat?: number; iss?: string; idp?: string; role?: string[]; } export declare class JwtUtils { /** * Decodes a JWT token without verifying signature * @param token - The JWT token to decode * @returns Decoded token payload or null if invalid */ static decode(token: string): string | jwt.JwtPayload | null; /** * Decodes and verifies a JWT token * @param token - The JWT token to verify * @param secret - The secret key used to sign the token * @returns Decoded and verified token payload or null if invalid */ static verify(token: string, secret: string): string | jwt.JwtPayload | null; /** * Checks if a token has expired * @param token - The JWT token to check * @returns boolean indicating if token is expired */ static isTokenExpired(token: string): boolean; /** * Extracts token from Authorization header * @param authHeader - The Authorization header value * @returns Clean token string or null */ static extractTokenFromHeader(authHeader?: string): string | null; }