Shorten long urls by using Bitly Api
Install the package through Composer.
composer require darshphpdev/bitly-shortner
to make your own token to can use bitly api
php artisan vendor:publish --tag="bitlyconfig"
// In your controller
// Use The Helper class Bitly to shorten urls
use Bitly;
return Bitly::shorten('https://www.youtube.com');
The Http Client Package is open-sourced software licensed under the MIT license