get authetication in google api browser but gargle permission fails

Viewed 61

I am using googledrive to download directly from my drive folders, I am getting now this error

since i was getting this error Show in New Window

Error in gargle_abort_request_failed(): ! Client error: (403) Forbidden Insufficient Permission: Request had insufficient authentication scopes. • domain: global • reason: insufficientPermissions • message: Insufficient Permission: Request had insufficient authentication scopes.

Backtrace:

  1. googledrive::drive_ls(...)
  2. googledrive:::as_parent(path)
  3. googledrive:::as_dribble.drive_id(d)
  4. googledrive::drive_get(id = x)
  5. purrr::map(as_id(id), get_one_file_id)
  6. googledrive (local) .f(.x[[i]], ...)
  7. gargle::response_process(response)
  8. gargle:::gargle_abort_request_failed(error_message(resp), resp) Error in gargle_abort_request_failed(error_message(resp), resp) :

I used gs4_deauth() and then gs4_auth() to open the google api and get authentified again... I am still getting the same error, what should I do? Thanks

1 Answers

Permission: Request had insufficient authentication scopes.

Means that the access token that was used to make this request was not created with the proper scopes. Im not sure which method you are using exactly but

The file.export method requires one of the following scopes

enter image description here

The file.get method requires one of the following scopes

enter image description here

You need to request authorization of the user with the proper consent scope

Related