AuthnAuthzAPI
Get Started
Get Started
  1. OAuth Authentication
  • Overview
  • Registration & Onboarding
    • Register a new user
      POST
    • Verify email address
      POST
    • Resend verification code
      POST
  • Authentication
    • Login user
      POST
    • Logout user
      POST
    • Request a password reset email
      POST
    • Verify password reset token
      POST
    • Update password
      POST
    • Refresh access token
      POST
    • Get current authenticated user
      GET
  • OAuth Authentication
    • OAuth authentication
      GET
    • OAuth callback
      GET
  • Session Management
    • Get all sessions
      GET
    • Revoke session
      DELETE
    • Revoke all sessions
      DELETE
  • Profile Management
    • View profile information
      GET
    • Update profile information
      PATCH
  1. OAuth Authentication

OAuth authentication

Developing
GET
/auth/oauth/{provider}
Initiates OAuth 2.0 authentication with a supported third-party provider (Google or GitHub). This endpoint redirects the user to the provider's authorization page, where they can authenticate and grant access to their profile information.
According to the system requirements, OAuth authentication supports both third-party registration and login through Google and GitHub. Accounts created through OAuth are automatically verified, and the system stores profile information retrieved from the provider, including name, email, and profile picture.

Request

Path Params

Responses

🔵302Success
text/plain
Redirects the user to the selected OAuth provider's authorization page.
🟠400Invalid Provider
🔴503OAuth Provider Unavailable
🟠429Rate Limit Exceeded
🔴500Internal Server Error
Request Request Example
Shell
JavaScript
Java
Swift
curl --location 'http://localhost:3000/api/v1/auth/oauth/'
Response Response Example
302 - Example
HTTP/1.1 302 Found
Location: https://accounts.google.com/o/oauth2/v2/auth?client_id=...&redirect_uri=...&response_type=code&scope=...&state=...&code_challenge=...&code_challenge_method=S256
Modified at 2026-07-18 20:07:13
Previous
Get current authenticated user
Next
OAuth callback
Built with