# ccp task



{/* Generated by scripts/sync-cli-reference.ts */}

Delegate and retrieve coding tasks

```text
Usage: ccp task [OPTIONS] <COMMAND>
```

| Argument   | Type or values | Default | Parser environment variable | Description |
| ---------- | -------------- | ------- | --------------------------- | ----------- |
| --help, -h | flag           | —       | —                           | Print help  |

## `ccp task delegate` [#ccp-task-delegate]

Start one detached coding task

```text
Usage: ccp task delegate [OPTIONS] <TASK>
```

| Argument       | Type or values | Default | Parser environment variable | Description                                                                     |
| -------------- | -------------- | ------- | --------------------------- | ------------------------------------------------------------------------------- |
| task           | text           | —       | —                           | Task and acceptance criteria for the remote worker                              |
| --task-context | text           | —       | —                           | Pass relevant decisions or reproduction steps                                   |
| --source       | path           | —       | —                           | Git checkout to share after reviewing its snapshot                              |
| --repo         | text           | —       | —                           | HTTPS GitHub repository to clone at an exact commit                             |
| --commit       | text           | —       | —                           | Full lowercase commit SHA for the remote checkout                               |
| --include      | text           | —       | —                           | Include a nonignored untracked file, relative to the checkout root (repeatable) |
| --worker       | codex          | codex   | —                           | Select a qualified worker runtime                                               |
| --org-id       | text           | —       | —                           | Select the organization paying for the sandbox                                  |
| --vault-id     | text           | —       | —                           | ID of your private Cluster vault holding the worker credential                  |
| --json         | flag           | false   | —                           | Emit the task receipt as JSON                                                   |
| --help, -h     | flag           | —       | —                           | Print help                                                                      |

## `ccp task integrate` [#ccp-task-integrate]

Merge successful tasks from one pinned commit into a new local worktree

```text
Usage: ccp task integrate [OPTIONS] --source <SOURCE> --base <BASE> --branch <BRANCH> --worktree <WORKTREE> <TASK_IDS>...
```

| Argument   | Type or values | Default | Parser environment variable | Description                                |
| ---------- | -------------- | ------- | --------------------------- | ------------------------------------------ |
| task\_ids  | text           | —       | —                           | Successful task IDs to merge, in order     |
| --source   | path           | —       | —                           | Local repository holding the common commit |
| --base     | text           | —       | —                           | Exact shared base commit                   |
| --branch   | text           | —       | —                           | New local integration branch               |
| --worktree | path           | —       | —                           | New worktree for the merged result         |
| --json     | flag           | false   | —                           |                                            |
| --help, -h | flag           | —       | —                           | Print help                                 |

## `ccp task result` [#ccp-task-result]

Read the durable status and download a finished patch

```text
Usage: ccp task result [OPTIONS] <TASK_ID>
```

| Argument   | Type or values | Default | Parser environment variable | Description                   |
| ---------- | -------------- | ------- | --------------------------- | ----------------------------- |
| task\_id   | text           | —       | —                           |                               |
| --patch    | path           | —       | —                           | Write the patch to a new file |
| --json     | flag           | false   | —                           |                               |
| --help, -h | flag           | —       | —                           | Print help                    |

## Example [#example]

```bash
ccp task result "$TASK_ID" --json
```

## Global options [#global-options]

Set `CCP_CONTEXT` to choose a named context. An explicit `--context` takes precedence. See [organization selection](/docs/ccp/organizations) for organization defaults.

| Argument  | Type or values | Default | Parser environment variable | Description                                         |
| --------- | -------------- | ------- | --------------------------- | --------------------------------------------------- |
| --context | text           | —       | —                           | Select a developer context from \~/.ccp/config.toml |
