[英]Google Calendar OAuth 2.0 Error 403: access_denied
I have been trying to gain authorization from the Google Calendar API on my site so that I can access user calendar data.我一直在尝试从我网站上的 Google 日历 API 获得授权,以便我可以访问用户日历数据。 When I issue an HttpResponseRedirect from the desired view on my site via Django (to send the user to Google so they can provide the necessary permissions), the redirect works as expected.
当我通过 Django 从我的网站上的所需视图发出 HttpResponseRedirect (将用户发送到 Google 以便他们可以提供必要的权限)时,重定向按预期工作。 The issue is that on Google it's returning "error 403: access denied", along with a message stating that the developer must authorize my account before I can use the API (I'm trying to use a different Google account to log in for the purpose of testing).
问题是在 Google 上它返回“错误 403:访问被拒绝”,以及一条消息指出开发人员必须授权我的帐户才能使用 API(我正在尝试使用不同的 Google 帐户登录测试目的)。 I've poked around the Google API site, but can't find where this authorization occurs.
我浏览了 Google API 站点,但找不到此授权发生的位置。 Any idea of where I might find this?
知道我在哪里可以找到这个吗? Full Specific Error Message.
完整的特定错误消息。
Was able to fix it by adding additional test users on the Google Cloud Platform (console.cloud.google.com).能够通过在 Google Cloud Platform (console.cloud.google.com) 上添加额外的测试用户来修复它。 Navigated to the relevant project under the dropdown in the top left corner, then from there clicked the "OAuth consent screen" tab on the left hand side.
导航到左上角下拉菜单下的相关项目,然后从那里单击左侧的“OAuth 同意屏幕”选项卡。 You should see the option there to add users under the "Test users" header
您应该在“测试用户”header 下看到添加用户的选项
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.