Jake
Jake

Reputation: 1390

I am getting "dailyLimitExceeded" errors with barely 300 total requests

I am getting "dailyLimitExceeded" errors with barely 300 total requests... I created this api project a few hours ago and everything was working fine at the beginning until I hit about 200 requests and from there every request failed

this is the type of request I am currently trying

https://www.googleapis.com/youtube/v3/search?order=date&part=snippet&channelId={{channel_id}}&maxResults=25&key={{api_key}}

What am I missing? Why was my API key locked so quickly?

Thank you!

Upvotes: 0

Views: 247

Answers (1)

stvar
stvar

Reputation: 6975

The Search endpoint is kind of expensive: according to the docs, each one of your search query costs 100 units of quota. Multiply that with 200 and you're quite likely to exceed the daily quota allocated.

If you're only interested to find the new video entries of a given channel, then you better use the PlaylistItems endpoint queried appropriately (see my answer to a related question) that have a quota cost of only 3 units.

Also you should be aware about one of the issues of the API w.r.t. published vs. upload date time of any given video.

Upvotes: 1

Related Questions