Laravel Socialite Login with Google and Github | Laravel Breeze

Поділитися
Вставка
  • Опубліковано 8 лис 2024
  • In this video tutorial we will learn on how to add google and GitHub authentication in our Laravel breeze starter kit.
    Channel: / @laraphant
    Twitter: / misikowilliam
    Facebook: / williamjumamisiko
  • Наука та технологія

КОМЕНТАРІ • 15

  • @riadhcoding
    @riadhcoding 2 місяці тому

    Great brother we can take number google account ? After login user

    • @laraphant
      @laraphant  2 місяці тому +1

      Yes the callback provides the gmail address of the user, the avatar, names, among other details

    • @riadhcoding
      @riadhcoding 2 місяці тому

      @@laraphant you are the best brother thanks

    • @riadhcoding
      @riadhcoding 2 місяці тому

      I try everything brother we cant get user phone after login with google account if you have solution lat me know

    • @laraphant
      @laraphant  2 місяці тому

      @@riadhcoding Oooh if you are intending to get the phone number of a user, you can just have a form where the user will provide it before logging them in. The google api wont provide that.

  • @jfprograma4004
    @jfprograma4004 7 місяців тому

    Thanks for this awesome video, can you demostrate on another video how to create a local app manager to login with, I mean, as google and github but app locally hosted?

    • @laraphant
      @laraphant  7 місяців тому

      I would appreciate more details. Thanks

    • @jfprograma4004
      @jfprograma4004 7 місяців тому

      @@laraphant Thank you for answer, I mean, create an application to handle the authentication of several other apps, for example lets say you create a laravel blog, a shop and a social media all in laravel and turn that 3 auth in only one separated auth app that handle the authentication of the previous 3 apps delivering also the roles, permissiones etc. I dont know if is clear

  • @akbargunawan204
    @akbargunawan204 5 місяців тому +1

    Laravel\ Socialite\ Two\ InvalidStateException
    why?

  • @NigelTore
    @NigelTore 3 місяці тому +1

    Also getting this error: Laravel\ Socialite\ Two\ InvalidStateException

    • @martinbalaz2335
      @martinbalaz2335 2 місяці тому

      This worked for me - $user = Socialite::driver('google')->stateless()->user();

  • @ibnuzaman3941
    @ibnuzaman3941 2 місяці тому +1

    excuse me i got error Laravel\Socialite\Two\InvalidStateException, anyone solve this error?

    • @andresokei6486
      @andresokei6486 2 місяці тому

      I had the same error; I followed the tutorial again and encountered it once more.
      Now I no longer have the issue, but I'm not sure how I fixed it. In my case, I only used Google login, not GitHub. I think that if you follow the tutorial exactly, in the step of creating Google credentials, they are not fully created. You need to close the pop-up that remains open for it to be saved properly.
      Also, I recommend you taking screenshots of the errors and uploading them to ChatGPT if you really lost; it might be helpful.

  • @abdelkaderrefaat4631
    @abdelkaderrefaat4631 4 місяці тому

    so awesome