Skip to content

Backend v1 Phase 2#1

Merged
estif0 merged 7 commits intomainfrom
backend-v1
Jan 23, 2026
Merged

Backend v1 Phase 2#1
estif0 merged 7 commits intomainfrom
backend-v1

Conversation

@estif0
Copy link
Copy Markdown
Collaborator

@estif0 estif0 commented Jan 23, 2026

This pull request establishes the foundational backend infrastructure for the HackScore-AI project, focusing on database setup, authentication, and initial developer experience improvements. Major changes include the introduction of a robust PostgreSQL schema using Prisma ORM, sample data seeding, Google OAuth integration, and improved documentation and configuration for local development.

Backend Infrastructure & Database:

  • Added a comprehensive Prisma schema (schema.prisma) defining tables for users, chat sessions, messages, and uploaded files, with appropriate relations and indexes. [1] [2]
  • Implemented a database seeding script (prisma/seed.ts) to populate the database with demo users, sample chat sessions, messages, and uploaded files for development/testing.
  • Added Prisma migration files and configuration, including migration lock and environment-specific settings. [1] [2] [3]

Authentication & Security:

  • Introduced Google OAuth 2.0 authentication via Passport.js, with configuration for client credentials and callback URLs. [1] [2]
  • Centralized authentication configuration for JWT, session management, and OAuth providers in src/config/auth.ts.
  • Updated .env.example to clarify and separate Google/GitHub OAuth credentials, database URL, and frontend/backend URLs for local development.

Developer Experience & Documentation:

  • Added detailed project documentation in README.md, including architecture overview, tech stack, quick start guide, and database/authentication instructions.
  • Updated package.json scripts for database migration, seeding, reset, and Prisma Studio access; added relevant dependencies for backend and type safety.
  • Added .gitignore to prevent committing environment files and generated Prisma code.

- Add JWT and session configuration for user authentication.
- Implement Google OAuth strategy using Passport.js.
- Create routes for session management, login, logout, and magic link.
- Ensure user data is persisted in the database with Prisma.
- Create comprehensive authentication setup guide
- Add database quick reference with common commands
- Document phase 2 completion summary and API endpoints
- Update development steps to reflect phase 2 completion
- Change BASE_URL to point to the API server for OAuth callbacks.
- Introduce FRONTEND_URL for CORS configuration.
- Add a new script to test Google OAuth authentication flow.
@estif0 estif0 merged commit aa1372a into main Jan 23, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant