A Dockerized Hotel Reservation System built with Django, offering REST APIs for user management, room reservations, payments, and check-ins/check-outs. This project provides seamless Swagger and Insomnia documentation support for developers.
- User Management: Register, login, change password, and manage user profiles.
- Room Management: Add, update, and view room details.
- Customer Management: Add, update, and view customer details.
- Booking System: Manage bookings with real-time check-in/check-out functionality.
- Payment System: Record and track payments.
- API Documentation:
- Swagger: Interactive API documentation available at
http://localhost:8010/swagger/
. - Insomnia: Pre-configured API workspace for testing.
- Swagger: Interactive API documentation available at
Ensure the following are installed on your system:
- Python 3.x
- Docker and Docker Compose
-
Clone the repository:
git clone https://github.com/shiningflash/django-reservation-system.git cd django-reservation-system
-
Copy the
.env.example
file and create a.env
file, and adjust the values accordingly. -
Build and run the application using Docker:
docker-compose up --build
-
Access Swagger documentation:
-
Manage migrations:
docker exec -it reservationsystem_app_1 bash python3 manage.py makemigrations python3 manage.py migrate python3 manage.py createsuperuser
- Register Admin:
POST /api/account/register
- Login:
POST /api/account/login
- Change Password:
PUT /api/account/change-password
- Password Reset:
- Request:
POST /api/password_reset/
- Confirm:
POST /api/password_reset/confirm/
- Request:
- List Customers:
GET /api/customer/
- Add Customer:
POST /api/customer/
- Update Customer:
PATCH /api/customer/<id>/
- List Rooms:
GET /api/room/
- Add Room:
POST /api/room/
- Update Room:
PATCH /api/room/<id>/
- List Bookings:
GET /api/booking/
- Add Booking:
POST /api/booking/
- Check-in:
PATCH /api/booking/<id>/checkin/
- Check-out:
PATCH /api/booking/<id>/checkout/
- List Payments:
GET /api/payment/
- Add Payment:
POST /api/payment/
To run the tests, execute:
docker exec -it reservationsystem_app_1 bash
python3 manage.py test
- Backend: Django, Django REST Framework
- Containerization: Docker, Docker Compose
- Database: PostgreSQL
- Documentation: Swagger, Insomnia
- CI/CD: Github Actions
We welcome contributions! Please follow the steps below:
- Fork the repository.
- Create a new feature branch:
git checkout -b feature/your-feature-name
. - Commit your changes:
git commit -m "Add some feature"
. - Push to the branch:
git push origin feature/your-feature-name
. - Open a pull request.
This project is licensed under the MIT License.
For more details, reach out to:
- Email: [email protected]