Download the PHP package marcusyan/youtube-laravel-api without Composer
On this page you can find all versions of the php package marcusyan/youtube-laravel-api. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download marcusyan/youtube-laravel-api
More information about marcusyan/youtube-laravel-api
Files in marcusyan/youtube-laravel-api
Package youtube-laravel-api
Short Description It is a wrapper over Youtube Api v3 which simplifies functionalities the laravel way.
License MIT
Homepage https://github.com/alchemyguy/YoutubeLaravelApi
Informations about the package youtube-laravel-api
Youtube Laravel Api
PHP (Laravel) Package for Google / YouTube API V3 with Google Auth
Features
- [x] Google Auth
- [x] Full Live Streaming API for Youtube
- [x] Full Youtube Channel API
- [x] Full Youtube Video API
Installation
Add Service provider to config/app.php provider's array:
Execute the following command to get the configurations:
Steps to create your google oauth credentials:
- Goto
https://console.developers.google.com
- Login with your credentials & then create a new project.
- Enable the following features while creating key
- Youtube Data API
- Youtube Analytics API
- Youtube Reporting API
- Then create
API key
from credentials tab. - Then in OAuth Consent Screen enter the
product name
(your site name). - create credentials > select OAuth Client ID. (here you will get client_id and client_secret)
- Then in the Authorized Javascript Origins section add
you site url
. - In the Authorized Redirect URLs section add
add a url which you want the auth code to return
(login callback) - You will get values (to be exact - client_id, client_secret & api_key)
- Then add these values - client_id, client_secret, api_key and redirect_url in the env file and you can start using the package now.
Usage :
Google Auth
-
Add Code to call the api class
-
Generating an Auth-Url
-
Fetching the Auth Code and Identifier Now once the user authorizes by visiting the url, the authcode will be redirected to the redirect_url specified in .env with params as code( this will be auth code) and state (this will be identifier we added during making the loginUrl)
-
Auth-Token and Details For Channel
- This will return an array:
Full Live Streaming API
-
Add Code to call the api class
-
Creating a Youtube Event
-
Updating a Youtube Event
-
Deleting a Youtube Event
-
Starting a Youtube Event Stream:
- Stopping a Youtube Event Stream
Full Youtube Channel API
-
Add Code to call the api class
-
Channel details By Channel Id If you want channel details for multiple channels add channel id saperated by commas(,) in param
NOTE: This doesn't require authorization token
-
Channel Detail by Token Channel Details of the users channel which has authorized token
-
Channel Subscription List List of subscriptions of the channel
- Add Subscriptions For Authorized Channel
-Remove Subscriptions For Authorized Channel To remove subscription we need subscription id which can be found from subscription list.
- Update Channel Branding Settings Updates the channel details and preferences.
Full Youtube Video API
-
Add Code to call the api class
-
List Video By Id
-
Upload Video To Your Channel
-
Delete Video To Your Channel
- Rate Video Adding a like, dislike or removing the response from video