Calendar API v3中eventType规范的变更是否会影响GoogleAppsScript的CalendarApp?

问题描述 投票:0回答:1

2024 年 2 月 8 日,我收到了来自“Google Developers. “[需要采取行动] 更新您的应用程序以包含 Google Calendar API v3 的通知改进”

如果我使用 Calendar API v3 检索 event.list 时没有指定 eventType 参数的任何值,则返回值将从 2024 年 3 月 11 日开始更改。

*如果没有为 eventType 指定值 现在: 返回带有 ["default", "focusTime", "outOfOffice"] 的事件。 2024 年 3 月 11 日之后: 将返回“workingLocation”的事件 https://developers.google.com/calendar/api/v3/reference/events/list?hl=ja

此 API 变更是否会影响 GoogleAppsScript 的 CalendarApp 服务的使用? 目前,使用CalendarApp的getEvents时,没有指定eventType的方法。

我猜CalendarApp服务也是通过在后台调用日历API来工作的,所以我们想知道这个变化是否会影响这个服务。 2024年3月31日之后,GoogleAppsScript的CalendarApp的“getEvents”方法会像现在一样工作吗?

google-calendar-api google-workspace
1个回答
0
投票

收到了 Google Workspace 支持人员的答复

我已收到 Google Workspace 支持人员的答复。如下所示。

  • Calendar API v3 中 eventType 规范的更改会影响 GoogleAppsScript 的 CalendarApp。
  • 2024年3月11日之后,GAS中CalendarApp的getEvents()等方法,除了当前值之外,还将返回“工作位置事件”。
  • 即CalendarApp 将在 2024 年 3 月 11 日之后返回 ["default"、"focusTime"、"outOfOffice"、"workingLocation"] 事件。
  • 此行为也适用于日历 API v3。
  • 即如果我们在使用 Calendar API v3 检索 event.list 时没有指定 eventType 参数的任何值,它将返回 2024 年 3 月 11 日之后的 ["default", "focusTime", "outOfOffice", "workingLocation"] 事件。

正如 Tanaike-san 在评论中提到的,我担心 Google 的两个答案之间存在一些差异。
但我认为这不会产生任何大的影响,因为“工作位置事件”将被添加到 API 的当前响应中。

© www.soinside.com 2019 - 2024. All rights reserved.