Closed Askancy closed 4 years ago
Hello,
Make sure that you added YouTube API Key in your .env
file and also published config file using:
$ php artisan vendor:publish --provider="Alaouy\Youtube\YoutubeServiceProvider"
Additionaly, make sure that you selected correct API key type.
now it's work, the problem was in google console api, the library had not activated... I deleted and recreated and now it's work...
I have tried using this packages on Laravel 5.8 and am having problems: if I use:
$videos = Youtube::parseVidFromURL('https://www.youtube.com/watch?v=moSFlvxnbgk');
it works and prints : moSFlvxnbgk but if i use:$videos = Youtube::getVideoInfo('moSFlvxnbgk');
I get the error:Error 403 Access Not Configured. YouTube Data API has not been used in project 826858712416 before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/youtube.googleapis.com/overview?project=826858712416 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry. : accessNotConfigured {"userId":2,"exception":"[object] (Exception(code: 0): Error 403 Access Not Configured. YouTube Data API has not been used in project 826858712416 before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/youtube.googleapis.com/overview?project=826858712416 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry. : accessNotConfigured at /var/www/vhosts/gameli.net/httpdocs/vendor/alaouy/youtube/src/Youtube.php:597)