Skip to content

UpdateThingRequest

Source code in docs_src/capo_iot/types/update_thing_request.py
class UpdateThingRequest(TypedDict, closed=True):
    thing_name: "capo_iot.types.thing_name.ThingName"
    """<p>The name of the thing to update.</p> <p>You can't change a thing's name. To change a thing's name, you must create a new thing, give it the new name, and then delete the old thing.</p>"""
    thing_type_name: NotRequired["capo_iot.types.thing_type_name.ThingTypeName"]
    """<p>The name of the thing type.</p>"""
    attribute_payload: NotRequired["capo_iot.types.attribute_payload.AttributePayload"]
    r"""<p>A list of thing attributes, a JSON string containing name-value pairs. For example:</p> <p> <code>{\"attributes\":{\"name1\":\"value2\"}}</code> </p> <p>This data is used to add new attributes or update existing attributes.</p>"""
    expected_version: NotRequired["capo_iot.types.optional_version.OptionalVersion"]
    """<p>The expected version of the thing record in the registry. If the version of the record in the registry does not match the expected version specified in the request, the <code>UpdateThing</code> request is rejected with a <code>VersionConflictException</code>.</p>"""
    remove_thing_type: "capo_iot.types.remove_thing_type.RemoveThingType"
    """<p>Remove a thing type association. If <b>true</b>, the association is removed.</p>"""

attribute_payload instance-attribute

attribute_payload: NotRequired[AttributePayload]

A list of thing attributes, a JSON string containing name-value pairs. For example:

{\"attributes\":{\"name1\":\"value2\"}}

This data is used to add new attributes or update existing attributes.

expected_version instance-attribute

expected_version: NotRequired[OptionalVersion]

The expected version of the thing record in the registry. If the version of the record in the registry does not match the expected version specified in the request, the UpdateThing request is rejected with a VersionConflictException.

remove_thing_type instance-attribute

remove_thing_type: RemoveThingType

Remove a thing type association. If true, the association is removed.

thing_name instance-attribute

thing_name: ThingName

The name of the thing to update.

You can't change a thing's name. To change a thing's name, you must create a new thing, give it the new name, and then delete the old thing.

thing_type_name instance-attribute

thing_type_name: NotRequired[ThingTypeName]

The name of the thing type.