Can't publish more than 6 videos within one day even through the quota has been changed to 50000 - quota

{
"code" : 403,
"errors" : [ {
"domain" : "youtube.quota",
"message" : "The request cannot be completed because you have exceeded your quota.",
"reason" : "quotaExceeded"
} ],
quota calculator
test quota usage

The queries or requests quota is 50k not video uplaods quota video uploads quota is 25-50 tops you can refer this thread for more information.
Hope this helps

Related

YouTube API 429 error while not using full quota

Still a couple of weeks; we are getting more and more 429 HTTP Errors while making API requests to the YouTube API (mainly when trying to add or delete videos in a playlist). The error seems related to "quotas" indicated in the Google API console, but we checked this and are way below the limit according to the Google console report (we already have increased our quota value in the past, so this one should be more than enough).
Any idea why we are getting this error?
Error message:
{
"error": {
"code": 429,
"message": "Resource has been exhausted (e.g. check quota).",
"errors": [
{
"message": "Resource has been exhausted (e.g. check quota).",
"domain": "global",
"reason": "rateLimitExceeded"
}
],
"status": "RESOURCE_EXHAUSTED"
}
}
And our quota for the YouTube API:

YouTube Data API v3 queries per day quota went to 0

Today our YouTube Data API v3 daily quota went from 37 millions to 0 for no apparent reason. So now we get 403 error when trying to access YouTube API:
{
"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.",
"errors": [
{
"message": "The request cannot be completed because you have exceeded your \u003ca href=\"/youtube/v3/getting-started#quota\"\u003equota\u003c/a\u003e.",
"domain": "youtube.quota",
"reason": "quotaExceeded"
}
]
}
}
In the GCP Queries per day limit appears no be non-editable.
We have checked emails related to the API client but there seems to be no warnings or notifications about anything related to the issue.
Any idea on why this could happen?

Youtube API quota exceeded with 1 video

I try to insert a video in nodeJS to Youtube, and I got this error :
{ errors: [ { domain: 'youtube.quota',
reason: 'quotaExceeded',
message: 'The request cannot be completed because you have exceeded your quota.'
} ], code: 403, message: 'The request cannot be completed because
you have exceeded your quota.' }
EDIT : this is when I use Auth with an existing Token, I get token from https://developers.google.com/oauthplayground/ and use it in my code. I tried with different accounts, can't upload video but I can insert item in playlist for example.
Here is my code (nodeJS) :
var req = Youtube.videos.insert({
"resource": {
// Video title and description
"snippet": {
"title": "Test",
"description": "Test video upload via YouTube API"
},
"status": {
"privacyStatus": "private"
}
},
"part": "snippet,status,id",
"media": {
"body": fs.createReadStream('./test.mp4')
}
}, function (err, data) {
....
The video is 600 Ko... How can I see or update quotas ? I use OAuth auth, for example I can insert elements in my playlist with no problems, but I can't upload videos. Do I need something ?
Thanks.
Here is a reference of your error from the documentation.
About the quota:
The YouTube Data API uses a quota to ensure that developers use the
service as intended and do not create applications that unfairly
reduce service quality or limit access for others. All API requests,
including invalid requests, incur at least a one-point quota cost. You
can find the quota available to your application in the Developers
Console.
Projects that enable the YouTube Data API have a default quota
allocation of 1 million units per day, an amount sufficient for the
overwhelming majority of our API users. Default quota, which is
subject to change, helps us optimize quota allocations and scale our
infrastructure in a way that is more meaningful to our API users. You
can see your quota usage on the Usage tab for the API in the
Google Developer's Console.
Note: If you reach the quota limit, you can request additional quota on the Quotas tab in the Developer's Console.

google safebrowsing api response : Deadline expired before operation could complete

I'm using the google safebrowsing api for getting fullhashes for the prefixes of hashes of url present in threat lists. When i'm using 5 threads to do the job, the job completes but the latency is high, so i tried increasing the threads to 7 and more but i'm getting the following error on doing that:
com.google.api.client.googleapis.json.GoogleJsonResponseException: 504 Gateway Time-out
{
"code" : 504,
"errors" : [ {
"domain" : "global",
"message" : "Deadline expired before operation could complete.",
"reason" : "backendError"
} ],
"message" : "Deadline expired before operation could complete.",
"status" : "DEADLINE_EXCEEDED"
}
But, I'm sure that my daily quota has not exceeded.
By looking at the console, i can see that the number of requests per second is not more than the default quota (3000 req/100sec).
What other reason can be there for the above error ?

Quota Limits For You-Tube Data API V3?

The new Google Developers console shows the following limit for YouTube Data API v3:
PER USER LIMIT 2 requests/second/user
Whereas the old Google Developers console shows:
2.0 units/second/user
(i.e. one is requests per second, the other is units per second which are quite different).
From - https://developers.google.com/youtube/v3/determine_quota_cost - the Search request appears to have a cost of 200 units, if the latter case above is correct would this mean we can only make one of these requests every 100 seconds?
This does seem to tie in more closely with what we are experiencing which is regular occurrences of the following 403 forbidden error after paging through only a few results from a YouTube search:
"error": {
"errors": [
{
"domain": "youtube.quota",
"reason": "quotaExceeded",
"message": "Quota Exceeded"
}
],
"code": 403,
"message": "Quota Exceeded"
}
}
The new console is right on this point. It's request/sec.
But you may have been hitting daily quota limits.
Remember that in many cases, you can substitute a less costly call, such as youtube.videos.list, in place of the youtube.search.list method. For example, to search most popular videos instead of the search.list call, you can use the videos.list call using the most popular chart.
you can contact youtube and apply for higher quota or pay for higher quota

Resources