It's a python fastAPI web API.
fastAPI comes with an out of the box openapi doc feature. It's available under:
- http://localhost:8000/docs when you run it locally
- as a json: openapi.json copy & paste it for example to: https://editor.swagger.io/
- python version 3.11 installed
- pipenv
pipenv install --dev
- Fill the content from .env.
- Run
pipenv run uvicorn app.main:app --reload
- The server is listen on http://localhost:8000 and has an endpoint ui on: http://localhost:8000/docs
.vscode/launch.json::
{
"version": "0.2.0",
"configurations": [
{
"name": "Run & debug",
"type": "python",
"request": "launch",
"module": "uvicorn",
"args": ["app.main:app", "--reload"]
}
]
}
.vscode/settings.json:
{
"python.defaultInterpreterPath": "/Users/(your username)/.local/share/virtualenvs/(the created virtualenvs folder)/bin/python",
"python.envFile": "${workspaceFolder}/.env",
}