Skip to main content

Social Login Integration

LearnWay supports frictionless onboarding through Google and Apple OAuth providers on both mobile (Flutter/iOS/Android) and web.

1. Client-Side Flow

  1. The client invokes Google Sign-In or Apple Sign-In SDK.
  2. The provider returns an identity payload / token (idToken or user details).
  3. The client submits the credentials to /api/v2/auth/login-with-social.

2. API Endpoint

Supported Providers

  • google
  • apple

3. Server Behavior

  • If the user with the given email does not exist, a new user profile is created automatically, setting isEmailVerified: true and assigning standard onboarding XP.
  • If the user already exists, the system issues a fresh JWT pair (accessToken and refreshToken).