Files
app/ts_interfaces/data/loint-reception.jwt.ts
T

44 lines
860 B
TypeScript
Raw Normal View History

2024-09-29 13:56:38 +02:00
export type TLoginStatus = 'loggedIn' | 'loggedOut' | 'invalidated' | 'not found' | 'transfer';
export type TLoginAction = 'login' | 'logout' | 'manage';
export interface IJwt {
id: string;
blocked: boolean;
data: {
/**
* the user id of the jwt
*/
userId: string;
/**
* the login session backing this jwt
*/
sessionId?: string;
2024-09-29 13:56:38 +02:00
/**
* the latest point of
*/
validUntil: number;
/**
* hold off from refreshing before
*/
refreshFrom: number;
/**
* an interval in millis to recheck token invalidation
*/
refreshEvery: number;
/**
* legacy field kept for compatibility with already-issued jwt documents
2024-09-29 13:56:38 +02:00
*/
refreshToken?: string;
2024-09-29 13:56:38 +02:00
/**
* just for looks/debugging
*/
justForLooks: {
validUntilIsoString: string;
};
};
}