Listing all folders which user has write access to in Google Drive V3 API

Viewed 33

I am currently trying to list out all the folders that a given user has write access with the Google Drive API. I am able to list out all the folders but have not found a way to only list folders that the user has write access to.

For example, the user has 3 folders in their Google Drive:

["Id1","Id2","Id3]

The user has write access to folders Id1 and Id3.

I am able to use the URL q=mimeType%20%3D%20%27application%2Fvnd.google-apps.folder%27&key=[MY_API_KEY] to list out all the folders the user currently has in their Drive, which would be Id1,2, and 3. However, if I only want to list out Id1 and 3, how would I accomplish that?

Thanks in advance!

1 Answers

In that case, how about using writers for the search query as follows?

Sample search query:

mimeType='application/vnd.google-apps.folder' and '###' in writers
  • In your situation, ### might be the email address of the user.
  • If it is required to do URL encode, please encode it.

Reference:

Related