> ## Documentation Index
> Fetch the complete documentation index at: https://docs.controlplane.com/llms.txt
> Use this file to discover all available pages before exploring further.

# task

> cpln task — Manage pending tasks that require approval or manual intervention.

Manage pending tasks

```none theme={null}
cpln task [SUBCOMMAND]
```

```text theme={null}
Commands:
  cpln task complete <ref>     Complete the referenced task
  cpln task delete <ref...>    Delete one or more referenced tasks
  cpln task get [ref...]       Retrieve one or more referenced tasks
  cpln task get-mine [ref...]  Retrieve one or more referenced tasks for the current or overridden profile  [aliases: mine]
  cpln task permissions        Show the grantable permissions for a task object type
  cpln task query              Find all the tasks based on the given query

Options:
  --help  Show help  [boolean]
```

***

#### task complete

Complete the referenced task

**Usage**

```none theme={null}
cpln task complete <ref> --answer {accept|reject} [OPTIONS]
```

> [accordion] Reference
>
> ```text theme={null}
> Positionals:
>   ref  The resource reference. Usually it is the name of the resource.  [required]
>
> Command options:
>   --answer  Accept or reject referenced task  [required] [choices: "accept", "reject"]
>
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***

#### task delete

Delete one or more referenced tasks

**Usage**

```none theme={null}
cpln task delete <ref...> [OPTIONS]
```

> [accordion] Reference
>
> ```text theme={null}
> Positionals:
>   ref  One or more resource references. Usually it is the name of the resource.  [array] [required] [default: []]
>
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>   --org      Override the organization. The default organization can be set in your profile by using the `cpln profile update` command
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***

#### task get

Retrieve one or more referenced tasks

**Usage**

```none theme={null}
cpln task get [ref...] [OPTIONS]
```

> [!NOTE]
>
> An empty reference will return all references

> [accordion] Reference
>
> ```text theme={null}
> Positionals:
>   ref  One or more resource references. Usually it is the name of the resource.  [array] [default: []]
>
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>   --org      Override the organization. The default organization can be set in your profile by using the `cpln profile update` command
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***

#### task get-mine

Retrieve one or more referenced tasks for the current or overridden profile

**Usage**

```none theme={null}
cpln task get-mine [ref...] [OPTIONS]
```

> [!NOTE]
>
> An empty reference will return all tasks for the current or overridden profile

> [accordion] Reference
>
> ```text theme={null}
> Positionals:
>   ref  One or more resource references. Usually it is the name of the resource.  [array] [default: []]
>
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***

#### task permissions

Show the grantable permissions for a task object type

**Usage**

```none theme={null}
cpln task permissions [OPTIONS]
```

> [accordion] Reference
>
> ```text theme={null}
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>   --org      Override the organization. The default organization can be set in your profile by using the `cpln profile update` command
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

> [accordion] Example
>
> ```bash Command theme={null}
> cpln task permissions --org demo-cpln-organization
> ```
>
> ```text Output theme={null}
> +-------+-----------------------------+---------------------------+
> |NAME   |DESCRIPTION                  |IMPLIES                    |
> |-------|-----------------------------|---------------------------|
> |delete |Delete/Cancel existing tasks |                           |
> |edit   |Modify existing tasks        |view                       |
> |manage |Full access                  |delete, edit, manage, view |
> |view   |Read-only access             |                           |
> +-------+-----------------------------+---------------------------+
> ```

***

#### task query

Find all the tasks based on the given query

**Usage**

```none theme={null}
cpln task query QUERY_OPTIONS [OPTIONS]
```

> [accordion] Reference
>
> ```text theme={null}
> Query options:
>   --match             Query filter type  [choices: "all", "none", "any"] [default: "all"]
>   --property, --prop  Property to query
>   --tag               Tag to query
>   --rel               Relation to query
>
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>   --org      Override the organization. The default organization can be set in your profile by using the `cpln profile update` command
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***
