Skip to content

SWEProject25/backend

Repository files navigation

Hankers — Backend API

Hankers Logo

Scalable Social Networking Backend — NestJS

A modular, production-ready REST API powering the Hankers platform

🔗 Live Platform: hankers.tech

📌 Overview

Hankers Backend is a scalable, secure, and maintainable REST API built with NestJS and TypeScript, designed to support a modern social networking platform similar to Twitter/X.

The backend follows domain-driven and feature-based architecture, emphasizing:

  • Clear separation of concerns
  • Strong typing and validation
  • Testability and scalability
  • Real-world backend engineering practices

This codebase is structured to support large teams, high traffic, and long-term growth.


✨ Core Backend Features

  • 🔐 Authentication & Authorization

    • JWT access & refresh tokens
    • OTP & password reset flows
    • Role-based access control (RBAC)
  • 👤 User Management

    • Profiles, avatars, bios
    • Follow / unfollow system
    • Privacy & account settings
  • 📝 Posts & Interactions

    • Create, edit, delete posts
    • Replies, likes, reposts
    • Optimized feed queries
  • 💬 Messaging System

    • One-to-one & group chats
    • Read receipts & typing indicators
    • WebSocket real-time support
  • 🔔 Notifications

    • Real-time notifications
    • Event-driven architecture
    • Firebase / push-ready
  • 🔍 Search & Explore

    • Hashtags & trending topics
    • User & content search
    • Pagination & filtering
  • 🛡 Security

    • Input validation
    • Rate limiting
    • Secure password hashing

🧱 Architecture Philosophy

The backend follows a Feature-First Modular Architecture, fully aligned with NestJS best practices.

Each feature is:

  • Encapsulated inside its own module
  • Independently testable
  • Easy to scale, refactor, or remove

✅ This avoids bloated global folders and mirrors real production NestJS systems.


🛠 Tech Stack

Core

  • Framework: NestJS
  • Language: TypeScript
  • Runtime: Node.js

Data & Infrastructure

  • Database: PostgreSQL
  • ORM: Prisma
  • Caching: Redis
  • File Storage: AWS S3 (or compatible)

Communication

  • API: REST
  • Real-Time: WebSockets (Socket.IO)
  • Async Events: Event Emitters / Queues

Security & Auth

  • Auth: JWT + Passport
  • Validation: class-validator & class-transformer
  • Hashing: bcrypt

Testing & Quality

  • Unit & Integration: Jest
  • E2E Testing: Supertest
  • Linting: ESLint + Prettier

DevOps & Deployment

  • Containerization: Docker
  • CI/CD: GitHub Actions
  • Hosting: AWS

🚀 Getting Started

1️⃣ Install Dependencies

npm install

⚙️ Backend Team


Omar Nabil

Salah Mostafa

Ahmed Ellabban

Mohamed Albaz

Yousef Aref

About

Handles system logic, data management

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors