export interface SyncAccount {
  id: string;
  user_id: string;
  account_email: string;
  account_id: string;
  provider: "office365" | "exchange" | "google";
  profile_picture: string;
  profile_url: string | null;
  access_token?: string | null;
  refresh_token?: string | null;
  access_token_expire: string;
  locale: string | null;
  created_at: string;
  updated_at: string;
}

export interface Calendar {
  id: string;
  provider: "office365" | "exchange" | "google";
  sync_account_id: string;
  syncing: boolean;
  exporting: boolean;
  sync_availability: boolean;
  sync_listings: boolean;
  uid: string;
  name: string;
  description: string | null;
  url: string | null;
  owner: string | null;
  min_access_role: string;
  read_only?: boolean;
  originally_created: unknown;
  last_modified: unknown;
  timezone: string;
  created_at: string;
  updated_at: string;
}

export interface WithSyncAccount<T = unknown> {
  sync_account: SyncAccount & T;
}
