调用报表API时出错:
<HttpError 403 when requesting https://www.googleapis.com/admin/reports/v1/usage/users/all/dates/2013-08-01?alt=json&maxResults=1 returned "Caller does not have access to the customers reporting data.">
以前有人见过这个错误吗?我错过了什么? 我就是不明白这是为什么,或者我应该检查什么。在
敬上。在
编辑:
授权:
^{pr2}$实际通话:
result = service.userUsageReport().get(
userKey='all',
date='2013-08-01',
maxResults=1).execute()
其他api可以很好地使用该服务帐户。 “https://www.googleapis.com/auth/admin.reports.usage.readonly”已正确添加到OAuth2域配置页。在
尝试:
在使用adminisdk的服务帐户时,您仍然需要代表googleapps实例中的管理员。在
另外,请确保服务帐户客户机ID已被授予使用Google Apps控制面板中Reports API作用域的权限。googledrive文档describe this process well,只是在Reports范围内进行sub。在
相关问题 更多 >
编程相关推荐