{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-application-migration-service/json-schema/amazon-application-migration-service-start-network-migration-mapping-update-request-schema.json",
  "title": "StartNetworkMigrationMappingUpdateRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-application-migration-service-network-migration-api-openapi.yml#/components/schemas/StartNetworkMigrationMappingUpdateRequest",
  "type": "object",
  "properties": {
    "networkMigrationExecutionID": {
      "type": "string",
      "description": "The unique identifier of the network migration execution."
    },
    "networkMigrationDefinitionID": {
      "type": "string",
      "description": "The unique identifier of the network migration definition."
    },
    "constructs": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/StartNetworkMigrationMappingUpdateConstruct"
      },
      "description": "A list of construct updates to apply."
    },
    "segments": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/StartNetworkMigrationMappingUpdateSegment"
      },
      "description": "A list of segment updates to apply."
    }
  },
  "required": [
    "networkMigrationExecutionID",
    "networkMigrationDefinitionID"
  ],
  "$defs": {
    "DeleteOperation": {
      "type": "object",
      "properties": {}
    },
    "MergeConstruct": {
      "type": "object",
      "properties": {
        "segmentID": {
          "type": "string",
          "description": "The segment ID of the construct to merge."
        },
        "constructID": {
          "type": "string",
          "description": "The construct ID to merge."
        }
      }
    },
    "MergeOperation": {
      "type": "object",
      "properties": {
        "mergeConstructs": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/MergeConstruct"
          },
          "description": "The list of constructs to merge into the target."
        }
      }
    },
    "OperationUnion": {
      "type": "object",
      "properties": {
        "merge": {
          "$ref": "#/$defs/MergeOperation"
        },
        "split": {
          "$ref": "#/$defs/SplitOperation"
        },
        "delete": {
          "$ref": "#/$defs/DeleteOperation"
        },
        "update": {
          "$ref": "#/$defs/UpdateOperation"
        }
      },
      "description": "Exactly one member is set."
    },
    "SplitConstruct": {
      "type": "object",
      "properties": {
        "cidrBlock": {
          "type": "string",
          "description": "The CIDR block for the split construct."
        }
      }
    },
    "SplitOperation": {
      "type": "object",
      "properties": {
        "splitConstructs": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/SplitConstruct"
          },
          "description": "The list of split targets with their CIDR blocks."
        }
      }
    },
    "StartNetworkMigrationMappingUpdateConstruct": {
      "type": "object",
      "properties": {
        "segmentID": {
          "type": "string",
          "description": "The ID of the segment containing the construct."
        },
        "constructID": {
          "type": "string",
          "description": "The ID of the construct to update."
        },
        "constructType": {
          "type": "string",
          "description": "The type of the construct."
        },
        "operation": {
          "$ref": "#/$defs/OperationUnion"
        }
      },
      "required": [
        "segmentID",
        "constructID",
        "constructType"
      ]
    },
    "StartNetworkMigrationMappingUpdateSegment": {
      "type": "object",
      "properties": {
        "segmentID": {
          "type": "string",
          "description": "The ID of the segment to update."
        },
        "targetAccount": {
          "type": "string",
          "description": "The updated target AWS account for the segment."
        },
        "scopeTags": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "The updated scope tags for the segment."
        }
      },
      "required": [
        "segmentID"
      ]
    },
    "UpdateOperation": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The updated name for the construct."
        },
        "excluded": {
          "type": "boolean",
          "description": "Whether to exclude this construct from the migration."
        },
        "properties": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "The properties to update on the construct."
        }
      }
    }
  }
}