Skip to content
This repository has been archived by the owner on Jun 17, 2024. It is now read-only.

SignedJwtAssertionCredentials Method is not there in client class of oauth2client python module #72

Open
siddharthhudda opened this issue Feb 25, 2021 · 1 comment

Comments

@siddharthhudda
Copy link

Hi,

`from oauth2client import client
credentials = client.SignedJwtAssertionCredentials(
SERVICE_ACCOUNT_EMAIL,
key,
scope='https://www.googleapis.com/auth/androidpublisher')

http = httplib2.Http()
http = credentials.authorize(http)

service = build('androidpublisher', 'v3', http=http)`

SignedJwtAssertionCredentials Method is not there in client class of oauth2client python module

basic_list_apks_service_account.py script fails becuase method/function not defined in client class.

Can you please update it with the fix?

Note: Alternative solution to this

SCOPES = ['https://www.googleapis.com/auth/androidpublisher']
SERVICE_ACCOUNT_FILE = '<service_account_file>.json'

credentials = service_account.Credentials.from_service_account_file(
SERVICE_ACCOUNT_FILE, scopes=SCOPES)
service = googleapiclient.discovery.build('androidpublisher', 'v3', credentials=credentials)

@longma-tech
Copy link

Good

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants