{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-iot-sitewise/json-schema/amazon-iot-sitewise-put-asset-model-interface-relationship-request-schema.json",
  "title": "PutAssetModelInterfaceRelationshipRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-iot-sitewise-asset-model-interface-relationship-api-openapi.yml#/components/schemas/PutAssetModelInterfaceRelationshipRequest",
  "type": "object",
  "properties": {
    "assetModelId": {
      "type": "string",
      "description": "The ID of the asset model. This can be either the actual ID in UUID format, or else externalId: followed by the external ID."
    },
    "interfaceAssetModelId": {
      "type": "string",
      "description": "The ID of the interface asset model. This can be either the actual ID in UUID format, or else externalId: followed by the external ID."
    },
    "propertyMappingConfiguration": {
      "$ref": "#/$defs/PropertyMappingConfiguration"
    },
    "clientToken": {
      "type": "string",
      "description": "A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required."
    }
  },
  "required": [
    "assetModelId",
    "interfaceAssetModelId",
    "propertyMappingConfiguration"
  ],
  "$defs": {
    "PropertyMapping": {
      "type": "object",
      "properties": {
        "assetModelPropertyId": {
          "type": "string",
          "description": "The ID of the property in the asset model where the interface is applied."
        },
        "interfaceAssetModelPropertyId": {
          "type": "string",
          "description": "The ID of the property in the interface asset model."
        }
      },
      "required": [
        "assetModelPropertyId",
        "interfaceAssetModelPropertyId"
      ]
    },
    "PropertyMappingConfiguration": {
      "type": "object",
      "properties": {
        "matchByPropertyName": {
          "type": "boolean",
          "description": "If true, properties are matched by name between the interface asset model and the asset model where the interface is applied."
        },
        "createMissingProperty": {
          "type": "boolean",
          "description": "If true, missing properties from the interface asset model are automatically created in the asset model where the interface is applied."
        },
        "overrides": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/PropertyMapping"
          },
          "description": "A list of specific property mappings that override the automatic mapping by name when an interface is applied to an asset model."
        }
      }
    }
  }
}