associate_targets_with_job
(**kwargs)¶Associates a group with a continuous job. The following criteria must be met:
targetSelection
field set to "CONTINUOUS".Requires permission to access the AssociateTargetsWithJob action.
See also: AWS API Documentation
Request Syntax
response = client.associate_targets_with_job(
targets=[
'string',
],
jobId='string',
comment='string',
namespaceId='string'
)
[REQUIRED]
A list of thing group ARNs that define the targets of the job.
[REQUIRED]
The unique identifier you assigned to this job when it was created.
The namespace used to indicate that a job is a customer-managed job.
When you specify a value for this parameter, Amazon Web Services IoT Core sends jobs notifications to MQTT topics that contain the value in the following format.
$aws/things/THING_NAME/jobs/JOB_ID/notify-namespace-NAMESPACE_ID/
Note
The namespaceId
feature is in public preview.
dict
Response Syntax
{
'jobArn': 'string',
'jobId': 'string',
'description': 'string'
}
Response Structure
(dict) --
jobArn (string) --
An ARN identifying the job.
jobId (string) --
The unique identifier you assigned to this job when it was created.
description (string) --
A short text description of the job.
Exceptions
IoT.Client.exceptions.InvalidRequestException
IoT.Client.exceptions.ResourceNotFoundException
IoT.Client.exceptions.LimitExceededException
IoT.Client.exceptions.ThrottlingException
IoT.Client.exceptions.ServiceUnavailableException