> ## Documentation Index
> Fetch the complete documentation index at: https://docs.attio.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Syncing meetings

> How to use Attio's public API to sync de-duplicated meetings from your service

If you are building an integration with Attio and would like to read or write meeting data over the
Attio API, this guide will walk you through the appropriate steps.

## How to sync meetings

One of Attio's most powerful features is its real-time email and calendar sync. When a user connects
their Gmail or Outlook account, Attio will automatically and continuously keep the user's emails and
meetings in sync. As a result, if you are writing meeting data that may have also been written by
Attio's sync engine (i.e. meetings that you have synced from Gmail or Outlook into Attio inside your
own product), you need to ensure that you write meetings correctly to avoid duplicates.

Alternatively, if you are writing data that has not come from Gmail or Outlook, we provide additional
ID-based de-duplication mechanisms to provide convenient find/create functionality for meetings.

The core endpoint for both of these paths is the [find or create a meeting endpoint](/rest-api/endpoint-reference/meetings/find-or-create-a-meeting).

### Writing calendar events from Google and Outlook

When writing calendar events that you have synced from Gmail or Outlook, Attio's meetings API uses
iCal data to match meetings, regardless of which account or provider they have been synced from. As
such, you should specify the object form of the `external_ref` attribute when writing these meetings.

The following properties must always be specified:

* `ical_uid` - The iCal UID of the meeting (note: not the provider's unique ID).
* `provider` - One of `'google'` or `'outlook'`.
* `is_recurring` - Whether or not the meeting repeats in the user's calendar.

Additionally, if you are syncing a meeting which has had its start time modified, you must specify
the original start time of the meeting also via the `original_start_time` property.

Attio always treats data from our own sync engine as authoritative. Consequently, if you are writing
a meeting that matches to an existing meeting in Attio, you may receive slightly different data back
in the response to your API call.

### Writing calendar events without Google or Outlook

When writing calendar events that do not have a corresponding Google or Outlook meeting in your
system, you should specify the `external_ref` attribute as a string.

The value of this string should be a consistent, unique identifier for the meeting in your system.
For example, it may be an ID of a row in your meeting database table. When calling the find or create
meeting endpoint, calls made by your app with the same `external_ref` value will be treated as the
same meeting.
