新的 Google 控制台项目超出了 YouTube 配额限制 [英] Youtube quota limit exceeded on a new Google Console Project

查看:27
本文介绍了新的 Google 控制台项目超出了 YouTube 配额限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在编写一个 PHP CLI 脚本,用于将视频上传到我的 Youtube 频道.我在 Google Console 中创建了一个项目,启用了 Youtube API,启用了 OAuth 并收到了我的客户端 ID 和密码.然后我使用 https://developers.google.com/oauthplayground 生成了一个刷新令牌.

I am writing a PHP CLI script that will upload videos to my Youtube channel. I created a project in Google Console, enabled Youtube API, enabled OAuth and received my client ID and secret. Then I generated a refresh token using https://developers.google.com/oauthplayground .

身份验证似乎有效,因为我没有收到任何关于此的错误,但我收到以下错误:

The authentication seems to work as I don't get any errors regarding that, but I get the following error:

"code": 403,
"message": "The request cannot be completed because you have exceeded your \u003ca href=\"/youtube/v3/getting-started#quota\"\u003equota\u003c/a\u003e."

凭据适用于我没有使用配额中的任何内容的新项目.

为什么会出现此错误,我该如何解决?

Why do I get this error and how could I fix it?

推荐答案

我认为你是对的 @GeorgeOlah.我不想浪费时间设置 OAuth2 的东西,所以我在操场上生成了一个密钥,然后尝试将它与 https://github.com/h2non/youtube-video-api.

I think you're right @GeorgeOlah. I didn't want to waste time setting up OAuth2 stuff, so I generated a key with the playground and then tried to use it with https://github.com/h2non/youtube-video-api.

我使用 Playground 中的访问令牌立即收到配额错误.

I immediately got quota errors using the access token from the playground.

所以我使用 https 设置了一个令牌://github.com/google/google-api-nodejs-client/blob/1bcb74430143e498b9fd58cf2ca2b97da2ed3b07/samples/oauth2.js.

到目前为止,我没有使用该令牌出现配额错误.

So far, I've had no quota errors with that token.

这篇关于新的 Google 控制台项目超出了 YouTube 配额限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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