Add /api/system/briefing/force endpoint to trigger morning briefing on demand

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
fix/customer-field-migration
PeninsulaInd 2026-03-04 22:30:46 -06:00
parent 6b5d0ac71e
commit ca73689099
1 changed files with 9 additions and 0 deletions

View File

@ -562,6 +562,15 @@ async def force_loop_run():
return {"status": "ok", "message": "Force pulse sent to heartbeat and poll loops"}
@router.post("/system/briefing/force")
async def force_briefing():
"""Force the morning briefing to send now (won't block tomorrow's)."""
if not _scheduler:
return {"status": "error", "message": "Scheduler not available"}
_scheduler.force_briefing()
return {"status": "ok", "message": "Briefing force-triggered"}
@router.post("/cache/clear")
async def clear_cache():
"""Clear the ClickUp data cache."""