Skip to content

[Feature] OAuth infrastructure setup #20

@fregataa

Description

@fregataa

Summary

Set up the common infrastructure for OAuth authentication to support multiple providers.

Scope

Backend (API Server)

  • Add OAuth configuration structure in config
  • Create OAuth callback handler base
  • Implement user linking logic (OAuth account ↔ existing user)
  • Add oauth_providers table or extend users table
  • Handle first-time OAuth login (auto-registration)
  • Handle returning OAuth user login

Frontend

  • Create OAuth button components
  • Add OAuth callback page (/auth/callback/[provider])
  • Handle OAuth redirect flow
  • Update auth store for OAuth

Database Schema

CREATE TABLE oauth_accounts (
    id UUID PRIMARY KEY,
    user_id UUID REFERENCES users(id),
    provider VARCHAR(50) NOT NULL,  -- google, kakao, naver, apple, facebook
    provider_user_id VARCHAR(255) NOT NULL,
    email VARCHAR(255),
    created_at TIMESTAMP DEFAULT NOW(),
    UNIQUE(provider, provider_user_id)
);

Acceptance Criteria

  • OAuth base infrastructure implemented
  • Database migration created
  • Easy to add new OAuth providers
  • Existing email/password login still works

Related Issues

  • Blocks: Google, Kakao, Naver, Apple, Facebook OAuth issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions