Skip to main content
← Back to projects TopServers - Online Game Server Ranking Platform

TopServers - Online Game Server Ranking Platform

React Next.js Node.js TypeScript PostgreSQL

Overview

TopServers is a ranking and discovery platform for online game servers (Minecraft, FiveM, Ragnarok and similar). The goal was to centralize how players find, compare, and vote on private servers, filling the gap left by fragmented ranking sites that usually focus on a single game and have very weak anti-fraud mechanisms.

I built the project end-to-end as a solo full-stack engineer, using it as a playground to practice real-world concerns: domain modeling, clean architecture, anti-fraud voting, Stripe payments, async queues, and production-like CI/CD. The backend is a TypeScript Node.js/Express API using Prisma ORM and Redis/Bull for queues; the frontend is a Next.js 12 application with server-side rendering for SEO.

Core features include a multi-layer voting system (reCAPTCHA + IP + 12h time window per account), server management for admins, premium plans with Stripe checkout and webhooks, and asynchronous processing of GeoIP and notifications. Everything runs inside Docker containers, orchestrated via Docker Compose, with GitHub Actions pipelines for building and deploying from the main branches.

The platform was not scaled as a commercial product, so the main impact is the technical maturity of the implementation: a realistic reference codebase for payments, queues, anti-fraud logic, and modular architecture that I now reuse as a blueprint in client projects.

Key Differentiator

TopServers stands out by combining three aspects that are uncommon in a side project:

  1. A voting system designed with realistic fraud vectors in mind (IP + account + 12h time window + async GeoIP analysis), not just a simple “like” counter.
  2. A fully integrated Stripe premium flow with webhook-driven state changes that correctly handles both instant and async payment methods, with strong idempotency guarantees to avoid double-granting benefits.
  3. A modular architecture with clearly separated domains (Accounts, Servers, Votes, Premium, Games, etc.), async workers, and automated infrastructure, making the project feel like a production-grade system even though it was built solo.

On the technical side, using Prisma as the single source of truth for the data model, TSyringe for dependency injection, and Bull/Redis for background jobs provides a clean, extensible foundation to ship new features (reviews, advanced analytics, public API) without rewriting the core.

Architecture

  • Next.js Frontend: React application built with Next.js 12, using SSR and routing for server lists and detail pages, voting forms, auth screens, and the premium checkout flow.
  • Express API: Node.js/Express backend written in TypeScript, structured into domain modules (Accounts, Servers, Votes, Premium, Games, Translations, Roles, Contact).
  • Accounts Module: Manages users, authentication, password recovery, and basic permissions.
  • Servers Module: CRUD for game servers, connection info, premium status, and aggregated metrics.
  • Votes Module: Handles vote creation, applies anti-fraud rules (reCAPTCHA, IP, 12h window), and dispatches async GeoIP jobs.
  • Premium Module: Stripe integration (checkout sessions, webhooks), payment history management, and premium days calculation.
  • Games Module: Catalog of supported games and classification of servers per game.
  • Translations Module: Multi-language support for UI texts and static content.
  • Roles Module: Role-based access control (admin, server owner, regular user) and endpoint authorization.
  • Contact Module: Contact form handling and email delivery through AWS SES.
  • PostgreSQL (Prisma): Primary relational database for users, servers, votes, payments, and premium history, with type-safe queries via Prisma Client.
  • Redis + Bull Queues: Acts as cache for hot data and as the backbone for background job queues (GeoIP lookups, webhook side effects, email sending).
  • Job Workers: Dedicated Node.js processes consuming Bull queues to execute GeoIP API calls, apply derived business rules, and trigger notifications.
  • Docker Infrastructure: Docker Compose setup orchestrating API, frontend, PostgreSQL, Redis, and workers, with PM2 managing Node processes in production environments.
  • CI/CD with GitHub Actions: Automated pipelines for building, basic checks, and deployment triggered on commits to the API and frontend repositories.

Technical Highlights

  • Implemented a fraud-resistant voting rule that cross-checks IP and account within a 12-hour sliding window, using Prisma query capabilities and proper timezone handling to minimize both abuse and false positives.
  • Offloaded GeoIP lookups and related analytics to Bull/Redis queues, keeping the vote HTTP endpoint responsive even when external IP APIs are slow or unreliable.
  • Designed a Stripe integration based entirely on webhooks, covering both synchronous and asynchronous payment methods, and enforcing idempotency via a gatewayId to prevent duplicated premium grants.
  • Structured the backend using a Clean Architecture-inspired approach with TSyringe-based dependency injection, allowing use cases to be tested with in-memory repositories and fakes for mail, storage, and queue providers.
  • Built a Next.js 12 SSR frontend optimized for SEO on server detail pages, leveraging next-sitemap to generate XML sitemaps automatically for better crawler coverage.
  • Packaged the entire stack (API, frontend, PostgreSQL, Redis, workers) into a Docker Compose setup that can be reproduced locally and on servers with minimal manual configuration.
  • Set up CI/CD with GitHub Actions to automatically build, test, and deploy both API and frontend upon changes, mirroring production workflows used in client projects.
  • Integrated reCAPTCHA v3 into the voting flow, combining Google’s risk scoring with internal IP/account heuristics to mitigate both automated bots and manual abuse patterns.

Gallery