So I am building a website in Javascript/html and have user specific data stored in google drive. Now, I am under certain stipulations which I need to work around.
Firstly, the files on google drive must be kept on 'shared within my organisation'. They contain private data and so I can't share them with anyone with the link.
Secondly, we have created our own user/login system and separate from Google's and we don't want our users to have to make google accounts in order to access their data.
I've read about service accounts, and am wondering if it's possible to share the files with a service account, then have users authenticate as that service account (behind the scenes) once they login successfully. I'm still reading trying to figure out whether this is possible, but hoping someone could save me some time and let me know if it is.
So far, I have set up the service account and have the client ID as well as an API key for Google Drive API. I have enabled 'Domain-Wide Delegation' for the service account and done the same on the admin console of my google drive and shared a test folder with the service account email. I'm currently looking at the OAuth sign-in and reading through it carefully (https://developers.google.com/identity/protocols/oauth2/service-account). I will post updates if I make any progress. Thanks in advance!