|
|
|
@ -21,6 +21,7 @@ import argparse
@@ -21,6 +21,7 @@ import argparse
|
|
|
|
|
from apiclient.discovery import build |
|
|
|
|
import httplib2 |
|
|
|
|
from oauth2client import client |
|
|
|
|
from oauth2client.service_account import ServiceAccountCredentials |
|
|
|
|
|
|
|
|
|
TRACK = 'beta' # Can be 'alpha', beta', 'production' or 'rollout' |
|
|
|
|
SERVICE_ACCOUNT_EMAIL = ( |
|
|
|
@ -47,10 +48,7 @@ def main():
@@ -47,10 +48,7 @@ def main():
|
|
|
|
|
# with the Credentials. Note that the first parameter, service_account_name, |
|
|
|
|
# is the Email address created for the Service account. It must be the email |
|
|
|
|
# address associated with the key that was created. |
|
|
|
|
credentials = client.SignedJwtAssertionCredentials( |
|
|
|
|
SERVICE_ACCOUNT_EMAIL, |
|
|
|
|
key, |
|
|
|
|
scope='https://www.googleapis.com/auth/androidpublisher') |
|
|
|
|
credentials = ServiceAccountCredentials.from_p12_keyfile(SERVICE_ACCOUNT_EMAIL, key, scopes=['https://www.googleapis.com/auth/androidpublisher']) |
|
|
|
|
http = httplib2.Http() |
|
|
|
|
http = credentials.authorize(http) |
|
|
|
|
|
|
|
|
|