It is a corruption reporting platform that enables any/every citizen to bring any form of corruption to the notice of appropriate authorities and the general public. Users can also report on things that needs government intervention.
Clone the project
git clone https://github.com/Curti-s/ireporter-api.git
You require a python virtual environment. Use venv module provided by python
python -m venv venv
Source the .env file that contains the project's settings and automatically creates a
virtual environment
source .env
Install the project dependecies using the requirements file
pip install -r requirements.txt
Run the flask application
flask run
Test the red-flag api endpoints using postman or curl. HTTP methods allowed GET POST PUT DELETE
`Use the following routes:
localhost:5000/ **POST** create a new red-flag
localhost:5000/ **GET** all red-flags
localhost:5000/redflag/ **POST** create a red-flag
localhost:5000/redflag/ **GET** get all red-flags
localhost:5000/redflag/id **GET** a specific red-flag
localhost:5000/redflag/id **PUT** update the location of a specific red-flag
localhost:5000/redflag/id **DELETE** delete a specific red-flag
`
Use pytest to run the tests
pytest tests/
Change the FLASK_ENV
variable value to production
FLASK_ENV=production
and source the environment
source .env
This project is licensed under the MIT License - see the LICENSE.md file for details