Overview

EcoSpark Hub - Sustainability Community Platform

Full Stack Developer

EcoSpark Hub is a full-stack community platform that connects sustainability-minded members around actionable environmental ideas — from plastic-reduction initiatives to community solar projects. The platform combines a structured editorial review pipeline for idea approval, threaded discussion powered by nested commenting, and integrated Stripe payments to unlock premium content. Positioned at the intersection of Reddit's community engagement, Medium's editorial quality, and Stripe's monetization infrastructure, EcoSpark Hub is built to help green initiatives move from proposal to execution.

Technologies

Next.jsTailwind CSSNode.jsExpress.jsPrismaPostgreSQLJWTBetter-AuthStripeCloudinary

Features

  • Idea Submission & Editorial Workflow

    Members draft and submit sustainability ideas through a formal state machine: DRAFT → PENDING → UNDER_REVIEW → APPROVED / REJECTED. Admins moderate the queue, provide structured rejection feedback, and lock approved ideas from further edits.

  • Voting System

    Upvote and downvote system with one vote enforced per member per idea via a database-level unique constraint. Vote counters are denormalized on the idea row and updated transactionally to support performant listing pages.

  • Nested Comments

    Reddit-style threaded comment system using a self-referencing adjacency list (parentId). Supports up to 3–4 levels of reply depth, soft-deletes to preserve thread integrity, and efficient tree assembly via a single batched query.

  • Paid Idea Access & Payment Integration

    Idea authors can mark content as paid and set a price. Members trigger a payment flow via Stripe, and access is granted only after the gateway confirms payment through an async webhook — never on frontend redirect alone.

  • Admin Dashboard & Moderation

    Dedicated admin panel for managing the moderation queue, approving or rejecting ideas with feedback, managing user roles (MEMBER / ADMIN), activating or deactivating accounts, and handling category CRUD.

  • Member Dashboard

    Personal dashboard where members track their submitted ideas, view current status, read rejection feedback, manage drafts, and access their purchased ideas list.

  • Search, Filter & Pagination

    Server-side search across idea titles, descriptions, and problem statements. Filter by category, paid status, and vote range. Sort by most recent or top voted. Paginated at 12 ideas per page with SEO-friendly Server Component rendering.

  • Secure Authentication

    JWT-based authentication system with protected routes, role-based authorization, bcrypt password encryption, and secure API middleware.

  • Responsive Community Platform

    Fully responsive design optimized for mobile, tablet, and desktop with reusable components and modern UI architecture.

System Architecture

Architecture diagram

Future Improvements

  • 1

    Real-Time Notifications

  • 2

    AI-Powered Idea Recommendations

  • 3

    Stripe Integration for International Payments

  • 4

    Mobile Application