在 People API 迁移后,Google Apps Script Contacts Service (ContactsApp) 是否仍然有效? 答案:更多信息:

问题描述

Google 将从 2021 年 6 月开始将 Contacts API 迁移到新的 People API。在我的一些 Google Apps 脚本中,我使用了通讯录服务 (https://developers.google.com/apps-script/reference/contacts) 中的 ContactsApp 类。迁移到新的 People API 后,此服务是否仍能正常工作?

解决方法

答案:

Apps 脚本充当 Contacts API 的客户端,将收到与所有其他客户端相同的错误率。

更多信息:

在 Contacts API 停用后,无论如何调用它,都会看到尝试使用它时返回的任何错误 - 无论是客户端库、Apps 脚本包装器还是 HTTP 请求。

Google 最近发送了一封电子邮件,通知更改 - 无论他们是直接使用 Contacts API,还是有使用它的 Apps Script 项目,都应该收到这封邮件。

目前似乎没有 PeopleService 或同等产品的任何计划 - 但 Apps Script Advanced Services 确实集成了 People API。

如果您希望看到这样的实现,我也强烈建议您为 PeopleService 等价于 ContactsService 提出功能请求。您可以在 Google 的问题跟踪器上的 Apps 脚本功能请求组件下为此 here 提交功能请求。

希望对你有帮助!

,

要回答这个问题,不。它仍然不起作用。我正在重构我的代码,因为它不再起作用了。我正在尝试从具有特定标签的 Google 通讯录中获取联系人列表,现在随着迁移,我不知道如何执行此操作。