Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -250,7 +250,7 @@ async def home():
|
|
250 |
return HTMLResponse(content=html_content.replace("{{ status }}", status), status_code=200)
|
251 |
|
252 |
# Endpoint to receive JSON data to start/stop the email processing loop
|
253 |
-
@app.
|
254 |
async def control_email_loop(action: ActionModel,data: ModelData):
|
255 |
global running, loop_thread
|
256 |
logger.info(action.action)
|
|
|
250 |
return HTMLResponse(content=html_content.replace("{{ status }}", status), status_code=200)
|
251 |
|
252 |
# Endpoint to receive JSON data to start/stop the email processing loop
|
253 |
+
@app.get("/control", response_class=HTMLResponse)
|
254 |
async def control_email_loop(action: ActionModel,data: ModelData):
|
255 |
global running, loop_thread
|
256 |
logger.info(action.action)
|