An intelligent AI-powered ticketing system built with Node.js, Express.js, Inngest, Nodemailer, and Google AI APIs.
This system automatically assigns tickets, suggests helpful notes, matches skills, and updates ticket status.
- ✅ User Authentication & Authorization
- ✅ AI Agent Assignment using Google AI API
- ✅ Skill Matching & Ticket Assignment to Moderators
- ✅ Helpful Notes Generation with AI
- ✅ Auto Status Update for Tickets
- ✅ Email Notifications using Nodemailer
- ✅ Background Jobs Handling with Inngest
- ✅ Clean RESTful API with Express.js
- ✅ Modular Code Structure (Backend + Frontend)


- Backend: Node.js, Express.js
- AI Integration: Google AI Studio (Gemini API)
- Background Jobs: Inngest
- Email Service: Nodemailer
- Database: (MongoDB)
- Frontend: (Vite React)
Client App ──▶ Express Server ──▶ MongoDB
│
├──▶ Inngest Queue ──▶ Google Gemini AI
└──▶ Nodemailer
SmartTicket-AI
├── BACKEND
│ ├── controllers
│ ├── middlewares
│ ├── models
│ ├── routes
│ ├── utils
│ ├── inngest
│ ├── .env
│ ├── index.js
│ ├── package.json
├── FRONTEND
│ ├── components
│ │ ├── admin
│ │ ├── auth
│ │ ├── common
│ │ ├── tickets
│ ├── contexts
│ ├── hooks
│ ├── services
│ ├── .env
│ ├── App.tsx
│ ├── index.tsx
│ ├── package.json
├── README.md
1️⃣ User creates a ticket
2️⃣ AI Agent reads the ticket & analyzes it via Google AI API
3️⃣ Suggests Helpful Notes
4️⃣ Matches Relevant Skills with Moderators
5️⃣ Auto assigns the ticket to best-fit Moderator
6️⃣ Updates ticket Status
7️⃣ Sends notification emails via Nodemailer
8️⃣ Runs background tasks using Inngest
1️⃣ Clone the Repo
git clone https://github.com/rajveer-09/SmartTicket-AI.git
cd SmartTicket-AI/BACKEND
npm install
MONGO_URI=
PORT=
JWT_SECRET=
MAILTRAP_SMTP_HOST=
MAILTRAP_SMTP_PORT=
MAILTRAP_SMTP_USER=
MAILTRAP_SMTP_PASS=
GEMINI_API_KEY=
APP_URL=
GMAIL_USER=
GMAIL_PASS=
INGGEST_SIGNING_KEY=
✅ Don't forget to add .env in .gitignore
npm start
- Recommended Platforms: Render, Railway, Vercel, Heroku
- Add environment variables securely
- Keep your secrets safe
Fork & Clone
Create a new feature branch
Raise a Pull Request
- MIT License
- Inngest — Event-driven jobs
- Google AI Studio — AI Capabilities
- Nodemailer — Email Services
┌───────────────────────────────────────────────────────┐
│ Client Application │
└──────────────────────────┬────────────────────────────┘
│
┌──────────────────────────▼────────────────────────────┐
│ Express Server │
│ ┌─────────────┐ ┌─────────────┐ ┌───────────────┐ │
│ │ Auth Routes │ │Ticket Routes│ │ Admin Routes │ │
│ └─────────────┘ └─────────────┘ └───────────────┘ │
└───────────┬──────────────────────────────┬────────────┘
│ │
┌───────────▼─────────────┐ ┌──────────▼───────────┐
│ MongoDB │ │ Inngest Queue │
│ ┌───────────────────┐ │ │ ┌────────────────┐ │
│ │ Tickets │ │ │ │ AI Processing │ │
│ ├───────────────────┤ │ │ ├────────────────┤ │
│ │ Users │ │ │ │ Notifications │ │
│ ├───────────────────┤ │ │ ├────────────────┤ │
│ │ Moderators │ │ │ │ Assignments │ │
│ └───────────────────┘ │ │ └────────────────┘ │
└─────────────────────────┘ └──────────────────────┘
│ │
└──────────────┬───────────────┘
│
┌─────────▼─────────┐
│ Google Gemini AI │
└───────────────────┘