freescout2ant/Services
Claude fc5a3d949a
Fix archived replies not retried after re-login (#39)
The core bug was in CrmApiClient::archiveConversation() which returned a
truthy error array on token failures, causing archiveConversationData()
to mark threads as archived even though the CRM API was never called.

Changes:
- Return false (not error array) from archiveConversation() on token error
- Add `last_error` column to crm_archive_threads to track failed archivals
- Record failures in CrmArchiveThread so the cron can retry them
- Update ArchiveThreads command to retry failed entries and skip
  disconnected users (no token file)
- Wrap ArchiveThreadsJob in try-catch to track unexpected exceptions
- Use CrmArchive as source for conversation IDs (more reliable)

https://claude.ai/code/session_01Bvg33MSPkDhxo1LJ6kQBxu
2026-04-14 21:50:01 +00:00
..
ConversationArchiver.php Fix archived replies not retried after re-login (#39) 2026-04-14 21:50:01 +00:00
CrmApiClient.php Fix archived replies not retried after re-login (#39) 2026-04-14 21:50:01 +00:00
CrmService.php Refactor CRM integration 2025-06-04 19:49:10 +02:00
TokenService.php Sanitize token-related logging in Ameise services 2026-04-14 23:32:34 +02:00