from __future__ import annotations from dataclasses import dataclass @dataclass(frozen=True) class CoreScanResult: scanned: int linkedin: int advertising: int veille_techno: int skipped: int failed: int @dataclass(frozen=True) class CoreBusySlot: calendar_id: str start: str end: str @dataclass(frozen=True) class CoreAvailabilityResult: start: str end: str available: bool busy_slots: list[CoreBusySlot] checked_calendars: list[str] @dataclass(frozen=True) class CoreMeetingInterval: start: str end: str @dataclass(frozen=True) class CoreMeetingIntervalsResult: start: str end: str timezone: str meeting_intervals: list[CoreMeetingInterval] checked_calendars: list[str] @dataclass(frozen=True) class CoreUnsubscribeDigestResult: scanned_messages: int extracted_unique_links: int new_links: int sent_to: str | None email_sent: bool @dataclass(frozen=True) class CoreUnsubscribeMethod: method_id: str method_type: str value: str @dataclass(frozen=True) class CoreMailingListCandidate: candidate_id: str list_name: str sender_domain: str message_count: int sample_senders: list[str] sample_subjects: list[str] methods: list[CoreUnsubscribeMethod] approved: bool @dataclass(frozen=True) class CoreUnsubscribeCandidatesResult: scanned_messages: int candidates: list[CoreMailingListCandidate] @dataclass(frozen=True) class CoreMethodExecution: candidate_id: str list_name: str method_id: str method_type: str value: str success: bool detail: str @dataclass(frozen=True) class CoreUnsubscribeExecutionResult: scanned_messages: int candidates_considered: int selected_candidates: int executed_methods: int skipped_already_executed: int failed_methods: int updated_approved_count: int results: list[CoreMethodExecution]