Scope required: calendar:write
A person can only have one instance of an event type every day. That means no 2 instances of a sick day, of 2 instances of the same type of overtime/day off are allowed on the same date. Because it's tedious to perform a delete-and-add cycle, this API call can overwrite an existing event or create a new one if no previous event was found.
This API call is handy for ERP integrations that want to synchronize timetracking and overtime in particular to Officient.
- The 'type' parameter can be either 'sick_day', 'education' or 'custom'
- The custom_day_off_type_id must only be set when using the 'custom' type. Use the custom event types API call to get the custom types that are available in a given year.
For ease of use, the 'duration_minutes' parameter can be set to 'all_day'. This will signal that the event should have the duration of the scheduled amount of hours for that day.