Comment to 'Log in with PayPal'
  • Log in with PayPal can be added by integrating PayPal’s OpenID Connect (OAuth2) identity service with the UNA account system.

    Key steps

    1. Set up a PayPal Developer App with “Log in with PayPal” enabled.
    2. Add the PayPal login button to the UNA login/register interface.
    3. On click, redirect the user to PayPal’s authorization URL.
    4. After authentication, PayPal returns an authorization code to the site’s callback URL.
    5. Exchange the code for an access token and retrieve the user’s profile details (email, name, PayPal ID).
    6. Match the PayPal user to an existing UNA profile by email or PayPal ID.
    • If found, log the user into their UNA account.
    • If not found, create a new UNA profile and link the PayPal account.