Merge branch

veryfront__merge_branch

Requires project.files.write.

Access

No external-service connection is required. Use a Veryfront credential with access to the requested resources.

Call type: Can change resources.

Arguments

FieldTypeRequiredDescription and constraints
branch_idstringYesBranch ID to merge Format: uuid.
expected_versionintegerNoExpected source branch version. Stale versions return a precondition failure before any merge writes. Minimum: 0.
target_branch_idstring or nullNoTarget branch ID; omit for main. An unknown target returns not found. Merge eligibility and conflicts are checked again when the merge commits.
merge_messagestringNoOptional message describing the merge

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.

json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "veryfront__merge_branch",
    "arguments": {
      "branch_id": "00000000-0000-4000-8000-000000000000"
    }
  }
}

Result

The published output shape is summarized below. Inspect both the MCP response content and isError when handling a call.

FieldTypeRequiredDescription and constraints
merged_documentsnumberYesNumber of documents the source branch changed that were written to the target unchanged.
added_documentsnumberYesNumber of documents the source branch added to the target.
deleted_documentsnumberYesNumber of documents the source branch deleted from the target.
auto_merged_documentsnumberYesNumber of documents changed on both branches whose changes were combined without conflicts.
audit_idstringYesID of the merge audit record holding the before and after snapshots.
branch_namestringYesName of the source branch that was merged.
target_branch_idstring or nullYesID of the branch that received the merge, or null when the merge went into the main branch.
target_branch_namestringYesName of the branch that received the merge ("main" for the main branch).

Full schemas

json
{
  "type": "object",
  "properties": {
    "branch_id": {
      "type": "string",
      "format": "uuid",
      "description": "Branch ID to merge"
    },
    "expected_version": {
      "type": "integer",
      "minimum": 0,
      "description": "Expected source branch version. Stale versions return a precondition failure before any merge writes."
    },
    "target_branch_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid",
          "description": "Provide the target branch id."
        },
        {
          "type": "null",
          "description": "Provide the target branch id."
        }
      ],
      "description": "Target branch ID; omit for main. An unknown target returns not found. Merge eligibility and conflicts are checked again when the merge commits."
    },
    "merge_message": {
      "type": "string",
      "description": "Optional message describing the merge"
    }
  },
  "required": [
    "branch_id"
  ],
  "additionalProperties": false,
  "description": "Arguments for the merge_branch tool.",
  "$schema": "http://json-schema.org/draft-07/schema#"
}
json
{
  "type": "object",
  "properties": {
    "merged_documents": {
      "type": "number",
      "description": "Number of documents the source branch changed that were written to the target unchanged."
    },
    "added_documents": {
      "type": "number",
      "description": "Number of documents the source branch added to the target."
    },
    "deleted_documents": {
      "type": "number",
      "description": "Number of documents the source branch deleted from the target."
    },
    "auto_merged_documents": {
      "type": "number",
      "description": "Number of documents changed on both branches whose changes were combined without conflicts."
    },
    "audit_id": {
      "type": "string",
      "description": "ID of the merge audit record holding the before and after snapshots."
    },
    "branch_name": {
      "type": "string",
      "description": "Name of the source branch that was merged."
    },
    "target_branch_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "ID of the branch that received the merge, or null when the merge went into the main branch."
    },
    "target_branch_name": {
      "type": "string",
      "description": "Name of the branch that received the merge (\"main\" for the main branch)."
    }
  },
  "required": [
    "merged_documents",
    "added_documents",
    "deleted_documents",
    "auto_merged_documents",
    "audit_id",
    "branch_name",
    "target_branch_id",
    "target_branch_name"
  ],
  "additionalProperties": false,
  "description": "Structured result returned by the merge_branch tool.",
  "$schema": "http://json-schema.org/draft-07/schema#"
}