I’m using Facebooks’ API to get user credentials to login/sign-up to my application.
But I’m struggling with what type of credentials should I save to the database as username(email) and password? should I save Facebook’s user-id and token as username and password? or is there another way to do that?
2
Answers
Just add new field and name it as facebook_id(bigint):
you can do validate exist email or user_id from facebook depend on your requirement.
hope it can give you some idea and also i’m not a native speaker.
Check this package:
https://laravel.com/docs/7.x/socialite
It provides social authentication out of the box for laravel including facebook login.