简体   繁体   中英

Can I create a Google Drive folder using service account with Python?

I can create a folder using account Owner but cannot share it with service account.

Is there a way for My Python script to create a folder using service account and then upload a file?

You can create a folder and upload file, same process flow as a real user when you using a service account.

BUT

As stated in this blog , you have to remember that:

A service account is a sort of virtual user or robot account associated with a given project. It has an email address, and a cryptographic key pair.

Also, there is a statement from a related SO question that:

There is no UI for Service Accounts. The files are only accessible to your app.

I suggest that you share a folder from a real account to your service account so that accessing the files would be easier.

Hope this help!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM