Skip to main content

scheduler

Registered module. One agent tool: schedule.

At each cron fire, digitorn-background re-runs this session with an injected user message. The agent keeps accumulated session context. Schedules are durable across restarts.

Not for building a standalone timer app. scheduler schedules a wake-up of the current chat session — a "remind me every morning" inside a conversation. To build an autonomous app that runs on a schedule (a background app that does X every minute/hour/day), do NOT grant this module: use a cron channel on a runtime.mode: background app instead — see Channels. Rule of thumb: an app on a timer → mode: background + a cron channel; a reminder inside a chat → scheduler.

PropertyValue
Module idscheduler
Version1.0.0
Toolsschedule
Blank-imported bycmd/digitornd

Enable in an app​

yaml
tools:
modules:
scheduler: {}
capabilities:
grant:
- module: scheduler

Optional module config (also overridable via env):

FieldDefault / envMeaning
background_urlDIGITORN_BG_URL or http://127.0.0.1:8090Background ops base URL
ops_tokenDIGITORN_BG_OPS_TOKENBearer token for ops
default_replyautoDefault reply when the tool omits it

Tool: schedule​

ParamTypeRequiredDescription
schedulestringyes5-field cron: minute hour day-of-month month day-of-week
messagestringyesInstruction injected as the user message each fire
contextstringnoExtra context alongside the message
replystringnoauto, none, or stream
reportsbooleannoDated downloadable folder per run under attachments

Example cron strings: 0 9 * * * (09:00 daily), */15 * * * * (every 15 minutes), 0 9 * * 1-5 (weekdays 09:00).

The handler POSTs to {background_url}/ops/schedules with app_id, session_id, owner, and the params above. On success it returns confirmation and metadata (id, next_run, schedule).

schedule takes a recurring 5-field cron expression and a session message - it is not a one-shot when: "in 5m" / ISO-timestamp scheduler.

For app-level channel cron / webhook triggers, see Channels. For HTTP schedule management outside the agent, use the automations / background ops API.