{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-iot-twinmaker/json-schema/amazon-iot-twinmaker-update-component-type-request-schema.json",
  "title": "UpdateComponentTypeRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-iot-twinmaker-component-types-api-openapi.yml#/components/schemas/UpdateComponentTypeRequest",
  "type": "object",
  "properties": {
    "workspaceId": {
      "type": "string",
      "description": "The ID of the workspace."
    },
    "isSingleton": {
      "type": "boolean",
      "description": "A Boolean value that specifies whether an entity can have more than one component of this type."
    },
    "componentTypeId": {
      "type": "string",
      "description": "The ID of the component type."
    },
    "description": {
      "type": "string",
      "description": "The description of the component type."
    },
    "propertyDefinitions": {
      "type": "object",
      "additionalProperties": {
        "$ref": "#/$defs/PropertyDefinitionRequest"
      },
      "description": "An object that maps strings to the property definitions in the component type. Each string in the mapping must be unique to this object."
    },
    "extendsFrom": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Specifies the component type that this component type extends."
    },
    "functions": {
      "type": "object",
      "additionalProperties": {
        "$ref": "#/$defs/FunctionRequest"
      },
      "description": "An object that maps strings to the functions in the component type. Each string in the mapping must be unique to this object."
    },
    "propertyGroups": {
      "type": "object",
      "additionalProperties": {
        "$ref": "#/$defs/PropertyGroupRequest"
      },
      "description": "The property groups."
    },
    "componentTypeName": {
      "type": "string",
      "description": "The component type name."
    },
    "compositeComponentTypes": {
      "type": "object",
      "additionalProperties": {
        "$ref": "#/$defs/CompositeComponentTypeRequest"
      },
      "description": "This is an object that maps strings to compositeComponentTypes of the componentType. CompositeComponentType is referenced by componentTypeId."
    }
  },
  "required": [
    "workspaceId",
    "componentTypeId"
  ],
  "$defs": {
    "CompositeComponentTypeRequest": {
      "type": "object",
      "properties": {
        "componentTypeId": {
          "type": "string",
          "description": "This is the componentTypeId that the compositeComponentType refers to."
        }
      }
    },
    "DataConnector": {
      "type": "object",
      "properties": {
        "lambda": {
          "$ref": "#/$defs/LambdaFunction"
        },
        "isNative": {
          "type": "boolean",
          "description": "A Boolean value that specifies whether the data connector is native to IoT TwinMaker."
        }
      }
    },
    "DataType": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "The underlying type of the data type."
        },
        "nestedType": {
          "$ref": "#/$defs/DataType"
        },
        "allowedValues": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/DataValue"
          },
          "description": "The allowed values for this data type."
        },
        "unitOfMeasure": {
          "type": "string",
          "description": "The unit of measure used in this data type."
        },
        "relationship": {
          "$ref": "#/$defs/Relationship"
        }
      },
      "required": [
        "type"
      ]
    },
    "DataValue": {
      "type": "object",
      "properties": {
        "booleanValue": {
          "type": "boolean",
          "description": "A Boolean value."
        },
        "doubleValue": {
          "type": "number",
          "description": "A double value."
        },
        "integerValue": {
          "type": "integer",
          "description": "An integer value."
        },
        "longValue": {
          "type": "integer",
          "description": "A long value."
        },
        "stringValue": {
          "type": "string",
          "description": "A string value."
        },
        "listValue": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/DataValue"
          },
          "description": "A list of multiple values."
        },
        "mapValue": {
          "type": "object",
          "additionalProperties": {
            "$ref": "#/$defs/DataValue"
          },
          "description": "An object that maps strings to multiple DataValue objects."
        },
        "relationshipValue": {
          "$ref": "#/$defs/RelationshipValue"
        },
        "expression": {
          "type": "string",
          "description": "An expression that produces the value."
        }
      }
    },
    "FunctionRequest": {
      "type": "object",
      "properties": {
        "requiredProperties": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "The required properties of the function."
        },
        "scope": {
          "type": "string",
          "description": "The scope of the function."
        },
        "implementedBy": {
          "$ref": "#/$defs/DataConnector"
        }
      }
    },
    "LambdaFunction": {
      "type": "object",
      "properties": {
        "arn": {
          "type": "string",
          "description": "The ARN of the Lambda function."
        }
      },
      "required": [
        "arn"
      ]
    },
    "PropertyDefinitionRequest": {
      "type": "object",
      "properties": {
        "dataType": {
          "$ref": "#/$defs/DataType"
        },
        "isRequiredInEntity": {
          "type": "boolean",
          "description": "A Boolean value that specifies whether the property is required."
        },
        "isExternalId": {
          "type": "boolean",
          "description": "A Boolean value that specifies whether the property ID comes from an external data store."
        },
        "isStoredExternally": {
          "type": "boolean",
          "description": "A Boolean value that specifies whether the property is stored externally."
        },
        "isTimeSeries": {
          "type": "boolean",
          "description": "A Boolean value that specifies whether the property consists of time series data."
        },
        "defaultValue": {
          "$ref": "#/$defs/DataValue"
        },
        "configuration": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "A mapping that specifies configuration information about the property. Use this field to specify information that you read from and write to an external source."
        },
        "displayName": {
          "type": "string",
          "description": "A friendly name for the property."
        }
      }
    },
    "PropertyGroupRequest": {
      "type": "object",
      "properties": {
        "groupType": {
          "type": "string",
          "description": "The group type."
        },
        "propertyNames": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "The names of properties."
        }
      }
    },
    "Relationship": {
      "type": "object",
      "properties": {
        "targetComponentTypeId": {
          "type": "string",
          "description": "The ID of the target component type associated with this relationship."
        },
        "relationshipType": {
          "type": "string",
          "description": "The type of the relationship."
        }
      }
    },
    "RelationshipValue": {
      "type": "object",
      "properties": {
        "targetEntityId": {
          "type": "string",
          "description": "The ID of the target entity associated with this relationship value."
        },
        "targetComponentName": {
          "type": "string",
          "description": "The name of the target component associated with the relationship value."
        }
      }
    }
  }
}