21 lines
299 B
Python
21 lines
299 B
Python
from fastapi import FastAPI
|
|
|
|
app = FastAPI()
|
|
|
|
@app.get("/")
|
|
def root():
|
|
return {"message": "Pozdrav svijete"}
|
|
|
|
@app.get("/info")
|
|
def info():
|
|
return {
|
|
"python": platform.python_version(),
|
|
"verzija": "2.0"
|
|
}
|
|
|
|
|
|
|
|
@app.get("/health")
|
|
def health():
|
|
return {"status": "ok"}
|