50 lines
906 B
TypeScript
Executable File
50 lines
906 B
TypeScript
Executable File
/**
|
|
* types.ts
|
|
*
|
|
* @author Descomplicar® Crescimento Digital
|
|
* @link https://descomplicar.pt
|
|
* @copyright 2025 Descomplicar®
|
|
*/
|
|
|
|
export interface Email {
|
|
id: number;
|
|
sender: string;
|
|
subject: string;
|
|
snippet: string;
|
|
timestamp: string;
|
|
}
|
|
|
|
export enum EmailCategory {
|
|
PROMOTIONS = 'PROMOÇÕES',
|
|
NOTIFICATIONS = 'NOTIFICAÇÕES',
|
|
IMPORTANT = 'IMPORTANTE',
|
|
NEWSLETTERS = 'NEWSLETTERS',
|
|
SPAM = 'SPAM',
|
|
UNKNOWN = 'DESCONHECIDO'
|
|
}
|
|
|
|
export interface ClassifiedCategory {
|
|
category: EmailCategory | string;
|
|
summary: string;
|
|
email_ids: number[];
|
|
}
|
|
|
|
export interface CategorizedEmails {
|
|
[key: string]: {
|
|
summary: string;
|
|
emails: Email[];
|
|
};
|
|
}
|
|
|
|
export interface Account {
|
|
id: number;
|
|
email: string;
|
|
provider: 'gmail' | 'outlook' | 'yahoo' | 'imap';
|
|
avatar: string;
|
|
}
|
|
|
|
export interface CrmSettings {
|
|
url: string;
|
|
token: string;
|
|
autoDeleteTickets: boolean;
|
|
} |