I recently created a new app on Google Cloud Console and obtained a YouTube Data API v3 key. However, when I make a request like the one below, I receive a 403 error.
https://www.googleapis.com/youtube/v3/videos?part=snippet&q=workout&maxResults=5&key={MyKey}
The response I get is:
{
"error": {
"code": 403,
"message": "The request cannot be completed because you have exceeded your <a href="/youtube/v3/getting-started#quota">quota</a>.",
"errors": [
{
"message": "The request cannot be completed because you have exceeded your <a href="/youtube/v3/getting-started#quota">quota</a>.",
"domain": "youtube.quota",
"reason": "quotaExceeded"
}
]
}
}
Strangely, if I try the same query from YouTube Data API v3 Explorer, I get a successful response with a 200 status code.
https://developers.google.com/youtube/v3/docs/search/list
Additionally, when I check the quotas section in the Google Cloud Console, it shows that none of my quotas are used.
What could I be missing here? How can I resolve this issue and successfully make requests using my API key?