获取请求令牌谷歌+ oauth 2.0

时间:2014-11-27 08:20:27

标签: android oauth-2.0 google-plus

我正试图通过谷歌+登录我的Android应用程序。我的代码

OAuthService authService = new ServiceBuilder().provider(GoogleApi.class).apiKey(GOOGLE_API_KEY)
                .apiSecret(GOOGLE_API_KEY_SECRET).scope(GOOGLE_OAUTH_WEB_SCOPE)
                .callback(OAUTH_INTENT_SCHEME + "://" + OAUTH_GOOGLE_INTENT_HOST).build();

authService.getRequestToken();

但是我收到了下一个错误org.scribe.exceptions.OAuthException: Response body is incorrect. Can't extract token and secret from this: 'Consumer is not registered:

我在哪里可以获得正确的api密钥和api密钥?当我点击Create New Client Id -> Installed-> Android开发者控制台时,只给我一个客户端ID。我在哪里可以获得密钥

0 个答案:

没有答案