Initial commit
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
from datetime import datetime
|
||||
from fastapi import APIRouter, status, HTTPException
|
||||
|
||||
routes = APIRouter(prefix="", tags=['Miscellaneous'])
|
||||
|
||||
@routes.api_route('/', methods=['GET', 'POST', 'PUT', 'DELETE'], status_code=status.HTTP_400_BAD_REQUEST)
|
||||
def RootPathLocked():
|
||||
pass
|
||||
|
||||
@routes.get('/isalive', status_code=status.HTTP_200_OK)
|
||||
def CheckServerRunning():
|
||||
now = datatime.now().strftime('%Y-%m-%d %H:%M:%S')
|
||||
return {'data': f'Last server update: {now}'}
|
||||
Reference in New Issue
Block a user