我正在嘗試使用服務(wù)帳戶調(diào)用 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 配置方面,但是:我創(chuàng)建了服務(wù)帳戶我下載了 JWT我授權(quán)了所需的范圍然后我嘗試調(diào)用這個 URL:https : //www.googleapis.com/admin/reports/v1/activity/users/all/applications/login我能忘記什么?謝謝你幫助我。
1 回答

慕斯709654
TA貢獻1840條經(jīng)驗 獲得超5個贊
修復(fù)。需要明確指定主題值。我現(xiàn)在按照服務(wù)帳戶示例:https : //godoc.org/golang.org/x/oauth2/google
- 1 回答
- 0 關(guān)注
- 218 瀏覽
添加回答
舉報
0/150
提交
取消