FanDesk

Background Sync

FanDesk keeps your data synchronized with external services automatically, using smart incremental sync to stay up-to-date without hammering APIs.

How Sync Works

When you connect an external service (Google, GitHub), FanDesk registers background sync jobs that run on a schedule. These jobs run server-side — you do not need to keep FanDesk open for sync to happen.

Google Calendar ──── every 5 min ────→ FanDesk
Gmail           ──── every 60 sec ───→ FanDesk
Google Contacts ──── every 15 min ───→ FanDesk
GitHub Issues   ──── every 10 min ───→ FanDesk
GitHub CI       ──── every 5 min ────→ FanDesk

Sync Frequencies

ServiceFrequencyWhat Syncs
GmailEvery 60 secondsInbox, Sent, Labels, Threads
Google CalendarEvery 5 minutesEvents, calendars, attendees
Google ContactsEvery 15 minutesFull contact directory
GitHub IssuesEvery 10 minutesIssues from linked repositories
GitHub CI StatusEvery 5 minutesPR CI pass/fail status

Incremental Sync

FanDesk uses incremental sync techniques to minimize API usage and keep sync fast:

Gmail Incremental Sync

Gmail sync uses history IDs — a Gmail API feature that lets FanDesk fetch only the changes since the last sync (new emails, label changes, deletions) instead of downloading everything.

  • First sync: Full inbox download (may take a few minutes)
  • Subsequent syncs: Only changes since the last sync
  • This means sync stays fast even with thousands of emails

Calendar Incremental Sync

Calendar sync uses sync tokens from the Google Calendar API:

  • First sync: Downloads all upcoming events
  • Subsequent syncs: Only events created, modified, or deleted since the last sync
  • Deletions are properly handled — events deleted in Google Calendar disappear from FanDesk

OAuth Token Refresh

Google OAuth tokens expire after a period of time. FanDesk automatically refreshes them:

  • Refresh happens every 15 minutes proactively
  • If a sync job encounters an expired token, it refreshes before retrying
  • This is transparent to you — sync continues uninterrupted

If token refresh fails (e.g., you revoked access in Google settings), FanDesk shows a Reconnect prompt in Settings > Integrations.


Manual Sync

Force an immediate sync for any service:

  1. Go to the module that uses the service (Mail, Calendar, etc.)
  2. Click the refresh icon (circular arrow) in the top-right
  3. FanDesk triggers an immediate sync
  4. New data appears within a few seconds

Sync Status

Check the health of your syncs:

  1. Go to Settings > Integrations
  2. Each integration shows:
    • Last synced: Time of most recent successful sync
    • Status: Active, Error, or Reconnect needed
  3. Click Details on any integration to see error messages if something went wrong

Common Sync Issues

IssueCauseFix
Token expiredGoogle revoked or expired the sessionClick Reconnect in Settings > Integrations
Rate limitedToo many API requestsFanDesk backs off automatically; wait a few minutes
Permission revokedYou removed FanDesk's access in Google settingsReconnect and re-grant permissions
Sync pausedFanDesk server maintenanceUsually resolves within minutes

What Sync Does Not Change

Sync is one-way for most data:

  • Gmail: FanDesk reads your Gmail and lets you act on it. Actions (archive, reply, star) sync back to Gmail.
  • Calendar: Two-way. Events created in FanDesk appear in Google Calendar. Changes in Google Calendar sync back.
  • Drive: Read-only. FanDesk shows your files but does not modify them except via explicit actions.
  • GitHub: Read-only sync of issues and CI status. Creating PRs or merging goes through GitHub directly.

Next: Learn about real-time updates in Real-time Updates.

Need help? Contact us at hello@fandesk.ai