Skip to content
LogoLogo

Apply the canonical completion action to a Task

Apply the canonical completion action to a Task

POST/api/v1/cli/tasks/{task_code}/done

Applies the Project completion policy in one idempotent, revision-checked, audited transaction. When review is required, an active Task enters the default review Status and only an authorized reviewer can invoke this operation again to enter the default done Status. Definition-of-Done and transition guards remain server-owned. The completing Status comes from the lifecycle completion rule: one applicable Status that counts as completed is used directly; several answer 409 completion_target_required with the choices (LifecycleCompletionChoices) until the caller sends target_status_id. A Status that does not count as completed answers 422 completion_target_invalid.

Path Parameters

task_codeRequired
string·min 4·max 28

Case-insensitive UI-equivalent Task code (PROJECT_KEY-TASK_NUMBER, for example PRO-123), normalized to uppercase before lookup.

Query Parameters

target_status_id
string <uuid>

Explicit completing Status; required when several Statuses count as completed.

Header Parameters

Idempotency-KeyRequired
string·min 16·max 200

Opaque client-generated key for safely retrying this operation.

If-MatchRequired
string

Entity tag containing the resource version last observed by the client.

Responses