Store Manager is a web application that helps store owners manage sales and product inventory records. This application is meant for use in a single store.
- Admin can add a product.
- Admin/store attendant can get all products
- Admin/store attendant can get a specific product
- Store attendant can add a sale order
- Admin can get all sale records
Step 1
Create directory
$ mkdir store_manager_api
$ cd store_manager_api
create a .env file
touch .env
using the .env_example as an example, add details to the .env file
Create and activate virtual environment
$ virtualenv env -p python3
$ source env/bin/activate
Clone the repository here or
git clone https://github.com/waracci/store_manager_api
Install project dependencies
$ pip install -r requirements.txt
Step 2
No database setup required, the app uses data-structures to store data
Step 3
environment variables are stored in .env file
Step 4
$ flask run
Step 5
$ python manage.py run_tests
| Method | Endpoint | Functionality |
|---|---|---|
| POST | /api/v1/product | Create a product |
| GET | /api/v1/product | Get all products |
| GET | /api/v1/product/productId | Get a single product |
| Method | Endpoint | Functionality |
|---|---|---|
| POST | /api/v1/sales | Create a sales order |
| GET | /api/v1/sales | Get all sales orders |
| GET | /api/v1/sales/salesId | Get a single sales order |