Skip to content

feat: cron channel targeting + cron management UI page#77

Open
HaoweiChan wants to merge 1 commit intoTraderAlice:masterfrom
HaoweiChan:feat/cron-enhancements
Open

feat: cron channel targeting + cron management UI page#77
HaoweiChan wants to merge 1 commit intoTraderAlice:masterfrom
HaoweiChan:feat/cron-enhancements

Conversation

@HaoweiChan
Copy link

Summary

  • Add optional channel field to cron jobs, allowing each job to deliver results to a specific connector (e.g. "telegram", "web") instead of always using last-interacted channel. Propagated through CronJobCronFirePayloadCronListenerConnectorCenter.
  • Add full Cron Jobs UI page (/cron): job listing with status badges, create/edit modal, enable/disable toggle, run-now trigger, delete with confirmation, and recent cron events table.
  • Add channel support to cron AI tools (cronAdd, cronUpdate) and API routes.

Changes

Backend

  • src/task/cron/engine.ts: channel field on CronJob, CronJobCreate, CronJobPatch, CronFirePayload
  • src/task/cron/listener.ts: Pass channel to connectorCenter.notify()
  • src/task/cron/tools.ts: channel param on cronAdd and cronUpdate tools
  • src/connectors/web/routes/cron.ts: Accept channel in POST body
  • src/core/connector-center.ts: channel option in NotifyOpts, targeted delivery in notify() and notifyStream()

Frontend

  • ui/src/pages/CronPage.tsx: New page with full CRUD, run-now, events table
  • ui/src/App.tsx: Route registration for /cron
  • ui/src/components/Sidebar.tsx: Navigation entry with clock icon
  • ui/src/api/cron.ts: channel param support in add() and update()
  • ui/src/api/types.ts: channel field on CronJob interface

OpenSpec

  • openspec/specs/cron-channel-targeting/spec.md
  • openspec/specs/cron-ui-page/spec.md

Test plan

  • Verify cron jobs page loads at /cron and lists existing jobs
  • Create a new cron job with channel targeting (e.g. "telegram")
  • Edit an existing job, toggle enable/disable
  • Run a job manually and verify output reaches the targeted channel
  • Delete a non-heartbeat job
  • Verify heartbeat job cannot be deleted
  • Verify recent cron events display correctly

Made with Cursor

Add optional `channel` field to cron jobs enabling delivery to a specific
connector (e.g. "telegram", "web") instead of always using last-interacted.
Propagated through CronJob → CronFirePayload → CronListener → ConnectorCenter.

Add full CronPage UI: job listing, create/edit modal, enable/disable toggle,
run-now, delete with confirmation, and recent cron events table.

Includes OpenSpec specs for both features.

Made-with: Cursor
@HaoweiChan HaoweiChan force-pushed the feat/cron-enhancements branch from ab81296 to 5b42989 Compare March 20, 2026 03:37
@HaoweiChan HaoweiChan marked this pull request as ready for review March 20, 2026 03:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant