- Get a OAuth2 Client here: https://code.google.com/apis/console/
- Follow instructions here: https://developers.google.com/accounts/docs/OAuth2WebServer#offline
- Once you have an auth code, you must exchange it for a refresh token
- The refresh token is another curl away, using the same URL, but setting the code (newly acquired), client_id, client_secret, redirect_uri and grant_type=authorization_code, using the url https://oauth2.googleapis.com/token
- Once you have the refresh token, setup a crontab at every 15 or 30 minutes to keep a fresh token for use on server at all times
- Follow instructions here: https://developers.google.com/accounts/docs/OAuth2WebServer#refresh
- It's another curl, but with client_id, client_secret, refresh_token (the one you just got) and grant_type=refresh_token
- Output to home directory or some local repository for future use
-
Notifications
You must be signed in to change notification settings - Fork 1
cedricsam/Utilities
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
My Utilities
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published