I'm trying to set authentication with google for my website but I have a problem:
**
Client error: POST https://accounts.google.com/o/oauth2/token
resulted in a 400 Bad Request
response:\n {\n
"error" : "invalid_request",\n
"error_description" : "Missing required parameter: code"\n }\n
**
This is my code:
public function redirectToProvider(){
return Socialite::driver('google')->redirect();
}
public function handleProviderCallback()
{
$user = Socialite::driver('google')->stateless()->user();
dd($user->getName());
}
Can someone tell me what's the problem?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire