batch_update_detector
(**kwargs)¶Updates the state, variable values, and timer settings of one or more detectors (instances) of a specified detector model.
See also: AWS API Documentation
Request Syntax
response = client.batch_update_detector(
detectors=[
{
'messageId': 'string',
'detectorModelName': 'string',
'keyValue': 'string',
'state': {
'stateName': 'string',
'variables': [
{
'name': 'string',
'value': 'string'
},
],
'timers': [
{
'name': 'string',
'seconds': 123
},
]
}
},
]
)
[REQUIRED]
The list of detectors (instances) to update, along with the values to update.
Information used to update the detector (instance).
The ID to assign to the detector update "message"
. Each "messageId"
must be unique within each batch sent.
The name of the detector model that created the detectors (instances).
The value of the input key attribute (identifying the device or system) that caused the creation of this detector (instance).
The new state, variable values, and timer settings of the detector (instance).
The name of the new state of the detector (instance).
The new values of the detector's variables. Any variable whose value isn't specified is cleared.
The new value of the variable.
The name of the variable.
The new value of the variable.
The new values of the detector's timers. Any timer whose value isn't specified is cleared, and its timeout event won't occur.
The new setting of a timer.
The name of the timer.
The new setting of the timer (the number of seconds before the timer elapses).
{
'batchUpdateDetectorErrorEntries': [
{
'messageId': 'string',
'errorCode': 'ResourceNotFoundException'|'InvalidRequestException'|'InternalFailureException'|'ServiceUnavailableException'|'ThrottlingException',
'errorMessage': 'string'
},
]
}
Response Structure
A list of those detector updates that resulted in errors. (If an error is listed here, the specific update did not occur.)
Information about the error that occurred when attempting to update a detector.
The "messageId"
of the update request that caused the error. (The value of the "messageId"
in the update request "Detector"
object.)
The error code.
A message that describes the error.
Exceptions
IoTEventsData.Client.exceptions.InvalidRequestException
IoTEventsData.Client.exceptions.InternalFailureException
IoTEventsData.Client.exceptions.ServiceUnavailableException
IoTEventsData.Client.exceptions.ThrottlingException