worksome / socialite
A Worksome provider for Laravel Socialite
Installs: 180 519
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 14
Forks: 0
Open Issues: 0
Requires
- php: ^8.2
- ext-json: *
- socialiteproviders/manager: ^4.5
Requires (Dev)
- laravel/pint: ^1.13.10
- orchestra/testbench: ^8.21 || ^9.0
- pestphp/pest: ^2.33
- phpstan/phpstan: ^1.10
- symfony/var-dumper: ^6.4 || ^7.0
README
A Worksome provider for Laravel Socialite
Install
Via Composer
composer require worksome/socialite
Please see the Base Installation Guide, then follow the provider specific instructions below.
Add configuration to config/services.php
'worksome' => [ 'client_id' => env('WORKSOME_CLIENT_ID'), 'client_secret' => env('WORKSOME_CLIENT_SECRET'), 'redirect' => env('WORKSOME_REDIRECT_URI'), // Optional 'auth_uri' => env('WORKSOME_AUTH_URI', 'https://auth.worksome.com'), 'auth_redirect_uri' => env('WORKSOME_AUTH_REDIRECT_URI', 'https://auth.worksome.test'), ],
Add provider event listener
Configure the package's listener to listen for SocialiteWasCalled
events.
Add the event to your listen[]
array in app/Providers/EventServiceProvider
. See the Base Installation Guide for detailed instructions.
protected $listen = [ \SocialiteProviders\Manager\SocialiteWasCalled::class => [ // ... other providers \Worksome\Socialite\WorksomeExtendSocialite::class, ], ];
Usage
You should now be able to use the provider like you would regularly use Socialite (assuming you have the facade installed):
return Socialite::driver('worksome')->redirect();
Returned User fields
id
: The id of the authenticated username
: The name of the authenticated useremail
: The email address of the authenticated user
Change log
Please see GitHub Releases for more information on what has changed recently.
Credits
License
The MIT License (MIT). Please see License File for more information.