我正在访问 Google Calendar API 并使用服务令牌对应用程序域帐户拥有的日历进行身份验证。当我调用 calendar.events.list 时,我得到了响应:
{ kind: 'calendar#events',
etag: [snip],
summary: [snip],
description: [snip],
updated: '2014-11-16T12:33:06.434Z',
timeZone: 'Europe/London',
accessRole: 'reader', <------ this is the problem
defaultReminders: [],
nextSyncToken: [snip],
items: [] }
我希望能够写入日历。令牌accessRole
是reader
. 如何授予服务令牌writer
访问日历的权限?我曾尝试使用 Google 日历网络用户界面授予对服务令牌电子邮件地址的“进行更改和管理共享”访问权限,但在我保存时它会自动更改为“查看所有事件详细信息”。