Google Plus Domains API AccessTokenRefreshError -
i'm attempting use google+ domains api provision circles google apps domain. i'm using domain-wide delegation per https://developers.google.com/+/domains/authentication/delegation have used group, user , calendar provisioning. in api console, i've added google+ api , google+ domains api api project. i've tried using both pre-existing key, , generating new one. when attempt run following code:
service_account_email='somelongstring@developer.gserviceaccount.com' key=file("path/to/keyfile","rb").read() user_email='someroleaccount@mydomain.com' scopes_plus = [ 'https://www.googleapis.com/auth/plus.me', 'https://www.googleapis.com/auth/plus.stream.write', ] credentials = signedjwtassertioncredentials(service_account_email, key, scope=scopes_plus, sub=user_email) http = httplib2.http() http = credentials.authorize(http) plus = build(servicename='plus', version='v1domains', http=http)
i get
accesstokenrefresherror: access_denied
when hits build() call.
however, exact same code (with different scopes , services) works directory service, groupssettings service , calendar service.
i have tried both role account sub email address, , own (super-admin) account.
any ideas?
did remember give service account authorization new scopes in control panel domain? process is described in drive documentation. sure enter google plus domains scopes directory , group settings scopes changes overwrite existing authorizations.
Comments
Post a Comment