A sample backend for the kro test made with FastAPI
These instructions will get your copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
What things you need to install the software and how to install them:
- Python 3.8 or higher
- pip (Python package installer)
- PostgreSQL (Neon PostgreSQL if you're using Neon for cloud-based database)
A step-by-step series of examples that tell you how to get a development environment running:
-
Clone the repository
git clone https://github.com/isaaccodekill/kro-backend.git
-
Navigate to the project directory
cd kro-backend
-
Create a virtual environment
python -m venv venv source venv/bin/activate # for linux or mac source venv\Scripts\activate # for windows
-
Install the required packages
pip install -r requirements.txt
-
Create a
.env
file in the root directory of the project and add the following environment variables:DATABASE_URL=postgresql://username:password@localhost:5432/kro
-
Run the fastapi server
uvicorn app.main:app --reload
-
Navigate to
http://127.0.0.1:8000/docs
in your browser to view the API documentation