blob: 1b5b4047ddb23d1da11a29ba56040fe5e19f6a4f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
"""
Index route for the forms API.
"""
from starlette.responses import JSONResponse
from backend.route import Route
class IndexRoute(Route):
"""
Return a generic hello world message with some information to the client.
Can be used as a healthcheck for Kubernetes or a frontend connection check.
"""
name = "index"
path = "/"
def get(self, request):
return JSONResponse({
"message": "Hello, world!",
"client": request.client.host
})
|