I am using Laravel 8 & trying to create a custom authentication through external API source.
I am keeping the Frontend as Laravel without any direct database interactions & Lumen as the application data layer which interacts directly to the databases & works as an external API.
These are the authentication logic to be followed:
- User enters his email & password.
- Laravel will POST this credentials to a custom Lumen external API say - http://example.com/api/v1/login.
- This external API will then validate the credentials & returns a custom Login token.
- Then the Laravel application will use this login token across user devices as session storage & for authentication purpose.
I searched for solution but there is no detailed documentation on this. Your help is much appreciated. Thanks