I am thinking of developing an application like this:
- My application has a google-service-account
- I let my users share their documents with my service account
- While an user visits my application, he gets some reports based on the files he has shared.
For this, my application needs to uniquely identify the owner of the documents shared with it. I looked at the API but could not find how to do so. I found methods like File.getOwnerNames(), but they are plain strings containing the names, but not any unique key to identify the user.
Need help on how to achieve this. Thanks.
Sanjay
Use the permissions.list method and find the permission corresponding to the owner.