Spaces:
Sleeping
Sleeping
fix: root endpoint
Browse files- server/app.py +12 -0
server/app.py
CHANGED
|
@@ -20,6 +20,18 @@ app = create_app(
|
|
| 20 |
)
|
| 21 |
|
| 22 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23 |
def _resolve_cli_args(
|
| 24 |
default_host: str = "0.0.0.0",
|
| 25 |
default_port: int = 8000,
|
|
|
|
| 20 |
)
|
| 21 |
|
| 22 |
|
| 23 |
+
@app.get("/")
|
| 24 |
+
def root() -> dict[str, object]:
|
| 25 |
+
"""Provide a simple 200 OK landing response for Space health checks."""
|
| 26 |
+
return {
|
| 27 |
+
"name": "invoiceops_env",
|
| 28 |
+
"status": "ok",
|
| 29 |
+
"openenv": True,
|
| 30 |
+
"docs": "/docs",
|
| 31 |
+
"health": "/health",
|
| 32 |
+
}
|
| 33 |
+
|
| 34 |
+
|
| 35 |
def _resolve_cli_args(
|
| 36 |
default_host: str = "0.0.0.0",
|
| 37 |
default_port: int = 8000,
|