【问题标题】:Android Google Drive API Exception: 403 ForbiddenAndroid Google Drive API 异常:403 Forbidden
【发布时间】:2016-06-15 17:55:27
【问题描述】:

我正在开发一个可以访问 Google Drive 上用户的 appdata 文件夹的应用。当我处于调试模式时,该应用程序运行良好。当我发布应用程序并尝试连接到 Google 云端硬盘时,在我选择要连接的帐户后出现此错误:

com.google.api.client.googleapis.json.GoogleJsonResponseException: 
403 Forbidden 
{
   "errors" : [ {
      "domain" : "global",
      "reason" : "insufficientScopes",
      "message" : "The granted scopes do not give access to all of the requested spaces.",
      "locationType" : "parameter",
      "location" : "spaces"
   } ],
      "code" : 403,
      "message" : "The granted scopes do not give access to all of the requested spaces."
}

我用这种方式连接到Google Drive:https://developers.google.com/drive/v3/web/quickstart/android

我还在 Google Dev Console 中制作了一份用于调试的凭据和一份用于发布模式的凭据。

我该如何解决这个问题? 任何帮助都是不胜感激的。谢谢朋友!

【问题讨论】:

标签: android api credentials drive


【解决方案1】:

【讨论】:

  • 您好,我也遇到了同样的问题,我将相同的代码放在我的 proguard 文件中,但没有成功。我仍然有 403
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2023-01-26
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多