MonkeyBusiness/modules/core/pcbevent.py
2022-11-15 14:03:37 +00:00

20 lines
559 B
Python

from fastapi import APIRouter, Request, Response
from core_common import core_process_request, core_prepare_response, E
router = APIRouter(prefix="/core", tags=["pcbevent"])
@router.post("/{gameinfo}/pcbevent/put")
async def pcbevent_put(request: Request):
request_info = await core_process_request(request)
response = E.response(
E.pcbevent(
expire=600,
)
)
response_body, response_headers = await core_prepare_response(request, response)
return Response(content=response_body, headers=response_headers)