{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-codecommit/json-schema/amazon-codecommit-describe-merge-conflicts-output-schema.json",
  "title": "DescribeMergeConflictsOutput",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-codecommit-merge-conflict-api-openapi.yml#/components/schemas/DescribeMergeConflictsOutput",
  "type": "object",
  "properties": {
    "conflictMetadata": {
      "$ref": "#/$defs/ConflictMetadata"
    },
    "mergeHunks": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/MergeHunk"
      },
      "description": "A list of merge hunks of the differences between the files or lines."
    },
    "nextToken": {
      "type": "string",
      "description": "An enumeration token that can be used in a request to return the next batch of the results."
    },
    "destinationCommitId": {
      "type": "string",
      "description": "The commit ID of the destination commit specifier that was used in the merge evaluation."
    },
    "sourceCommitId": {
      "type": "string",
      "description": "The commit ID of the source commit specifier that was used in the merge evaluation."
    },
    "baseCommitId": {
      "type": "string",
      "description": "The commit ID of the merge base."
    }
  },
  "required": [
    "conflictMetadata",
    "mergeHunks",
    "destinationCommitId",
    "sourceCommitId"
  ],
  "$defs": {
    "ConflictMetadata": {
      "type": "object",
      "properties": {
        "filePath": {
          "type": "string",
          "description": "The path of the file that contains conflicts."
        },
        "fileSizes": {
          "$ref": "#/$defs/FileSizes"
        },
        "fileModes": {
          "$ref": "#/$defs/FileModes"
        },
        "objectTypes": {
          "$ref": "#/$defs/ObjectTypes"
        },
        "numberOfConflicts": {
          "type": "integer",
          "description": "The number of conflicts, including both hunk conflicts and metadata conflicts."
        },
        "isBinaryFile": {
          "$ref": "#/$defs/IsBinaryFile"
        },
        "contentConflict": {
          "type": "boolean",
          "description": "A boolean value indicating whether there are conflicts in the content of a file."
        },
        "fileModeConflict": {
          "type": "boolean",
          "description": "A boolean value indicating whether there are conflicts in the file mode of a file."
        },
        "objectTypeConflict": {
          "type": "boolean",
          "description": "A boolean value (true or false) indicating whether there are conflicts between the branches in the object type of a file, folder, or submodule."
        },
        "mergeOperations": {
          "$ref": "#/$defs/MergeOperations"
        }
      }
    },
    "FileModes": {
      "type": "object",
      "properties": {
        "source": {
          "type": "string",
          "enum": [
            "EXECUTABLE",
            "NORMAL",
            "SYMLINK"
          ],
          "description": "The file mode of a file in the source of a merge or pull request."
        },
        "destination": {
          "type": "string",
          "enum": [
            "EXECUTABLE",
            "NORMAL",
            "SYMLINK"
          ],
          "description": "The file mode of a file in the destination of a merge or pull request."
        },
        "base": {
          "type": "string",
          "enum": [
            "EXECUTABLE",
            "NORMAL",
            "SYMLINK"
          ],
          "description": "The file mode of a file in the base of a merge or pull request."
        }
      }
    },
    "FileSizes": {
      "type": "object",
      "properties": {
        "source": {
          "type": "integer",
          "description": "The size of a file in the source of a merge or pull request."
        },
        "destination": {
          "type": "integer",
          "description": "The size of a file in the destination of a merge or pull request."
        },
        "base": {
          "type": "integer",
          "description": "The size of a file in the base of a merge or pull request."
        }
      }
    },
    "IsBinaryFile": {
      "type": "object",
      "properties": {
        "source": {
          "type": "boolean",
          "description": "The binary or non-binary status of file in the source of a merge or pull request."
        },
        "destination": {
          "type": "boolean",
          "description": "The binary or non-binary status of a file in the destination of a merge or pull request."
        },
        "base": {
          "type": "boolean",
          "description": "The binary or non-binary status of a file in the base of a merge or pull request."
        }
      }
    },
    "MergeHunk": {
      "type": "object",
      "properties": {
        "isConflict": {
          "type": "boolean",
          "description": "A Boolean value indicating whether a combination of hunks contains a conflict. Conflicts occur when the same file or the same lines in a file were modified in both the source and destination of a merge or pull request. Valid values include true, false, and null. True when the hunk represents a conflict and one or more files contains a line conflict. File mode conflicts in a merge do not set this to true."
        },
        "source": {
          "$ref": "#/$defs/MergeHunkDetail"
        },
        "destination": {
          "$ref": "#/$defs/MergeHunkDetail"
        },
        "base": {
          "$ref": "#/$defs/MergeHunkDetail"
        }
      }
    },
    "MergeHunkDetail": {
      "type": "object",
      "properties": {
        "startLine": {
          "type": "integer",
          "description": "The start position of the hunk in the merge result."
        },
        "endLine": {
          "type": "integer",
          "description": "The end position of the hunk in the merge result."
        },
        "hunkContent": {
          "type": "string",
          "description": "The base-64 encoded content of the hunk merged region that might contain a conflict."
        }
      }
    },
    "MergeOperations": {
      "type": "object",
      "properties": {
        "source": {
          "type": "string",
          "enum": [
            "A",
            "M",
            "D"
          ],
          "description": "The operation (add, modify, or delete) on a file in the source of a merge or pull request."
        },
        "destination": {
          "type": "string",
          "enum": [
            "A",
            "M",
            "D"
          ],
          "description": "The operation on a file in the destination of a merge or pull request."
        }
      }
    },
    "ObjectTypes": {
      "type": "object",
      "properties": {
        "source": {
          "type": "string",
          "enum": [
            "FILE",
            "DIRECTORY",
            "GIT_LINK",
            "SYMBOLIC_LINK"
          ],
          "description": "The type of the object in the source branch."
        },
        "destination": {
          "type": "string",
          "enum": [
            "FILE",
            "DIRECTORY",
            "GIT_LINK",
            "SYMBOLIC_LINK"
          ],
          "description": "The type of the object in the destination branch."
        },
        "base": {
          "type": "string",
          "enum": [
            "FILE",
            "DIRECTORY",
            "GIT_LINK",
            "SYMBOLIC_LINK"
          ],
          "description": "The type of the object in the base commit of the merge."
        }
      }
    }
  }
}