openauthdev / socialiteopenauthprovider
OpenAuth.dev provider for Laravel Socialite
Requires
- php: >=7.2.5
- socialiteproviders/manager: ~4.0
This package is auto-updated.
Last update: 2022-06-25 19:55:59 UTC
README
OpenAuth.dev Provider for Laravel Socialite
Table of contents
- About the project
- Getting Started
- Configuration
- Usage
- Contributing
- Versioning
- Built With
- Authors
- License
About the project
TBA
Getting started
Require the project:
composer require openauthdev/socialiteopenauthprovider
Ready! Now you can start with your project.
Configuration
First of all replace the service provider Laravel\Socialite\SocialiteServiceProvider
in the config\app.php
in providers[]
with \SocialiteProviders\Manager\ServiceProvider::class
.
Then we add the required event listener. Go to app/Providers/EventServiceProvider
and add the following lines to the listen[]
array.
\SocialiteProviders\Manager\SocialiteWasCalled::class => [ 'SocialiteProviders\\OpenAuth\\OpenAuthExtendSocialite@handle', ]
Finally, we just need to add the configuration instructions. To do this, add the following to the `config/services.php' file.
'openauth' => [ 'client_id' => env('OPENAUTH_CLIENT_ID'), 'client_secret' => env('OPENAUTH_CLIENT_SECRET'), 'redirect' => env('OPENAUTH_REDIRECT_URI') ]
The configuration is now complete.
Usage
Now you can use the OAuthProvider as usual with Sociallite.
return Socialite::driver('openauth')->redirect();
Contributing
There are many ways to help this open source project. Write tutorials, improve documentation, share bugs with others, make feature requests, or just write code. We look forward to every contribution.
Versioning
We use SemVer for versioning. For available versions, see the tags on this repository.
Built with
- Socialite Providers Manager - Easily add new or override built-in Laravel Socialite providers
Authors
- Titus Kirch - Main development - TitusKirch
See also the list of contributors who participated in this project.
License
This project is licensed under the LGPL-2.1 License - see the LICENSE file for details.