A helpdesk backend for organizing technical support requests and managing ticket workflows.
River is a helpdesk ticket management system designed to organize technical support requests, track ticket progress, and provide a foundation for role-based support workflows.
The project is being developed incrementally, starting with a secure REST API and expanding toward a complete helpdesk application.
Ticket creation workflow — from request validation to database storage.
- Receive a ticket creation request.
- Authenticate the user using a JWT.
- Verify that the account is active.
- Validate the submitted ticket data.
- Apply default values and associate the creator.
- Save the ticket to MongoDB.
- Return a
201 Createdresponse.
| Technology | Purpose |
|---|---|
| Node.js | JavaScript runtime |
| Express 5 | REST API and routing |
| TypeScript | Type-safe backend development |
| MongoDB | Database |
| JWT | Authentication |
| bcrypt | Password hashing |
| Zod | Request validation |
- User registration and login
- Password hashing with bcrypt
- JWT-based authentication
- Active-account verification
- Role definitions for employees, agents, and administrators
- Ticket creation with validated input
- Ticket categories and priorities
- Default ticket status and priority
- MongoDB indexes for user lookup and ticket queries
Development note: River is a work in progress. Ticket assignment, status management, and the frontend are planned but are not yet implemented.
Base URL for local development:
http://localhost:5000
| Method | Endpoint | Description |
|---|---|---|
GET |
/api/health |
Health check |
POST |
/api/auth/register |
Register an account |
POST |
/api/auth/login |
Log in |
GET |
/api/auth/me |
Get the authenticated identity |
POST |
/api/tickets |
Create a ticket |
Protected endpoints require a valid bearer token:
Authorization: Bearer <your-token>- Node.js and npm
- MongoDB
- Git
git clone https://github.com/feeridev/River.git
cd River/servernpm installCopy the example environment file:
cp .env.example .envConfigure the values in .env:
PORT=5000
MONGODB_URI=mongodb://127.0.0.1:27017/river
JWT_SECRET=replace_with_a_long_random_secretGenerate a strong secret locally:
openssl rand -hex 32Use the generated value for JWT_SECRET. Never commit your real .env file.
Ensure your MongoDB service is running before starting the API.
On systems using systemd:
sudo systemctl start mongodnpm run devThe API will run at:
http://localhost:5000
npm run build
npm startRiver/
├── .gitignore
└── server/
├── scripts/
├── src/
│ ├── config/
│ ├── middleware/
│ ├── models/
│ ├── repositories/
│ ├── routes/
│ ├── services/
│ ├── utils/
│ ├── validation/
│ ├── app.ts
│ └── server.ts
├── .env.example
├── package.json
└── tsconfig.json
- Ticket listing and filtering
- Ticket assignment to support agents
- Ticket status updates and resolution
- Role-based authorization for helpdesk operations
- Ticket history and comments
- Automated tests
- React and TypeScript frontend
- Deployment and installation documentation
River is built step by step, with an emphasis on understanding the implementation, validating inputs, protecting user accounts, and keeping the codebase maintainable.
The goal is to build a practical helpdesk system while documenting the engineering decisions and development process along the way.
Farshad Safarkhanloo
- GitHub: @feeridev
River is an independent portfolio project and is actively being developed.

