Skip to main content
PATCH
/
api
/
tasks
/
{task_id}
Patch Task
curl --request PATCH \
  --url https://api.example.com/api/tasks/{task_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "project_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'
{
  "created_at": "2023-11-07T05:31:56Z",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "mode": "plan",
  "name": "<string>",
  "project_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "updated_at": "2023-11-07T05:31:56Z",
  "user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "cost_usd": 123,
  "github_branch": "<string>",
  "has_plan": false,
  "machine_url": "<string>",
  "plan_version": 123,
  "pull_requests": [],
  "selected_branches": {}
}

Documentation Index

Fetch the complete documentation index at: https://docs.codecobra.ai/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

task_id
string<uuid>
required

Body

application/json

Fields a user can change on an existing task. Only project_id is supported today — it's the "I picked the wrong project for this task before sending anything" escape hatch wired up to the task header's ProjectSwitcher.

project_id
string<uuid> | null

Response

Successful Response

created_at
string<date-time>
required
id
string<uuid>
required
mode
enum<string>
required
Available options:
plan,
build
name
string
required
project_id
string<uuid>
required
updated_at
string<date-time>
required
user_id
string<uuid>
required
cost_usd
number | null
github_branch
string | null
has_plan
boolean
default:false
machine_url
string | null
plan_version
integer | null
pull_requests
PullRequestResponse · object[]
selected_branches
Selected Branches · object