Skip to main content
POST
/
{org}
/
{repo}
/
merge
/
{base}
Merge branches
curl --request POST \
  --url https://depot.mesa.dev/api/v1/{org}/{repo}/merge/{base} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "head": "<string>",
  "author": {
    "name": "<string>",
    "email": "jsmith@example.com",
    "date": "<string>"
  },
  "message": "<string>",
  "delete_branch": false
}
'
{
  "merge_type": "fast_forward",
  "sha": "<string>",
  "base": "<string>",
  "head": "<string>",
  "branch_deleted": true
}

Authorizations

Authorization
string
header
required

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

Path Parameters

org
string
required
Minimum string length: 1
repo
string
required
Minimum string length: 1
base
string
required
Minimum string length: 1

Body

application/json
head
string
required

The branch to merge from

Minimum string length: 1
author
object
required

The author of the merge commit

message
string

Custom merge commit message. Defaults to "Merge branch 'head' into 'base'"

delete_branch
boolean
default:false

Whether to delete the head branch after a successful merge

Response

Merge completed

merge_type
enum<string>
required

The type of merge that was performed

Available options:
fast_forward,
merge_commit
sha
string
required

The SHA of the resulting commit on the base branch

base
string
required

The base branch that was merged into

head
string
required

The head branch that was merged from

branch_deleted
boolean
required

Whether the head branch was deleted after merge