feat: user/service sessions type
This commit is contained in:
@ -31,3 +31,50 @@ export interface ApiServiceCredentials {
|
||||
client_id: string;
|
||||
client_secret: string;
|
||||
}
|
||||
|
||||
export interface ServiceSession {
|
||||
id: string;
|
||||
service_id: string;
|
||||
api_service?: ApiService | null;
|
||||
client_id: string;
|
||||
user_id?: string | null;
|
||||
user?: UserProfile | null;
|
||||
issued_at: string;
|
||||
expires_at?: string | null;
|
||||
last_active?: string | null;
|
||||
ip_address?: string | null;
|
||||
user_agent?: string | null;
|
||||
access_token_id?: string | null;
|
||||
refresh_token_id?: string | null;
|
||||
is_active: boolean;
|
||||
revoked_at?: string | null;
|
||||
scope?: string | null;
|
||||
claims: string; // base64 encoded
|
||||
}
|
||||
|
||||
export interface UserSession {
|
||||
id: string;
|
||||
user_id: string;
|
||||
user?: UserProfile | null;
|
||||
session_type: string; // "user" | "admin"
|
||||
issued_at: string;
|
||||
expires_at?: string | null;
|
||||
last_active?: string | null;
|
||||
ip_address?: string | null;
|
||||
user_agent?: string | null;
|
||||
access_token_id?: string | null;
|
||||
refresh_token_id?: string | null;
|
||||
device_info: string; // base64 encoded
|
||||
is_active: boolean;
|
||||
revoked_at?: string | null;
|
||||
}
|
||||
|
||||
export interface DeviceInfo {
|
||||
os: string;
|
||||
os_version: string;
|
||||
device_name: string;
|
||||
device_type: string;
|
||||
location: string;
|
||||
browser: string;
|
||||
browser_version: string;
|
||||
}
|
||||
|
Reference in New Issue
Block a user