google-calendar
google-calendar copied to clipboard
Get events that are marked as “busy” only
I am using the Google Calendar api to access users' events. I want to access all of the users events that are marked as "busy." I can't use the freebusy
api since I need the actual event details. Here's what I currently have:
gcal(accessToken).events.list(
calendars[inc].id,
{
orderBy: 'startTime',
maxResults: 2500,
singleEvents: true,
timeMax: max.toISOString(),
timeMin: min.toISOString()
},
(err, data) => {
// ...
}
);
This works fine. How can I limit the results to only events marked as "busy"? (So excluding, for example holidays, or day-long reminder events that the user has marked as "available.")
Thank you
NOTE: this is a duplicate of this StackOverflow post.