Google oauth2中的invalid_client [英] invalid_client in google oauth2

查看:213
本文介绍了Google oauth2中的invalid_client的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试制作一个用于上传youtube视频的网页,因此我尝试从google api控制台获取客户端ID,并且在api控制台中显示如下内容:

I try to make a web page for youtube video upload, therefore I try to get the client id from google api console, and in the api console it shows something like this:

Client ID: 533832195920.apps.googleusercontent.com
Redirect URIs: http://bobyouku.ap01.aws.af.cm/testyoutube.php
https://developers.google.com/oauthplayground

但是,当我尝试使用以下URL测试我的帐户时:

However when I try to test my account using the following URL:

它给出了invalid_client的结果.即使我在oauth2操场上尝试,也会发生同样的失败

It gives out the result of invalid_client. Even when I try it on oauth2 playground, same fail occurs

所以有人知道会发生什么事吗?

So anyone knows what's happen?

推荐答案

设置/更改您的产品名称,在创建与项目名称相同的产品名称之前,我一直遇到这个问题.

Set/change your product name, I had this issue until I created a product name as same as project name.

可以在您的项目的Google Developers Console的同意"屏幕部分中设置产品名称.看一下API&在左侧导航栏中进行身份验证,然后选择同意"屏幕. 您还需要在产品名称上方的框中设置您的电子邮件地址.

The product name can be set in the Consent screen section of the Google Developers Console for your project. Look under APIs & auth in the left navigation and select Consent screen. You need also to set your email address in the box above the product name.

这篇关于Google oauth2中的invalid_client的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆