Google 日历:如何通过 google 日历查看客人是否忙碌并且可以预订
Google Calendar: How to check guest is not busy and available to book through google calendar
我正在探索通过 google 脚本或 api 编写 google 日历 api 集成。
有什么方法可以让我在预订活动之前检查客人是否有空?
我在 google 脚本中使用 freebusy api 像这样
var resource = {
timeMin: timeMin,
timeMax: timeMax,
items: [
{
id: calendarId
}
]
};
var response = Calendar.Freebusy.query(resource);
return response.calendars[calendarId]['busy'].length == 0;
我正在探索通过 google 脚本或 api 编写 google 日历 api 集成。
有什么方法可以让我在预订活动之前检查客人是否有空?
我在 google 脚本中使用 freebusy api 像这样
var resource = {
timeMin: timeMin,
timeMax: timeMax,
items: [
{
id: calendarId
}
]
};
var response = Calendar.Freebusy.query(resource);
return response.calendars[calendarId]['busy'].length == 0;