Tasks
57 methods on the Tasks resource.
57 methods · 40 available to app tokens36 pages in SDK Reference
import { Compozy } from "@compozy/client";57 of 57
addTaskDependencyapproveTaskarchiveTaskattachTaskRunSessionblockTaskbulkForceFailTaskRunsbulkForceReleaseTaskRunscancelTaskcancelTaskRunclearTaskBlockcompleteTaskRuncreateChildTaskcreateTaskdeleteTaskdeleteTaskExecutionProfiledismissTaskdrainSchedulerenqueueTaskRunfailTaskRunfanOutTaskRunsforceFailTaskRunforceReleaseTaskRungetSchedulergetSchedulerBackloggetTaskgetTaskExecutionProfilegetTaskRungetTaskRunReviewgetTaskTimelinegetTaskTreeinspectRuninspectTasklistTaskBlockslistTaskReviewslistTaskRunReviewslistTaskRunslistTasksmarkTaskReadpauseSchedulerpauseTaskpublishTaskreadTaskRunResultrecoverTaskrecoverTaskRunrejectTaskremoveTaskDependencyrequestTaskRunReviewresumeSchedulerresumeTaskretryTaskRunsetTaskExecutionProfilesetTaskWorktreePolicystartTaskstartTaskRunstreamTaskssesubmitTaskRunReviewVerdictupdateTask
addTaskDependency
Add one task dependency
compozy.tasks.addTaskDependency({ path, query, body }) → Promise<TaskDetailResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyAddTaskDependencyRequest
POST /api/tasks/{id}/dependenciesapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.addTaskDependency({ path: { "id": "id" }, body: { /* request fields */ } });approveTask
Approve one approval-gated task and enqueue executable work
compozy.tasks.approveTask({ path, query, body }) → Promise<TaskExecutionResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyTaskExecutionRequest
POST /api/tasks/{id}/approveapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.approveTask({ path: { "id": "id" }, body: { /* request fields */ } });archiveTask
Archive one task inbox item
compozy.tasks.archiveTask({ path, query }) → Promise<TaskTriageStateResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
POST /api/tasks/{id}/triage/archiveapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.archiveTask({ path: { "id": "id" } });attachTaskRunSession
Attach an existing session to one task run
compozy.tasks.attachTaskRunSession({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyAttachTaskRunSessionRequest
POST /api/task-runs/{id}/attach-sessionapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.attachTaskRunSession({ path: { "id": "id" }, body: { /* request fields */ } });blockTask
Create one typed task block
compozy.tasks.blockTask({ path, query, body }) → Promise<TaskBlockResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyCreateTaskBlockRequest
POST /api/tasks/{id}/blocksapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.blockTask({ path: { "id": "id" }, body: { /* request fields */ } });bulkForceFailTaskRuns
Force fail a bounded set of queued or claimed task runs
compozy.tasks.bulkForceFailTaskRuns({ query, body }) → Promise<BulkForceTaskRunResponse>
Options
- profilestringquery
- Act as this profile by name
Request bodyBulkForceTaskRunRequest
POST /api/runs/bulk/failapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.bulkForceFailTaskRuns({ body: { /* request fields */ } });bulkForceReleaseTaskRuns
Force release a bounded set of claimed task runs
compozy.tasks.bulkForceReleaseTaskRuns({ query, body }) → Promise<BulkForceTaskRunResponse>
Options
- profilestringquery
- Act as this profile by name
Request bodyBulkForceTaskRunRequest
POST /api/runs/bulk/releaseapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.bulkForceReleaseTaskRuns({ body: { /* request fields */ } });cancelTask
Cancel one task tree
compozy.tasks.cancelTask({ path, query, body }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyCancelTaskRequest
POST /api/tasks/{id}/cancelapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.cancelTask({ path: { "id": "id" }, body: { /* request fields */ } });cancelTaskRun
Cancel one task run
compozy.tasks.cancelTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyCancelTaskRunRequest
POST /api/task-runs/{id}/cancelapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.cancelTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });clearTaskBlock
Clear one typed task block
compozy.tasks.clearTaskBlock({ path, query, body }) → Promise<TaskBlockResponse>
Options
- idstringpathrequired
- Task id
- block_idstringpathrequired
- Task block id
- profilestringquery
- Act as this profile by name
Request bodyClearTaskBlockRequest
POST /api/tasks/{id}/blocks/{block_id}/clearapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.clearTaskBlock({ path: { "id": "id", "block_id": "block_id" }, body: { /* request fields */ } });Show all 57 methods
completeTaskRun
Complete one running task run
compozy.tasks.completeTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyCompleteTaskRunRequest
POST /api/task-runs/{id}/completeapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.completeTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });createChildTask
Create one child task
compozy.tasks.createChildTask({ path, query, body }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Parent task id
- profilestringquery
- Act as this profile by name
Request bodyCreateTaskChildRequest
POST /api/tasks/{id}/childrenapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.createChildTask({ path: { "id": "id" }, body: { /* request fields */ } });createTask
Create a task
compozy.tasks.createTask({ query, body }) → Promise<TaskResponse>
Options
- profilestringquery
- Act as this profile by name
Request bodyCreateTaskRequest
POST /api/tasksapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.createTask({ body: { /* request fields */ } });deleteTask
Delete one task
compozy.tasks.deleteTask({ path, query }) → Promise<void>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
DELETE /api/tasks/{id}app tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.deleteTask({ path: { "id": "id" } });deleteTaskExecutionProfile
Delete one task execution profile
compozy.tasks.deleteTaskExecutionProfile({ path, query }) → Promise<void>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
DELETE /api/tasks/{id}/execution-profileapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.deleteTaskExecutionProfile({ path: { "id": "id" } });dismissTask
Dismiss one task inbox item
compozy.tasks.dismissTask({ path, query }) → Promise<TaskTriageStateResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
POST /api/tasks/{id}/triage/dismissapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.dismissTask({ path: { "id": "id" } });drainScheduler
Pause the scheduler and wait for active claims to drain
compozy.tasks.drainScheduler({ body }) → Promise<SchedulerDrainResponse>
Request bodySchedulerDrainRequest
POST /api/scheduler/drainapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.drainScheduler({ body: { /* request fields */ } });enqueueTaskRun
Enqueue one task run
compozy.tasks.enqueueTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyEnqueueTaskRunRequest
POST /api/tasks/{id}/runsapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.enqueueTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });failTaskRun
Fail one task run
compozy.tasks.failTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyFailTaskRunRequest
POST /api/task-runs/{id}/failapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.failTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });fanOutTaskRuns
Enqueue designated sibling runs for one task
compozy.tasks.fanOutTaskRuns({ path, query, body }) → Promise<FanOutTaskRunsResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyFanOutTaskRunsRequest
POST /api/tasks/{id}/runs/fan-outapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.fanOutTaskRuns({ path: { "id": "id" }, body: { /* request fields */ } });forceFailTaskRun
Force fail one queued or claimed task run
compozy.tasks.forceFailTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyForceFailTaskRunRequest
POST /api/runs/{id}/failapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.forceFailTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });forceReleaseTaskRun
Force release one claimed task run
compozy.tasks.forceReleaseTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyForceReleaseTaskRunRequest
POST /api/runs/{id}/releaseapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.forceReleaseTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });getScheduler
Get scheduler pause state and queue pressure
compozy.tasks.getScheduler() → Promise<SchedulerStatusResponse>
GET /api/schedulerapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getScheduler();getSchedulerBacklog
List queued scheduler backlog rows
compozy.tasks.getSchedulerBacklog({ query }) → Promise<SchedulerBacklogResponse>
Options
- limitintegerquery
- Maximum number of queued runs to return
- scope"all" | "global" | "workspace" | "user" | "@user"query
- Filter by catalog visibility
- workspacestringquery
- Filter by workspace path, name, or ID
- include_pausedbooleanquery
- Include runs blocked by task pause state
GET /api/scheduler/backlogapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getSchedulerBacklog();getTask
Get one task with detail
compozy.tasks.getTask({ path, query }) → Promise<TaskDetailResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}app tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getTask({ path: { "id": "id" } });getTaskExecutionProfile
Get one task execution profile
compozy.tasks.getTaskExecutionProfile({ path, query }) → Promise<TaskExecutionProfileResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/execution-profileapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getTaskExecutionProfile({ path: { "id": "id" } });getTaskRun
Get one task run detail
compozy.tasks.getTaskRun({ path, query }) → Promise<TaskRunDetailResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/task-runs/{id}app tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getTaskRun({ path: { "id": "id" } });getTaskRunReview
Get one task-run review
compozy.tasks.getTaskRunReview({ path, query }) → Promise<TaskRunReviewResponse>
Options
- idstringpathrequired
- Review id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/task-reviews/{id}app tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getTaskRunReview({ path: { "id": "id" } });getTaskTimeline
Get one task timeline
compozy.tasks.getTaskTimeline({ path, query }) → Promise<TaskTimelineResponse>
Options
- idstringpathrequired
- Task id
- after_sequenceintegerquery
- Return only events after the supplied sequence
- limitintegerquery
- Maximum number of timeline items to return
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/timelineapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getTaskTimeline({ path: { "id": "id" } });getTaskTree
Get one task tree live view
compozy.tasks.getTaskTree({ path, query }) → Promise<TaskTreeResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/treeapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.getTaskTree({ path: { "id": "id" } });inspectRun
Inspect one task run with diagnostics
compozy.tasks.inspectRun({ path, query }) → Promise<TaskInspectResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/runs/{id}/inspectapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.inspectRun({ path: { "id": "id" } });inspectTask
Inspect one task with diagnostics
compozy.tasks.inspectTask({ path, query }) → Promise<TaskInspectResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/inspectapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.inspectTask({ path: { "id": "id" } });listTaskBlocks
List typed task blocks
compozy.tasks.listTaskBlocks({ path, query }) → Promise<TaskBlocksResponse>
Options
- idstringpathrequired
- Task id
- include_clearedbooleanquery
- Include cleared task blocks
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/blocksapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.listTaskBlocks({ path: { "id": "id" } });listTaskReviews
List task-run reviews for one task
compozy.tasks.listTaskReviews({ path, query }) → Promise<TaskRunReviewsResponse>
Options
- idstringpathrequired
- Task id
- status"requested" | "routed" | "in_review" | "recorded" | "circuit_opened" | "canceled"query
- Filter by review status
- reviewer_session_idstringquery
- Filter by reviewer session id
- limitintegerquery
- Maximum number of records to return
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/reviewsapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.listTaskReviews({ path: { "id": "id" }, query: { "status": "requested" } });listTaskRunReviews
List reviews for one task run
compozy.tasks.listTaskRunReviews({ path, query }) → Promise<TaskRunReviewsResponse>
Options
- idstringpathrequired
- Task run id
- status"requested" | "routed" | "in_review" | "recorded" | "circuit_opened" | "canceled"query
- Filter by review status
- reviewer_session_idstringquery
- Filter by reviewer session id
- limitintegerquery
- Maximum number of records to return
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/task-runs/{id}/reviewsapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.listTaskRunReviews({ path: { "id": "id" }, query: { "status": "requested" } });listTaskRuns
List runs for one task
compozy.tasks.listTaskRuns({ path, query }) → Promise<TaskRunsResponse>
Options
- idstringpathrequired
- Task id
- status"queued" | "claimed" | "starting" | "running" | "completed" | "failed" | "canceled" | "needs_attention"query
- Filter by run status
- session_idstringquery
- Filter by attached session id
- limitintegerquery
- Maximum number of records to return
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/runsapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.listTaskRuns({ path: { "id": "id" }, query: { "status": "queued" } });listTasks
List a bounded task catalog page
compozy.tasks.listTasks({ query }) → Promise<TasksResponse>
Options
- all_workspacesbooleanquery
- Read every project and User within the profile lens; conflicts with workspace
- workspace_idsstring[]query
- Repeatable project IDs; @user selects User; requires all_workspaces=true
- scope"all" | "global" | "workspace" | "user" | "@user"query
- Filter by catalog visibility
- workspacestringquery
- Filter by workspace path, name, or ID
- status"draft" | "pending" | "blocked" | "needs_attention" | "ready" | "in_progress" | "completed" | "failed" | "canceled"query
- Filter by task status
- priority"low" | "medium" | "high" | "urgent"query
- Filter by task priority
- include_draftsbooleanquery
- Include draft tasks in list results
- include_loopbooleanquery
- Include Loop execution records; omitted means false
- loop_run_idstringquery
- Filter by Loop run ID; also includes Loop execution records
- approval_state"not_required" | "pending" | "approved" | "rejected"query
- Filter by task approval state
- owner_kind"human" | "agent_session" | "automation" | "extension" | "pool"query
- Filter by owner kind
- owner_refstringquery
- Filter by owner reference
- parent_task_idstringquery
- Filter by parent task ID
- worktreestringquery
- Filter by active run worktree ID
- querystringquery
- Filter by task title or identifier
- sort"recent" | "priority"query
- Order by recent activity or priority
- cursorstringquery
- Opaque query-bound continuation cursor
- limitintegerquery
- Page size from 1 to 200 (default 50)
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasksapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.listTasks({ query: { "status": "draft" } });markTaskRead
Mark one task inbox item as read
compozy.tasks.markTaskRead({ path, query }) → Promise<TaskTriageStateResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
POST /api/tasks/{id}/triage/readapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.markTaskRead({ path: { "id": "id" } });pauseScheduler
Pause scheduler dispatch and task-run claims
compozy.tasks.pauseScheduler({ body }) → Promise<SchedulerStatusResponse>
Request bodySchedulerPauseRequest
POST /api/scheduler/pauseapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.pauseScheduler({ body: { /* request fields */ } });pauseTask
Pause one task for future scheduler claims
compozy.tasks.pauseTask({ path, query, body }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyPauseTaskRequest
POST /api/tasks/{id}/pauseapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.pauseTask({ path: { "id": "id" }, body: { /* request fields */ } });publishTask
Publish one draft task and enqueue executable work
compozy.tasks.publishTask({ path, query, body }) → Promise<TaskExecutionResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyTaskExecutionRequest
POST /api/tasks/{id}/publishapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.publishTask({ path: { "id": "id" }, body: { /* request fields */ } });readTaskRunResult
Read one exact byte page from a task-run result
compozy.tasks.readTaskRunResult({ path, query }) → Promise<TaskRunResultPageResponse>
Options
- idstringpathrequired
- Task run id
- offsetintegerquery
- Zero-based byte offset
- limitintegerquery
- Page size in bytes; defaults to and is capped at 65536
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/task-runs/{id}/resultapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.readTaskRunResult({ path: { "id": "id" } });recoverTask
Recover one task from needs_attention
compozy.tasks.recoverTask({ path, query, body }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyRecoverTaskRequest
POST /api/tasks/{id}/recoverapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.recoverTask({ path: { "id": "id" }, body: { /* request fields */ } });recoverTaskRun
Recover one needs_attention task run
compozy.tasks.recoverTaskRun({ path, query, body }) → Promise<RetryTaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyRecoverTaskRunRequest
POST /api/runs/{id}/recoverapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.recoverTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });rejectTask
Reject one approval-gated task
compozy.tasks.rejectTask({ path, query }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
POST /api/tasks/{id}/rejectapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.rejectTask({ path: { "id": "id" } });removeTaskDependency
Remove one task dependency
compozy.tasks.removeTaskDependency({ path, query }) → Promise<TaskDetailResponse>
Options
- idstringpathrequired
- Task id
- depends_on_idstringpathrequired
- Dependency task id
- profilestringquery
- Act as this profile by name
DELETE /api/tasks/{id}/dependencies/{depends_on_id}app tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.removeTaskDependency({ path: { "id": "id", "depends_on_id": "depends_on_id" } });requestTaskRunReview
Request review for one terminal task run
compozy.tasks.requestTaskRunReview({ path, query, body }) → Promise<RequestTaskRunReviewResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyRunReviewRequest
POST /api/task-runs/{id}/reviewsapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.requestTaskRunReview({ path: { "id": "id" }, body: { /* request fields */ } });resumeScheduler
Resume scheduler dispatch and task-run claims
compozy.tasks.resumeScheduler({ body }) → Promise<SchedulerStatusResponse>
Request bodySchedulerResumeRequest
POST /api/scheduler/resumeapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.resumeScheduler({ body: { /* request fields */ } });resumeTask
Resume one paused task for future scheduler claims
compozy.tasks.resumeTask({ path, query, body }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyResumeTaskRequest
POST /api/tasks/{id}/resumeapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.resumeTask({ path: { "id": "id" }, body: { /* request fields */ } });retryTaskRun
Retry one failed task run
compozy.tasks.retryTaskRun({ path, query, body }) → Promise<RetryTaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyRetryTaskRunRequest
POST /api/runs/{id}/retryapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.retryTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });setTaskExecutionProfile
Replace one task execution profile
compozy.tasks.setTaskExecutionProfile({ path, query, body }) → Promise<TaskExecutionProfileResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyExecutionProfile
PUT /api/tasks/{id}/execution-profileapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.setTaskExecutionProfile({ path: { "id": "id" }, body: { /* request fields */ } });setTaskWorktreePolicy
Set one task worktree policy
compozy.tasks.setTaskWorktreePolicy({ path, query, body }) → Promise<TaskExecutionProfileResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyWorktreePolicy
PATCH /api/tasks/{id}/execution-profile/worktreeapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.setTaskWorktreePolicy({ path: { "id": "id" }, body: { /* request fields */ } });startTask
Start one task by enqueueing executable work
compozy.tasks.startTask({ path, query, body }) → Promise<TaskExecutionResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyTaskExecutionRequest
POST /api/tasks/{id}/startapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.startTask({ path: { "id": "id" }, body: { /* request fields */ } });startTaskRun
Start one claimed task run
compozy.tasks.startTaskRun({ path, query, body }) → Promise<TaskRunResponse>
Options
- idstringpathrequired
- Task run id
- profilestringquery
- Act as this profile by name
Request bodyStartTaskRunRequest
POST /api/task-runs/{id}/startapp tokens denied
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.startTaskRun({ path: { "id": "id" }, body: { /* request fields */ } });streamTask
Stream task-native live events for one task
compozy.events("streamTask", { path, query }) → AsyncIterable<StreamEvent<SseFrame<"streamTask">>>
Options
- idstringpathrequired
- Task id
- after_sequenceintegerquery
- Replay events after the supplied task stream sequence
- profilestringquery
- Read one profile's rows by name
- all_profilesbooleanquery
- Read the owner-labeled all-profiles aggregate
GET /api/tasks/{id}/streamapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();for await (const frame of compozy.events("streamTask", { path: { "id": "id" } })) { console.log(frame);}submitTaskRunReviewVerdict
Submit one task-run review verdict
compozy.tasks.submitTaskRunReviewVerdict({ path, query, body }) → Promise<TaskRunReviewVerdictResponse>
Options
- idstringpathrequired
- Review id
- profilestringquery
- Act as this profile by name
Request bodySubmitTaskRunReviewVerdictRequest
POST /api/task-reviews/{id}/verdictapp tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.submitTaskRunReviewVerdict({ path: { "id": "id" }, body: { /* request fields */ } });updateTask
Update one task
compozy.tasks.updateTask({ path, query, body }) → Promise<TaskResponse>
Options
- idstringpathrequired
- Task id
- profilestringquery
- Act as this profile by name
Request bodyUpdateTaskRequest
PATCH /api/tasks/{id}app tokens allowed
import { Compozy } from "@compozy/client"; const compozy = await Compozy.connect();const result = await compozy.tasks.updateTask({ path: { "id": "id" }, body: { /* request fields */ } });