Why do I get duplicate events?
If you’re getting duplicated events when you edit existing events, it may be because of how you’re using event_id
and event_uid
values.
Cronofy operates an upsert model when creating or updating events from your application. The API creates an event if one doesn’t exist or updates an existing one if it does. The key field used to identify an event from your application is the event_id
. This is a value that your application specifies and manages.
The most common cause of duplicate events is using the event_uid
value in the event_id
attribute when attempting to update an event.
An events event_uid
is Cronofy’s internal identifier for the event. The reason there are two IDs is because we differentiate between events that your application manages and events that are created in the calendar by other means, eg by the user. We call these unmanaged or external events.
You can only use the event_uid
to edit unmanaged events. This requires and additional permission from the end-user before you have this capability enabled. See Edit External Events for more information.