How to make google drive as your automated backup location using python

Before you going to coming paragraphs of this article, I recommend you to watch following youtube video so you will get what is going to describe here:

Read following links to learn more about the authentication mechanism google API is using :

As Claudio (GOOGLE) mentioned in the above video, (, we need to use some logic (client library) to sort your crendentials for reusing. Other wise on every execution of ‘’ script, you need human interaction for getting tokens. I added 6 lines to google’s ‘’ to keep authorization code for reusing. So as long as the user has not revoked the access granted initially to the application, you don’t need a human interaction.

For more details :

You can get modified google’s using following


Goto :

So, you got the idea how to deal with Google API and authentication to Google drive without human interaction. Now, you just need to apply your modifications to the script, suitable to your environment and then just put a cron job.