QuickRoute is an AI-based itinerary-generating web application that allows users to create personalized travel plans. The application supports two user roles: admin and user.
- Manage destinations
- Manage destination locations
- Manage offers
- View site and destination location reviews
- Register and log in to the system
- Add destination locations to a wishlist
- Create trip plans and add destination locations to the plans
- Write reviews for the site and destination locations
- Generate two AI-suggested itineraries from their trip plans
- Choose the most suitable itinerary and download it
- Frontend: React framework
- Backend: Ballerina
- Database: MySQL
- AI Model: GPT-3.5 Turbo for itinerary generation
The application uses JWT tokens for authentication and authorization, with the following approach:
- Algorithm: HS256
- Header: Type
jwt - Payload: Encoded as base64
- Secret: Stored in
config.tomlfile - Custom modules were developed for generating and decoding JWT tokens.
A request filter module filters requests based on user roles.
To ensure clean code and reusability, the following modules were developed:
- DB Module: Singleton module for database interactions
- Email Module: For handling email services
- Image Upload Module: For managing file uploads
- Time Module: For time-related functionalities
- Password Module: For encrypting user passwords using a secret stored in
config.toml - Itinerary Generation Module: Integrates with GPT-3.5 Turbo for AI-based itinerary suggestions
- Admin services are maintained in
admin_services.bal - Client services are maintained in
client_services.bal - Authentication services, including login, registration, and admin login, are handled in
auth_service.bal - Static server file access is managed in
auth_service.bal - File uploading uses multipart form data handling in Ballerina
- Enums: For regex and error messages
- Validation Methods: Separate methods for various validations
- Ballerina: Download and install Ballerina.
- Node.js and npm: Ensure that Node.js and npm are installed.
-
Clone the Git repository:
git clone https://github.com/hiranyasemindi/iwb470-byte-seekers.git
-
Frontend Setup:
cd client npm install npm run dev -
Database Setup:
- Inside the project file tree, there is a
QuickRoute.sqlfile. Run this file to create the database schema. - Update the database configuration in
config.tomlunder the[QuickRoute.db]section:hostusernamepassworddatabaseport
- Inside the project file tree, there is a
-
Email Module Configuration:
- Update the email server configuration in
config.toml:serverusernamepassword
- Update the email server configuration in
-
AI Module Configuration:
- In
config.toml, configure the following:API_TOKEN: Provide your OpenAI API token.API_URL: Set this tohttps://api.openai.com/v1/chat/completions.
- In
-
Start the Ballerina Server:
- Use the Ballerina extension or run the following command in the project root:
bal run
- Use the Ballerina extension or run the following command in the project root:
Make sure you have installed Ballerina before running the server. You can download Ballerina from here.

