一键导入
cron
Schedule any registered function on a 6- or 7-field cron expression with the standalone cron worker. Its whole surface is the `cron` trigger type.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Schedule any registered function on a 6- or 7-field cron expression with the standalone cron worker. Its whole surface is the `cron` trigger type.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Run Unix commands and structured filesystem ops from the iii engine: exec, background jobs, and a structured fs (ls/stat/mkdir/rm/chmod/mv/grep/sed/ read/write, jailed only if fs.host_roots is configured), all forwardable into a sandbox microVM.
Shared, adapter-backed key/value store addressed by scope and key, with a reactive `state` trigger so other functions can run on every create, update, or delete without polling.
Durable topic queues for iii: subscribe functions to topics, publish work asynchronously, retry failed deliveries with backoff, and inspect/redrive dead-lettered messages.
Mint isolated git worktrees for parallel agent work, track ownership in a cross-agent registry, and land finished branches back onto a target with a queued rebase, test gate, and atomic fast-forward merge.
Connect this engine to another iii engine over a long-lived WebSocket so functions call across the boundary. Wire stable ids with `forward:`/`expose:`; `bridge.invoke` is the ad-hoc escape hatch.
Drive Devin over the iii bus. Run the local Devin CLI agent (SWE-1.6) with the iii runtime context so it discovers and operates your mesh, or start and steer autonomous Devin cloud sessions through the REST API, with a passthrough to any Devin v1/v3 endpoint.
| name | cron |
| tags | cron, scheduling, triggers, jobs |
| description | Schedule any registered function on a 6- or 7-field cron expression with the standalone cron worker. Its whole surface is the `cron` trigger type. |
The cron worker schedules registered functions to run on recurring cron
expressions. It exposes no callable cron::* functions; its entire surface is
the cron trigger type, bound through a worker SDK trigger registration such
as iii.registerTrigger({ type: 'cron', function_id, config }).
Install it with iii worker add cron. The engine builtin iii-cron must not
run on the same engine because it also owns the cron trigger type. Remove
iii-cron from the engine config before starting this worker; the standalone
worker refuses to boot when the builtin is active.
On every firing, the worker optionally evaluates a condition function, acquires
a lock through the configured backend, and invokes the target function with an
event payload containing trigger, job_id, scheduled_time, and
actual_time. scheduled_time and actual_time let handlers observe drift
without querying the scheduler.
The schedule grammar is the Rust cron crate dialect: six or seven fields,
second minute hour day-of-month month day-of-week [year]. The year field is
optional. The leading field is always seconds, so 0 */5 * * * * fires every
5 minutes at second 0, while */5 * * * * * fires every 5 seconds.
Two lock backends govern duplicate firing. local is the default and is only
process-local; every worker instance can fire the same job in a multi-instance
deployment. redis uses Redis locking and is required for once-only firing
across a fleet. The lock TTL is 30 seconds.
redis lock
backend.condition_function_id, without putting the condition inside the handler.cron::*; bind the cron
trigger type to one of your own functions.local backend is process-local. Do not rely on it for once-only
jobs in a multi-instance deployment.false.
Truthy, null, or missing results allow the fire; condition errors skip that
fire.cron fires on the clock only.Bind a cron trigger when a handler should run on a recurring schedule. The
handler runs through the engine as a normal function invocation. With the
redis backend, only one worker instance should own a scheduled fire across
the fleet.
Reach for it when:
condition_function_id and the worker
evaluates it before each run.job_id payload field.iii.registerFunction('jobs::cleanup-old-data', handler).iii.registerTrigger({
type: 'cron',
function_id: 'jobs::cleanup-old-data',
config: {
expression: '0 0 2 * * * *', // sec min hour dom month dow [year]; daily at 02:00:00 UTC.
// condition_function_id is optional.
},
})
expression is required and must parse. Bind one function_id to several
triggers with distinct trigger ids to drive multiple schedules into one
handler; the trigger id arrives as job_id in the event. The handler's return
value is ignored.
Event payload:
{
"trigger": "cron",
"job_id": "<trigger-id>",
"scheduled_time": "2026-07-03T12:00:00+00:00",
"actual_time": "2026-07-03T12:00:00.123456789+00:00"
}
Configure the lock backend through the central configuration entry for worker
cron:
adapter:
name: redis
config:
redis_url: redis://localhost:6379
Use adapter.name: local for single-process development and
adapter.name: redis for multi-instance once-only scheduling.