Tools reference: tasks
On this page
List, read, run, propose, follow, stop, pause and archive the tasks of a context.
These 13 tools are part of Cortex control. They let a session work with the tasks of its own context. They never delete a task. The tools a task run is given for itself are on Tools for minis and task runs. For the whole list, see Cortex tools reference.
Who can call them. Every session Cortex starts while Cortex control is on in Settings → MCP. A task run is not given them: a task does not start tasks. An applet can call them with cortex.tools.call, if its manifest lists them and its configuration names a context.
Naming a task. A task is found by its id, else by its title in the session's context. A title that two tasks share is refused, with their ids.
Schedules. schedule takes now (saved, run when you say), at (with a date-time in at, ISO 8601) or a five-field cron expression in local time, at most every 5 minutes.
Try it
You don't call these tools yourself: you ask in your own words, in a session, and the agent picks the tools. Saying with Cortex or naming what you want to see (a view, a tab, the Stack) makes it reach for them.
| You type | What the agent uses |
|---|---|
| Every Monday at 8, summarise last week's support tickets into a report | task_create with a schedule |
| Run the supplier check task now and wait for it | task_run, task_wait |
| What did the last run of the weekly report find? | task_runs, task_read |
| Pause the price-watch task until next month | task_pause |
Look
task_list
The tasks of this context: id, title, the objective's first line, the minis (lead first), the schedule in words, status, the last run (start, status) and the next run. Archived tasks are listed too. This context only. No parameters. Read-only.
task_read
A task whole, with its objective, minis, schedule, access and commands, and its last run's status and report (cut at 8 000 characters). Read-only.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
task_runs
A task's runs, newest first: id, start, status, duration and the report's first line, with skipped and missed lines. With run, one run whole: status, why it ended, its worker, its outputs and its report (cut at 20 000 characters). Read-only.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
last |
integer | no | How many runs. Default 10, at most 50. |
run |
string | no | A run's id, for that run whole. |
task_activity
What a run did, step by step, oldest first: its start and why, each tool call by name with its duration (never its input), each consult, each question and permission ask and how it ended, progress lines, failures and the end. Read-only.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
run |
string | no | A run's id from task_runs. Default the run going on, else the last one. |
last |
integer | no | Only the latest lines. Default 100, at most 500. |
task_wait
Waits until a run has ended or waits for you. Read-only.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
run |
string | no | A run id that task_run returned. Default the task's run going on. |
timeout |
integer | no | Seconds. Default 300, at most 600. |
Returns. The run's status, its report's first line and whether it timed out.
Run and stop
task_run
Runs a task now, in the background, as your Run Now does. A task that already has a run going is refused, naming that run.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
Returns. The run's id. task_read or task_runs give its report later. Asking. Each time, with Allow for This Session.
task_stop
Stops a run this session started with task_run. The run is asked for its report first. Any other run is refused. It does not ask, since the run is the session's own.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
Propose and change
task_create
Proposes a new task in this context. Cortex shows it to you, every time, and you save it or decline. The question starts with anything its runs would do without asking you.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
title |
string | yes | A few words. |
objective |
string | yes | Markdown: what to achieve, what done means, what to avoid. |
minis |
array of strings | no | Aliases from your library, the first leads. None means the context's default account. |
schedule |
string | no | now, at or a cron expression. |
at |
string | for at |
An ISO 8601 date-time. |
access |
string | no | readOnly, ask (default) or editFreely: how its runs may write this context. |
commands |
string | no | ask or auto. Default: the account's setting for new tasks. |
ifMissed |
string | no | runOnce (default) or skip: a repeating task's runs that were due while Cortex was not running. |
notify |
string | no | failures, always or never. |
{ "title": "Weekly dependency check", "objective": "List outdated packages and propose upgrades. Do not change files.", "schedule": "0 9 * * 1" }
task_update
Proposes changes to a task: any of its title, objective, minis (replacing the list) and schedule. Its access, commands, limits, attachments and output folder are yours alone. Cortex shows you what changes, and you save or decline. A run going on keeps what it started with.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
title |
string | no | A few words. |
objective |
string | no | Markdown. |
minis |
array of strings | no | Aliases, the lead first. Empty means the context's default account. |
schedule |
string | no | now, at or a cron expression. |
at |
string | for at |
An ISO 8601 date-time. |
Pause and archive
Each of these asks you, each time, with Allow for This Session. Each is allowed for itself: allowing pauses does not allow resumes.
task_pause
Pauses a task's schedule, so it no longer starts by itself. Your Run Now still works.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
task_resume
Resumes a paused schedule from now on. What fell due while it was paused is not caught up.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
task_archive
Archives a task: it plans no run and leaves your lists, but task_list still lists it. A run going on goes on. Its runs and reports are kept.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
task_unarchive
Brings an archived task back. Its schedule plans again from now. A one-off whose time passed meanwhile does not run.
| Parameter | Type | Required | Meaning |
|---|---|---|---|
task |
string | yes | A task's id or title. |
Something wrong or missing? Tell us