I use java google drive api v2(1.22.0), and when I try to get list files from "Shared With Me" folder using drive.files.list and query "sharedWithMe and trashed = false" it returns files from "My Drive". I was try same code on several accounts, all works fine except one user with empty "Shared With Me"(it does't meter other account also has empty this folder but works fine). I got same affect by using example on https://developers.google.com/drive/v2/reference/files/list
2
votes
After more testing I found case that reproduce this problem. So if I have two accounts "A" and "B" and do steps: 'A'->create file; 'A'->share file with 'B'; A->change owner for this file to 'B'. Then my problem is reproduce. So can anyone help me to filter sharedWithMe files according google drive view
– Volodymyr
1 Answers
3
votes
For my case help query "sharedWithMe and trashed = false and not 'me' in owners". So Google remember that file was shared ant this option is independent. And also looks like this query is a same like in google view for "Shared With Me" folder. P.S. If any found some other case for my question, please attach a link))