我正在使用 Python 2.6 和 Google API 的客户端库,我试图用它来获得对电子邮件设置的身份验证访问:
f = file(SERVICE_ACCOUNT_PKCS12_FILE_PATH, 'rb')
key = f.read()
f.close()
credentials = client.SignedJwtAssertionCredentials(SERVICE_ACCOUNT_EMAIL, key, scope='https://apps-apis.google.com/a/feeds/emailsettings/2.0/', sub=user_email)
http = httplib2.Http()
http = credentials.authorize(http)
return discovery.build('email-settings', 'v2', http=http)
当我执行此代码时,出现以下错误:UnknownApiNameOrVersion: name: email-settings version: v2
email settingsV2 的 api 名称和版本是什么?是否可以将其与服务帐户一起使用?问候