A simple ticket management application for employees to report and track IT issues.
Built with Spring Boot (Java 17), Oracle SQL, and Java Swing for the UI.
Supports role-based access, status tracking, audit logging, and search/filtering.
The IT Support Ticket System API provides a platform for employees to create and track IT support tickets while allowing IT support staff to manage and resolve them. It includes endpoints for user authentication, ticket management, comments, and audit logs.
git clone [email protected]:alfahami/it-support-ticket-system.git
cd it-support-ticket-system
This project uses H2, an in-memory database for development and testing.
Visit http://localhost:8080/h2-console
- JDBC URL:
jdbc:h2:mem:ticketing
- Username:
sa
- Password: (leave empty by default)
mvn clean install
mvn spring-boot:run
- Method:
POST
- URL:
/users
- Description: Registers a new user (Employee or IT Support).
- Request Body:
{ "username": "tupac", "password": "12345RFTE", "email": "[email protected]", "role": "EMPLOYEE" }
- Method:
POST
- URL:
/user/authenticate
- Description: Logs in a user and returns a JWT token.
- Request Body:
{ "username": "tupac", "password": "12345RFTE" }
- Method:
GET
- URL:
/users/{userId}
- Authentication: Bearer token required.
- Method:
DELETE
- URL:
/users/{userId}
- Method:
POST
- URL:
/users/{userId}/tickets
- Description: Allows an employee to create a new support ticket.
- Request Body:
{ "title": "Issue with VPN", "description": "Cannot connect to VPN", "category": "NETWORK", "priority": "HIGH", "status": "NEW" }
- Method:
GET
- URL:
/users/{userId}/tickets/{ticketId}
- Method:
PATCH
- URL:
/users/{userId}/tickets/{ticketId}
- Description: Updates ticket details such as status and priority.
- Method:
DELETE
- URL:
/users/{userId}/tickets/{ticketId}
- Method:
GET
- URL:
/users/{userId}/tickets/all
- Method:
GET
- URL:
/users/{userId}/tickets/search?status=RESOLVED
- Method:
GET
- URL:
/users/{userId}/tickets/{ticketId}/audit-logs
- Description: Retrieves the history of status changes and actions performed on a ticket.
- Method:
POST
- URL:
/users/{userId}/tickets/{ticketId}/comments
- Description: Adds a comment to a ticket.
- Request Body:
{ "content": "Can you provide more details about the issue?" }
- Method:
GET
- URL:
/users/{userId}/tickets/{ticketId}/comments/{commentId}
- Method:
PATCH
- URL:
/users/{userId}/tickets/{ticketId}/comments/{commentId}
- Request Body:
{ "content": "Have you tried restarting the system?" }
- Method:
DELETE
- URL:
/users/{userId}/tickets/{ticketId}/comments/{commentId}
- The API uses JWT Bearer Token Authentication for protected routes.
- Employees can only access their own tickets.
- IT Support has permissions to view and modify all tickets.