Calendar

Get availability

Returns availability information for the specified user or group of users. All participants' email addresses must be associated with valid Nylas grants, and should be unique within their application.

post/v3/calendars/availability

Request body

duration_minutesinteger required

The duration of each time slot, in minutes. The duration must be a multiple of 5 minutes.

end_timeinteger required

The end of the time slot that Nylas checks availability for, in seconds using the Unix timestamp format. The time must be a multiple of 5 minutes.

interval_minutesinteger

Nylas generates a time slot every interval_minutes (for example, every 30 minutes) and returns only slots when all participants are free. The interval must be a multiple of 5 minutes.

round_tointeger

Nylas rounds each time slot to the nearest round_to value. For example, if a time slot starts at 9:05a.m. and round_to is set to 15, Nylas rounds it to 9:15a.m. The round to value must be a multiple of 5 minutes.

start_timeinteger required

The beginning of the time slot that Nylas checks availability for, in seconds using the Unix timestamp format. The time must be a multiple of 5 minutes.

Example request

{
  "Collective request": {
    "participants": [
      {
        "email": "nyla@example.com",
        "calendar_ids": [
          "primary"
        ],
        "open_hours": [
          {
            "days": [
              0,
              1,
              2
            ],
            "timezone": "America/Toronto",
            "start": "9:00",
            "end": "17:00"
          }
        ]
      },
      {
        "email": "leyah@example.com"
      }
    ],
    "start_time": 1659366000,
    "end_time": 1659733200,
    "interval_minutes": 30,
    "duration_minutes": 30,
    "round_to": 15,
    "availability_rules": {
      "availability_method": "collective",
      "buffer": {
        "before": 15,
        "after": 15
      }
    }
  }
}

Response

Return availability

request_idstring

The request ID.

Example response

{
  "request_id": "5fa64c92-e840-4357-86b9-2aa364d35b88"
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.