Skip to main content
PATCH
/
{org}
/
{repo}
/
changes
/
{change_id}
Patch change
curl --request PATCH \
  --url https://api.mesa.dev/v1/{org}/{repo}/changes/{change_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "message": "<string>",
  "files": [
    {
      "path": "<string>",
      "content": "<string>",
      "encoding": "base64",
      "action": "<string>"
    }
  ],
  "base_commit_oid": "<string>",
  "resolutions": [
    {
      "path": "<string>",
      "content": "<string>",
      "encoding": "base64"
    }
  ]
}
'
{
  "id": "<string>",
  "current_commit_oid": "<string>",
  "is_conflicted": true,
  "message": "<string>",
  "author": {
    "name": "<string>",
    "email": "jsmith@example.com",
    "date": "2023-11-07T05:31:56Z"
  },
  "committer": {
    "name": "<string>",
    "email": "jsmith@example.com",
    "date": "2023-11-07T05:31:56Z"
  },
  "parents": [
    "<string>"
  ],
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}
Required scope: write

Authorizations

Authorization
string
header
required

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

Path Parameters

org
string
required

Organization slug

Minimum string length: 1
repo
string
required

Repository name

Minimum string length: 1
change_id
string
required
Pattern: ^[zyxwvutsrqponmlk]{32}$

Body

application/json
message
string

Replacement change description. Omit to preserve the existing description; pass an empty string to clear it.

author
object
committer
object
files
object[]
Minimum array length: 1
base_commit_oid
string
Pattern: ^[0-9a-f]{40}$
resolutions
object[]

Conflict resolutions to apply to a conflicted change. When present, the change advances to a new commit: fully resolved paths collapse into the target-term tree and the change becomes clean when no conflicts remain. files and resolutions are mutually exclusive — a conflicted change must be resolved via resolutions before regular file writes land.

A single caller-supplied resolution. Whole-file variants carry content OR take (not both); per-hunk variants carry hunks. Whole-file replaces the merged content at path. Per-hunk requires all hunks for the path to be resolved.

Response

Change updated

id
string
required
Pattern: ^[zyxwvutsrqponmlk]{32}$
current_commit_oid
string
required
Pattern: ^[0-9a-f]{40}$
is_conflicted
boolean
required

True when the change current commit still contains unresolved conflicts

message
string
required

Current change description. Empty string means the change has no description.

author
object
required
committer
object
required
parents
string[]
required

Parent change IDs for this change

created_at
string<date-time>
required
updated_at
string<date-time>
required