---
title: "Update a trail branch with the latest base branch changes"
method: POST
path: "/api/v1/trails/{forge}/{owner}/{repo}/{number}/update-branch"
tags: ["Trails"]
---

# Update a trail branch with the latest base branch changes

`POST /api/v1/trails/{forge}/{owner}/{repo}/{number}/update-branch`

## Path parameters

- `forge` string, required
- `owner` string, required
- `repo` string, required
- `number` string, required

## Response `200`

Branch updated (or already up to date)

- object
  - `ok` boolean, required
  - `merge_commit_sha` string, required

## Other responses

- `409` — Branch has merge conflicts with the base branch
- `422` — Update gate failed

---

[API](https://skmtc.dev/entire/apis/entire-api.md) · [All operations](https://skmtc.dev/entire/apis/entire-api/llms.txt) · [OpenAPI document](https://skmtc.dev/entire/apis/entire-api/revisions/d69a682d6e44?raw)
