<!-- GENERATED by scripts/build-docs.mjs from the live Commander tree (src/cli/program.ts). Do not edit by hand. -->

# pai task

> Task bus: list, add, dispatch, and complete cross-session work

**Aliases:** `tasks`

## Synopsis

```
pai task <subcommand> [options]
```

## Subcommands

| Command | Description |
|---------|-------------|
| [`pai task projects`](#pai-task-projects) | Show which sessions can be given work from the tracker, and create the missing projects |
| [`pai task list`](#pai-task-list) | List open tasks on the bus |
| [`pai task add <title>`](#pai-task-add-title) | File a task onto the bus |
| [`pai task dispatch`](#pai-task-dispatch) | Hand open tasks to the PAI sessions that own them |
| [`pai task poll`](#pai-task-poll) | One scheduler tick: dispatch what is due, check what is running, report |
| [`pai task schedule`](#pai-task-schedule) | Install, remove or inspect the launchd agent that ticks the scheduler |
| [`pai task config`](#pai-task-config) | View or change task bus settings without running the full setup wizard |
| [`pai task archive <id>`](#pai-task-archive-id) | Save a task's discussion into the owning project's notes, without completing it |
| [`pai task done <id>`](#pai-task-done-id) | Mark a task complete on the tracker, keeping its discussion |

### pai task projects

Show which sessions can be given work from the tracker, and create the missing projects

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--create <names...>` | Create tracker projects for these session names |  |
| `--create-all` | Create a project for every session that has none |  |


### pai task list

List open tasks on the bus

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--owner <project>` | Only tasks owned by this PAI project |  |
| `--due <date>` | Only tasks due on or before this ISO date |  |
| `--today` | Shorthand for --due <today> |  |
| `--routed` | Hide tasks with no resolved owner |  |
| `--limit <n>` | Maximum tasks to show |  |


### pai task add <title>

File a task onto the bus

**Arguments**

| Argument | Kind |
|----------|------|
| `<title>` | required |

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--owner <project>` | PAI project that owns this (adds a pai: label) |  |
| `--body <text>` | Full procedure and reasoning — not just a restatement of the title |  |
| `--due <when>` | Due date: ISO, natural language, or a recurrence ("every monday at 9") |  |
| `--priority <p>` | p1 (highest) … p4 (default) |  |
| `--url <url>` | Reference — prefer a hook:// URL over a file path |  |
| `--into <sub-project>` | File into this sub-project under the bus root, creating it if absent |  |


### pai task dispatch

Hand open tasks to the PAI sessions that own them

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--owner <project>` | Only dispatch tasks for this project |  |
| `--today` | Only tasks due today or overdue |  |
| `--dry-run` | Report what would happen without contacting any session |  |
| `--no-spawn` | Never launch a session; skip owners that are not running |  |


### pai task poll

One scheduler tick: dispatch what is due, check what is running, report

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--dry-run` | Show what would happen without touching anything |  |


### pai task schedule

Install, remove or inspect the launchd agent that ticks the scheduler


### pai task schedule install

Install the scheduler tick (default: every 15 minutes)

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--interval <secs>` | Seconds between ticks |  |


### pai task schedule uninstall

Remove the scheduler agent


### pai task schedule status

Show whether the scheduler agent is installed and loaded


### pai task config

View or change task bus settings without running the full setup wizard

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--token` | Prompt for the Todoist API token (input is hidden) |  |
| `--from-env` | Adopt the token from TODOIST_API_KEY in the environment |  |
| `--project <id>` | Tracker project ID that roots the bus (an ID, never a name) |  |
| `--findings <id>` | Section ID for the findings inbox |  |
| `--timeout <secs>` | Seconds a single dispatch may take |  |
| `--auto-dispatch <bool>` | Hand tasks to owning sessions automatically (true/false) |  |
| `--disable` | Turn the task bus off without discarding its settings |  |


### pai task archive <id>

Save a task's discussion into the owning project's notes, without completing it

**Arguments**

| Argument | Kind |
|----------|------|
| `<id>` | required |

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--quiet` | Print nothing (for hook and webhook callers) |  |
| `--no-notify` | Do not tell the owning session where the file landed |  |


### pai task done <id>

Mark a task complete on the tracker, keeping its discussion

**Arguments**

| Argument | Kind |
|----------|------|
| `<id>` | required |

**Options**

| Option | Description | Default |
|--------|-------------|---------|
| `--no-archive` | Complete without saving the comment thread |  |


## See also

[`pai audit`](audit.md) · [`pai backup`](backup.md) · [`pai clear-names`](clear-names.md) · [`pai config`](config.md) · [`pai daemon`](daemon.md) · [`pai db`](db.md) · [`pai end`](end.md) · [`pai help`](help.md) · [`pai identity`](identity.md) · [`pai kg`](kg.md) · [`pai launch`](launch.md) · [`pai mcp`](mcp.md) · [`pai memory`](memory.md) · [`pai notify`](notify.md) · [`pai observation`](observation.md) · [`pai obsidian`](obsidian.md) · [`pai pause`](pause.md) · [`pai project`](project.md) · [`pai projects`](projects.md) · [`pai registry`](registry.md) · [`pai restore`](restore.md) · [`pai session`](session.md) · [`pai sessions`](sessions.md) · [`pai setup`](setup.md) · [`pai shell-init`](shell-init.md) · [`pai skill`](skill.md) · [`pai topic`](topic.md) · [`pai update`](update.md) · [`pai worker`](worker.md) · [`pai zettel`](zettel.md)

Run `pai help <area>` to read any of these in the terminal.

