v52

latestOpenAPI 3.0.0Apache 2.0raw.githubusercontent.com2026-08-03134119177.4 KB
refs

merge references

post/repositories/{repository}/refs/{sourceRef}/merge/{destinationBranch}

Request body

messagestring
metadataobject
strategystring

In case of a merge conflict, this option will force the merge process to automatically favor changes from the dest branch ('dest-wins') or from the source branch('source-wins'). In case no selection is made, the merge process will fail in case of a conflict

forceboolean

Allow merge into a read-only branch or into a branch with the same content

allow_emptyboolean

Allow merge when the branches have the same content

squash_mergeboolean

If set, set only the destination branch as a parent, which "squashes" the merge to appear as a single commit on the destination branch. The source commit is no longer a part of the merge commit; consider adding it to the 'metadata' or 'message' fields. This behaves like a GitHub or GitLab "squash merge", or in Git terms 'git merge --squash; git commit ...'.

Response

merge completed

referencestring required