Domanda

We are using the Google drive API to allow our users to browse and select a file to use in a report. One of our users (the issue is not widespread) is getting an error(below) when attempting to get a list of files.

JSON body returned from Google:

{
 "error": {
  "errors": [
   {
    "domain": "global",
    "reason": "forbidden",
    "message": "Forbidden"
   }
  ],
  "code": 403,
  "message": "Forbidden"
 }
}

Which is a bit confusing as it is not one of the listed errors here: https://developers.google.com/drive/web/handle-errors

Does anyone have any ideas on what might be causing this? Thanks for any insight!

È stato utile?

Soluzione

It turned out to be related to this question: Getting a 403 - Forbidden for Google Service Account

This user's company did not have Google Drive as one of their activated apps.

Altri suggerimenti

This error also occurs if you disable the Google Drive setting called "Allow users to install Google Drive apps". This might be a good thing to check if you are certain that Google Drive is already enabled.

enter image description here

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top