Skip to content

Commit

Permalink
feat: add HEAD route for '/' to support status checks (#835)
Browse files Browse the repository at this point in the history
  • Loading branch information
dahifi committed Mar 28, 2024
1 parent 407adef commit 205305d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions backend/chainlit/server.py
Expand Up @@ -743,6 +743,11 @@ async def get_logo(theme: Optional[Theme] = Query(Theme.light)):
return FileResponse(logo_path, media_type=media_type)


@app.head('/')
def status_check():
return {"message": "Site is operational"}


def register_wildcard_route_handler():
@app.get("/{path:path}")
async def serve(request: Request, path: str):
Expand Down

0 comments on commit 205305d

Please sign in to comment.