previewMerge() is read-only. It checks the merge result with a git:read scoped request and does not create commits or update refs.
Pass includeContent when you want inline conflict blob content. The response still includes conflictPaths when content is omitted or filtered.
Options
Source branch name to merge from.
Target branch name to merge into.
Include bounded conflict blob content in
conflicts when the preview is conflicted. Python: include_content. Go: IncludeContent as *bool.Token TTL for this invocation in seconds. In Go, use
TTL as a time.Duration.Response
Field names below use TypeScript casing. Python returns snake_case keys and Go returns exported struct fields.Preview status:
clean or conflicted.Merge outcome if applied:
merge_commit, fast_forward, or no_op.Resolved source branch name.
Resolved target branch name.
Source branch tip SHA used for the preview.
Target branch tip SHA used for the preview.
Merge base SHA when the backend reports one.
Paths that would conflict if the merge were applied.
Inline conflict details for each returned path. Each item has
path, result, base, ours, and theirs fields. ours is the target branch stage and theirs is the source branch stage. Blob fields include oid, content, truncated, and binary.Conflicted paths whose inline content was omitted. Each item has
path and reason, such as max_conflict_files_exceeded.Notes
conflictsis empty whenincludeContentis omitted or set tofalse.filteredConflictstells you which conflicted files were left out of the inline preview and why.- Use
merge()after a clean preview when you are ready to update the target branch.