This is a pharmacy marketplace where users can buy and sell drugs. The application is built using Django and Django Rest Framework.
- Users can register and login in 3 roles:
admin
,seller
,buyer
- Admin can add, update, delete drugs
- Seller can add, update, delete drugs
- Buyer can view drugs and buy drugs
- Buyer can view order history
- Buyer can view order details
- Buyer can cancel order
- Django
- Django Rest Framework
- Docker
- Docker Compose
- Django Rest Framework Simple JWT
- drf-yasg
- Redis
- Django Cors Headers
- Clone the repository
git clone https://github.com//Diyarbekoralbaev/Pharmacy-Marketplace.git
- Change directory
cd Pharmacy-Marketplace
- Run the application
docker-compose up --build
- Create superuser
docker-compose exec web python manage.py createsuperuser
- Access the application at
http://localhost:8000
- Access the admin panel at
http://localhost:8000/admin
- Access the Swagger documentation at
http://localhost:8000/swagger
- Access the Redoc documentation at
http://localhost:8000/redoc
- GET
/users/
- Get all users - POST
/users/signup/
- Register user - POST
/users/login/
- Login user - GET
/users/me/
- Get current user - PUT
/users/me/
- Update current user - POST
/users/change-password/
- Change password (current user) - POST
/users/forgot-password/
- Forgot password (send email) - POST
/users/reset-password/
- Reset password (via otp code sent to email) - GET
/users/{id}/
- Get user by id - PUT
/users/{id}/
- Update user by id - DELETE
/users/{id}/
- Delete user by id
- GET
/drugs/
- Get all drugs - POST
/drugs/create/
- Create drug - GET
/drugs/{id}/
- Get drug by id - PUT
/drugs/update/{id}/
- Update drug by id - DELETE
/drugs/delete/{id}/
- Delete drug by id - GET
/drugs/categories/
- Get all drug categories - GET
/drugs/my_drugs/
- Get all drugs created by current user
- GET
/users/orders/
- Get all orders created by current user - POST
/users/orders/
- Create order - GET
/users/orders/{id}/
- Get order by id - PUT
/users/orders/{id}/
- Update order by id - DELETE
/users/orders/{id}/
- Delete order by id - POST
/users/orders/items/
- Delete item from order
This project is open-sourced software licensed under the MIT license.
- Django
- Django Rest Framework
- Docker
- Docker Compose
- Django Rest Framework Simple JWT
- drf-yasg
- Redis
- Django Cors Headers
Contributions are welcome! Fork the repository and create a pull request to contribute.
For support, contact me from the links provided above.