{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-entity-resolution/json-schema/amazon-entity-resolution-generate-match-id-output-schema.json",
  "title": "GenerateMatchIdOutput",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-entity-resolution-operations-api-openapi.yml#/components/schemas/GenerateMatchIdOutput",
  "type": "object",
  "properties": {
    "matchGroups": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/MatchGroup"
      },
      "description": "The match groups from the generated match ID."
    },
    "failedRecords": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/FailedRecord"
      },
      "description": "The records that didn't receive a generated Match ID."
    }
  },
  "required": [
    "matchGroups",
    "failedRecords"
  ],
  "$defs": {
    "FailedRecord": {
      "type": "object",
      "properties": {
        "inputSourceARN": {
          "type": "string",
          "description": "The input source ARN of the record that didn't generate a Match ID."
        },
        "uniqueId": {
          "type": "string",
          "description": "The unique ID of the record that didn't generate a Match ID."
        },
        "errorMessage": {
          "type": "string",
          "description": "The error message for the record that didn't generate a Match ID."
        }
      },
      "required": [
        "inputSourceARN",
        "uniqueId",
        "errorMessage"
      ]
    },
    "MatchGroup": {
      "type": "object",
      "properties": {
        "records": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/MatchedRecord"
          },
          "description": "The matched records."
        },
        "matchId": {
          "type": "string",
          "description": "The match ID."
        },
        "matchRule": {
          "type": "string",
          "description": "The match rule of the match group."
        }
      },
      "required": [
        "records",
        "matchId",
        "matchRule"
      ]
    },
    "MatchedRecord": {
      "type": "object",
      "properties": {
        "inputSourceARN": {
          "type": "string",
          "description": "The input source ARN of the matched record."
        },
        "recordId": {
          "type": "string",
          "description": "The record ID of the matched record."
        }
      },
      "required": [
        "inputSourceARN",
        "recordId"
      ]
    }
  }
}