鉴于用户(Google Play的帐户所有者)已使用正确的范围对我的应用程序(Google App Engine的服务帐户)进行了身份验证...
Google API中是否有返回dev_acc用于访问其Play商店开发者帐户的参数的端点?
具体我想检索它以访问https://play.google.com/apps/publish/?dev_acc=DEV_ACC_ID以gs://pubsite_prod_rev_DEV_ACC_ID/
编程方式找到的以下URI
或云存储桶?
或者,列出他/她拥有的所有云存储桶?(包括gs://pubsite_prod_rev_DEV_ACC_ID/水桶)
google-api-client google-cloud-storage google-play google-api-ruby-client google-play-developer-api
我有 python webapp2 应用程序,但是当我运行它时出现此错误
导入错误:没有名为 googleapiclient.discovery 的模块
我在 stackoverflow 中发现的是 ImportError: No module named apiclient.discovery
我试图按照人们所说的去做,但没有奏效
编辑:
点冻结
python google-app-engine google-api-client google-api-python-client
我想使用 python google client api 获取项目中所有实例的列表google-api-python-client==1.7.11
我正在尝试使用googleapiclient.discovery.build此方法需要凭据作为参数的方法进行连接
我阅读了文档,但没有获得凭证格式以及它需要的凭证
任何人都可以解释什么凭据以及如何传递以建立 gcp 连接
我管理的Google域中的文件已陷入糟糕状态; 根目录中有数千个文件.我想识别这些文件并将它们移动到"我的驱动器"下面的文件夹中.
当我使用API列出其中一个孤立文件的父项时,结果是一个空数组.要确定文件是否是孤立的,我可以迭代我域中的所有文件,并请求每个文件的父项列表.如果列表为空,我知道该文件是孤立的.
但这非常缓慢.
无论如何使用Drive API来搜索没有父项的文件?
q参数的"parents"字段似乎对此没有用,因为它只能指定父列表包含一些ID.
更新:
我正在尝试找到一种快速方法来查找真正位于文档层次结构根目录的项目.也就是说,他们是"我的驱动器"的兄弟姐妹,而不是"我的驱动器"的孩子.
我想用来data.photos.service.PhotosService从Picasa推送和拉取照片.我从Google控制台获得了一个服务密钥文件XXXXXXXX-privatekey.p12,现在我正在尝试使用谷歌的密钥进行身份验证.
使用appengine的OAUTH2文档让我相信使用以下内容是有用的:
f = file(settings.SITE_ROOT + '/aurora/' + settings.PRIVATE_KEY, 'rb')
key = f.read()
f.close()
credentials = SignedJwtAssertionCredentials(settings.SERVICE_ACCOUNT_NAME, key, scope = 'http://picasaweb.google.com/data https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/userinfo.profile')
http = httplib2.Http()
http = credentials.authorize(http)
service = build("oauth2", "v2", http=http)
user_info = None
try:
user_info = service.userinfo().get().execute()
# neither of these two methods work
#gd_client.SetOAuthInputParameters(signature_method = gdata.auth.OAuthSignatureMethod.RSA_SHA1, consumer_key = "asdfasdfasdf.apps.googleusercontent.com", rsa_key = key, two_legged_oauth = True, requestor_id = user_info.get('email'))
#gd_client.auth_token = gdata.gauth.TwoLeggedOAuthRsaToken(consumer_key = user_info.get('email'), rsa_private_key = key, requestor_id = user_info.get('email'))
except errors.HttpError, e:
logging.error('An …Run Code Online (Sandbox Code Playgroud) 您好,Google Tasks API团队,
从几天前开始,我们已经开始"403 Forbidden"为很多用户提供服务.
你能检查一下发生了什么吗?我们的API控制台很干净,#calls方式如下.
Caused by: com.google.api.client.googleapis.json.GoogleJsonResponseException: 403 Forbidden
{
"code" : 403,
"errors" : [ {
"domain" : "global",
"message" : "Serving Limit Exceeded",
"reason" : "serviceLimit"
} ],
"message" : "Serving Limit Exceeded"
}
at com.google.api.client.googleapis.json.GoogleJsonResponseException.from(GoogleJsonResponseException.java:145) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:111) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:38) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:312) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1042) ~[google-http-client-1.15.0-rc.jar:na]
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:410) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:343) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:460) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
Run Code Online (Sandbox Code Playgroud) 我正在开发一个使用GoogleAPIClient的应用程序(显然)在后台获取用户当前位置.
对于此任务,我将IntentService与WakefulBroadcastReceiver一起使用(每小时获取一次位置).一切都在开发环境中运行良好,但在Play商店中部署时,某些设备会收到此错误:
Fatal Exception: java.lang.NoClassDefFoundError: com/google/android/gms/internal/zzsa
at com.google.android.gms.common.api.GoogleApiClient$Builder.<init>(Unknown Source)
at tellerina.com.br.vivara.services.MyService.onHandleIntent(MyService.java:37)
at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:65)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:157)
at android.os.HandlerThread.run(HandlerThread.java:61)
Run Code Online (Sandbox Code Playgroud)
我在互联网上搜索了答案,但我没有找到任何答案.这是异常出现的点:
mGoogleApiClient = new GoogleApiClient.Builder(MyApplication.getContext())
.addConnectionCallbacks(this)
.addOnConnectionFailedListener(this)
.addApi(LocationServices.API)
.build();
Run Code Online (Sandbox Code Playgroud)
非常感谢!
编辑
app build.gradle
buildscript {
repositories {
maven { url 'https://maven.fabric.io/public' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.21.2'
}
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
defaultConfig {
applicationId "app.package"
minSdkVersion 14
targetSdkVersion 22
versionCode 9
versionName "1.5.2"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled …Run Code Online (Sandbox Code Playgroud) 我在尝试为Android Google登录注销时收到此错误消息:
Caused by: java.lang.IllegalStateException: GoogleApiClient is not connected yet.
Run Code Online (Sandbox Code Playgroud)
崩溃发生在DrawerActivity.java(下面)中,我在其中调用signOut()方法.
我已经查看了其他帖子中的解决方案,并试过它们无济于事:
java.lang.IllegalStateException:GoogleApiClient尚未连接
GoogleApiClient尚未连接异常 致命异常:java.lang.IllegalStateException GoogleApiClient尚未连接
MainActivity.java:
protected void onCreate(Bundle savedInstanceState) {
mGoogleApiClient = new GoogleApiClient.Builder(this)
.enableAutoManage(this, this)
.addApi(Auth.GOOGLE_SIGN_IN_API, gso)
.build();
//... other code for google sign in not shown
}
protected void onStart() {
mGoogleApiClient.connect();
}
private void handleSignInResult(GoogleSignInResult result) {
if (result.isSuccess()) {
App.getInstance().setClient(mGoogleApiClient);
//start DrawerActivity
}
}
Run Code Online (Sandbox Code Playgroud)
在DrawerActivity.java中(我要执行注销)
private void googleSignOut(){
mGoogleApiClient = App.getInstance().getClient();
Auth.GoogleSignInApi.signOut(mGoogleApiClient);
}
Run Code Online (Sandbox Code Playgroud)
在我的App活动中扩展了Application(用于存储GoogleApiClient)
public class App extends Application {
private GoogleApiClient mGoogleApiClient;
private …Run Code Online (Sandbox Code Playgroud) java android google-api-client android-studio android-googleapiclient
为了测试我们的应用程序,我需要插入/更新谷歌日历事件并验证边缘情况,比如会议邀请是否超过 30 天,它不应该显示给最终用户。我正在为单个 gmail id testaccount@.com 进行此设置,并尝试操纵事件以涵盖所有边缘情况。
按照此链接 - https://developers.google.com/calendar/v3/reference/events/insert
1)我创建了一个新项目https://console.cloud.google.com。
2) 启用谷歌日历 API
3)为credentials.json设置OAuth客户端
4) 运行 python 快速启动以获得 10 个日历事件 - 验证步骤 3 是否正确。
5)现在在同意屏幕上插入添加以下范围的事件 https://www.googleapis.com/auth/calendar https://www.googleapis.com/auth/calendar.events
6) 重新生成凭证,使其具有新添加的插入事件的范围。
我收到以下错误消息 - 请求https://www.googleapis.com/calendar/v3/calendars/primary/events?alt=json时出现 HttpError 403返回“权限不足:请求的身份验证范围不足”。
我也尝试过使用电子邮件 ID 代替“primay”,但最终还是出现了同样的错误。
我在调用 Google Play Developer API 时遇到问题。
我已按照https://developers.google.com/android-publisher/authorization 上列出的所有步骤进行操作。这包括
然后,为了调用 purchase.subscriptions.get API,我使用了以下 CURL 命令:
(https://developers.google.com/android-publisher/api-ref/rest/v3/purchases.subscriptions/get)
curl -X GET "https://androidpublisher.googleapis.com/androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}" -H "Authorization: Bearer {access_token}" -H "Accept: application/json" --compressed
Run Code Online (Sandbox Code Playgroud)
但是,我收到以下错误:
"error": {
"code": 401,
"message": "The …Run Code Online (Sandbox Code Playgroud) google-api ×5
android ×3
java ×2
gdata ×1
google-oauth ×1
google-play ×1
google-tasks ×1
oauth-2.0 ×1
picasa ×1
python ×1
python-3.x ×1