How to get event type and user calendar availability data
Event Type Availability
Bookafy users can retrieve information about availability for a specific event type when they generate and use a personal access token or OAuth token to authenticate requests to Bookafy’s API.
Use cases that can be achieved with this API:
Take appropriate action based on available times for a given event type.
Effectively share available meeting times from an external application to increase the probability of meetings being booked and enhance the invitee experience.
For example:
Display specific available times when sending communications to invitees directly from external applications.
Include and share first 'X’ available times.
To retrieve a list of available times for a specific event type within a specified date range:
Make a call to /event_types to retrieve a list of all event types (using the organization scope to get all event types across the organization or using the user scope to get all event types for a specific user). The endpoint will return a collection of event types with an event type uri for each item in the array.
Make a call to /event_type_available_times and pass the event type uri for the event type you would like to retrieve information about. Please note that start_time and end_time parameters are required, must be in the future, and cannot be a range greater than 7 days.
User Calendar Availability
Bookafy users can retrieve information about the availability of users in their organization when they generate and use a personal access token or OAuth token to authenticate requests to Bookafy’s API.
Use cases that can be achieved with this API:
Programmatically calculate total hours available for a given user for a given period of time. For example:
Total available hours
Total scheduled hours
Build a custom ‘Calendar View’ for a given user.
View availability schedules and date overrides to determine if a user needs to open up more availability options.
To retrieve information about a specific user’s availability schedule and their busy times for a given period, make the following GET requests:
To retrieve the availability schedules and date overrides for a specific user:
Make a call to /organization_memberships to return a collection of users in an organization which includes a user.uri for each item in the array.
Make a call to /user_availability_schedules and pass the specified user.uri .
To retrieve busy times for a specific user (based upon the connected calendars marked as “Check for Conflicts” in Bookafy ):
Make a call to /organization_memberships to return a collection of users in an organization which includes a user.uri for each item in the array.
Make a call to /user_busy_times and pass the specified user.uri . Please note that start_time and end_time parameters are required, must be in the future, and cannot be a range greater than 7 days.