Documentation/User Control Panel
WEB PLATFORM · REFERENCE GUIDE

User Control Panel

A full-stack player portal with an integrated administration console, Discord authentication and game-data integrations.

React 18Vite 6Node.js 18+Express 4MySQL 8MongoDB 4+
01

Overview

The supplied README describes a full-stack User Control Panel for the New City RP SA-MP server. It includes a React/Vite frontend and an Express backend, with player-facing pages and an integrated admin console.

02

Backend stack

Node.js 18+, Express 4, MySQL 8 through mysql2 for user and game data, MongoDB through Mongoose for permissions and roles, Passport Discord OAuth2, JWT, Helmet, CORS, rate limiting, validation, Winston logging and node-cron are listed.

03

Frontend stack

The README lists React 18, Vite 6, Tailwind CSS, React Router, Axios, Framer Motion, React Toastify, Chart.js, Lucide React and React Icons.

04

Authentication and permissions

The documented login flow uses Discord OAuth2. Roles include admin, moderator and user; route-level permission middleware and MongoDB-backed role/route-permission records are described.

05

API areas

The documented API prefixes include `/api/auth`, `/api/user`, `/api/premium`, `/api/admin`, `/api/perms`, `/api/push`, `/api/faq` and `/api/songs`, alongside bot-related endpoints.

06

Local setup

The README lists Node.js 18+, npm, MySQL 8+, MongoDB 4+ and a Discord application as prerequisites. It describes separate backend and client dependency installation, environment configuration and a permission seeding script. Review the seeder carefully: the supplied README warns that it clears and repopulates permission-related collections.

07

Security notes

Never publish `.env`, OAuth secrets, database credentials, real player information, logs, uploads or production backups. Review Git history as well as the working tree. The README identifies an ISC license, but the final release license and mandatory branding policy must be reconciled before publication.

SOURCE BASIS: USER-SUPPLIED PROJECT README · CONTENT SUMMARIZED FOR THE NCRP LEGACY WEBSITE.