veryfront__get_branch_merge_preview
Requires project.read.
Access
No external-service connection is required. Use a Veryfront credential with access to the requested resources.
Call type: Read-only.
Arguments
| Field | Type | Required | Description and constraints |
|---|---|---|---|
target_branch_id | string or null | No | Target branch ID; omit for main. |
branch_id | string | Yes | Branch to merge. A missing branch and one you cannot read are both not found. Format: uuid. |
Example request
Send this JSON-RPC request through an initialized MCP client. Replace sample identifiers and values before calling the tool. See MCP client setup.
request.json
1{2 "jsonrpc": "2.0",3 "id": 1,4 "method": "tools/call",5 "params": {6 "name": "veryfront__get_branch_merge_preview",7 "arguments": {8 "branch_id": "00000000-0000-4000-8000-000000000000"9 }10 }11}Result
The published output shape is summarized below. Inspect both the MCP response content and isError when handling a call.
| Field | Type | Required | Description and constraints |
|---|---|---|---|
source_branch | object | Yes | Branch to merge. |
target_branch_id | string or null | Yes | Branch that receives the merge, or null for main. |
target_branch_name | string | Yes | Name of the branch that receives the merge. |
can_merge | boolean | Yes | True only when blocked_reason is null, merge policies pass and no file has conflicts. Advisory: the merge checks these conditions again. |
blocked_reason | string or null | Yes | Precondition that blocks the merge, such as a merged or closed branch, or a target that is the source branch or is closed; null when none does. A target that is missing or in another project is a not found error. |
has_conflicts | boolean | Yes | Whether at least one file has conflicts. |
diffs | object[] | Yes | File-by-file changes the merge applies. |
Full schemas
input-schema.json
1{2 "type": "object",3 "properties": {4 "target_branch_id": {5 "anyOf": [6 {7 "type": "string",8 "format": "uuid",9 "description": "Provide the target branch id."10 },11 {12 "type": "null",13 "description": "Provide the target branch id."14 }15 ],16 "description": "Target branch ID; omit for main."17 },18 "branch_id": {19 "type": "string",20 "format": "uuid",21 "description": "Branch to merge. A missing branch and one you cannot read are both not found."22 }23 },24 "required": [25 "branch_id"26 ],27 "additionalProperties": false,28 "description": "Use this before merge_branch to review the file-by-file changes a merge applies and to resolve conflicts. Returns the source branch, the target, can_merge with blocked_reason, has_conflicts, and one diff per changed file with its conflict regions and the content of each side.",29 "$schema": "http://json-schema.org/draft-07/schema#"30}output-schema.json
1{2 "type": "object",3 "properties": {4 "source_branch": {5 "type": "object",6 "properties": {7 "id": {8 "type": "string",9 "format": "uuid",10 "description": "Branch ID."11 },12 "name": {13 "type": "string",14 "description": "Branch name, unique in the project."15 },16 "project_id": {17 "type": "string",18 "format": "uuid",19 "description": "Project that owns the branch."20 },21 "base_branch_id": {22 "anyOf": [23 {24 "type": "string",25 "format": "uuid"26 },27 {28 "type": "null",29 "description": "The base branch id returned by the tool."30 }31 ],32 "description": "Branch this branch was created from, or null for the root branch."33 },34 "status": {35 "type": "string",36 "enum": [37 "active",38 "merged",39 "closed"40 ],41 "description": "Lifecycle state; closed is distinct from merged."42 },43 "description": {44 "type": [45 "string",46 "null"47 ],48 "description": "Branch description, or null."49 },50 "auto_delete_on_merge": {51 "type": "boolean",52 "description": "Whether the branch is deleted after it merges."53 },54 "version": {55 "type": "integer",56 "minimum": 0,57 "description": "Version to pass as expected_version when merging."58 },59 "created_at": {60 "type": "string",61 "description": "Creation time."62 },63 "created_by": {64 "anyOf": [65 {66 "$ref": "#/properties/source_branch/properties/base_branch_id/anyOf/0",67 "description": "The created by returned by the tool."68 },69 {70 "type": "null",71 "description": "The created by returned by the tool."72 }73 ],74 "description": "User who created the branch, or null."75 },76 "updated_at": {77 "type": [78 "string",79 "null"80 ],81 "description": "Last update time, or null."82 },83 "merged_at": {84 "type": [85 "string",86 "null"87 ],88 "description": "Merge time, or null before a merge."89 },90 "merged_by": {91 "anyOf": [92 {93 "$ref": "#/properties/source_branch/properties/base_branch_id/anyOf/0",94 "description": "The merged by returned by the tool."95 },96 {97 "type": "null",98 "description": "The merged by returned by the tool."99 }100 ],101 "description": "User who merged the branch, or null."102 }103 },104 "required": [105 "id",106 "name",107 "project_id",108 "base_branch_id",109 "status",110 "description",111 "auto_delete_on_merge",112 "version",113 "created_at",114 "created_by",115 "updated_at",116 "merged_at",117 "merged_by"118 ],119 "additionalProperties": false,120 "description": "Branch to merge."121 },122 "target_branch_id": {123 "anyOf": [124 {125 "$ref": "#/properties/source_branch/properties/base_branch_id/anyOf/0",126 "description": "The target branch id returned by the tool."127 },128 {129 "type": "null",130 "description": "The target branch id returned by the tool."131 }132 ],133 "description": "Branch that receives the merge, or null for main."134 },135 "target_branch_name": {136 "type": "string",137 "description": "Name of the branch that receives the merge."138 },139 "can_merge": {140 "type": "boolean",141 "description": "True only when blocked_reason is null, merge policies pass and no file has conflicts. Advisory: the merge checks these conditions again."142 },143 "blocked_reason": {144 "type": [145 "string",146 "null"147 ],148 "description": "Precondition that blocks the merge, such as a merged or closed branch, or a target that is the source branch or is closed; null when none does. A target that is missing or in another project is a not found error."149 },150 "has_conflicts": {151 "type": "boolean",152 "description": "Whether at least one file has conflicts."153 },154 "diffs": {155 "type": "array",156 "items": {157 "type": "object",158 "properties": {159 "file_path": {160 "type": "string",161 "description": "File path; the file ID when neither side has a path."162 },163 "file_type": {164 "type": "string",165 "description": "File type."166 },167 "file_id": {168 "type": [169 "string",170 "null"171 ],172 "description": "File ID, or null."173 },174 "has_conflicts": {175 "type": "boolean",176 "description": "Whether the file has conflicts that block an automatic merge."177 },178 "conflict_count": {179 "type": "integer",180 "minimum": 0,181 "description": "Number of conflict regions."182 },183 "conflict_regions": {184 "type": "array",185 "items": {186 "type": "object",187 "properties": {188 "id": {189 "type": "string",190 "description": "Region ID, stable within one preview; conflict resolutions are keyed by it."191 },192 "type": {193 "type": "string",194 "const": "conflict",195 "description": "Region kind."196 },197 "base_start": {198 "type": "integer",199 "description": "First line in the common base."200 },201 "base_end": {202 "type": "integer",203 "description": "Last line in the common base."204 },205 "target_start": {206 "type": "integer",207 "description": "First line in the target branch."208 },209 "target_end": {210 "type": "integer",211 "description": "Last line in the target branch."212 },213 "source_start": {214 "type": "integer",215 "description": "First line in the source branch."216 },217 "source_end": {218 "type": "integer",219 "description": "Last line in the source branch."220 },221 "base_lines": {222 "type": "string",223 "description": "Conflicting text in the common base."224 },225 "target_lines": {226 "type": "string",227 "description": "Conflicting text in the target branch."228 },229 "source_lines": {230 "type": "string",231 "description": "Conflicting text in the source branch."232 }233 },234 "required": [235 "id",236 "type",237 "base_start",238 "base_end",239 "target_start",240 "target_end",241 "source_start",242 "source_end",243 "base_lines",244 "target_lines",245 "source_lines"246 ],247 "additionalProperties": false248 },249 "description": "Conflicting line ranges."250 },251 "is_new": {252 "type": "boolean",253 "description": "The merge adds the file to the target."254 },255 "is_deleted": {256 "type": "boolean",257 "description": "The merge deletes the file from the target."258 },259 "is_modified": {260 "type": "boolean",261 "description": "The merge changes the file in the target."262 },263 "base_changed": {264 "type": "boolean",265 "description": "The target changed the file since the branch was created."266 },267 "branch_changed": {268 "type": "boolean",269 "description": "The branch changed the file."270 },271 "base_content": {272 "type": [273 "string",274 "null"275 ],276 "description": "Content at the common base, or null."277 },278 "target_content": {279 "type": [280 "string",281 "null"282 ],283 "description": "Content in the target branch, or null."284 },285 "source_content": {286 "type": [287 "string",288 "null"289 ],290 "description": "Content in the source branch, or null."291 }292 },293 "required": [294 "file_path",295 "file_type",296 "file_id",297 "has_conflicts",298 "conflict_count",299 "conflict_regions",300 "is_new",301 "is_deleted",302 "is_modified",303 "base_changed",304 "branch_changed",305 "base_content",306 "target_content",307 "source_content"308 ],309 "additionalProperties": false310 },311 "description": "File-by-file changes the merge applies."312 }313 },314 "required": [315 "source_branch",316 "target_branch_id",317 "target_branch_name",318 "can_merge",319 "blocked_reason",320 "has_conflicts",321 "diffs"322 ],323 "additionalProperties": false,324 "description": "Structured result returned by the get_branch_merge_preview tool.",325 "$schema": "http://json-schema.org/draft-07/schema#"326}