Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/219.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何撤销/取消Android设备上应用程序的帐户授权_Android_Google Api_Google Calendar Api_Google Api Client_Android Account - Fatal编程技术网

如何撤销/取消Android设备上应用程序的帐户授权

如何撤销/取消Android设备上应用程序的帐户授权,android,google-api,google-calendar-api,google-api-client,android-account,Android,Google Api,Google Calendar Api,Google Api Client,Android Account,我正在与谷歌日历API进行集成。为了获得访问特定帐户日历的授权,我使用了calendar Android示例项目中的以下代码片段: if (e instanceof UserRecoverableAuthIOException) { Intent intent=((UserRecoverableAuthIOException) e).getIntent(); activity.startActivityForResult(intent, REQUEST_AUTHORIZATION);

我正在与谷歌日历API进行集成。为了获得访问特定帐户日历的授权,我使用了calendar Android示例项目中的以下代码片段:

if (e instanceof UserRecoverableAuthIOException) {
    Intent intent=((UserRecoverableAuthIOException) e).getIntent();
activity.startActivityForResult(intent, REQUEST_AUTHORIZATION);
    return;
}
出于某种原因,示例项目返回一条“access not configured”(访问未配置)错误消息,而我的工作正常,我遵循了示例项目中采取的相同步骤,可能是因为我的是另一个项目

我面临的问题是重复API的授权步骤,因为如果我已经授权了对设备的访问,那么即使我从该设备卸载了应用程序,下次安装它时,它也被授权了,我不需要再次执行授权步骤

为了一致性,我希望能够撤销授予应用程序的授权,以便下次运行任何API调用时,我必须对应用程序进行授权

如何做到这一点

谢谢,
亚当。

这里回答了重复的问题:

这似乎不是一种程序化的方式。但发现你似乎需要撤销谷歌的第三方访问权(即你的程序)

后藤


现在,您应该看到一个使用日历API的应用程序(希望命名为您设置的应用程序名)撤销了此访问权限并恢复了您的商品。

重复问题回答如下:

这似乎不是一种程序化的方式。但发现你似乎需要撤销谷歌的第三方访问权(即你的程序)

后藤

现在,您应该看到一个使用日历API的应用程序(希望将您设置为应用程序名的名称命名为某物)撤销了此访问权限,并恢复了您的良好状态

    1.) Sign in on the Google Accounts homepage.
    2.) Click Security on the left-hand side of the page.
    3.) Scroll down to the Connected applications and sites section and click the Manage access button.
    4.) Click Revoke Access next to the service you want to disconnect from your account.