Simple REST API that returns a "Hello World" message in JSON.
171
This is a project built in Python using Flask to provide a simple REST API that returns a "Hello World" message in JSON format.
A list of technologies used within the project:
There are two methods to install this project.
Verify you are python version 3.12.0
python --version
Copy the repository
git clone https://github.com/nava2105/py_restapi.git
Enter the directory
cd ../py_restapi
Create a virtual environment
python -m venv .venv
Activate your virtual environment
.venv\Scripts\activate
In macOS or Linux
source .venv/bin/activate
Build the dependencies
pip install -r requirements.txt
Run main.py file
python main.py
python3 main.py
Open a browser and enter to http://localhost:5000
Or to review the endpoints in Swagger enter to http:localhost:5000/apidocs
Pull the image from Docker-hub
docker pull na4va4/py_restapi
Start a container from the image
docker run -p 5000:5000 na4va4/py_restapi
Open a browser and enter to http://localhost:5000
Or to review the endpoints in Swagger enter to http:localhost:5000/apidocs
Content type
Image
Digest
sha256:a9ba08f65…
Size
373.9 MB
Last updated
almost 2 years ago
docker pull na4va4/py_restapi