Skip to content

google cloud utility for turning account services json into tokens for use in headers

License

Notifications You must be signed in to change notification settings

elbow-jason/cirrus_py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cirrus_py

Usage

>>> from cirrus_py.credentials import ServiceAccountCredentials
>>> from cirrus_py.google_jwt import GoogleJwt
>>> creds = ServiceAccountCredentials("./my_secret_service_account_credentials.json")
>>> STORAGE_FULL_CONTROL_SCOPE = "https://www.googleapis.com/auth/devstorage.full_control"
>>> my_jwt = GoogleJwt(scope=STORAGE_FULL_CONTROL_SCOPE, credentials=creds)
>>> my_jwt.get_token()
{
  'access_token': "<access_token_here>",
  'expires_in':   3600,
  'token_type':   'Bearer'
}

Links

About

google cloud utility for turning account services json into tokens for use in headers

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages