Welcome to the Fastcommerce Template! ๐ This template provides a robust foundation for building e-commerce applications using FastAPI, a modern and fast web framework for building APIs with Python 3.9+.
- Python 3.9+
- Pip
-
Clone the repository:
git clone https://github.com/NotThorz/Fastcommerce.git cd Fastcommerce
-
Create a virtual environment and install dependencies:
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate pip install -r requirements.txt
-
Make sure you created the .env file using the .env.template as an example to connect the postgresSQL database
-
Run the FastAPI application:
uvicorn app.main:app --reload
-
Access the APIs:
Explore the various API endpoints for managing users, products, and orders as outlined below:
- Create User:
POST /users/
- Get User:
GET /users/{id}
- Update User:
PUT /users/{id}
- Delete User:
DELETE /users/{id}
- Login:
POST /login
- Get Products:
GET /products/
- Create Product:
POST /products/
- Get Product:
GET /products/{id}
- Update Product:
PUT /products/{id}
- Delete Product:
DELETE /products/{id}
- Mass Create Products:
POST /products/mass-create
- Get Orders:
GET /orders/
- Create Order:
POST /orders/
- Get Order:
GET /orders/{id}
- Update Order:
PUT /orders/{id}
- Delete Order:
DELETE /orders/{id}
- Default route.
Feel free to customize and extend this template to meet the specific requirements of your e-commerce project. If you encounter any issues or have suggestions for improvements, please don't hesitate to open an issue or contribute to the repository.
Happy coding! ๐