我正在尝试使用服务帐户调用 Google Reports API。
我遵循这个代码示例:https : //godoc.org/golang.org/x/oauth2/google#JWTConfigFromJSON
{
"error": {
"errors": [
{
"domain": "global",
"reason": "authError",
"message": "Access denied. You are not authorized to read activity records."
,
"locationType": "header",
"location": "Authorization"
}
],
"code": 401,
"message": "Access denied. You are not authorized to read activity records."
}
}
我很确定它在 Google 配置方面,但是:
我创建了服务帐户
我下载了 JWT
我授权了所需的范围
然后我尝试调用这个 URL:https : //www.googleapis.com/admin/reports/v1/activity/users/all/applications/login
我能忘记什么?
谢谢你帮助我。
慕斯709654
相关分类