Thing types are immutable. They can't be changed after they are defined. You can, however, deprecate a thing type to prevent users from associating any new things with it. All existing things associated with the thing type are unchanged.
To deprecate a thing type, use the DeprecateThingType command:
$ aws iot deprecate-thing-type --thing-type-name "myThingType"
You can use the DescribeThingType command to see the result:
$ aws iot describe-thing-type --thing-type-name "StopLight":
{
"thingTypeName": "StopLight",
"thingTypeProperties": {
"searchableAttributes": [
"wattage",
"numOfLights",
"model"
],
"thingTypeDescription": "traffic light type",
},
"thingTypeMetadata": {
"deprecated": true,
"creationDate": 1468425854308,
"deprecationDate": 1468446026349
}
}
Deprecating a thing type is a reversible operation. You can undo a deprecation by
using the --undo-deprecate
flag with the
DeprecateThingType CLI command:
$ aws iot deprecate-thing-type --thing-type-name "myThingType" --undo-deprecate
You can use the DescribeThingType CLI command to see the result:
$ aws iot describe-thing-type --thing-type-name "StopLight":
{
"thingTypeName": "StopLight",
"thingTypeArn": "arn:aws:iot:us-east-1:123456789012:thingtype/StopLight",
"thingTypeId": "12345678abcdefgh12345678ijklmnop12345678"
"thingTypeProperties": {
"searchableAttributes": [
"wattage",
"numOfLights",
"model"
],
"thingTypeDescription": "traffic light type"
},
"thingTypeMetadata": {
"deprecated": false,
"creationDate": 1468425854308,
}
}