Skip to content

ankitsharma101/smart-ai-ticket-assistant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

12 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Smart AI Ticket Assistant πŸŽŸοΈπŸ€–

A full-stack MERN application that automates ticket management using AI-powered workflows and Inngest event-driven functions. The project supports user authentication, ticket creation, AI-based ticket analysis, and automated email notifications.

πŸš€ Features

πŸ”‘ Authentication – Signup/Login using JWT

🎟️ Ticket Management – Create and track support tickets

πŸ€– AI-Powered Assistance – Classify, assign, and add notes to tickets using AI

πŸ“© Email Notifications – Sends welcome emails and ticket updates

⚑ Event-Driven Workflows – Uses Inngest for reliable async event handling

πŸ—ΊοΈ Full-Stack MERN – React + Node.js + Express + MongoDB

πŸ› οΈ Tech Stack

Frontend: React (Vite, Tailwind, DaisyUI)

Backend: Node.js, Express

Database: MongoDB

Event System: Inngest

AI Integration: Custom AI utility (via Gemini)

Auth: JWT-based

Deployment:

Frontend β†’ Vercel

Backend β†’ Render

πŸ“‚ Project Structure

smart-ai-ticket-assistant/ β”‚ β”œβ”€β”€ ai-ticket-assistant/ # Backend β”‚ β”œβ”€β”€ controllers/ # Auth & ticket controllers β”‚ β”œβ”€β”€ inngest/ # Inngest client & event functions β”‚ β”œβ”€β”€ middlewares/ # Auth middleware β”‚ β”œβ”€β”€ models/ # Mongoose models (User, Ticket) β”‚ β”œβ”€β”€ routes/ # API routes β”‚ β”œβ”€β”€ utils/ # Helpers (Mailer, AI) β”‚ β”œβ”€β”€ index.js # Express server entry β”‚ └── .env # Backend environment variables β”‚ β”œβ”€β”€ ai-ticket-frontend/ # Frontend β”‚ β”œβ”€β”€ src/ β”‚ β”‚ β”œβ”€β”€ components/ # Navbar, Auth check β”‚ β”‚ β”œβ”€β”€ pages/ # Login, Signup, Tickets, Admin β”‚ β”‚ β”œβ”€β”€ App.jsx # Routes β”‚ β”‚ └── main.jsx # React entry β”‚ β”œβ”€β”€ public/ # Static assets β”‚ β”œβ”€β”€ vite.config.js # Vite config β”‚ └── .env # Frontend environment variables β”‚ β”œβ”€β”€ .gitignore └── README.md

yaml Copy code


βš™οΈ Setup Instructions

1. Clone Repository

git clone https://github.com/ankitsharma101/smart-ai-ticket-assistant.git
cd smart-ai-ticket-assistant
2. Backend Setup
bash
Copy code
cd ai-ticket-assistant
npm install
Create a .env file inside ai-ticket-assistant/:

env
Copy code
PORT=5000
MONGO_URL=your_mongo_connection_string
JWT_SECRET=your_secret_key
INNGEST_EVENT_KEY=your_inngest_event_key
EMAIL_USER=your_email
EMAIL_PASS=your_email_password
Run backend:

bash
Copy code
npm start
Or with Inngest dev:

bash
Copy code
npx inngest dev --sdk-url=http://localhost:5000/api/inngest
vbnet
Copy code

βœ… This will now render perfectly with **code blocks, tree structure, and .env example**.  

Do you want me to also **fix the frontend setup section** in the same way (with clean Markdown formatting)?

3. Frontend Setup
cd ai-ticket-frontend
npm install


Create .env:

VITE_SERVER_URL=http://localhost:5000

Run frontend:

npm run dev

🌍 Deployment

Frontend (Vercel): Connect ai-ticket-frontend/ to Vercel

Backend (Render): Deploy ai-ticket-assistant/ on Render

Ensure all .env variables are configured in deployment dashboards

πŸ§ͺ Testing

Signup a new user β†’ triggers onUserSignup event β†’ sends welcome email

Create a new ticket β†’ triggers onTicketCreated event β†’ AI assigns ticket & adds notes

View tickets on frontend β†’ should display assigned moderator & status

πŸ“Œ Future Improvements

Google OAuth integration

Admin dashboard with analytics

Priority-based ticket routing

File upload support for tickets

πŸ‘¨β€πŸ’» Author

Ankit Sharma
MERN Stack Developer | AI Enthusiast

Releases

No releases published

Packages

 
 
 

Contributors

Languages