Class: AWS.Iot
- Inherits:
-
AWS.Service
- Object
- AWS.Service
- AWS.Iot
- Identifier:
- iot
- API Version:
- 2015-05-28
- Defined in:
- (unknown)
Overview
Constructs a service interface object. Each API operation is exposed as a function on service.
Service Description
IoT provides secure, bi-directional communication between Internet-connected devices (such as sensors, actuators, embedded devices, or smart appliances) and the Amazon Web Services cloud. You can discover your custom IoT-Data endpoint to communicate with, configure rules for data processing and integration with other services, organize resources associated with each device (Registry), configure logging, and create and manage policies and credentials to authenticate devices.
The service endpoints that expose this API are listed in Amazon Web Services IoT Core Endpoints and Quotas. You must use the endpoint for the region that has the resources you want to access.
The service name used by Amazon Web Services Signature Version 4 to sign the request is: execute-api.
For more information about how IoT works, see the Developer Guide.
For information about how to use the credentials provider for IoT, see Authorizing Direct Calls to Amazon Web Services Services.
Sending a Request Using Iot
var iot = new AWS.Iot();
iot.associateTargetsWithJob(params, function (err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Locking the API Version
In order to ensure that the Iot object uses this specific API, you can
construct the object by passing the apiVersion
option to the constructor:
var iot = new AWS.Iot({apiVersion: '2015-05-28'});
You can also set the API version globally in AWS.config.apiVersions
using
the iot service identifier:
AWS.config.apiVersions = {
iot: '2015-05-28',
// other service API versions
};
var iot = new AWS.Iot();
Version:
-
2015-05-28
Constructor Summary collapse
-
new AWS.Iot(options = {}) ⇒ Object
constructor
Constructs a service object.
Property Summary collapse
-
endpoint ⇒ AWS.Endpoint
readwrite
An Endpoint object representing the endpoint URL for service requests.
Properties inherited from AWS.Service
Method Summary collapse
-
acceptCertificateTransfer(params = {}, callback) ⇒ AWS.Request
Accepts a pending certificate transfer.
- addThingToBillingGroup(params = {}, callback) ⇒ AWS.Request
- addThingToThingGroup(params = {}, callback) ⇒ AWS.Request
-
associateTargetsWithJob(params = {}, callback) ⇒ AWS.Request
Associates a group with a continuous job.
-
attachPolicy(params = {}, callback) ⇒ AWS.Request
Attaches the specified policy to the specified principal (certificate or other credential).
Requires permission to access the AttachPolicy action.
. -
attachPrincipalPolicy(params = {}, callback) ⇒ AWS.Request
Attaches the specified policy to the specified principal (certificate or other credential).
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements.
-
attachSecurityProfile(params = {}, callback) ⇒ AWS.Request
Associates a Device Defender security profile with a thing group or this account.
-
attachThingPrincipal(params = {}, callback) ⇒ AWS.Request
Attaches the specified principal to the specified thing.
-
cancelAuditMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Cancels a mitigation action task that is in progress.
-
cancelAuditTask(params = {}, callback) ⇒ AWS.Request
Cancels an audit that is in progress.
-
cancelCertificateTransfer(params = {}, callback) ⇒ AWS.Request
Cancels a pending transfer for the specified certificate.
Note Only the transfer source account can use this operation to cancel a transfer.
-
cancelDetectMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Cancels a Device Defender ML Detect mitigation action.
- cancelJob(params = {}, callback) ⇒ AWS.Request
-
cancelJobExecution(params = {}, callback) ⇒ AWS.Request
Cancels the execution of a job for a given thing.
Requires permission to access the CancelJobExecution action.
. - clearDefaultAuthorizer(params = {}, callback) ⇒ AWS.Request
-
confirmTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Confirms a topic rule destination.
-
createAuditSuppression(params = {}, callback) ⇒ AWS.Request
Creates a Device Defender audit suppression.
- createAuthorizer(params = {}, callback) ⇒ AWS.Request
- createBillingGroup(params = {}, callback) ⇒ AWS.Request
-
createCertificateFromCsr(params = {}, callback) ⇒ AWS.Request
Creates an X.509 certificate using the specified certificate signing request.
-
createCertificateProvider(params = {}, callback) ⇒ AWS.Request
Creates an Amazon Web Services IoT Core certificate provider.
-
createCustomMetric(params = {}, callback) ⇒ AWS.Request
Use this API to define a Custom Metric published by your devices to Device Defender.
-
createDimension(params = {}, callback) ⇒ AWS.Request
Create a dimension that you can use to limit the scope of a metric used in a security profile for IoT Device Defender.
-
createDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Creates a domain configuration.
Requires permission to access the CreateDomainConfiguration action.
. - createDynamicThingGroup(params = {}, callback) ⇒ AWS.Request
- createFleetMetric(params = {}, callback) ⇒ AWS.Request
- createJob(params = {}, callback) ⇒ AWS.Request
- createJobTemplate(params = {}, callback) ⇒ AWS.Request
-
createKeysAndCertificate(params = {}, callback) ⇒ AWS.Request
Creates a 2048-bit RSA key pair and issues an X.509 certificate using the issued public key.
-
createMitigationAction(params = {}, callback) ⇒ AWS.Request
Defines an action that can be applied to audit findings by using StartAuditMitigationActionsTask.
-
createOTAUpdate(params = {}, callback) ⇒ AWS.Request
Creates an IoT OTA update on a target group of things or groups.
Requires permission to access the CreateOTAUpdate action.
. -
createPackage(params = {}, callback) ⇒ AWS.Request
Creates an IoT software package that can be deployed to your fleet.
Requires permission to access the CreatePackage and GetIndexingConfiguration actions.
. -
createPackageVersion(params = {}, callback) ⇒ AWS.Request
Creates a new version for an existing IoT software package.
Requires permission to access the CreatePackageVersion and GetIndexingConfiguration actions.
. -
createPolicy(params = {}, callback) ⇒ AWS.Request
Creates an IoT policy.
The created policy is the default version for the policy.
-
createPolicyVersion(params = {}, callback) ⇒ AWS.Request
Creates a new version of the specified IoT policy.
- createProvisioningClaim(params = {}, callback) ⇒ AWS.Request
-
createProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Creates a provisioning template.
Requires permission to access the CreateProvisioningTemplate action.
. -
createProvisioningTemplateVersion(params = {}, callback) ⇒ AWS.Request
Creates a new version of a provisioning template.
Requires permission to access the CreateProvisioningTemplateVersion action.
. - createRoleAlias(params = {}, callback) ⇒ AWS.Request
-
createScheduledAudit(params = {}, callback) ⇒ AWS.Request
Creates a scheduled audit that is run at a specified time interval.
Requires permission to access the CreateScheduledAudit action.
. -
createSecurityProfile(params = {}, callback) ⇒ AWS.Request
Creates a Device Defender security profile.
Requires permission to access the CreateSecurityProfile action.
. -
createStream(params = {}, callback) ⇒ AWS.Request
Creates a stream for delivering one or more large files in chunks over MQTT.
-
createThing(params = {}, callback) ⇒ AWS.Request
Creates a thing record in the registry.
-
createThingGroup(params = {}, callback) ⇒ AWS.Request
Create a thing group.
Note: This is a control plane operation.- createThingType(params = {}, callback) ⇒ AWS.Request
- createTopicRule(params = {}, callback) ⇒ AWS.Request
Creates a rule.
- createTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Creates a topic rule destination.
- deleteAccountAuditConfiguration(params = {}, callback) ⇒ AWS.Request
Restores the default settings for Device Defender audits for this account.
- deleteAuditSuppression(params = {}, callback) ⇒ AWS.Request
Deletes a Device Defender audit suppression.
- deleteAuthorizer(params = {}, callback) ⇒ AWS.Request
- deleteBillingGroup(params = {}, callback) ⇒ AWS.Request
- deleteCACertificate(params = {}, callback) ⇒ AWS.Request
- deleteCertificate(params = {}, callback) ⇒ AWS.Request
Deletes the specified certificate.
A certificate cannot be deleted if it has a policy or IoT thing attached to it or if its status is set to ACTIVE.
- deleteCertificateProvider(params = {}, callback) ⇒ AWS.Request
- deleteCustomMetric(params = {}, callback) ⇒ AWS.Request
Deletes a Device Defender detect custom metric.
- deleteDimension(params = {}, callback) ⇒ AWS.Request
Removes the specified dimension from your Amazon Web Services accounts.
Requires permission to access the DeleteDimension action.
.- deleteDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Deletes the specified domain configuration.
Requires permission to access the DeleteDomainConfiguration action.
.- deleteDynamicThingGroup(params = {}, callback) ⇒ AWS.Request
- deleteFleetMetric(params = {}, callback) ⇒ AWS.Request
Deletes the specified fleet metric.
- deleteJob(params = {}, callback) ⇒ AWS.Request
Deletes a job and its related job executions.
Deleting a job may take time, depending on the number of job executions created for the job and various other factors.
- deleteJobExecution(params = {}, callback) ⇒ AWS.Request
- deleteJobTemplate(params = {}, callback) ⇒ AWS.Request
Deletes the specified job template.
.
- deleteMitigationAction(params = {}, callback) ⇒ AWS.Request
Deletes a defined mitigation action from your Amazon Web Services accounts.
Requires permission to access the DeleteMitigationAction action.
.- deleteOTAUpdate(params = {}, callback) ⇒ AWS.Request
- deletePackage(params = {}, callback) ⇒ AWS.Request
Deletes a specific version from a software package.
Note: All package versions must be deleted before deleting the software package.
Requires permission to access the DeletePackageVersion action.
.- deletePackageVersion(params = {}, callback) ⇒ AWS.Request
Deletes a specific version from a software package.
Note: If a package version is designated as default, you must remove the designation from the software package using the UpdatePackage action.
.- deletePolicy(params = {}, callback) ⇒ AWS.Request
Deletes the specified policy.
A policy cannot be deleted if it has non-default versions or it is attached to any certificate.
To delete a policy, use the DeletePolicyVersion action to delete all non-default versions of the policy; use the DetachPolicy action to detach the policy from any certificate; and then use the DeletePolicy action to delete the policy.
When a policy is deleted using DeletePolicy, its default version is deleted with it.
Note: Because of the distributed nature of Amazon Web Services, it can take up to five minutes after a policy is detached before it's ready to be deleted.- deletePolicyVersion(params = {}, callback) ⇒ AWS.Request
Deletes the specified version of the specified policy.
- deleteProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Deletes a provisioning template.
Requires permission to access the DeleteProvisioningTemplate action.
.- deleteProvisioningTemplateVersion(params = {}, callback) ⇒ AWS.Request
Deletes a provisioning template version.
Requires permission to access the DeleteProvisioningTemplateVersion action.
.- deleteRegistrationCode(params = {}, callback) ⇒ AWS.Request
Deletes a CA certificate registration code.
Requires permission to access the DeleteRegistrationCode action.
.- deleteRoleAlias(params = {}, callback) ⇒ AWS.Request
- deleteScheduledAudit(params = {}, callback) ⇒ AWS.Request
- deleteSecurityProfile(params = {}, callback) ⇒ AWS.Request
Deletes a Device Defender security profile.
Requires permission to access the DeleteSecurityProfile action.
.- deleteStream(params = {}, callback) ⇒ AWS.Request
- deleteThing(params = {}, callback) ⇒ AWS.Request
Deletes the specified thing.
- deleteThingGroup(params = {}, callback) ⇒ AWS.Request
- deleteThingType(params = {}, callback) ⇒ AWS.Request
Deletes the specified thing type.
- deleteTopicRule(params = {}, callback) ⇒ AWS.Request
- deleteTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Deletes a topic rule destination.
Requires permission to access the DeleteTopicRuleDestination action.
.- deleteV2LoggingLevel(params = {}, callback) ⇒ AWS.Request
- deprecateThingType(params = {}, callback) ⇒ AWS.Request
Deprecates a thing type.
- describeAccountAuditConfiguration(params = {}, callback) ⇒ AWS.Request
Gets information about the Device Defender audit settings for this account.
- describeAuditFinding(params = {}, callback) ⇒ AWS.Request
Gets information about a single audit finding.
- describeAuditMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Gets information about an audit mitigation task that is used to apply mitigation actions to a set of audit findings.
- describeAuditSuppression(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender audit suppression.
- describeAuditTask(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender audit.
Requires permission to access the DescribeAuditTask action.
.- describeAuthorizer(params = {}, callback) ⇒ AWS.Request
- describeBillingGroup(params = {}, callback) ⇒ AWS.Request
Returns information about a billing group.
Requires permission to access the DescribeBillingGroup action.
.- describeCACertificate(params = {}, callback) ⇒ AWS.Request
Describes a registered CA certificate.
Requires permission to access the DescribeCACertificate action.
.- describeCertificate(params = {}, callback) ⇒ AWS.Request
Gets information about the specified certificate.
Requires permission to access the DescribeCertificate action.
.- describeCertificateProvider(params = {}, callback) ⇒ AWS.Request
Describes a certificate provider.
Requires permission to access the DescribeCertificateProvider action.
- describeCustomMetric(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender detect custom metric.
- describeDefaultAuthorizer(params = {}, callback) ⇒ AWS.Request
Describes the default authorizer.
Requires permission to access the DescribeDefaultAuthorizer action.
.- describeDetectMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender ML Detect mitigation action.
- describeDimension(params = {}, callback) ⇒ AWS.Request
Provides details about a dimension that is defined in your Amazon Web Services accounts.
Requires permission to access the DescribeDimension action.
.- describeDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Gets summary information about a domain configuration.
Requires permission to access the DescribeDomainConfiguration action.
.- describeEndpoint(params = {}, callback) ⇒ AWS.Request
Returns or creates a unique endpoint specific to the Amazon Web Services account making the call.
Note: The first timeDescribeEndpoint
is called, an endpoint is created.- describeEventConfigurations(params = {}, callback) ⇒ AWS.Request
Describes event configurations.
Requires permission to access the DescribeEventConfigurations action.
.- describeFleetMetric(params = {}, callback) ⇒ AWS.Request
Gets information about the specified fleet metric.
Requires permission to access the DescribeFleetMetric action.
.- describeIndex(params = {}, callback) ⇒ AWS.Request
- describeJob(params = {}, callback) ⇒ AWS.Request
- describeJobExecution(params = {}, callback) ⇒ AWS.Request
- describeJobTemplate(params = {}, callback) ⇒ AWS.Request
Returns information about a job template.
.
- describeManagedJobTemplate(params = {}, callback) ⇒ AWS.Request
View details of a managed job template.
.
- describeMitigationAction(params = {}, callback) ⇒ AWS.Request
Gets information about a mitigation action.
Requires permission to access the DescribeMitigationAction action.
.- describeProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Returns information about a provisioning template.
Requires permission to access the DescribeProvisioningTemplate action.
.- describeProvisioningTemplateVersion(params = {}, callback) ⇒ AWS.Request
Returns information about a provisioning template version.
Requires permission to access the DescribeProvisioningTemplateVersion action.
.- describeRoleAlias(params = {}, callback) ⇒ AWS.Request
- describeScheduledAudit(params = {}, callback) ⇒ AWS.Request
Gets information about a scheduled audit.
Requires permission to access the DescribeScheduledAudit action.
.- describeSecurityProfile(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender security profile.
Requires permission to access the DescribeSecurityProfile action.
.- describeStream(params = {}, callback) ⇒ AWS.Request
- describeThing(params = {}, callback) ⇒ AWS.Request
Gets information about the specified thing.
Requires permission to access the DescribeThing action.
.- describeThingGroup(params = {}, callback) ⇒ AWS.Request
- describeThingRegistrationTask(params = {}, callback) ⇒ AWS.Request
Describes a bulk thing provisioning task.
Requires permission to access the DescribeThingRegistrationTask action.
.- describeThingType(params = {}, callback) ⇒ AWS.Request
Gets information about the specified thing type.
Requires permission to access the DescribeThingType action.
.- detachPolicy(params = {}, callback) ⇒ AWS.Request
Detaches a policy from the specified target.
Note: Because of the distributed nature of Amazon Web Services, it can take up to five minutes after a policy is detached before it's ready to be deleted.- detachPrincipalPolicy(params = {}, callback) ⇒ AWS.Request
Removes the specified policy from the specified certificate.
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements.
- detachSecurityProfile(params = {}, callback) ⇒ AWS.Request
Disassociates a Device Defender security profile from a thing group or from this account.
Requires permission to access the DetachSecurityProfile action.
.- detachThingPrincipal(params = {}, callback) ⇒ AWS.Request
Detaches the specified principal from the specified thing.
- disableTopicRule(params = {}, callback) ⇒ AWS.Request
- enableTopicRule(params = {}, callback) ⇒ AWS.Request
- getBehaviorModelTrainingSummaries(params = {}, callback) ⇒ AWS.Request
Returns a Device Defender's ML Detect Security Profile training model's status.
- getBucketsAggregation(params = {}, callback) ⇒ AWS.Request
Aggregates on indexed data with search queries pertaining to particular fields.
- getCardinality(params = {}, callback) ⇒ AWS.Request
Returns the approximate count of unique values that match the query.
Requires permission to access the GetCardinality action.
.- getEffectivePolicies(params = {}, callback) ⇒ AWS.Request
Gets a list of the policies that have an effect on the authorization behavior of the specified device when it connects to the IoT device gateway.
Requires permission to access the GetEffectivePolicies action.
.- getIndexingConfiguration(params = {}, callback) ⇒ AWS.Request
Gets the indexing configuration.
Requires permission to access the GetIndexingConfiguration action.
.- getJobDocument(params = {}, callback) ⇒ AWS.Request
- getLoggingOptions(params = {}, callback) ⇒ AWS.Request
Gets the logging options.
NOTE: use of this command is not recommended.
- getOTAUpdate(params = {}, callback) ⇒ AWS.Request
- getPackage(params = {}, callback) ⇒ AWS.Request
Gets information about the specified software package.
Requires permission to access the GetPackage action.
.- getPackageConfiguration(params = {}, callback) ⇒ AWS.Request
Gets information about the specified software package's configuration.
Requires permission to access the GetPackageConfiguration action.
.- getPackageVersion(params = {}, callback) ⇒ AWS.Request
Gets information about the specified package version.
- getPercentiles(params = {}, callback) ⇒ AWS.Request
Groups the aggregated values that match the query into percentile groupings.
- getPolicy(params = {}, callback) ⇒ AWS.Request
Gets information about the specified policy with the policy document of the default version.
Requires permission to access the GetPolicy action.
.- getPolicyVersion(params = {}, callback) ⇒ AWS.Request
Gets information about the specified policy version.
Requires permission to access the GetPolicyVersion action.
.- getRegistrationCode(params = {}, callback) ⇒ AWS.Request
Gets a registration code used to register a CA certificate with IoT.
IoT will create a registration code as part of this API call if the registration code doesn't exist or has been deleted.
- getStatistics(params = {}, callback) ⇒ AWS.Request
Returns the count, average, sum, minimum, maximum, sum of squares, variance, and standard deviation for the specified aggregated field.
- getTopicRule(params = {}, callback) ⇒ AWS.Request
- getTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Gets information about a topic rule destination.
Requires permission to access the GetTopicRuleDestination action.
.- getV2LoggingOptions(params = {}, callback) ⇒ AWS.Request
Gets the fine grained logging options.
Requires permission to access the GetV2LoggingOptions action.
.- listActiveViolations(params = {}, callback) ⇒ AWS.Request
Lists the active violations for a given Device Defender security profile.
Requires permission to access the ListActiveViolations action.
.- listAttachedPolicies(params = {}, callback) ⇒ AWS.Request
Lists the policies attached to the specified thing group.
Requires permission to access the ListAttachedPolicies action.
.- listAuditFindings(params = {}, callback) ⇒ AWS.Request
Lists the findings (results) of a Device Defender audit or of the audits performed during a specified time period.
- listAuditMitigationActionsExecutions(params = {}, callback) ⇒ AWS.Request
Gets the status of audit mitigation action tasks that were executed.
Requires permission to access the ListAuditMitigationActionsExecutions action.
.- listAuditMitigationActionsTasks(params = {}, callback) ⇒ AWS.Request
Gets a list of audit mitigation action tasks that match the specified filters.
Requires permission to access the ListAuditMitigationActionsTasks action.
.- listAuditSuppressions(params = {}, callback) ⇒ AWS.Request
Lists your Device Defender audit listings.
- listAuditTasks(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender audits that have been performed during a given time period.
Requires permission to access the ListAuditTasks action.
.- listAuthorizers(params = {}, callback) ⇒ AWS.Request
Lists the authorizers registered in your account.
Requires permission to access the ListAuthorizers action.
.- listBillingGroups(params = {}, callback) ⇒ AWS.Request
Lists the billing groups you have created.
Requires permission to access the ListBillingGroups action.
.- listCACertificates(params = {}, callback) ⇒ AWS.Request
Lists the CA certificates registered for your Amazon Web Services account.
The results are paginated with a default page size of 25.
- listCertificateProviders(params = {}, callback) ⇒ AWS.Request
Lists all your certificate providers in your Amazon Web Services account.
Requires permission to access the ListCertificateProviders action.
- listCertificates(params = {}, callback) ⇒ AWS.Request
Lists the certificates registered in your Amazon Web Services account.
The results are paginated with a default page size of 25.
- listCertificatesByCA(params = {}, callback) ⇒ AWS.Request
List the device certificates signed by the specified CA certificate.
Requires permission to access the ListCertificatesByCA action.
.- listCustomMetrics(params = {}, callback) ⇒ AWS.Request
Lists your Device Defender detect custom metrics.
- listDetectMitigationActionsExecutions(params = {}, callback) ⇒ AWS.Request
Lists mitigation actions executions for a Device Defender ML Detect Security Profile.
- listDetectMitigationActionsTasks(params = {}, callback) ⇒ AWS.Request
List of Device Defender ML Detect mitigation actions tasks.
- listDimensions(params = {}, callback) ⇒ AWS.Request
List the set of dimensions that are defined for your Amazon Web Services accounts.
Requires permission to access the ListDimensions action.
.- listDomainConfigurations(params = {}, callback) ⇒ AWS.Request
Gets a list of domain configurations for the user.
- listFleetMetrics(params = {}, callback) ⇒ AWS.Request
Lists all your fleet metrics.
- listIndices(params = {}, callback) ⇒ AWS.Request
- listJobExecutionsForJob(params = {}, callback) ⇒ AWS.Request
Lists the job executions for a job.
Requires permission to access the ListJobExecutionsForJob action.
.- listJobExecutionsForThing(params = {}, callback) ⇒ AWS.Request
Lists the job executions for the specified thing.
Requires permission to access the ListJobExecutionsForThing action.
.- listJobs(params = {}, callback) ⇒ AWS.Request
- listJobTemplates(params = {}, callback) ⇒ AWS.Request
- listManagedJobTemplates(params = {}, callback) ⇒ AWS.Request
Returns a list of managed job templates.
.
- listMetricValues(params = {}, callback) ⇒ AWS.Request
Lists the values reported for an IoT Device Defender metric (device-side metric, cloud-side metric, or custom metric) by the given thing during the specified time period.
.
- listMitigationActions(params = {}, callback) ⇒ AWS.Request
Gets a list of all mitigation actions that match the specified filter criteria.
Requires permission to access the ListMitigationActions action.
.- listOTAUpdates(params = {}, callback) ⇒ AWS.Request
- listOutgoingCertificates(params = {}, callback) ⇒ AWS.Request
Lists certificates that are being transferred but not yet accepted.
Requires permission to access the ListOutgoingCertificates action.
.- listPackages(params = {}, callback) ⇒ AWS.Request
Lists the software packages associated to the account.
Requires permission to access the ListPackages action.
.- listPackageVersions(params = {}, callback) ⇒ AWS.Request
Lists the software package versions associated to the account.
Requires permission to access the ListPackageVersions action.
.- listPolicies(params = {}, callback) ⇒ AWS.Request
- listPolicyPrincipals(params = {}, callback) ⇒ AWS.Request
Lists the principals associated with the specified policy.
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements.
- listPolicyVersions(params = {}, callback) ⇒ AWS.Request
Lists the versions of the specified policy and identifies the default version.
Requires permission to access the ListPolicyVersions action.
.- listPrincipalPolicies(params = {}, callback) ⇒ AWS.Request
Lists the policies attached to the specified principal.
- listPrincipalThings(params = {}, callback) ⇒ AWS.Request
Lists the things associated with the specified principal.
- listProvisioningTemplates(params = {}, callback) ⇒ AWS.Request
Lists the provisioning templates in your Amazon Web Services account.
Requires permission to access the ListProvisioningTemplates action.
.- listProvisioningTemplateVersions(params = {}, callback) ⇒ AWS.Request
A list of provisioning template versions.
Requires permission to access the ListProvisioningTemplateVersions action.
.- listRelatedResourcesForAuditFinding(params = {}, callback) ⇒ AWS.Request
The related resources of an Audit finding.
- listRoleAliases(params = {}, callback) ⇒ AWS.Request
Lists the role aliases registered in your account.
Requires permission to access the ListRoleAliases action.
.- listScheduledAudits(params = {}, callback) ⇒ AWS.Request
- listSecurityProfiles(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender security profiles you've created.
- listSecurityProfilesForTarget(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender security profiles attached to a target (thing group).
Requires permission to access the ListSecurityProfilesForTarget action.
.- listStreams(params = {}, callback) ⇒ AWS.Request
Lists all of the streams in your Amazon Web Services account.
Requires permission to access the ListStreams action.
.- listTagsForResource(params = {}, callback) ⇒ AWS.Request
Lists the tags (metadata) you have assigned to the resource.
Requires permission to access the ListTagsForResource action.
.- listTargetsForPolicy(params = {}, callback) ⇒ AWS.Request
List targets for the specified policy.
Requires permission to access the ListTargetsForPolicy action.
.- listTargetsForSecurityProfile(params = {}, callback) ⇒ AWS.Request
Lists the targets (thing groups) associated with a given Device Defender security profile.
Requires permission to access the ListTargetsForSecurityProfile action.
.- listThingGroups(params = {}, callback) ⇒ AWS.Request
- listThingGroupsForThing(params = {}, callback) ⇒ AWS.Request
List the thing groups to which the specified thing belongs.
Requires permission to access the ListThingGroupsForThing action.
.- listThingPrincipals(params = {}, callback) ⇒ AWS.Request
Lists the principals associated with the specified thing.
- listThingRegistrationTaskReports(params = {}, callback) ⇒ AWS.Request
Information about the thing registration tasks.
.
- listThingRegistrationTasks(params = {}, callback) ⇒ AWS.Request
List bulk thing provisioning tasks.
Requires permission to access the ListThingRegistrationTasks action.
.- listThings(params = {}, callback) ⇒ AWS.Request
Lists your things.
- listThingsInBillingGroup(params = {}, callback) ⇒ AWS.Request
Lists the things you have added to the given billing group.
Requires permission to access the ListThingsInBillingGroup action.
.- listThingsInThingGroup(params = {}, callback) ⇒ AWS.Request
Lists the things in the specified group.
Requires permission to access the ListThingsInThingGroup action.
.- listThingTypes(params = {}, callback) ⇒ AWS.Request
- listTopicRuleDestinations(params = {}, callback) ⇒ AWS.Request
Lists all the topic rule destinations in your Amazon Web Services account.
Requires permission to access the ListTopicRuleDestinations action.
.- listTopicRules(params = {}, callback) ⇒ AWS.Request
- listV2LoggingLevels(params = {}, callback) ⇒ AWS.Request
- listViolationEvents(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender security profile violations discovered during the given time period.
- putVerificationStateOnViolation(params = {}, callback) ⇒ AWS.Request
Set a verification state and provide a description of that verification state on a violation (detect alarm).
.
- registerCACertificate(params = {}, callback) ⇒ AWS.Request
Registers a CA certificate with Amazon Web Services IoT Core.
- registerCertificate(params = {}, callback) ⇒ AWS.Request
Registers a device certificate with IoT in the same certificate mode as the signing CA.
- registerCertificateWithoutCA(params = {}, callback) ⇒ AWS.Request
Register a certificate that does not have a certificate authority (CA).
- registerThing(params = {}, callback) ⇒ AWS.Request
Provisions a thing in the device registry.
- rejectCertificateTransfer(params = {}, callback) ⇒ AWS.Request
Rejects a pending certificate transfer.
- removeThingFromBillingGroup(params = {}, callback) ⇒ AWS.Request
Removes the given thing from the billing group.
Requires permission to access the RemoveThingFromBillingGroup action.
Note: This call is asynchronous.- removeThingFromThingGroup(params = {}, callback) ⇒ AWS.Request
Remove the specified thing from the specified group.
You must specify either a
thingGroupArn
or athingGroupName
to identify the thing group and either athingArn
or athingName
to identify the thing to remove from the thing group.- replaceTopicRule(params = {}, callback) ⇒ AWS.Request
Replaces the rule.
- searchIndex(params = {}, callback) ⇒ AWS.Request
- setDefaultAuthorizer(params = {}, callback) ⇒ AWS.Request
Sets the default authorizer.
- setDefaultPolicyVersion(params = {}, callback) ⇒ AWS.Request
Sets the specified version of the specified policy as the policy's default (operative) version.
- setLoggingOptions(params = {}, callback) ⇒ AWS.Request
Sets the logging options.
NOTE: use of this command is not recommended.
- setV2LoggingLevel(params = {}, callback) ⇒ AWS.Request
- setV2LoggingOptions(params = {}, callback) ⇒ AWS.Request
Sets the logging options for the V2 logging service.
Requires permission to access the SetV2LoggingOptions action.
.- startAuditMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Starts a task that applies a set of mitigation actions to the specified target.
Requires permission to access the StartAuditMitigationActionsTask action.
.- startDetectMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Starts a Device Defender ML Detect mitigation actions task.
- startOnDemandAuditTask(params = {}, callback) ⇒ AWS.Request
Starts an on-demand Device Defender audit.
Requires permission to access the StartOnDemandAuditTask action.
.- startThingRegistrationTask(params = {}, callback) ⇒ AWS.Request
Creates a bulk thing provisioning task.
Requires permission to access the StartThingRegistrationTask action.
.- stopThingRegistrationTask(params = {}, callback) ⇒ AWS.Request
Cancels a bulk thing provisioning task.
Requires permission to access the StopThingRegistrationTask action.
.- tagResource(params = {}, callback) ⇒ AWS.Request
Adds to or modifies the tags of the given resource.
- testAuthorization(params = {}, callback) ⇒ AWS.Request
Tests if a specified principal is authorized to perform an IoT action on a specified resource.
- testInvokeAuthorizer(params = {}, callback) ⇒ AWS.Request
Tests a custom authorization behavior by invoking a specified custom authorizer.
- transferCertificate(params = {}, callback) ⇒ AWS.Request
Transfers the specified certificate to the specified Amazon Web Services account.
Requires permission to access the TransferCertificate action.
You can cancel the transfer until it is acknowledged by the recipient.
No notification is sent to the transfer destination's account.
- untagResource(params = {}, callback) ⇒ AWS.Request
Removes the given tags (metadata) from the resource.
Requires permission to access the UntagResource action.
.- updateAccountAuditConfiguration(params = {}, callback) ⇒ AWS.Request
Configures or reconfigures the Device Defender audit settings for this account.
- updateAuditSuppression(params = {}, callback) ⇒ AWS.Request
Updates a Device Defender audit suppression.
- updateAuthorizer(params = {}, callback) ⇒ AWS.Request
- updateBillingGroup(params = {}, callback) ⇒ AWS.Request
Updates information about the billing group.
Requires permission to access the UpdateBillingGroup action.
.- updateCACertificate(params = {}, callback) ⇒ AWS.Request
- updateCertificate(params = {}, callback) ⇒ AWS.Request
Updates the status of the specified certificate.
- updateCertificateProvider(params = {}, callback) ⇒ AWS.Request
- updateCustomMetric(params = {}, callback) ⇒ AWS.Request
Updates a Device Defender detect custom metric.
- updateDimension(params = {}, callback) ⇒ AWS.Request
Updates the definition for a dimension.
- updateDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Updates values stored in the domain configuration.
- updateDynamicThingGroup(params = {}, callback) ⇒ AWS.Request
- updateEventConfigurations(params = {}, callback) ⇒ AWS.Request
Updates the event configurations.
Requires permission to access the UpdateEventConfigurations action.
.- updateFleetMetric(params = {}, callback) ⇒ AWS.Request
- updateIndexingConfiguration(params = {}, callback) ⇒ AWS.Request
Updates the search configuration.
Requires permission to access the UpdateIndexingConfiguration action.
.- updateJob(params = {}, callback) ⇒ AWS.Request
- updateMitigationAction(params = {}, callback) ⇒ AWS.Request
Updates the definition for the specified mitigation action.
Requires permission to access the UpdateMitigationAction action.
.- updatePackage(params = {}, callback) ⇒ AWS.Request
Updates the supported fields for a specific software package.
Requires permission to access the UpdatePackage and GetIndexingConfiguration actions.
.- updatePackageConfiguration(params = {}, callback) ⇒ AWS.Request
Updates the software package configuration.
Requires permission to access the UpdatePackageConfiguration and iam:PassRole actions.
.- updatePackageVersion(params = {}, callback) ⇒ AWS.Request
Updates the supported fields for a specific package version.
Requires permission to access the UpdatePackageVersion and GetIndexingConfiguration actions.
.- updateProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Updates a provisioning template.
Requires permission to access the UpdateProvisioningTemplate action.
.- updateRoleAlias(params = {}, callback) ⇒ AWS.Request
- updateScheduledAudit(params = {}, callback) ⇒ AWS.Request
Updates a scheduled audit, including which checks are performed and how often the audit takes place.
Requires permission to access the UpdateScheduledAudit action.
.- updateSecurityProfile(params = {}, callback) ⇒ AWS.Request
Updates a Device Defender security profile.
Requires permission to access the UpdateSecurityProfile action.
.- updateStream(params = {}, callback) ⇒ AWS.Request
Updates an existing stream.
- updateThing(params = {}, callback) ⇒ AWS.Request
- updateThingGroup(params = {}, callback) ⇒ AWS.Request
- updateThingGroupsForThing(params = {}, callback) ⇒ AWS.Request
Updates the groups to which the thing belongs.
Requires permission to access the UpdateThingGroupsForThing action.
.- updateTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Updates a topic rule destination.
- validateSecurityProfileBehaviors(params = {}, callback) ⇒ AWS.Request
Validates a Device Defender security profile behaviors specification.
Requires permission to access the ValidateSecurityProfileBehaviors action.
.Methods inherited from AWS.Service
makeRequest, makeUnauthenticatedRequest, waitFor, setupRequestListeners, defineService
Constructor Details
new AWS.Iot(options = {}) ⇒ Object
Constructs a service object. This object has one method for each API operation.
Examples:
Constructing a Iot object
var iot = new AWS.Iot({apiVersion: '2015-05-28'});
Options Hash (options):
-
params
(map)
—
An optional map of parameters to bind to every request sent by this service object. For more information on bound parameters, see "Working with Services" in the Getting Started Guide.
-
endpoint
(String|AWS.Endpoint)
—
The endpoint URI to send requests to. The default endpoint is built from the configured
region
. The endpoint should be a string like'https://{service}.{region}.amazonaws.com'
or an Endpoint object. -
accessKeyId
(String)
—
your AWS access key ID.
-
secretAccessKey
(String)
—
your AWS secret access key.
-
sessionToken
(AWS.Credentials)
—
the optional AWS session token to sign requests with.
-
credentials
(AWS.Credentials)
—
the AWS credentials to sign requests with. You can either specify this object, or specify the accessKeyId and secretAccessKey options directly.
-
credentialProvider
(AWS.CredentialProviderChain)
—
the provider chain used to resolve credentials if no static
credentials
property is set. -
region
(String)
—
the region to send service requests to. See AWS.Iot.region for more information.
-
maxRetries
(Integer)
—
the maximum amount of retries to attempt with a request. See AWS.Iot.maxRetries for more information.
-
maxRedirects
(Integer)
—
the maximum amount of redirects to follow with a request. See AWS.Iot.maxRedirects for more information.
-
sslEnabled
(Boolean)
—
whether to enable SSL for requests.
-
paramValidation
(Boolean|map)
—
whether input parameters should be validated against the operation description before sending the request. Defaults to true. Pass a map to enable any of the following specific validation features:
- min [Boolean] — Validates that a value meets the min
constraint. This is enabled by default when paramValidation is set
to
true
. - max [Boolean] — Validates that a value meets the max constraint.
- pattern [Boolean] — Validates that a string value matches a regular expression.
- enum [Boolean] — Validates that a string value matches one of the allowable enum values.
- min [Boolean] — Validates that a value meets the min
constraint. This is enabled by default when paramValidation is set
to
-
computeChecksums
(Boolean)
—
whether to compute checksums for payload bodies when the service accepts it (currently supported in S3 only)
-
convertResponseTypes
(Boolean)
—
whether types are converted when parsing response data. Currently only supported for JSON based services. Turning this off may improve performance on large response payloads. Defaults to
true
. -
correctClockSkew
(Boolean)
—
whether to apply a clock skew correction and retry requests that fail because of an skewed client clock. Defaults to
false
. -
s3ForcePathStyle
(Boolean)
—
whether to force path style URLs for S3 objects.
-
s3BucketEndpoint
(Boolean)
—
whether the provided endpoint addresses an individual bucket (false if it addresses the root API endpoint). Note that setting this configuration option requires an
endpoint
to be provided explicitly to the service constructor. -
s3DisableBodySigning
(Boolean)
—
whether S3 body signing should be disabled when using signature version
v4
. Body signing can only be disabled when using https. Defaults totrue
. -
s3UsEast1RegionalEndpoint
('legacy'|'regional')
—
when region is set to 'us-east-1', whether to send s3 request to global endpoints or 'us-east-1' regional endpoints. This config is only applicable to S3 client. Defaults to
legacy
-
s3UseArnRegion
(Boolean)
—
whether to override the request region with the region inferred from requested resource's ARN. Only available for S3 buckets Defaults to
true
-
retryDelayOptions
(map)
—
A set of options to configure the retry delay on retryable errors. Currently supported options are:
- base [Integer] — The base number of milliseconds to use in the exponential backoff for operation retries. Defaults to 100 ms for all services except DynamoDB, where it defaults to 50ms.
- customBackoff [function] — A custom function that accepts a
retry count and error and returns the amount of time to delay in
milliseconds. If the result is a non-zero negative value, no further
retry attempts will be made. The
base
option will be ignored if this option is supplied. The function is only called for retryable errors.
-
httpOptions
(map)
—
A set of options to pass to the low-level HTTP request. Currently supported options are:
- proxy [String] — the URL to proxy requests through
- agent [http.Agent, https.Agent] — the Agent object to perform
HTTP requests with. Used for connection pooling. Defaults to the global
agent (
http.globalAgent
) for non-SSL connections. Note that for SSL connections, a special Agent object is used in order to enable peer certificate verification. This feature is only available in the Node.js environment. - connectTimeout [Integer] — Sets the socket to timeout after
failing to establish a connection with the server after
connectTimeout
milliseconds. This timeout has no effect once a socket connection has been established. - timeout [Integer] — Sets the socket to timeout after timeout milliseconds of inactivity on the socket. Defaults to two minutes (120000).
- xhrAsync [Boolean] — Whether the SDK will send asynchronous HTTP requests. Used in the browser environment only. Set to false to send requests synchronously. Defaults to true (async on).
- xhrWithCredentials [Boolean] — Sets the "withCredentials" property of an XMLHttpRequest object. Used in the browser environment only. Defaults to false.
-
apiVersion
(String, Date)
—
a String in YYYY-MM-DD format (or a date) that represents the latest possible API version that can be used in all services (unless overridden by
apiVersions
). Specify 'latest' to use the latest possible version. -
apiVersions
(map<String, String|Date>)
—
a map of service identifiers (the lowercase service class name) with the API version to use when instantiating a service. Specify 'latest' for each individual that can use the latest available version.
-
logger
(#write, #log)
—
an object that responds to .write() (like a stream) or .log() (like the console object) in order to log information about requests
-
systemClockOffset
(Number)
—
an offset value in milliseconds to apply to all signing times. Use this to compensate for clock skew when your system may be out of sync with the service time. Note that this configuration option can only be applied to the global
AWS.config
object and cannot be overridden in service-specific configuration. Defaults to 0 milliseconds. -
signatureVersion
(String)
—
the signature version to sign requests with (overriding the API configuration). Possible values are: 'v2', 'v3', 'v4'.
-
signatureCache
(Boolean)
—
whether the signature to sign requests with (overriding the API configuration) is cached. Only applies to the signature version 'v4'. Defaults to
true
. -
dynamoDbCrc32
(Boolean)
—
whether to validate the CRC32 checksum of HTTP response bodies returned by DynamoDB. Default:
true
. -
useAccelerateEndpoint
(Boolean)
—
Whether to use the S3 Transfer Acceleration endpoint with the S3 service. Default:
false
. -
clientSideMonitoring
(Boolean)
—
whether to collect and publish this client's performance metrics of all its API requests.
-
endpointDiscoveryEnabled
(Boolean|undefined)
—
whether to call operations with endpoints given by service dynamically. Setting this
-
endpointCacheSize
(Number)
—
the size of the global cache storing endpoints from endpoint discovery operations. Once endpoint cache is created, updating this setting cannot change existing cache size. Defaults to 1000
-
hostPrefixEnabled
(Boolean)
—
whether to marshal request parameters to the prefix of hostname. Defaults to
true
. -
stsRegionalEndpoints
('legacy'|'regional')
—
whether to send sts request to global endpoints or regional endpoints. Defaults to 'legacy'.
-
useFipsEndpoint
(Boolean)
—
Enables FIPS compatible endpoints. Defaults to
false
. -
useDualstackEndpoint
(Boolean)
—
Enables IPv6 dualstack endpoint. Defaults to
false
.
Property Details
Method Details
acceptCertificateTransfer(params = {}, callback) ⇒ AWS.Request
Accepts a pending certificate transfer. The default state of the certificate is INACTIVE.
To check for pending certificate transfers, call ListCertificates to enumerate your certificates.
Requires permission to access the AcceptCertificateTransfer action.
Service Reference:
Examples:
Calling the acceptCertificateTransfer operation
var params = { certificateId: 'STRING_VALUE', /* required */ setAsActive: true || false }; iot.acceptCertificateTransfer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
setAsActive
— (Boolean
)Specifies whether the certificate is active.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
addThingToBillingGroup(params = {}, callback) ⇒ AWS.Request
Adds a thing to a billing group.
Requires permission to access the AddThingToBillingGroup action.
Service Reference:
Examples:
Calling the addThingToBillingGroup operation
var params = { billingGroupArn: 'STRING_VALUE', billingGroupName: 'STRING_VALUE', thingArn: 'STRING_VALUE', thingName: 'STRING_VALUE' }; iot.addThingToBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name of the billing group.
Note: This call is asynchronous. It might take several seconds for the detachment to propagate.billingGroupArn
— (String
)The ARN of the billing group.
thingName
— (String
)The name of the thing to be added to the billing group.
thingArn
— (String
)The ARN of the thing to be added to the billing group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
addThingToThingGroup(params = {}, callback) ⇒ AWS.Request
Adds a thing to a thing group.
Requires permission to access the AddThingToThingGroup action.
Service Reference:
Examples:
Calling the addThingToThingGroup operation
var params = { overrideDynamicGroups: true || false, thingArn: 'STRING_VALUE', thingGroupArn: 'STRING_VALUE', thingGroupName: 'STRING_VALUE', thingName: 'STRING_VALUE' }; iot.addThingToThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The name of the group to which you are adding a thing.
thingGroupArn
— (String
)The ARN of the group to which you are adding a thing.
thingName
— (String
)The name of the thing to add to a group.
thingArn
— (String
)The ARN of the thing to add to a group.
overrideDynamicGroups
— (Boolean
)Override dynamic thing groups with static thing groups when 10-group limit is reached. If a thing belongs to 10 thing groups, and one or more of those groups are dynamic thing groups, adding a thing to a static group removes the thing from the last dynamic group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
associateTargetsWithJob(params = {}, callback) ⇒ AWS.Request
Associates a group with a continuous job. The following criteria must be met:
-
The job must have been created with the
targetSelection
field set to "CONTINUOUS". -
The job status must currently be "IN_PROGRESS".
-
The total number of targets associated with a job must not exceed 100.
Requires permission to access the AssociateTargetsWithJob action.
Service Reference:
Examples:
Calling the associateTargetsWithJob operation
var params = { jobId: 'STRING_VALUE', /* required */ targets: [ /* required */ 'STRING_VALUE', /* more items */ ], comment: 'STRING_VALUE', namespaceId: 'STRING_VALUE' }; iot.associateTargetsWithJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
targets
— (Array<String>
)A list of thing group ARNs that define the targets of the job.
jobId
— (String
)The unique identifier you assigned to this job when it was created.
comment
— (String
)An optional comment string describing why the job was associated with the targets.
namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties: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.
-
(AWS.Response)
—
Returns:
attachPolicy(params = {}, callback) ⇒ AWS.Request
Attaches the specified policy to the specified principal (certificate or other credential).
Requires permission to access the AttachPolicy action.
Service Reference:
Examples:
Calling the attachPolicy operation
var params = { policyName: 'STRING_VALUE', /* required */ target: 'STRING_VALUE' /* required */ }; iot.attachPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The name of the policy to attach.
target
— (String
)The identity to which the policy is attached. For example, a thing group or a certificate.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
attachPrincipalPolicy(params = {}, callback) ⇒ AWS.Request
Attaches the specified policy to the specified principal (certificate or other credential).
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements. Use AttachPolicy instead.
Requires permission to access the AttachPrincipalPolicy action.
Service Reference:
Examples:
Calling the attachPrincipalPolicy operation
var params = { policyName: 'STRING_VALUE', /* required */ principal: 'STRING_VALUE' /* required */ }; iot.attachPrincipalPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
principal
— (String
)The principal, which can be a certificate ARN (as returned from the CreateCertificate operation) or an Amazon Cognito ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
attachSecurityProfile(params = {}, callback) ⇒ AWS.Request
Associates a Device Defender security profile with a thing group or this account. Each thing group or account can have up to five security profiles associated with it.
Requires permission to access the AttachSecurityProfile action.
Service Reference:
Examples:
Calling the attachSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE', /* required */ securityProfileTargetArn: 'STRING_VALUE' /* required */ }; iot.attachSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The security profile that is attached.
securityProfileTargetArn
— (String
)The ARN of the target (thing group) to which the security profile is attached.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
attachThingPrincipal(params = {}, callback) ⇒ AWS.Request
Attaches the specified principal to the specified thing. A principal can be X.509 certificates, Amazon Cognito identities or federated identities.
Requires permission to access the AttachThingPrincipal action.
Service Reference:
Examples:
Calling the attachThingPrincipal operation
var params = { principal: 'STRING_VALUE', /* required */ thingName: 'STRING_VALUE' /* required */ }; iot.attachThingPrincipal(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing.
principal
— (String
)The principal, which can be a certificate ARN (as returned from the CreateCertificate operation) or an Amazon Cognito ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
cancelAuditMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Cancels a mitigation action task that is in progress. If the task is not in progress, an InvalidRequestException occurs.
Requires permission to access the CancelAuditMitigationActionsTask action.
Service Reference:
Examples:
Calling the cancelAuditMitigationActionsTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.cancelAuditMitigationActionsTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The unique identifier for the task that you want to cancel.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
cancelAuditTask(params = {}, callback) ⇒ AWS.Request
Cancels an audit that is in progress. The audit can be either scheduled or on demand. If the audit isn't in progress, an "InvalidRequestException" occurs.
Requires permission to access the CancelAuditTask action.
Service Reference:
Examples:
Calling the cancelAuditTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.cancelAuditTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The ID of the audit you want to cancel. You can only cancel an audit that is "IN_PROGRESS".
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
cancelCertificateTransfer(params = {}, callback) ⇒ AWS.Request
Cancels a pending transfer for the specified certificate.
Note Only the transfer source account can use this operation to cancel a transfer. (Transfer destinations can use RejectCertificateTransfer instead.) After transfer, IoT returns the certificate to the source account in the INACTIVE state. After the destination account has accepted the transfer, the transfer cannot be cancelled.
After a certificate transfer is cancelled, the status of the certificate changes from PENDING_TRANSFER to INACTIVE.
Requires permission to access the CancelCertificateTransfer action.
Service Reference:
Examples:
Calling the cancelCertificateTransfer operation
var params = { certificateId: 'STRING_VALUE' /* required */ }; iot.cancelCertificateTransfer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
cancelDetectMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Cancels a Device Defender ML Detect mitigation action.
Requires permission to access the CancelDetectMitigationActionsTask action.
Service Reference:
Examples:
Calling the cancelDetectMitigationActionsTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.cancelDetectMitigationActionsTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The unique identifier of the task.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
cancelJob(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the cancelJob operation
var params = { jobId: 'STRING_VALUE', /* required */ comment: 'STRING_VALUE', force: true || false, reasonCode: 'STRING_VALUE' }; iot.cancelJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The unique identifier you assigned to this job when it was created.
reasonCode
— (String
)(Optional)A reason code string that explains why the job was canceled.
comment
— (String
)An optional comment string describing why the job was canceled.
force
— (Boolean
)(Optional) If
true
job executions with status "IN_PROGRESS" and "QUEUED" are canceled, otherwise only job executions with status "QUEUED" are canceled. The default isfalse
.Canceling a job which is "IN_PROGRESS", will cause a device which is executing the job to be unable to update the job execution status. Use caution and ensure that each device executing a job which is canceled is able to recover to a valid state.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:jobArn
— (String
)The job ARN.
jobId
— (String
)The unique identifier you assigned to this job when it was created.
description
— (String
)A short text description of the job.
-
(AWS.Response)
—
Returns:
cancelJobExecution(params = {}, callback) ⇒ AWS.Request
Cancels the execution of a job for a given thing.
Requires permission to access the CancelJobExecution action.
Service Reference:
Examples:
Calling the cancelJobExecution operation
var params = { jobId: 'STRING_VALUE', /* required */ thingName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE', force: true || false, statusDetails: { '<DetailsKey>': 'STRING_VALUE', /* '<DetailsKey>': ... */ } }; iot.cancelJobExecution(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The ID of the job to be canceled.
thingName
— (String
)The name of the thing whose execution of the job will be canceled.
force
— (Boolean
)(Optional) If
true
the job execution will be canceled if it has status IN_PROGRESS or QUEUED, otherwise the job execution will be canceled only if it has status QUEUED. If you attempt to cancel a job execution that is IN_PROGRESS, and you do not setforce
totrue
, then anInvalidStateTransitionException
will be thrown. The default isfalse
.Canceling a job execution which is "IN_PROGRESS", will cause the device to be unable to update the job execution status. Use caution and ensure that the device is able to recover to a valid state.
expectedVersion
— (Integer
)(Optional) The expected current version of the job execution. Each time you update the job execution, its version is incremented. If the version of the job execution stored in Jobs does not match, the update is rejected with a VersionMismatch error, and an ErrorResponse that contains the current job execution status data is returned. (This makes it unnecessary to perform a separate DescribeJobExecution request in order to obtain the job execution status data.)
statusDetails
— (map<String>
)A collection of name/value pairs that describe the status of the job execution. If not specified, the statusDetails are unchanged. You can specify at most 10 name/value pairs.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
clearDefaultAuthorizer(params = {}, callback) ⇒ AWS.Request
Clears the default authorizer.
Requires permission to access the ClearDefaultAuthorizer action.
Service Reference:
Examples:
Calling the clearDefaultAuthorizer operation
var params = { }; iot.clearDefaultAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
confirmTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Confirms a topic rule destination. When you create a rule requiring a destination, IoT sends a confirmation message to the endpoint or base address you specify. The message includes a token which you pass back when calling
ConfirmTopicRuleDestination
to confirm that you own or have access to the endpoint.Requires permission to access the ConfirmTopicRuleDestination action.
Service Reference:
Examples:
Calling the confirmTopicRuleDestination operation
var params = { confirmationToken: 'STRING_VALUE' /* required */ }; iot.confirmTopicRuleDestination(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
confirmationToken
— (String
)The token used to confirm ownership or access to the topic rule confirmation URL.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
createAuditSuppression(params = {}, callback) ⇒ AWS.Request
Creates a Device Defender audit suppression.
Requires permission to access the CreateAuditSuppression action.
Service Reference:
Examples:
Calling the createAuditSuppression operation
var params = { checkName: 'STRING_VALUE', /* required */ clientRequestToken: 'STRING_VALUE', /* required */ resourceIdentifier: { /* required */ account: 'STRING_VALUE', caCertificateId: 'STRING_VALUE', clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', deviceCertificateArn: 'STRING_VALUE', deviceCertificateId: 'STRING_VALUE', iamRoleArn: 'STRING_VALUE', issuerCertificateIdentifier: { issuerCertificateSerialNumber: 'STRING_VALUE', issuerCertificateSubject: 'STRING_VALUE', issuerId: 'STRING_VALUE' }, policyVersionIdentifier: { policyName: 'STRING_VALUE', policyVersionId: 'STRING_VALUE' }, roleAliasArn: 'STRING_VALUE' }, description: 'STRING_VALUE', expirationDate: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, suppressIndefinitely: true || false }; iot.createAuditSuppression(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
checkName
— (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
expirationDate
— (Date
)The epoch timestamp in seconds at which this suppression expires.
suppressIndefinitely
— (Boolean
)Indicates whether a suppression should exist indefinitely or not.
description
— (String
)The description of the audit suppression.
clientRequestToken
— (String
)Each audit supression must have a unique client request token. If you try to create a new audit suppression with the same token as one that already exists, an exception occurs. If you omit this value, Amazon Web Services SDKs will automatically generate a unique client request.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
createAuthorizer(params = {}, callback) ⇒ AWS.Request
Creates an authorizer.
Requires permission to access the CreateAuthorizer action.
Service Reference:
Examples:
Calling the createAuthorizer operation
var params = { authorizerFunctionArn: 'STRING_VALUE', /* required */ authorizerName: 'STRING_VALUE', /* required */ enableCachingForHttp: true || false, signingDisabled: true || false, status: ACTIVE | INACTIVE, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], tokenKeyName: 'STRING_VALUE', tokenSigningPublicKeys: { '<KeyName>': 'STRING_VALUE', /* '<KeyName>': ... */ } }; iot.createAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
authorizerName
— (String
)The authorizer name.
authorizerFunctionArn
— (String
)The ARN of the authorizer's Lambda function.
tokenKeyName
— (String
)The name of the token key used to extract the token from the HTTP headers.
tokenSigningPublicKeys
— (map<String>
)The public keys used to verify the digital signature returned by your custom authentication service.
status
— (String
)The status of the create authorizer request.
Possible values include:"ACTIVE"
"INACTIVE"
tags
— (Array<map>
)Metadata which can be used to manage the custom authorizer.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: &&tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
signingDisabled
— (Boolean
)Specifies whether IoT validates the token signature in an authorization request.
enableCachingForHttp
— (Boolean
)When
true
, the result from the authorizer’s Lambda function is cached for clients that use persistent HTTP connections. The results are cached for the time specified by the Lambda function inrefreshAfterInSeconds
. This value does not affect authorization of clients that use MQTT connections.The default value is
false
.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authorizerName
— (String
)The authorizer's name.
authorizerArn
— (String
)The authorizer ARN.
-
(AWS.Response)
—
Returns:
createBillingGroup(params = {}, callback) ⇒ AWS.Request
Creates a billing group.
Requires permission to access the CreateBillingGroup action.
Service Reference:
Examples:
Calling the createBillingGroup operation
var params = { billingGroupName: 'STRING_VALUE', /* required */ billingGroupProperties: { billingGroupDescription: 'STRING_VALUE' }, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name you wish to give to the billing group.
billingGroupProperties
— (map
)The properties of the billing group.
billingGroupDescription
— (String
)The description of the billing group.
tags
— (Array<map>
)Metadata which can be used to manage the billing group.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:billingGroupName
— (String
)The name you gave to the billing group.
billingGroupArn
— (String
)The ARN of the billing group.
billingGroupId
— (String
)The ID of the billing group.
-
(AWS.Response)
—
Returns:
createCertificateFromCsr(params = {}, callback) ⇒ AWS.Request
Creates an X.509 certificate using the specified certificate signing request.
Requires permission to access the CreateCertificateFromCsr action.
Note: The CSR must include a public key that is either an RSA key with a length of at least 2048 bits or an ECC key from NIST P-256, NIST P-384, or NIST P-521 curves. For supported certificates, consult Certificate signing algorithms supported by IoT.Note: Reusing the same certificate signing request (CSR) results in a distinct certificate.You can create multiple certificates in a batch by creating a directory, copying multiple
.csr
files into that directory, and then specifying that directory on the command line. The following commands show how to create a batch of certificates given a batch of CSRs. In the following commands, we assume that a set of CSRs are located inside of the directory my-csr-directory:On Linux and OS X, the command is:
$ ls my-csr-directory/ | xargs -I {} aws iot create-certificate-from-csr --certificate-signing-request file://my-csr-directory/{}
This command lists all of the CSRs in my-csr-directory and pipes each CSR file name to the
aws iot create-certificate-from-csr
Amazon Web Services CLI command to create a certificate for the corresponding CSR.You can also run the
aws iot create-certificate-from-csr
part of the command in parallel to speed up the certificate creation process:$ ls my-csr-directory/ | xargs -P 10 -I {} aws iot create-certificate-from-csr --certificate-signing-request file://my-csr-directory/{}
On Windows PowerShell, the command to create certificates for all CSRs in my-csr-directory is:
> ls -Name my-csr-directory | %{aws iot create-certificate-from-csr --certificate-signing-request file://my-csr-directory/$_}
On a Windows command prompt, the command to create certificates for all CSRs in my-csr-directory is:
> forfiles /p my-csr-directory /c "cmd /c aws iot create-certificate-from-csr --certificate-signing-request file://@path"
Service Reference:
Examples:
Calling the createCertificateFromCsr operation
var params = { certificateSigningRequest: 'STRING_VALUE', /* required */ setAsActive: true || false }; iot.createCertificateFromCsr(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateSigningRequest
— (String
)The certificate signing request (CSR).
setAsActive
— (Boolean
)Specifies whether the certificate is active.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateArn
— (String
)The Amazon Resource Name (ARN) of the certificate. You can use the ARN as a principal for policy operations.
certificateId
— (String
)The ID of the certificate. Certificate management operations only take a certificateId.
certificatePem
— (String
)The certificate data, in PEM format.
-
(AWS.Response)
—
Returns:
createCertificateProvider(params = {}, callback) ⇒ AWS.Request
Creates an Amazon Web Services IoT Core certificate provider. You can use Amazon Web Services IoT Core certificate provider to customize how to sign a certificate signing request (CSR) in IoT fleet provisioning. For more information, see Customizing certificate signing using Amazon Web Services IoT Core certificate provider from Amazon Web Services IoT Core Developer Guide.
Requires permission to access the CreateCertificateProvider action.
After you create a certificate provider, the behavior of
CreateCertificateFromCsr
API for fleet provisioning will change and all API calls toCreateCertificateFromCsr
will invoke the certificate provider to create the certificates. It can take up to a few minutes for this behavior to change after a certificate provider is created.Service Reference:
Examples:
Calling the createCertificateProvider operation
var params = { accountDefaultForOperations: [ /* required */ CreateCertificateFromCsr, /* more items */ ], certificateProviderName: 'STRING_VALUE', /* required */ lambdaFunctionArn: 'STRING_VALUE', /* required */ clientToken: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createCertificateProvider(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateProviderName
— (String
)The name of the certificate provider.
lambdaFunctionArn
— (String
)The ARN of the Lambda function that defines the authentication logic.
accountDefaultForOperations
— (Array<String>
)A list of the operations that the certificate provider will use to generate certificates. Valid value:
CreateCertificateFromCsr
.clientToken
— (String
)A string that you can optionally pass in the
If a token is not provided, the SDK will use a version 4 UUID.CreateCertificateProvider
request to make sure the request is idempotent.tags
— (Array<map>
)Metadata which can be used to manage the certificate provider.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateProviderName
— (String
)The name of the certificate provider.
certificateProviderArn
— (String
)The ARN of the certificate provider.
-
(AWS.Response)
—
Returns:
createCustomMetric(params = {}, callback) ⇒ AWS.Request
Use this API to define a Custom Metric published by your devices to Device Defender.
Requires permission to access the CreateCustomMetric action.
Service Reference:
Examples:
Calling the createCustomMetric operation
var params = { clientRequestToken: 'STRING_VALUE', /* required */ metricName: 'STRING_VALUE', /* required */ metricType: string-list | ip-address-list | number-list | number, /* required */ displayName: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createCustomMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the custom metric. This will be used in the metric report submitted from the device/thing. The name can't begin with
aws:
. You can't change the name after you define it.displayName
— (String
)The friendly name in the console for the custom metric. This name doesn't have to be unique. Don't use this name as the metric identifier in the device metric report. You can update the friendly name after you define it.
metricType
— (String
)The type of the custom metric.
The type
number
only takes a single metric value as an input, but when you submit the metrics value in the DeviceMetrics report, you must pass it as an array with a single value."string-list"
"ip-address-list"
"number-list"
"number"
tags
— (Array<map>
)Metadata that can be used to manage the custom metric.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
clientRequestToken
— (String
)Each custom metric must have a unique client request token. If you try to create a new custom metric that already exists with a different token, an exception occurs. If you omit this value, Amazon Web Services SDKs will automatically generate a unique client request.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricName
— (String
)The name of the custom metric to be used in the metric report.
metricArn
— (String
)The Amazon Resource Number (ARN) of the custom metric. For example,
arn:aws-partition:iot:region:accountId:custommetric/metricName
-
(AWS.Response)
—
Returns:
createDimension(params = {}, callback) ⇒ AWS.Request
Create a dimension that you can use to limit the scope of a metric used in a security profile for IoT Device Defender. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric only to MQTT topics whose name match the pattern specified in the dimension.Requires permission to access the CreateDimension action.
Service Reference:
Examples:
Calling the createDimension operation
var params = { clientRequestToken: 'STRING_VALUE', /* required */ name: 'STRING_VALUE', /* required */ stringValues: [ /* required */ 'STRING_VALUE', /* more items */ ], type: TOPIC_FILTER, /* required */ tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createDimension(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
name
— (String
)A unique identifier for the dimension. Choose something that describes the type and value to make it easy to remember what it does.
type
— (String
)Specifies the type of dimension. Supported types:
Possible values include:TOPIC_FILTER.
"TOPIC_FILTER"
stringValues
— (Array<String>
)Specifies the value or list of values for the dimension. For
TOPIC_FILTER
dimensions, this is a pattern used to match the MQTT topic (for example, "admin/#").tags
— (Array<map>
)Metadata that can be used to manage the dimension.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
clientRequestToken
— (String
)Each dimension must have a unique client request token. If you try to create a new dimension with the same token as a dimension that already exists, an exception occurs. If you omit this value, Amazon Web Services SDKs will automatically generate a unique client request.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:name
— (String
)A unique identifier for the dimension.
arn
— (String
)The Amazon Resource Name (ARN) of the created dimension.
-
(AWS.Response)
—
Returns:
createDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Creates a domain configuration.
Requires permission to access the CreateDomainConfiguration action.
Service Reference:
Examples:
Calling the createDomainConfiguration operation
var params = { domainConfigurationName: 'STRING_VALUE', /* required */ authorizerConfig: { allowAuthorizerOverride: true || false, defaultAuthorizerName: 'STRING_VALUE' }, domainName: 'STRING_VALUE', serverCertificateArns: [ 'STRING_VALUE', /* more items */ ], serverCertificateConfig: { enableOCSPCheck: true || false }, serviceType: DATA | CREDENTIAL_PROVIDER | JOBS, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], tlsConfig: { securityPolicy: 'STRING_VALUE' }, validationCertificateArn: 'STRING_VALUE' }; iot.createDomainConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
domainConfigurationName
— (String
)The name of the domain configuration. This value must be unique to a region.
domainName
— (String
)The name of the domain.
serverCertificateArns
— (Array<String>
)The ARNs of the certificates that IoT passes to the device during the TLS handshake. Currently you can specify only one certificate ARN. This value is not required for Amazon Web Services-managed domains.
validationCertificateArn
— (String
)The certificate used to validate the server certificate and prove domain name ownership. This certificate must be signed by a public certificate authority. This value is not required for Amazon Web Services-managed domains.
authorizerConfig
— (map
)An object that specifies the authorization service for a domain.
defaultAuthorizerName
— (String
)The name of the authorization service for a domain configuration.
allowAuthorizerOverride
— (Boolean
)A Boolean that specifies whether the domain configuration's authorization service can be overridden.
serviceType
— (String
)The type of service delivered by the endpoint.
Note: Amazon Web Services IoT Core currently supports only thePossible values include:DATA
service type."DATA"
"CREDENTIAL_PROVIDER"
"JOBS"
tags
— (Array<map>
)Metadata which can be used to manage the domain configuration.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: &&tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
tlsConfig
— (map
)An object that specifies the TLS configuration for a domain.
securityPolicy
— (String
)The security policy for a domain configuration. For more information, see Security policies in the Amazon Web Services IoT Core developer guide.
serverCertificateConfig
— (map
)The server certificate configuration.
enableOCSPCheck
— (Boolean
)A Boolean value that indicates whether Online Certificate Status Protocol (OCSP) server certificate check is enabled or not.
For more information, see Configuring OCSP server-certificate stapling in domain configuration from Amazon Web Services IoT Core Developer Guide.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:domainConfigurationName
— (String
)The name of the domain configuration.
domainConfigurationArn
— (String
)The ARN of the domain configuration.
-
(AWS.Response)
—
Returns:
createDynamicThingGroup(params = {}, callback) ⇒ AWS.Request
Creates a dynamic thing group.
Requires permission to access the CreateDynamicThingGroup action.
Service Reference:
Examples:
Calling the createDynamicThingGroup operation
var params = { queryString: 'STRING_VALUE', /* required */ thingGroupName: 'STRING_VALUE', /* required */ indexName: 'STRING_VALUE', queryVersion: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], thingGroupProperties: { attributePayload: { attributes: { '<AttributeName>': 'STRING_VALUE', /* '<AttributeName>': ... */ }, merge: true || false }, thingGroupDescription: 'STRING_VALUE' } }; iot.createDynamicThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The dynamic thing group name to create.
thingGroupProperties
— (map
)The dynamic thing group properties.
thingGroupDescription
— (String
)The thing group description.
attributePayload
— (map
)The thing group attributes in JSON format.
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
indexName
— (String
)The dynamic thing group index name.
Note: Currently one index is supported:AWS_Things
.queryString
— (String
)The dynamic thing group search query string.
See Query Syntax for information about query string syntax.
queryVersion
— (String
)The dynamic thing group query version.
Note: Currently one query version is supported: "2017-09-30". If not specified, the query version defaults to this value.tags
— (Array<map>
)Metadata which can be used to manage the dynamic thing group.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingGroupName
— (String
)The dynamic thing group name.
thingGroupArn
— (String
)The dynamic thing group ARN.
thingGroupId
— (String
)The dynamic thing group ID.
indexName
— (String
)The dynamic thing group index name.
queryString
— (String
)The dynamic thing group search query string.
queryVersion
— (String
)The dynamic thing group query version.
-
(AWS.Response)
—
Returns:
createFleetMetric(params = {}, callback) ⇒ AWS.Request
Creates a fleet metric.
Requires permission to access the CreateFleetMetric action.
Service Reference:
Examples:
Calling the createFleetMetric operation
var params = { aggregationField: 'STRING_VALUE', /* required */ aggregationType: { /* required */ name: Statistics | Percentiles | Cardinality, /* required */ values: [ 'STRING_VALUE', /* more items */ ] }, metricName: 'STRING_VALUE', /* required */ period: 'NUMBER_VALUE', /* required */ queryString: 'STRING_VALUE', /* required */ description: 'STRING_VALUE', indexName: 'STRING_VALUE', queryVersion: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], unit: Seconds | Microseconds | Milliseconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None }; iot.createFleetMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the fleet metric to create.
queryString
— (String
)The search query string.
aggregationType
— (map
)The type of the aggregation query.
name
— required — (String
)The name of the aggregation type.
Possible values include:"Statistics"
"Percentiles"
"Cardinality"
values
— (Array<String>
)A list of the values of aggregation types.
period
— (Integer
)The time in seconds between fleet metric emissions. Range [60(1 min), 86400(1 day)] and must be multiple of 60.
aggregationField
— (String
)The field to aggregate.
description
— (String
)The fleet metric description.
queryVersion
— (String
)The query version.
indexName
— (String
)The name of the index to search.
unit
— (String
)Used to support unit transformation such as milliseconds to seconds. The unit must be supported by CW metric. Default to null.
Possible values include:"Seconds"
"Microseconds"
"Milliseconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
tags
— (Array<map>
)Metadata, which can be used to manage the fleet metric.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricName
— (String
)The name of the fleet metric to create.
metricArn
— (String
)The Amazon Resource Name (ARN) of the new fleet metric.
-
(AWS.Response)
—
Returns:
createJob(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the createJob operation
var params = { jobId: 'STRING_VALUE', /* required */ targets: [ /* required */ 'STRING_VALUE', /* more items */ ], abortConfig: { criteriaList: [ /* required */ { action: CANCEL, /* required */ failureType: FAILED | REJECTED | TIMED_OUT | ALL, /* required */ minNumberOfExecutedThings: 'NUMBER_VALUE', /* required */ thresholdPercentage: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, description: 'STRING_VALUE', destinationPackageVersions: [ 'STRING_VALUE', /* more items */ ], document: 'STRING_VALUE', documentParameters: { '<ParameterKey>': 'STRING_VALUE', /* '<ParameterKey>': ... */ }, documentSource: 'STRING_VALUE', jobExecutionsRetryConfig: { criteriaList: [ /* required */ { failureType: FAILED | TIMED_OUT | ALL, /* required */ numberOfRetries: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, jobExecutionsRolloutConfig: { exponentialRate: { baseRatePerMinute: 'NUMBER_VALUE', /* required */ incrementFactor: 'NUMBER_VALUE', /* required */ rateIncreaseCriteria: { /* required */ numberOfNotifiedThings: 'NUMBER_VALUE', numberOfSucceededThings: 'NUMBER_VALUE' } }, maximumPerMinute: 'NUMBER_VALUE' }, jobTemplateArn: 'STRING_VALUE', namespaceId: 'STRING_VALUE', presignedUrlConfig: { expiresInSec: 'NUMBER_VALUE', roleArn: 'STRING_VALUE' }, schedulingConfig: { endBehavior: STOP_ROLLOUT | CANCEL | FORCE_CANCEL, endTime: 'STRING_VALUE', maintenanceWindows: [ { durationInMinutes: 'NUMBER_VALUE', /* required */ startTime: 'STRING_VALUE' /* required */ }, /* more items */ ], startTime: 'STRING_VALUE' }, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], targetSelection: CONTINUOUS | SNAPSHOT, timeoutConfig: { inProgressTimeoutInMinutes: 'NUMBER_VALUE' } }; iot.createJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)A job identifier which must be unique for your Amazon Web Services account. We recommend using a UUID. Alpha-numeric characters, "-" and "_" are valid for use here.
targets
— (Array<String>
)A list of things and thing groups to which the job should be sent.
documentSource
— (String
)An S3 link, or S3 object URL, to the job document. The link is an Amazon S3 object URL and is required if you don't specify a value for
document
.For example,
--document-source https://s3.region-code.amazonaws.com/example-firmware/device-firmware.1.0
For more information, see Methods for accessing a bucket.
document
— (String
)The job document. Required if you don't specify a value for
documentSource
.description
— (String
)A short text description of the job.
presignedUrlConfig
— (map
)Configuration information for pre-signed S3 URLs.
roleArn
— (String
)The ARN of an IAM role that grants permission to download files from the S3 bucket where the job data/updates are stored. The role must also grant permission for IoT to download the files.
For information about addressing the confused deputy problem, see cross-service confused deputy prevention in the Amazon Web Services IoT Core developer guide.
expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 3600 seconds. Pre-signed URLs are generated when Jobs receives an MQTT request for the job document.
targetSelection
— (String
)Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a thing when the thing is added to a target group, even after the job was completed by all things originally in the group.
Note: We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.Possible values include:"CONTINUOUS"
"SNAPSHOT"
jobExecutionsRolloutConfig
— (map
)Allows you to create a staged rollout of the job.
maximumPerMinute
— (Integer
)The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute at the start of job rollout. This parameter allows you to define the initial rate of rollout.
incrementFactor
— required — (Float
)The exponential factor to increase the rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
numberOfNotifiedThings
— (Integer
)The threshold for number of notified things that will initiate the increase in rate of rollout.
numberOfSucceededThings
— (Integer
)The threshold for number of succeeded things that will initiate the increase in rate of rollout.
abortConfig
— (map
)Allows you to create the criteria to abort a job.
criteriaList
— required — (Array<map>
)The list of criteria that determine when and how to abort the job.
failureType
— required — (String
)The type of job execution failures that can initiate a job abort.
Possible values include:"FAILED"
"REJECTED"
"TIMED_OUT"
"ALL"
action
— required — (String
)The type of job action to take to initiate the job abort.
Possible values include:"CANCEL"
thresholdPercentage
— required — (Float
)The minimum percentage of job execution failures that must occur to initiate the job abort.
Amazon Web Services IoT Core supports up to two digits after the decimal (for example, 10.9 and 10.99, but not 10.999).
minNumberOfExecutedThings
— required — (Integer
)The minimum number of things which must receive job execution notifications before the job can be aborted.
timeoutConfig
— (map
)Specifies the amount of time each device has to finish its execution of the job. The timer is started when the job execution status is set to
IN_PROGRESS
. If the job execution status is not set to another terminal state before the time expires, it will be automatically set toTIMED_OUT
.inProgressTimeoutInMinutes
— (Integer
)Specifies the amount of time, in minutes, this device has to finish execution of this job. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The in progress timer can't be updated and will apply to all job executions for the job. Whenever a job execution remains in the IN_PROGRESS status for longer than this interval, the job execution will fail and switch to the terminal
TIMED_OUT
status.
tags
— (Array<map>
)Metadata which can be used to manage the job.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.jobTemplateArn
— (String
)The ARN of the job template used to create the job.
jobExecutionsRetryConfig
— (map
)Allows you to create the criteria to retry a job.
criteriaList
— required — (Array<map>
)The list of criteria that determines how many retries are allowed for each failure type for a job.
failureType
— required — (String
)The type of job execution failures that can initiate a job retry.
Possible values include:"FAILED"
"TIMED_OUT"
"ALL"
numberOfRetries
— required — (Integer
)The number of retries allowed for a failure type for the job.
documentParameters
— (map<String>
)Parameters of an Amazon Web Services managed template that you can specify to create the job document.
Note:documentParameters
can only be used when creating jobs from Amazon Web Services managed templates. This parameter can't be used with custom job templates or to create jobs from them.schedulingConfig
— (map
)The configuration that allows you to schedule a job for a future date and time in addition to specifying the end behavior for each job execution.
startTime
— (String
)The time a job will begin rollout of the job document to all devices in the target group for a job. The
startTime
can be scheduled up to a year in advance and must be scheduled a minimum of thirty minutes from the current time. The date and time format for thestartTime
is YYYY-MM-DD for the date and HH:MM for the time.For more information on the syntax for
startTime
when using an API command or the Command Line Interface, see Timestamp.endTime
— (String
)The time a job will stop rollout of the job document to all devices in the target group for a job. The
endTime
must take place no later than two years from the current time and be scheduled a minimum of thirty minutes from the current time. The minimum duration betweenstartTime
andendTime
is thirty minutes. The maximum duration betweenstartTime
andendTime
is two years. The date and time format for theendTime
is YYYY-MM-DD for the date and HH:MM for the time.For more information on the syntax for
endTime
when using an API command or the Command Line Interface, see Timestamp.endBehavior
— (String
)Specifies the end behavior for all job executions after a job reaches the selected
Possible values include:endTime
. IfendTime
is not selected when creating the job, thenendBehavior
does not apply."STOP_ROLLOUT"
"CANCEL"
"FORCE_CANCEL"
maintenanceWindows
— (Array<map>
)An optional configuration within the
SchedulingConfig
to setup a recurring maintenance window with a predetermined start time and duration for the rollout of a job document to all devices in a target group for a job.startTime
— required — (String
)Displays the start time of the next maintenance window.
durationInMinutes
— required — (Integer
)Displays the duration of the next maintenance window.
destinationPackageVersions
— (Array<String>
)The package version Amazon Resource Names (ARNs) that are installed on the device when the job successfully completes. The package version must be in either the Published or Deprecated state when the job deploys. For more information, see Package version lifecycle.
Note:The following Length Constraints relates to a single ARN. Up to 25 package version ARNs are allowed.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:jobArn
— (String
)The job ARN.
jobId
— (String
)The unique identifier you assigned to this job.
description
— (String
)The job description.
-
(AWS.Response)
—
Returns:
createJobTemplate(params = {}, callback) ⇒ AWS.Request
Creates a job template.
Requires permission to access the CreateJobTemplate action.
Service Reference:
Examples:
Calling the createJobTemplate operation
var params = { description: 'STRING_VALUE', /* required */ jobTemplateId: 'STRING_VALUE', /* required */ abortConfig: { criteriaList: [ /* required */ { action: CANCEL, /* required */ failureType: FAILED | REJECTED | TIMED_OUT | ALL, /* required */ minNumberOfExecutedThings: 'NUMBER_VALUE', /* required */ thresholdPercentage: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, destinationPackageVersions: [ 'STRING_VALUE', /* more items */ ], document: 'STRING_VALUE', documentSource: 'STRING_VALUE', jobArn: 'STRING_VALUE', jobExecutionsRetryConfig: { criteriaList: [ /* required */ { failureType: FAILED | TIMED_OUT | ALL, /* required */ numberOfRetries: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, jobExecutionsRolloutConfig: { exponentialRate: { baseRatePerMinute: 'NUMBER_VALUE', /* required */ incrementFactor: 'NUMBER_VALUE', /* required */ rateIncreaseCriteria: { /* required */ numberOfNotifiedThings: 'NUMBER_VALUE', numberOfSucceededThings: 'NUMBER_VALUE' } }, maximumPerMinute: 'NUMBER_VALUE' }, maintenanceWindows: [ { durationInMinutes: 'NUMBER_VALUE', /* required */ startTime: 'STRING_VALUE' /* required */ }, /* more items */ ], presignedUrlConfig: { expiresInSec: 'NUMBER_VALUE', roleArn: 'STRING_VALUE' }, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], timeoutConfig: { inProgressTimeoutInMinutes: 'NUMBER_VALUE' } }; iot.createJobTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobTemplateId
— (String
)A unique identifier for the job template. We recommend using a UUID. Alpha-numeric characters, "-", and "_" are valid for use here.
jobArn
— (String
)The ARN of the job to use as the basis for the job template.
documentSource
— (String
)An S3 link, or S3 object URL, to the job document. The link is an Amazon S3 object URL and is required if you don't specify a value for
document
.For example,
--document-source https://s3.region-code.amazonaws.com/example-firmware/device-firmware.1.0
For more information, see Methods for accessing a bucket.
document
— (String
)The job document. Required if you don't specify a value for
documentSource
.description
— (String
)A description of the job document.
presignedUrlConfig
— (map
)Configuration for pre-signed S3 URLs.
roleArn
— (String
)The ARN of an IAM role that grants permission to download files from the S3 bucket where the job data/updates are stored. The role must also grant permission for IoT to download the files.
For information about addressing the confused deputy problem, see cross-service confused deputy prevention in the Amazon Web Services IoT Core developer guide.
expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 3600 seconds. Pre-signed URLs are generated when Jobs receives an MQTT request for the job document.
jobExecutionsRolloutConfig
— (map
)Allows you to create a staged rollout of a job.
maximumPerMinute
— (Integer
)The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute at the start of job rollout. This parameter allows you to define the initial rate of rollout.
incrementFactor
— required — (Float
)The exponential factor to increase the rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
numberOfNotifiedThings
— (Integer
)The threshold for number of notified things that will initiate the increase in rate of rollout.
numberOfSucceededThings
— (Integer
)The threshold for number of succeeded things that will initiate the increase in rate of rollout.
abortConfig
— (map
)The criteria that determine when and how a job abort takes place.
criteriaList
— required — (Array<map>
)The list of criteria that determine when and how to abort the job.
failureType
— required — (String
)The type of job execution failures that can initiate a job abort.
Possible values include:"FAILED"
"REJECTED"
"TIMED_OUT"
"ALL"
action
— required — (String
)The type of job action to take to initiate the job abort.
Possible values include:"CANCEL"
thresholdPercentage
— required — (Float
)The minimum percentage of job execution failures that must occur to initiate the job abort.
Amazon Web Services IoT Core supports up to two digits after the decimal (for example, 10.9 and 10.99, but not 10.999).
minNumberOfExecutedThings
— required — (Integer
)The minimum number of things which must receive job execution notifications before the job can be aborted.
timeoutConfig
— (map
)Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to
IN_PROGRESS
. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set toTIMED_OUT
.inProgressTimeoutInMinutes
— (Integer
)Specifies the amount of time, in minutes, this device has to finish execution of this job. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The in progress timer can't be updated and will apply to all job executions for the job. Whenever a job execution remains in the IN_PROGRESS status for longer than this interval, the job execution will fail and switch to the terminal
TIMED_OUT
status.
tags
— (Array<map>
)Metadata that can be used to manage the job template.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
jobExecutionsRetryConfig
— (map
)Allows you to create the criteria to retry a job.
criteriaList
— required — (Array<map>
)The list of criteria that determines how many retries are allowed for each failure type for a job.
failureType
— required — (String
)The type of job execution failures that can initiate a job retry.
Possible values include:"FAILED"
"TIMED_OUT"
"ALL"
numberOfRetries
— required — (Integer
)The number of retries allowed for a failure type for the job.
maintenanceWindows
— (Array<map>
)Allows you to configure an optional maintenance window for the rollout of a job document to all devices in the target group for a job.
startTime
— required — (String
)Displays the start time of the next maintenance window.
durationInMinutes
— required — (Integer
)Displays the duration of the next maintenance window.
destinationPackageVersions
— (Array<String>
)The package version Amazon Resource Names (ARNs) that are installed on the device when the job successfully completes. The package version must be in either the Published or Deprecated state when the job deploys. For more information, see Package version lifecycle.
Note:The following Length Constraints relates to a single ARN. Up to 25 package version ARNs are allowed.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:jobTemplateArn
— (String
)The ARN of the job template.
jobTemplateId
— (String
)The unique identifier of the job template.
-
(AWS.Response)
—
Returns:
createKeysAndCertificate(params = {}, callback) ⇒ AWS.Request
Creates a 2048-bit RSA key pair and issues an X.509 certificate using the issued public key. You can also call
CreateKeysAndCertificate
over MQTT from a device, for more information, see Provisioning MQTT API.Note This is the only time IoT issues the private key for this certificate, so it is important to keep it in a secure location.
Requires permission to access the CreateKeysAndCertificate action.
Service Reference:
Examples:
Calling the createKeysAndCertificate operation
var params = { setAsActive: true || false }; iot.createKeysAndCertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
setAsActive
— (Boolean
)Specifies whether the certificate is active.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateArn
— (String
)The ARN of the certificate.
certificateId
— (String
)The ID of the certificate. IoT issues a default subject name for the certificate (for example, IoT Certificate).
certificatePem
— (String
)The certificate data, in PEM format.
keyPair
— (map
)The generated key pair.
PublicKey
— (String
)The public key.
PrivateKey
— (String
)The private key.
-
(AWS.Response)
—
Returns:
createMitigationAction(params = {}, callback) ⇒ AWS.Request
Defines an action that can be applied to audit findings by using StartAuditMitigationActionsTask. Only certain types of mitigation actions can be applied to specific check names. For more information, see Mitigation actions. Each mitigation action can apply only one type of change.
Requires permission to access the CreateMitigationAction action.
Service Reference:
Examples:
Calling the createMitigationAction operation
var params = { actionName: 'STRING_VALUE', /* required */ actionParams: { /* required */ addThingsToThingGroupParams: { thingGroupNames: [ /* required */ 'STRING_VALUE', /* more items */ ], overrideDynamicGroups: true || false }, enableIoTLoggingParams: { logLevel: DEBUG | INFO | ERROR | WARN | DISABLED, /* required */ roleArnForLogging: 'STRING_VALUE' /* required */ }, publishFindingToSnsParams: { topicArn: 'STRING_VALUE' /* required */ }, replaceDefaultPolicyVersionParams: { templateName: BLANK_POLICY /* required */ }, updateCACertificateParams: { action: DEACTIVATE /* required */ }, updateDeviceCertificateParams: { action: DEACTIVATE /* required */ } }, roleArn: 'STRING_VALUE', /* required */ tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createMitigationAction(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
actionName
— (String
)A friendly name for the action. Choose a friendly name that accurately describes the action (for example,
EnableLoggingAction
).roleArn
— (String
)The ARN of the IAM role that is used to apply the mitigation action.
actionParams
— (map
)Defines the type of action and the parameters for that action.
updateDeviceCertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the device certificate to inactive.
action
— required — (String
)The action that you want to apply to the device certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
updateCACertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the CA certificate to inactive.
action
— required — (String
)The action that you want to apply to the CA certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
addThingsToThingGroupParams
— (map
)Parameters to define a mitigation action that moves devices associated with a certificate to one or more specified thing groups, typically for quarantine.
thingGroupNames
— required — (Array<String>
)The list of groups to which you want to add the things that triggered the mitigation action. You can add a thing to a maximum of 10 groups, but you can't add a thing to more than one group in the same hierarchy.
overrideDynamicGroups
— (Boolean
)Specifies if this mitigation action can move the things that triggered the mitigation action even if they are part of one or more dynamic thing groups.
replaceDefaultPolicyVersionParams
— (map
)Parameters to define a mitigation action that adds a blank policy to restrict permissions.
templateName
— required — (String
)The name of the template to be applied. The only supported value is
Possible values include:BLANK_POLICY
."BLANK_POLICY"
enableIoTLoggingParams
— (map
)Parameters to define a mitigation action that enables Amazon Web Services IoT Core logging at a specified level of detail.
roleArnForLogging
— required — (String
)The Amazon Resource Name (ARN) of the IAM role used for logging.
logLevel
— required — (String
)Specifies the type of information to be logged.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
publishFindingToSnsParams
— (map
)Parameters to define a mitigation action that publishes findings to Amazon Simple Notification Service (Amazon SNS. You can implement your own custom actions in response to the Amazon SNS messages.
topicArn
— required — (String
)The ARN of the topic to which you want to publish the findings.
tags
— (Array<map>
)Metadata that can be used to manage the mitigation action.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:actionArn
— (String
)The ARN for the new mitigation action.
actionId
— (String
)A unique identifier for the new mitigation action.
-
(AWS.Response)
—
Returns:
createOTAUpdate(params = {}, callback) ⇒ AWS.Request
Creates an IoT OTA update on a target group of things or groups.
Requires permission to access the CreateOTAUpdate action.
Service Reference:
Examples:
Calling the createOTAUpdate operation
var params = { files: [ /* required */ { attributes: { '<AttributeKey>': 'STRING_VALUE', /* '<AttributeKey>': ... */ }, codeSigning: { awsSignerJobId: 'STRING_VALUE', customCodeSigning: { certificateChain: { certificateName: 'STRING_VALUE', inlineDocument: 'STRING_VALUE' }, hashAlgorithm: 'STRING_VALUE', signature: { inlineDocument: Buffer.from('...') || 'STRING_VALUE' /* Strings will be Base-64 encoded on your behalf */ }, signatureAlgorithm: 'STRING_VALUE' }, startSigningJobParameter: { destination: { s3Destination: { bucket: 'STRING_VALUE', prefix: 'STRING_VALUE' } }, signingProfileName: 'STRING_VALUE', signingProfileParameter: { certificateArn: 'STRING_VALUE', certificatePathOnDevice: 'STRING_VALUE', platform: 'STRING_VALUE' } } }, fileLocation: { s3Location: { bucket: 'STRING_VALUE', key: 'STRING_VALUE', version: 'STRING_VALUE' }, stream: { fileId: 'NUMBER_VALUE', streamId: 'STRING_VALUE' } }, fileName: 'STRING_VALUE', fileType: 'NUMBER_VALUE', fileVersion: 'STRING_VALUE' }, /* more items */ ], otaUpdateId: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ targets: [ /* required */ 'STRING_VALUE', /* more items */ ], additionalParameters: { '<AttributeKey>': 'STRING_VALUE', /* '<AttributeKey>': ... */ }, awsJobAbortConfig: { abortCriteriaList: [ /* required */ { action: CANCEL, /* required */ failureType: FAILED | REJECTED | TIMED_OUT | ALL, /* required */ minNumberOfExecutedThings: 'NUMBER_VALUE', /* required */ thresholdPercentage: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, awsJobExecutionsRolloutConfig: { exponentialRate: { baseRatePerMinute: 'NUMBER_VALUE', /* required */ incrementFactor: 'NUMBER_VALUE', /* required */ rateIncreaseCriteria: { /* required */ numberOfNotifiedThings: 'NUMBER_VALUE', numberOfSucceededThings: 'NUMBER_VALUE' } }, maximumPerMinute: 'NUMBER_VALUE' }, awsJobPresignedUrlConfig: { expiresInSec: 'NUMBER_VALUE' }, awsJobTimeoutConfig: { inProgressTimeoutInMinutes: 'NUMBER_VALUE' }, description: 'STRING_VALUE', protocols: [ MQTT | HTTP, /* more items */ ], tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], targetSelection: CONTINUOUS | SNAPSHOT }; iot.createOTAUpdate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
otaUpdateId
— (String
)The ID of the OTA update to be created.
description
— (String
)The description of the OTA update.
targets
— (Array<String>
)The devices targeted to receive OTA updates.
protocols
— (Array<String>
)The protocol used to transfer the OTA update image. Valid values are [HTTP], [MQTT], [HTTP, MQTT]. When both HTTP and MQTT are specified, the target device can choose the protocol.
targetSelection
— (String
)Specifies whether the update will continue to run (CONTINUOUS), or will be complete after all the things specified as targets have completed the update (SNAPSHOT). If continuous, the update may also be run on a thing when a change is detected in a target. For example, an update will run on a thing when the thing is added to a target group, even after the update was completed by all things originally in the group. Valid values: CONTINUOUS | SNAPSHOT.
Possible values include:"CONTINUOUS"
"SNAPSHOT"
awsJobExecutionsRolloutConfig
— (map
)Configuration for the rollout of OTA updates.
maximumPerMinute
— (Integer
)The maximum number of OTA update job executions started per minute.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate increase for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute, at the start of the job rollout. This is the initial rate of the rollout.
incrementFactor
— required — (Float
)The rate of increase for a job rollout. The number of things notified is multiplied by this factor.
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
numberOfNotifiedThings
— (Integer
)When this number of things have been notified, it will initiate an increase in the rollout rate.
numberOfSucceededThings
— (Integer
)When this number of things have succeeded in their job execution, it will initiate an increase in the rollout rate.
awsJobPresignedUrlConfig
— (map
)Configuration information for pre-signed URLs.
expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 1800 seconds. Pre-signed URLs are generated when a request for the job document is received.
awsJobAbortConfig
— (map
)The criteria that determine when and how a job abort takes place.
abortCriteriaList
— required — (Array<map>
)The list of criteria that determine when and how to abort the job.
failureType
— required — (String
)The type of job execution failures that can initiate a job abort.
Possible values include:"FAILED"
"REJECTED"
"TIMED_OUT"
"ALL"
action
— required — (String
)The type of job action to take to initiate the job abort.
Possible values include:"CANCEL"
thresholdPercentage
— required — (Float
)The minimum percentage of job execution failures that must occur to initiate the job abort.
Amazon Web Services IoT Core supports up to two digits after the decimal (for example, 10.9 and 10.99, but not 10.999).
minNumberOfExecutedThings
— required — (Integer
)The minimum number of things which must receive job execution notifications before the job can be aborted.
awsJobTimeoutConfig
— (map
)Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to
IN_PROGRESS
. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set toTIMED_OUT
.inProgressTimeoutInMinutes
— (Integer
)Specifies the amount of time, in minutes, this device has to finish execution of this job. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The in progress timer can't be updated and will apply to all job executions for the job. Whenever a job execution remains in the IN_PROGRESS status for longer than this interval, the job execution will fail and switch to the terminal
TIMED_OUT
status.
files
— (Array<map>
)The files to be streamed by the OTA update.
fileName
— (String
)The name of the file.
fileType
— (Integer
)An integer value you can include in the job document to allow your devices to identify the type of file received from the cloud.
fileVersion
— (String
)The file version.
fileLocation
— (map
)The location of the updated firmware.
stream
— (map
)The stream that contains the OTA update.
streamId
— (String
)The stream ID.
fileId
— (Integer
)The ID of a file associated with a stream.
s3Location
— (map
)The location of the updated firmware in S3.
bucket
— (String
)The S3 bucket.
key
— (String
)The S3 key.
version
— (String
)The S3 bucket version.
codeSigning
— (map
)The code signing method of the file.
awsSignerJobId
— (String
)The ID of the
AWSSignerJob
which was created to sign the file.startSigningJobParameter
— (map
)Describes the code-signing job.
signingProfileParameter
— (map
)Describes the code-signing profile.
certificateArn
— (String
)Certificate ARN.
platform
— (String
)The hardware platform of your device.
certificatePathOnDevice
— (String
)The location of the code-signing certificate on your device.
signingProfileName
— (String
)The code-signing profile name.
destination
— (map
)The location to write the code-signed file.
s3Destination
— (map
)Describes the location in S3 of the updated firmware.
bucket
— (String
)The S3 bucket that contains the updated firmware.
prefix
— (String
)The S3 prefix.
customCodeSigning
— (map
)A custom method for code signing a file.
signature
— (map
)The signature for the file.
inlineDocument
— (Buffer, Typed Array, Blob, String
)A base64 encoded binary representation of the code signing signature.
certificateChain
— (map
)The certificate chain.
certificateName
— (String
)The name of the certificate.
inlineDocument
— (String
)A base64 encoded binary representation of the code signing certificate chain.
hashAlgorithm
— (String
)The hash algorithm used to code sign the file. You can use a string as the algorithm name if the target over-the-air (OTA) update devices are able to verify the signature that was generated using the same signature algorithm. For example, FreeRTOS uses
SHA256
orSHA1
, so you can pass either of them based on which was used for generating the signature.signatureAlgorithm
— (String
)The signature algorithm used to code sign the file. You can use a string as the algorithm name if the target over-the-air (OTA) update devices are able to verify the signature that was generated using the same signature algorithm. For example, FreeRTOS uses
ECDSA
orRSA
, so you can pass either of them based on which was used for generating the signature.
attributes
— (map<String>
)A list of name-attribute pairs. They won't be sent to devices as a part of the Job document.
roleArn
— (String
)The IAM role that grants Amazon Web Services IoT Core access to the Amazon S3, IoT jobs and Amazon Web Services Code Signing resources to create an OTA update job.
additionalParameters
— (map<String>
)A list of additional OTA update parameters, which are name-value pairs. They won't be sent to devices as a part of the Job document.
tags
— (Array<map>
)Metadata which can be used to manage updates.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:otaUpdateId
— (String
)The OTA update ID.
awsIotJobId
— (String
)The IoT job ID associated with the OTA update.
otaUpdateArn
— (String
)The OTA update ARN.
awsIotJobArn
— (String
)The IoT job ARN associated with the OTA update.
otaUpdateStatus
— (String
)The OTA update status.
Possible values include:"CREATE_PENDING"
"CREATE_IN_PROGRESS"
"CREATE_COMPLETE"
"CREATE_FAILED"
"DELETE_IN_PROGRESS"
"DELETE_FAILED"
-
(AWS.Response)
—
Returns:
createPackage(params = {}, callback) ⇒ AWS.Request
Creates an IoT software package that can be deployed to your fleet.
Requires permission to access the CreatePackage and GetIndexingConfiguration actions.
Service Reference:
Examples:
Calling the createPackage operation
var params = { packageName: 'STRING_VALUE', /* required */ clientToken: 'STRING_VALUE', description: 'STRING_VALUE', tags: { '<TagKey>': 'STRING_VALUE', /* '<TagKey>': ... */ } }; iot.createPackage(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the new software package.
description
— (String
)A summary of the package being created. This can be used to outline the package's contents or purpose.
tags
— (map<String>
)Metadata that can be used to manage the package.
clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:packageName
— (String
)The name of the software package.
packageArn
— (String
)The Amazon Resource Name (ARN) for the package.
description
— (String
)The package description.
-
(AWS.Response)
—
Returns:
createPackageVersion(params = {}, callback) ⇒ AWS.Request
Creates a new version for an existing IoT software package.
Requires permission to access the CreatePackageVersion and GetIndexingConfiguration actions.
Service Reference:
Examples:
Calling the createPackageVersion operation
var params = { packageName: 'STRING_VALUE', /* required */ versionName: 'STRING_VALUE', /* required */ attributes: { '<ResourceAttributeKey>': 'STRING_VALUE', /* '<ResourceAttributeKey>': ... */ }, clientToken: 'STRING_VALUE', description: 'STRING_VALUE', tags: { '<TagKey>': 'STRING_VALUE', /* '<TagKey>': ... */ } }; iot.createPackageVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the associated software package.
versionName
— (String
)The name of the new package version.
description
— (String
)A summary of the package version being created. This can be used to outline the package's contents or purpose.
attributes
— (map<String>
)Metadata that can be used to define a package version’s configuration. For example, the S3 file location, configuration options that are being sent to the device or fleet.
The combined size of all the attributes on a package version is limited to 3KB.
tags
— (map<String>
)Metadata that can be used to manage the package version.
clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:packageVersionArn
— (String
)The Amazon Resource Name (ARN) for the package.
packageName
— (String
)The name of the associated software package.
versionName
— (String
)The name of the new package version.
description
— (String
)The package version description.
attributes
— (map<String>
)Metadata that were added to the package version that can be used to define a package version’s configuration.
status
— (String
)The status of the package version. For more information, see Package version lifecycle.
Possible values include:"DRAFT"
"PUBLISHED"
"DEPRECATED"
errorReason
— (String
)Error reason for a package version failure during creation or update.
-
(AWS.Response)
—
Returns:
createPolicy(params = {}, callback) ⇒ AWS.Request
Creates an IoT policy.
The created policy is the default version for the policy. This operation creates a policy version with a version identifier of 1 and sets 1 as the policy's default version.
Requires permission to access the CreatePolicy action.
Service Reference:
Examples:
Calling the createPolicy operation
var params = { policyDocument: 'STRING_VALUE', /* required */ policyName: 'STRING_VALUE', /* required */ tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
policyDocument
— (String
)The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
tags
— (Array<map>
)Metadata which can be used to manage the policy.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: &&tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
policyDocument
— (String
)The JSON document that describes the policy.
policyVersionId
— (String
)The policy version ID.
-
(AWS.Response)
—
Returns:
createPolicyVersion(params = {}, callback) ⇒ AWS.Request
Creates a new version of the specified IoT policy. To update a policy, create a new policy version. A managed policy can have up to five versions. If the policy has five versions, you must use DeletePolicyVersion to delete an existing version before you create a new one.
Optionally, you can set the new version as the policy's default version. The default version is the operative version (that is, the version that is in effect for the certificates to which the policy is attached).
Requires permission to access the CreatePolicyVersion action.
Service Reference:
Examples:
Calling the createPolicyVersion operation
var params = { policyDocument: 'STRING_VALUE', /* required */ policyName: 'STRING_VALUE', /* required */ setAsDefault: true || false }; iot.createPolicyVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
policyDocument
— (String
)The JSON document that describes the policy. Minimum length of 1. Maximum length of 2048, excluding whitespace.
setAsDefault
— (Boolean
)Specifies whether the policy version is set as the default. When this parameter is true, the new policy version becomes the operative version (that is, the version that is in effect for the certificates to which the policy is attached).
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policyArn
— (String
)The policy ARN.
policyDocument
— (String
)The JSON document that describes the policy.
policyVersionId
— (String
)The policy version ID.
isDefaultVersion
— (Boolean
)Specifies whether the policy version is the default.
-
(AWS.Response)
—
Returns:
createProvisioningClaim(params = {}, callback) ⇒ AWS.Request
Creates a provisioning claim.
Requires permission to access the CreateProvisioningClaim action.
Service Reference:
Examples:
Calling the createProvisioningClaim operation
var params = { templateName: 'STRING_VALUE' /* required */ }; iot.createProvisioningClaim(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template to use.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateId
— (String
)The ID of the certificate.
certificatePem
— (String
)The provisioning claim certificate.
keyPair
— (map
)The provisioning claim key pair.
PublicKey
— (String
)The public key.
PrivateKey
— (String
)The private key.
expiration
— (Date
)The provisioning claim expiration time.
-
(AWS.Response)
—
Returns:
createProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Creates a provisioning template.
Requires permission to access the CreateProvisioningTemplate action.
Service Reference:
Examples:
Calling the createProvisioningTemplate operation
var params = { provisioningRoleArn: 'STRING_VALUE', /* required */ templateBody: 'STRING_VALUE', /* required */ templateName: 'STRING_VALUE', /* required */ description: 'STRING_VALUE', enabled: true || false, preProvisioningHook: { targetArn: 'STRING_VALUE', /* required */ payloadVersion: 'STRING_VALUE' }, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], type: FLEET_PROVISIONING | JITP }; iot.createProvisioningTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template.
description
— (String
)The description of the provisioning template.
templateBody
— (String
)The JSON formatted contents of the provisioning template.
enabled
— (Boolean
)True to enable the provisioning template, otherwise false.
provisioningRoleArn
— (String
)The role ARN for the role associated with the provisioning template. This IoT role grants permission to provision a device.
preProvisioningHook
— (map
)Creates a pre-provisioning hook template. Only supports template of type
FLEET_PROVISIONING
. For more information about provisioning template types, see type.payloadVersion
— (String
)The payload that was sent to the target function.
Note: Only Lambda functions are currently supported.
targetArn
— required — (String
)The ARN of the target function.
Note: Only Lambda functions are currently supported.
tags
— (Array<map>
)Metadata which can be used to manage the provisioning template.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: &&tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
type
— (String
)The type you define in a provisioning template. You can create a template with only one type. You can't change the template type after its creation. The default value is
Possible values include:FLEET_PROVISIONING
. For more information about provisioning template, see: Provisioning template."FLEET_PROVISIONING"
"JITP"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:templateArn
— (String
)The ARN that identifies the provisioning template.
templateName
— (String
)The name of the provisioning template.
defaultVersionId
— (Integer
)The default version of the provisioning template.
-
(AWS.Response)
—
Returns:
createProvisioningTemplateVersion(params = {}, callback) ⇒ AWS.Request
Creates a new version of a provisioning template.
Requires permission to access the CreateProvisioningTemplateVersion action.
Service Reference:
Examples:
Calling the createProvisioningTemplateVersion operation
var params = { templateBody: 'STRING_VALUE', /* required */ templateName: 'STRING_VALUE', /* required */ setAsDefault: true || false }; iot.createProvisioningTemplateVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template.
templateBody
— (String
)The JSON formatted contents of the provisioning template.
setAsDefault
— (Boolean
)Sets a fleet provision template version as the default version.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:templateArn
— (String
)The ARN that identifies the provisioning template.
templateName
— (String
)The name of the provisioning template.
versionId
— (Integer
)The version of the provisioning template.
isDefaultVersion
— (Boolean
)True if the provisioning template version is the default version, otherwise false.
-
(AWS.Response)
—
Returns:
createRoleAlias(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the createRoleAlias operation
var params = { roleAlias: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ credentialDurationSeconds: 'NUMBER_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createRoleAlias(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
roleAlias
— (String
)The role alias that points to a role ARN. This allows you to change the role without having to update the device.
roleArn
— (String
)The role ARN.
credentialDurationSeconds
— (Integer
)How long (in seconds) the credentials will be valid. The default value is 3,600 seconds.
This value must be less than or equal to the maximum session duration of the IAM role that the role alias references.
tags
— (Array<map>
)Metadata which can be used to manage the role alias.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: &&tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleAlias
— (String
)The role alias.
roleAliasArn
— (String
)The role alias ARN.
-
(AWS.Response)
—
Returns:
createScheduledAudit(params = {}, callback) ⇒ AWS.Request
Creates a scheduled audit that is run at a specified time interval.
Requires permission to access the CreateScheduledAudit action.
Service Reference:
Examples:
Calling the createScheduledAudit operation
var params = { frequency: DAILY | WEEKLY | BIWEEKLY | MONTHLY, /* required */ scheduledAuditName: 'STRING_VALUE', /* required */ targetCheckNames: [ /* required */ 'STRING_VALUE', /* more items */ ], dayOfMonth: 'STRING_VALUE', dayOfWeek: SUN | MON | TUE | WED | THU | FRI | SAT, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createScheduledAudit(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
frequency
— (String
)How often the scheduled audit takes place, either
Possible values include:DAILY
,WEEKLY
,BIWEEKLY
orMONTHLY
. The start time of each audit is determined by the system."DAILY"
"WEEKLY"
"BIWEEKLY"
"MONTHLY"
dayOfMonth
— (String
)The day of the month on which the scheduled audit takes place. This can be "1" through "31" or "LAST". This field is required if the "frequency" parameter is set to
MONTHLY
. If days 29 to 31 are specified, and the month doesn't have that many days, the audit takes place on theLAST
day of the month.dayOfWeek
— (String
)The day of the week on which the scheduled audit takes place, either
Possible values include:SUN
,MON
,TUE
,WED
,THU
,FRI
, orSAT
. This field is required if thefrequency
parameter is set toWEEKLY
orBIWEEKLY
."SUN"
"MON"
"TUE"
"WED"
"THU"
"FRI"
"SAT"
targetCheckNames
— (Array<String>
)Which checks are performed during the scheduled audit. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)scheduledAuditName
— (String
)The name you want to give to the scheduled audit. (Max. 128 chars)
tags
— (Array<map>
)Metadata that can be used to manage the scheduled audit.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:scheduledAuditArn
— (String
)The ARN of the scheduled audit.
-
(AWS.Response)
—
Returns:
createSecurityProfile(params = {}, callback) ⇒ AWS.Request
Creates a Device Defender security profile.
Requires permission to access the CreateSecurityProfile action.
Service Reference:
Examples:
Calling the createSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE', /* required */ additionalMetricsToRetain: [ 'STRING_VALUE', /* more items */ ], additionalMetricsToRetainV2: [ { metric: 'STRING_VALUE', /* required */ exportMetric: true || false, metricDimension: { dimensionName: 'STRING_VALUE', /* required */ operator: IN | NOT_IN } }, /* more items */ ], alertTargets: { '<AlertTargetType>': { alertTargetArn: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE' /* required */ }, /* '<AlertTargetType>': ... */ }, behaviors: [ { name: 'STRING_VALUE', /* required */ criteria: { comparisonOperator: less-than | less-than-equals | greater-than | greater-than-equals | in-cidr-set | not-in-cidr-set | in-port-set | not-in-port-set | in-set | not-in-set, consecutiveDatapointsToAlarm: 'NUMBER_VALUE', consecutiveDatapointsToClear: 'NUMBER_VALUE', durationSeconds: 'NUMBER_VALUE', mlDetectionConfig: { confidenceLevel: LOW | MEDIUM | HIGH /* required */ }, statisticalThreshold: { statistic: 'STRING_VALUE' }, value: { cidrs: [ 'STRING_VALUE', /* more items */ ], count: 'NUMBER_VALUE', number: 'NUMBER_VALUE', numbers: [ 'NUMBER_VALUE', /* more items */ ], ports: [ 'NUMBER_VALUE', /* more items */ ], strings: [ 'STRING_VALUE', /* more items */ ] } }, exportMetric: true || false, metric: 'STRING_VALUE', metricDimension: { dimensionName: 'STRING_VALUE', /* required */ operator: IN | NOT_IN }, suppressAlerts: true || false }, /* more items */ ], metricsExportConfig: { mqttTopic: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE' /* required */ }, securityProfileDescription: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The name you are giving to the security profile.
securityProfileDescription
— (String
)A description of the security profile.
behaviors
— (Array<map>
)Specifies the behaviors that, when violated by a device (thing), cause an alert.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
alertTargets
— (map<map>
)Specifies the destinations to which alerts are sent. (Alerts are always sent to the console.) Alerts are generated when a device (thing) violates a behavior.
alertTargetArn
— required — (String
)The Amazon Resource Name (ARN) of the notification target to which alerts are sent.
roleArn
— required — (String
)The ARN of the role that grants permission to send alerts to the notification target.
additionalMetricsToRetain
— (Array<String>
)Please use CreateSecurityProfileRequest$additionalMetricsToRetainV2 instead.
A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's
behaviors
, but it is also retained for any metric specified here. Can be used with custom metrics; cannot be used with dimensions.additionalMetricsToRetainV2
— (Array<map>
)A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's
behaviors
, but it is also retained for any metric specified here. Can be used with custom metrics; cannot be used with dimensions.metric
— required — (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension of a metric. This can't be used with custom metrics.
dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
exportMetric
— (Boolean
)The value indicates exporting metrics related to the
MetricToRetain
when it's true.
tags
— (Array<map>
)Metadata that can be used to manage the security profile.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
metricsExportConfig
— (map
)Specifies the MQTT topic and role ARN required for metric export.
mqttTopic
— required — (String
)The MQTT topic that Device Defender Detect should publish messages to for metrics export.
roleArn
— required — (String
)This role ARN has permission to publish MQTT messages, after which Device Defender Detect can assume the role and publish messages on your behalf.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:securityProfileName
— (String
)The name you gave to the security profile.
securityProfileArn
— (String
)The ARN of the security profile.
-
(AWS.Response)
—
Returns:
createStream(params = {}, callback) ⇒ AWS.Request
Creates a stream for delivering one or more large files in chunks over MQTT. A stream transports data bytes in chunks or blocks packaged as MQTT messages from a source like S3. You can have one or more files associated with a stream.
Requires permission to access the CreateStream action.
Service Reference:
Examples:
Calling the createStream operation
var params = { files: [ /* required */ { fileId: 'NUMBER_VALUE', s3Location: { bucket: 'STRING_VALUE', key: 'STRING_VALUE', version: 'STRING_VALUE' } }, /* more items */ ], roleArn: 'STRING_VALUE', /* required */ streamId: 'STRING_VALUE', /* required */ description: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.createStream(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
streamId
— (String
)The stream ID.
description
— (String
)A description of the stream.
files
— (Array<map>
)The files to stream.
fileId
— (Integer
)The file ID.
s3Location
— (map
)The location of the file in S3.
bucket
— (String
)The S3 bucket.
key
— (String
)The S3 key.
version
— (String
)The S3 bucket version.
roleArn
— (String
)An IAM role that allows the IoT service principal to access your S3 files.
tags
— (Array<map>
)Metadata which can be used to manage streams.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:streamId
— (String
)The stream ID.
streamArn
— (String
)The stream ARN.
description
— (String
)A description of the stream.
streamVersion
— (Integer
)The version of the stream.
-
(AWS.Response)
—
Returns:
createThing(params = {}, callback) ⇒ AWS.Request
Creates a thing record in the registry. If this call is made multiple times using the same thing name and configuration, the call will succeed. If this call is made with the same thing name but different configuration a
ResourceAlreadyExistsException
is thrown.Note: This is a control plane operation. See Authorization for information about authorizing control plane actions.Requires permission to access the CreateThing action.
Service Reference:
Examples:
Calling the createThing operation
var params = { thingName: 'STRING_VALUE', /* required */ attributePayload: { attributes: { '<AttributeName>': 'STRING_VALUE', /* '<AttributeName>': ... */ }, merge: true || false }, billingGroupName: 'STRING_VALUE', thingTypeName: 'STRING_VALUE' }; iot.createThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing to create.
You can't change a thing's name after you create it. To change a thing's name, you must create a new thing, give it the new name, and then delete the old thing.
thingTypeName
— (String
)The name of the thing type associated with the new thing.
attributePayload
— (map
)The attribute payload, which consists of up to three name/value pairs in a JSON document. For example:
{\"attributes\":{\"string1\":\"string2\"}}
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
billingGroupName
— (String
)The name of the billing group the thing will be added to.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingName
— (String
)The name of the new thing.
thingArn
— (String
)The ARN of the new thing.
thingId
— (String
)The thing ID.
-
(AWS.Response)
—
Returns:
createThingGroup(params = {}, callback) ⇒ AWS.Request
Create a thing group.
Note: This is a control plane operation. See Authorization for information about authorizing control plane actions. If theThingGroup
that you create has the exact same attributes as an existingThingGroup
, you will get a 200 success response.Requires permission to access the CreateThingGroup action.
Service Reference:
Examples:
Calling the createThingGroup operation
var params = { thingGroupName: 'STRING_VALUE', /* required */ parentGroupName: 'STRING_VALUE', tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], thingGroupProperties: { attributePayload: { attributes: { '<AttributeName>': 'STRING_VALUE', /* '<AttributeName>': ... */ }, merge: true || false }, thingGroupDescription: 'STRING_VALUE' } }; iot.createThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The thing group name to create.
parentGroupName
— (String
)The name of the parent thing group.
thingGroupProperties
— (map
)The thing group properties.
thingGroupDescription
— (String
)The thing group description.
attributePayload
— (map
)The thing group attributes in JSON format.
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
tags
— (Array<map>
)Metadata which can be used to manage the thing group.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingGroupName
— (String
)The thing group name.
thingGroupArn
— (String
)The thing group ARN.
thingGroupId
— (String
)The thing group ID.
-
(AWS.Response)
—
Returns:
createThingType(params = {}, callback) ⇒ AWS.Request
Creates a new thing type.
Requires permission to access the CreateThingType action.
Service Reference:
Examples:
Calling the createThingType operation
var params = { thingTypeName: 'STRING_VALUE', /* required */ tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], thingTypeProperties: { searchableAttributes: [ 'STRING_VALUE', /* more items */ ], thingTypeDescription: 'STRING_VALUE' } }; iot.createThingType(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingTypeName
— (String
)The name of the thing type.
thingTypeProperties
— (map
)The ThingTypeProperties for the thing type to create. It contains information about the new thing type including a description, and a list of searchable thing attribute names.
thingTypeDescription
— (String
)The description of the thing type.
searchableAttributes
— (Array<String>
)A list of searchable thing attribute names.
tags
— (Array<map>
)Metadata which can be used to manage the thing type.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingTypeName
— (String
)The name of the thing type.
thingTypeArn
— (String
)The Amazon Resource Name (ARN) of the thing type.
thingTypeId
— (String
)The thing type ID.
-
(AWS.Response)
—
Returns:
createTopicRule(params = {}, callback) ⇒ AWS.Request
Creates a rule. Creating rules is an administrator-level action. Any user who has permission to create rules will be able to access data processed by the rule.
Requires permission to access the CreateTopicRule action.
Service Reference:
Examples:
Calling the createTopicRule operation
var params = { ruleName: 'STRING_VALUE', /* required */ topicRulePayload: { /* required */ actions: [ /* required */ { cloudwatchAlarm: { alarmName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ stateReason: 'STRING_VALUE', /* required */ stateValue: 'STRING_VALUE' /* required */ }, cloudwatchLogs: { logGroupName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false }, cloudwatchMetric: { metricName: 'STRING_VALUE', /* required */ metricNamespace: 'STRING_VALUE', /* required */ metricUnit: 'STRING_VALUE', /* required */ metricValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ metricTimestamp: 'STRING_VALUE' }, dynamoDB: { hashKeyField: 'STRING_VALUE', /* required */ hashKeyValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ hashKeyType: STRING | NUMBER, operation: 'STRING_VALUE', payloadField: 'STRING_VALUE', rangeKeyField: 'STRING_VALUE', rangeKeyType: STRING | NUMBER, rangeKeyValue: 'STRING_VALUE' }, dynamoDBv2: { putItem: { /* required */ tableName: 'STRING_VALUE' /* required */ }, roleArn: 'STRING_VALUE' /* required */ }, elasticsearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, firehose: { deliveryStreamName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, separator: 'STRING_VALUE' }, http: { url: 'STRING_VALUE', /* required */ auth: { sigv4: { roleArn: 'STRING_VALUE', /* required */ serviceName: 'STRING_VALUE', /* required */ signingRegion: 'STRING_VALUE' /* required */ } }, confirmationUrl: 'STRING_VALUE', headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, iotAnalytics: { batchMode: true || false, channelArn: 'STRING_VALUE', channelName: 'STRING_VALUE', roleArn: 'STRING_VALUE' }, iotEvents: { inputName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, messageId: 'STRING_VALUE' }, iotSiteWise: { putAssetPropertyValueEntries: [ /* required */ { propertyValues: [ /* required */ { timestamp: { /* required */ timeInSeconds: 'STRING_VALUE', /* required */ offsetInNanos: 'STRING_VALUE' }, value: { /* required */ booleanValue: 'STRING_VALUE', doubleValue: 'STRING_VALUE', integerValue: 'STRING_VALUE', stringValue: 'STRING_VALUE' }, quality: 'STRING_VALUE' }, /* more items */ ], assetId: 'STRING_VALUE', entryId: 'STRING_VALUE', propertyAlias: 'STRING_VALUE', propertyId: 'STRING_VALUE' }, /* more items */ ], roleArn: 'STRING_VALUE' /* required */ }, kafka: { clientProperties: { /* required */ '<String>': 'STRING_VALUE', /* '<String>': ... */ }, destinationArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], key: 'STRING_VALUE', partition: 'STRING_VALUE' }, kinesis: { roleArn: 'STRING_VALUE', /* required */ streamName: 'STRING_VALUE', /* required */ partitionKey: 'STRING_VALUE' }, lambda: { functionArn: 'STRING_VALUE' /* required */ }, location: { deviceId: 'STRING_VALUE', /* required */ latitude: 'STRING_VALUE', /* required */ longitude: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ trackerName: 'STRING_VALUE', /* required */ timestamp: { value: 'STRING_VALUE', /* required */ unit: 'STRING_VALUE' } }, openSearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, republish: { roleArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: { contentType: 'STRING_VALUE', correlationData: 'STRING_VALUE', messageExpiry: 'STRING_VALUE', payloadFormatIndicator: 'STRING_VALUE', responseTopic: 'STRING_VALUE', userProperties: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, qos: 'NUMBER_VALUE' }, s3: { bucketName: 'STRING_VALUE', /* required */ key: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ cannedAcl: private | public-read | public-read-write | aws-exec-read | authenticated-read | bucket-owner-read | bucket-owner-full-control | log-delivery-write }, salesforce: { token: 'STRING_VALUE', /* required */ url: 'STRING_VALUE' /* required */ }, sns: { roleArn: 'STRING_VALUE', /* required */ targetArn: 'STRING_VALUE', /* required */ messageFormat: RAW | JSON }, sqs: { queueUrl: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ useBase64: true || false }, stepFunctions: { roleArn: 'STRING_VALUE', /* required */ stateMachineName: 'STRING_VALUE', /* required */ executionNamePrefix: 'STRING_VALUE' }, timestream: { databaseName: 'STRING_VALUE', /* required */ dimensions: [ /* required */ { name: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ timestamp: { unit: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ } } }, /* more items */ ], sql: 'STRING_VALUE', /* required */ awsIotSqlVersion: 'STRING_VALUE', description: 'STRING_VALUE', errorAction: { cloudwatchAlarm: { alarmName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ stateReason: 'STRING_VALUE', /* required */ stateValue: 'STRING_VALUE' /* required */ }, cloudwatchLogs: { logGroupName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false }, cloudwatchMetric: { metricName: 'STRING_VALUE', /* required */ metricNamespace: 'STRING_VALUE', /* required */ metricUnit: 'STRING_VALUE', /* required */ metricValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ metricTimestamp: 'STRING_VALUE' }, dynamoDB: { hashKeyField: 'STRING_VALUE', /* required */ hashKeyValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ hashKeyType: STRING | NUMBER, operation: 'STRING_VALUE', payloadField: 'STRING_VALUE', rangeKeyField: 'STRING_VALUE', rangeKeyType: STRING | NUMBER, rangeKeyValue: 'STRING_VALUE' }, dynamoDBv2: { putItem: { /* required */ tableName: 'STRING_VALUE' /* required */ }, roleArn: 'STRING_VALUE' /* required */ }, elasticsearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, firehose: { deliveryStreamName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, separator: 'STRING_VALUE' }, http: { url: 'STRING_VALUE', /* required */ auth: { sigv4: { roleArn: 'STRING_VALUE', /* required */ serviceName: 'STRING_VALUE', /* required */ signingRegion: 'STRING_VALUE' /* required */ } }, confirmationUrl: 'STRING_VALUE', headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, iotAnalytics: { batchMode: true || false, channelArn: 'STRING_VALUE', channelName: 'STRING_VALUE', roleArn: 'STRING_VALUE' }, iotEvents: { inputName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, messageId: 'STRING_VALUE' }, iotSiteWise: { putAssetPropertyValueEntries: [ /* required */ { propertyValues: [ /* required */ { timestamp: { /* required */ timeInSeconds: 'STRING_VALUE', /* required */ offsetInNanos: 'STRING_VALUE' }, value: { /* required */ booleanValue: 'STRING_VALUE', doubleValue: 'STRING_VALUE', integerValue: 'STRING_VALUE', stringValue: 'STRING_VALUE' }, quality: 'STRING_VALUE' }, /* more items */ ], assetId: 'STRING_VALUE', entryId: 'STRING_VALUE', propertyAlias: 'STRING_VALUE', propertyId: 'STRING_VALUE' }, /* more items */ ], roleArn: 'STRING_VALUE' /* required */ }, kafka: { clientProperties: { /* required */ '<String>': 'STRING_VALUE', /* '<String>': ... */ }, destinationArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], key: 'STRING_VALUE', partition: 'STRING_VALUE' }, kinesis: { roleArn: 'STRING_VALUE', /* required */ streamName: 'STRING_VALUE', /* required */ partitionKey: 'STRING_VALUE' }, lambda: { functionArn: 'STRING_VALUE' /* required */ }, location: { deviceId: 'STRING_VALUE', /* required */ latitude: 'STRING_VALUE', /* required */ longitude: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ trackerName: 'STRING_VALUE', /* required */ timestamp: { value: 'STRING_VALUE', /* required */ unit: 'STRING_VALUE' } }, openSearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, republish: { roleArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: { contentType: 'STRING_VALUE', correlationData: 'STRING_VALUE', messageExpiry: 'STRING_VALUE', payloadFormatIndicator: 'STRING_VALUE', responseTopic: 'STRING_VALUE', userProperties: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, qos: 'NUMBER_VALUE' }, s3: { bucketName: 'STRING_VALUE', /* required */ key: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ cannedAcl: private | public-read | public-read-write | aws-exec-read | authenticated-read | bucket-owner-read | bucket-owner-full-control | log-delivery-write }, salesforce: { token: 'STRING_VALUE', /* required */ url: 'STRING_VALUE' /* required */ }, sns: { roleArn: 'STRING_VALUE', /* required */ targetArn: 'STRING_VALUE', /* required */ messageFormat: RAW | JSON }, sqs: { queueUrl: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ useBase64: true || false }, stepFunctions: { roleArn: 'STRING_VALUE', /* required */ stateMachineName: 'STRING_VALUE', /* required */ executionNamePrefix: 'STRING_VALUE' }, timestream: { databaseName: 'STRING_VALUE', /* required */ dimensions: [ /* required */ { name: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ timestamp: { unit: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ } } }, ruleDisabled: true || false }, tags: 'STRING_VALUE' }; iot.createTopicRule(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
ruleName
— (String
)The name of the rule.
topicRulePayload
— (map
)The rule payload.
sql
— required — (String
)The SQL statement used to query the topic. For more information, see IoT SQL Reference in the IoT Developer Guide.
description
— (String
)The description of the rule.
actions
— required — (Array<map>
)The actions associated with the rule.
dynamoDB
— (map
)Write to a DynamoDB table.
tableName
— required — (String
)The name of the DynamoDB table.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
operation
— (String
)The type of operation to be performed. This follows the substitution template, so it can be
${operation}
, but the substitution must result in one of the following:INSERT
,UPDATE
, orDELETE
.hashKeyField
— required — (String
)The hash key name.
hashKeyValue
— required — (String
)The hash key value.
hashKeyType
— (String
)The hash key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
rangeKeyField
— (String
)The range key name.
rangeKeyValue
— (String
)The range key value.
rangeKeyType
— (String
)The range key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
payloadField
— (String
)The action payload. This name can be customized.
dynamoDBv2
— (map
)Write to a DynamoDB table. This is a new version of the DynamoDB action. It allows you to write each attribute in an MQTT message payload into a separate DynamoDB column.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
putItem
— required — (map
)Specifies the DynamoDB table to which the message data will be written. For example:
{ "dynamoDBv2": { "roleArn": "aws:iam:12341251:my-role" "putItem": { "tableName": "my-table" } } }
Each attribute in the message payload will be written to a separate column in the DynamoDB database.
tableName
— required — (String
)The table where the message data will be written.
lambda
— (map
)Invoke a Lambda function.
functionArn
— required — (String
)The ARN of the Lambda function.
sns
— (map
)Publish to an Amazon SNS topic.
targetArn
— required — (String
)The ARN of the SNS topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
messageFormat
— (String
)(Optional) The message format of the message to publish. Accepted values are "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this setting to determine if the payload should be parsed and relevant platform-specific bits of the payload should be extracted. To read more about SNS message formats, see https://docs.aws.amazon.com/sns/latest/dg/json-formats.html refer to their official documentation.
Possible values include:"RAW"
"JSON"
sqs
— (map
)Publish to an Amazon SQS queue.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
queueUrl
— required — (String
)The URL of the Amazon SQS queue.
useBase64
— (Boolean
)Specifies whether to use Base64 encoding.
kinesis
— (map
)Write data to an Amazon Kinesis stream.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the Amazon Kinesis stream.
streamName
— required — (String
)The name of the Amazon Kinesis stream.
partitionKey
— (String
)The partition key.
republish
— (map
)Publish to another MQTT topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
topic
— required — (String
)The name of the MQTT topic.
qos
— (Integer
)The Quality of Service (QoS) level to use when republishing messages. The default value is 0.
headers
— (map
)MQTT Version 5.0 headers information. For more information, see MQTT from the Amazon Web Services IoT Core Developer Guide.
payloadFormatIndicator
— (String
)An
Enum
string value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTES
andUTF8_DATA
.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates.
contentType
— (String
)A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type from the MQTT Version 5.0 specification.
Supports substitution templates.
responseTopic
— (String
)A UTF-8 encoded string that's used as the topic name for a response message. The response topic is used to describe the topic which the receiver should publish to as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic from the MQTT Version 5.0 specification.
Supports substitution templates.
correlationData
— (String
)The base64-encoded binary data used by the sender of the request message to identify which request the response message is for when it's received.
For more information, see Correlation Data from the MQTT Version 5.0 specification.
Note: This binary data must be based64-encoded.Supports substitution templates.
messageExpiry
— (String
)A user-defined integer value that will persist a message at the message broker for a specified amount of time to ensure that the message will expire if it's no longer relevant to the subscriber. The value of
messageExpiry
represents the number of seconds before it expires. For more information about the limits ofmessageExpiry
, see Amazon Web Services IoT Core message broker and protocol limits and quotas from the Amazon Web Services Reference Guide.Supports substitution templates.
userProperties
— (Array<map>
)An array of key-value pairs that you define in the MQTT5 header.
key
— required — (String
)A key to be specified in
UserProperty
.value
— required — (String
)A value to be specified in
UserProperty
.
s3
— (map
)Write to an Amazon S3 bucket.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
bucketName
— required — (String
)The Amazon S3 bucket.
key
— required — (String
)The object key. For more information, see Actions, resources, and condition keys for Amazon S3.
cannedAcl
— (String
)The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs.
Possible values include:"private"
"public-read"
"public-read-write"
"aws-exec-read"
"authenticated-read"
"bucket-owner-read"
"bucket-owner-full-control"
"log-delivery-write"
firehose
— (map
)Write to an Amazon Kinesis Firehose stream.
roleArn
— required — (String
)The IAM role that grants access to the Amazon Kinesis Firehose stream.
deliveryStreamName
— required — (String
)The delivery stream name.
separator
— (String
)A character separator that will be used to separate records written to the Firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows newline), ',' (comma).
batchMode
— (Boolean
)Whether to deliver the Kinesis Data Firehose stream as a batch by using
PutRecordBatch
. The default value isfalse
.When
batchMode
istrue
and the rule's SQL statement evaluates to an Array, each Array element forms one record in thePutRecordBatch
request. The resulting array can't have more than 500 records.
cloudwatchMetric
— (map
)Capture a CloudWatch metric.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch metric.
metricNamespace
— required — (String
)The CloudWatch metric namespace name.
metricName
— required — (String
)The CloudWatch metric name.
metricValue
— required — (String
)The CloudWatch metric value.
metricUnit
— required — (String
)The metric unit supported by CloudWatch.
metricTimestamp
— (String
)An optional Unix timestamp.
cloudwatchAlarm
— (map
)Change the state of a CloudWatch alarm.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch alarm.
alarmName
— required — (String
)The CloudWatch alarm name.
stateReason
— required — (String
)The reason for the alarm change.
stateValue
— required — (String
)The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
cloudwatchLogs
— (map
)Send data to CloudWatch Logs.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch log.
logGroupName
— required — (String
)The CloudWatch log group to which the action sends data.
batchMode
— (Boolean
)Indicates whether batches of log records will be extracted and uploaded into CloudWatch. Values include
true
orfalse
(default).
elasticsearch
— (map
)Write data to an Amazon OpenSearch Service domain.
Note: TheElasticsearch
action can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearch
rule action instead. For more information, see OpenSearchAction.roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
salesforce
— (map
)Send a message to a Salesforce IoT Cloud Input Stream.
token
— required — (String
)The token used to authenticate access to the Salesforce IoT Cloud Input Stream. The token is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
url
— required — (String
)The URL exposed by the Salesforce IoT Cloud Input Stream. The URL is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
iotAnalytics
— (map
)Sends message data to an IoT Analytics channel.
channelArn
— (String
)(deprecated) The ARN of the IoT Analytics channel to which message data will be sent.
channelName
— (String
)The name of the IoT Analytics channel to which message data will be sent.
batchMode
— (Boolean
)Whether to process the action as a batch. The default value is
false
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed byBatchPutMessage
to the IoT Analytics channel. The resulting array can't have more than 100 messages.roleArn
— (String
)The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
iotEvents
— (map
)Sends an input to an IoT Events detector.
inputName
— required — (String
)The name of the IoT Events input.
messageId
— (String
)The ID of the message. The default
messageId
is a new UUID value.When
batchMode
istrue
, you can't specify amessageId
--a new UUID value will be assigned.Assign a value to this property to ensure that only one input (message) with a given
messageId
will be processed by an IoT Events detector.batchMode
— (Boolean
)Whether to process the event actions as a batch. The default value is
false
.When
batchMode
istrue
, you can't specify amessageId
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when it's sent to IoT Events by callingBatchPutMessage
. The resulting array can't have more than 10 messages.roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an input to an IoT Events detector. ("Action":"iotevents:BatchPutMessage").
iotSiteWise
— (map
)Sends data from the MQTT message that triggered the rule to IoT SiteWise asset properties.
putAssetPropertyValueEntries
— required — (Array<map>
)A list of asset property value entries.
entryId
— (String
)Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
assetId
— (String
)The ID of the IoT SiteWise asset. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyId
— (String
)The ID of the asset's property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyAlias
— (String
)The name of the property alias associated with your asset property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyValues
— required — (Array<map>
)A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
value
— required — (map
)The value of the asset property.
stringValue
— (String
)Optional. The string value of the value entry. Accepts substitution templates.
integerValue
— (String
)Optional. A string that contains the integer value of the value entry. Accepts substitution templates.
doubleValue
— (String
)Optional. A string that contains the double value of the value entry. Accepts substitution templates.
booleanValue
— (String
)Optional. A string that contains the boolean value (
true
orfalse
) of the value entry. Accepts substitution templates.
timestamp
— required — (map
)The asset property value timestamp.
timeInSeconds
— required — (String
)A string that contains the time in seconds since epoch. Accepts substitution templates.
offsetInNanos
— (String
)Optional. A string that contains the nanosecond time offset. Accepts substitution templates.
quality
— (String
)Optional. A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD
,BAD
, orUNCERTAIN
.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an asset property value to IoT SiteWise. (
"Action": "iotsitewise:BatchPutAssetPropertyValue"
). The trust policy can restrict access to specific asset hierarchy paths.
stepFunctions
— (map
)Starts execution of a Step Functions state machine.
executionNamePrefix
— (String
)(Optional) A name will be given to the state machine execution consisting of this prefix followed by a UUID. Step Functions automatically creates a unique name for each state machine execution if one is not provided.
stateMachineName
— required — (String
)The name of the Step Functions state machine whose execution will be started.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to start execution of a state machine ("Action":"states:StartExecution").
timestream
— (map
)The Timestream rule action writes attributes (measures) from an MQTT message into an Amazon Timestream table. For more information, see the Timestream topic rule action documentation.
roleArn
— required — (String
)The ARN of the role that grants permission to write to the Amazon Timestream database table.
databaseName
— required — (String
)The name of an Amazon Timestream database.
tableName
— required — (String
)The name of the database table into which to write the measure records.
dimensions
— required — (Array<map>
)Metadata attributes of the time series that are written in each measure record.
name
— required — (String
)The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.
Dimensions cannot be named:
measure_name
,measure_value
, ortime
. These names are reserved. Dimension names cannot start withts_
ormeasure_value
and they cannot contain the colon (:
) character.value
— required — (String
)The value to write in this column of the database record.
timestamp
— (map
)Specifies an application-defined value to replace the default value assigned to the Timestream record's timestamp in the
time
column.You can use this property to specify the value and the precision of the Timestream record's timestamp. You can specify a value from the message payload or a value computed by a substitution template.
If omitted, the topic rule action assigns the timestamp, in milliseconds, at the time it processed the rule.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— required — (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
http
— (map
)Send data to an HTTPS endpoint.
url
— required — (String
)The endpoint URL. If substitution templates are used in the URL, you must also specify a
confirmationUrl
. If this is a new destination, a newTopicRuleDestination
is created if possible.confirmationUrl
— (String
)The URL to which IoT sends a confirmation message. The value of the confirmation URL must be a prefix of the endpoint URL. If you do not specify a confirmation URL IoT uses the endpoint URL as the confirmation URL. If you use substitution templates in the confirmationUrl, you must create and enable topic rule destinations that match each possible value of the substitution template before traffic is allowed to your endpoint URL.
headers
— (Array<map>
)The HTTP headers to send with the message data.
key
— required — (String
)The HTTP header key.
value
— required — (String
)The HTTP header value. Substitution templates are supported.
auth
— (map
)The authentication method to use when sending data to an HTTPS endpoint.
sigv4
— (map
)Use Sig V4 authorization. For more information, see Signature Version 4 Signing Process.
signingRegion
— required — (String
)The signing region.
serviceName
— required — (String
)The service name to use while signing with Sig V4.
roleArn
— required — (String
)The ARN of the signing role.
kafka
— (map
)Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
destinationArn
— required — (String
)The ARN of Kafka action's VPC
TopicRuleDestination
.topic
— required — (String
)The Kafka topic for messages to be sent to the Kafka broker.
key
— (String
)The Kafka message key.
partition
— (String
)The Kafka message partition.
clientProperties
— required — (map<String>
)Properties of the Apache Kafka producer client.
headers
— (Array<map>
)The list of Kafka headers that you specify.
key
— required — (String
)The key of the Kafka header.
value
— required — (String
)The value of the Kafka header.
openSearch
— (map
)Write data to an Amazon OpenSearch Service domain.
roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The OpenSearch index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
location
— (map
)The Amazon Location Service rule action sends device location updates from an MQTT message to an Amazon Location tracker resource.
roleArn
— required — (String
)The IAM role that grants permission to write to the Amazon Location resource.
trackerName
— required — (String
)The name of the tracker resource in Amazon Location in which the location is updated.
deviceId
— required — (String
)The unique ID of the device providing the location data.
timestamp
— (map
)The time that the location data was sampled. The default value is the time the MQTT message was processed.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
latitude
— required — (String
)A string that evaluates to a double value that represents the latitude of the device's location.
longitude
— required — (String
)A string that evaluates to a double value that represents the longitude of the device's location.
ruleDisabled
— (Boolean
)Specifies whether the rule is disabled.
awsIotSqlVersion
— (String
)The version of the SQL rules engine to use when evaluating the rule.
errorAction
— (map
)The action to take when an error occurs.
dynamoDB
— (map
)Write to a DynamoDB table.
tableName
— required — (String
)The name of the DynamoDB table.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
operation
— (String
)The type of operation to be performed. This follows the substitution template, so it can be
${operation}
, but the substitution must result in one of the following:INSERT
,UPDATE
, orDELETE
.hashKeyField
— required — (String
)The hash key name.
hashKeyValue
— required — (String
)The hash key value.
hashKeyType
— (String
)The hash key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
rangeKeyField
— (String
)The range key name.
rangeKeyValue
— (String
)The range key value.
rangeKeyType
— (String
)The range key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
payloadField
— (String
)The action payload. This name can be customized.
dynamoDBv2
— (map
)Write to a DynamoDB table. This is a new version of the DynamoDB action. It allows you to write each attribute in an MQTT message payload into a separate DynamoDB column.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
putItem
— required — (map
)Specifies the DynamoDB table to which the message data will be written. For example:
{ "dynamoDBv2": { "roleArn": "aws:iam:12341251:my-role" "putItem": { "tableName": "my-table" } } }
Each attribute in the message payload will be written to a separate column in the DynamoDB database.
tableName
— required — (String
)The table where the message data will be written.
lambda
— (map
)Invoke a Lambda function.
functionArn
— required — (String
)The ARN of the Lambda function.
sns
— (map
)Publish to an Amazon SNS topic.
targetArn
— required — (String
)The ARN of the SNS topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
messageFormat
— (String
)(Optional) The message format of the message to publish. Accepted values are "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this setting to determine if the payload should be parsed and relevant platform-specific bits of the payload should be extracted. To read more about SNS message formats, see https://docs.aws.amazon.com/sns/latest/dg/json-formats.html refer to their official documentation.
Possible values include:"RAW"
"JSON"
sqs
— (map
)Publish to an Amazon SQS queue.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
queueUrl
— required — (String
)The URL of the Amazon SQS queue.
useBase64
— (Boolean
)Specifies whether to use Base64 encoding.
kinesis
— (map
)Write data to an Amazon Kinesis stream.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the Amazon Kinesis stream.
streamName
— required — (String
)The name of the Amazon Kinesis stream.
partitionKey
— (String
)The partition key.
republish
— (map
)Publish to another MQTT topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
topic
— required — (String
)The name of the MQTT topic.
qos
— (Integer
)The Quality of Service (QoS) level to use when republishing messages. The default value is 0.
headers
— (map
)MQTT Version 5.0 headers information. For more information, see MQTT from the Amazon Web Services IoT Core Developer Guide.
payloadFormatIndicator
— (String
)An
Enum
string value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTES
andUTF8_DATA
.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates.
contentType
— (String
)A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type from the MQTT Version 5.0 specification.
Supports substitution templates.
responseTopic
— (String
)A UTF-8 encoded string that's used as the topic name for a response message. The response topic is used to describe the topic which the receiver should publish to as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic from the MQTT Version 5.0 specification.
Supports substitution templates.
correlationData
— (String
)The base64-encoded binary data used by the sender of the request message to identify which request the response message is for when it's received.
For more information, see Correlation Data from the MQTT Version 5.0 specification.
Note: This binary data must be based64-encoded.Supports substitution templates.
messageExpiry
— (String
)A user-defined integer value that will persist a message at the message broker for a specified amount of time to ensure that the message will expire if it's no longer relevant to the subscriber. The value of
messageExpiry
represents the number of seconds before it expires. For more information about the limits ofmessageExpiry
, see Amazon Web Services IoT Core message broker and protocol limits and quotas from the Amazon Web Services Reference Guide.Supports substitution templates.
userProperties
— (Array<map>
)An array of key-value pairs that you define in the MQTT5 header.
key
— required — (String
)A key to be specified in
UserProperty
.value
— required — (String
)A value to be specified in
UserProperty
.
s3
— (map
)Write to an Amazon S3 bucket.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
bucketName
— required — (String
)The Amazon S3 bucket.
key
— required — (String
)The object key. For more information, see Actions, resources, and condition keys for Amazon S3.
cannedAcl
— (String
)The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs.
Possible values include:"private"
"public-read"
"public-read-write"
"aws-exec-read"
"authenticated-read"
"bucket-owner-read"
"bucket-owner-full-control"
"log-delivery-write"
firehose
— (map
)Write to an Amazon Kinesis Firehose stream.
roleArn
— required — (String
)The IAM role that grants access to the Amazon Kinesis Firehose stream.
deliveryStreamName
— required — (String
)The delivery stream name.
separator
— (String
)A character separator that will be used to separate records written to the Firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows newline), ',' (comma).
batchMode
— (Boolean
)Whether to deliver the Kinesis Data Firehose stream as a batch by using
PutRecordBatch
. The default value isfalse
.When
batchMode
istrue
and the rule's SQL statement evaluates to an Array, each Array element forms one record in thePutRecordBatch
request. The resulting array can't have more than 500 records.
cloudwatchMetric
— (map
)Capture a CloudWatch metric.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch metric.
metricNamespace
— required — (String
)The CloudWatch metric namespace name.
metricName
— required — (String
)The CloudWatch metric name.
metricValue
— required — (String
)The CloudWatch metric value.
metricUnit
— required — (String
)The metric unit supported by CloudWatch.
metricTimestamp
— (String
)An optional Unix timestamp.
cloudwatchAlarm
— (map
)Change the state of a CloudWatch alarm.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch alarm.
alarmName
— required — (String
)The CloudWatch alarm name.
stateReason
— required — (String
)The reason for the alarm change.
stateValue
— required — (String
)The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
cloudwatchLogs
— (map
)Send data to CloudWatch Logs.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch log.
logGroupName
— required — (String
)The CloudWatch log group to which the action sends data.
batchMode
— (Boolean
)Indicates whether batches of log records will be extracted and uploaded into CloudWatch. Values include
true
orfalse
(default).
elasticsearch
— (map
)Write data to an Amazon OpenSearch Service domain.
Note: TheElasticsearch
action can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearch
rule action instead. For more information, see OpenSearchAction.roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
salesforce
— (map
)Send a message to a Salesforce IoT Cloud Input Stream.
token
— required — (String
)The token used to authenticate access to the Salesforce IoT Cloud Input Stream. The token is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
url
— required — (String
)The URL exposed by the Salesforce IoT Cloud Input Stream. The URL is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
iotAnalytics
— (map
)Sends message data to an IoT Analytics channel.
channelArn
— (String
)(deprecated) The ARN of the IoT Analytics channel to which message data will be sent.
channelName
— (String
)The name of the IoT Analytics channel to which message data will be sent.
batchMode
— (Boolean
)Whether to process the action as a batch. The default value is
false
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed byBatchPutMessage
to the IoT Analytics channel. The resulting array can't have more than 100 messages.roleArn
— (String
)The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
iotEvents
— (map
)Sends an input to an IoT Events detector.
inputName
— required — (String
)The name of the IoT Events input.
messageId
— (String
)The ID of the message. The default
messageId
is a new UUID value.When
batchMode
istrue
, you can't specify amessageId
--a new UUID value will be assigned.Assign a value to this property to ensure that only one input (message) with a given
messageId
will be processed by an IoT Events detector.batchMode
— (Boolean
)Whether to process the event actions as a batch. The default value is
false
.When
batchMode
istrue
, you can't specify amessageId
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when it's sent to IoT Events by callingBatchPutMessage
. The resulting array can't have more than 10 messages.roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an input to an IoT Events detector. ("Action":"iotevents:BatchPutMessage").
iotSiteWise
— (map
)Sends data from the MQTT message that triggered the rule to IoT SiteWise asset properties.
putAssetPropertyValueEntries
— required — (Array<map>
)A list of asset property value entries.
entryId
— (String
)Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
assetId
— (String
)The ID of the IoT SiteWise asset. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyId
— (String
)The ID of the asset's property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyAlias
— (String
)The name of the property alias associated with your asset property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyValues
— required — (Array<map>
)A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
value
— required — (map
)The value of the asset property.
stringValue
— (String
)Optional. The string value of the value entry. Accepts substitution templates.
integerValue
— (String
)Optional. A string that contains the integer value of the value entry. Accepts substitution templates.
doubleValue
— (String
)Optional. A string that contains the double value of the value entry. Accepts substitution templates.
booleanValue
— (String
)Optional. A string that contains the boolean value (
true
orfalse
) of the value entry. Accepts substitution templates.
timestamp
— required — (map
)The asset property value timestamp.
timeInSeconds
— required — (String
)A string that contains the time in seconds since epoch. Accepts substitution templates.
offsetInNanos
— (String
)Optional. A string that contains the nanosecond time offset. Accepts substitution templates.
quality
— (String
)Optional. A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD
,BAD
, orUNCERTAIN
.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an asset property value to IoT SiteWise. (
"Action": "iotsitewise:BatchPutAssetPropertyValue"
). The trust policy can restrict access to specific asset hierarchy paths.
stepFunctions
— (map
)Starts execution of a Step Functions state machine.
executionNamePrefix
— (String
)(Optional) A name will be given to the state machine execution consisting of this prefix followed by a UUID. Step Functions automatically creates a unique name for each state machine execution if one is not provided.
stateMachineName
— required — (String
)The name of the Step Functions state machine whose execution will be started.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to start execution of a state machine ("Action":"states:StartExecution").
timestream
— (map
)The Timestream rule action writes attributes (measures) from an MQTT message into an Amazon Timestream table. For more information, see the Timestream topic rule action documentation.
roleArn
— required — (String
)The ARN of the role that grants permission to write to the Amazon Timestream database table.
databaseName
— required — (String
)The name of an Amazon Timestream database.
tableName
— required — (String
)The name of the database table into which to write the measure records.
dimensions
— required — (Array<map>
)Metadata attributes of the time series that are written in each measure record.
name
— required — (String
)The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.
Dimensions cannot be named:
measure_name
,measure_value
, ortime
. These names are reserved. Dimension names cannot start withts_
ormeasure_value
and they cannot contain the colon (:
) character.value
— required — (String
)The value to write in this column of the database record.
timestamp
— (map
)Specifies an application-defined value to replace the default value assigned to the Timestream record's timestamp in the
time
column.You can use this property to specify the value and the precision of the Timestream record's timestamp. You can specify a value from the message payload or a value computed by a substitution template.
If omitted, the topic rule action assigns the timestamp, in milliseconds, at the time it processed the rule.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— required — (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
http
— (map
)Send data to an HTTPS endpoint.
url
— required — (String
)The endpoint URL. If substitution templates are used in the URL, you must also specify a
confirmationUrl
. If this is a new destination, a newTopicRuleDestination
is created if possible.confirmationUrl
— (String
)The URL to which IoT sends a confirmation message. The value of the confirmation URL must be a prefix of the endpoint URL. If you do not specify a confirmation URL IoT uses the endpoint URL as the confirmation URL. If you use substitution templates in the confirmationUrl, you must create and enable topic rule destinations that match each possible value of the substitution template before traffic is allowed to your endpoint URL.
headers
— (Array<map>
)The HTTP headers to send with the message data.
key
— required — (String
)The HTTP header key.
value
— required — (String
)The HTTP header value. Substitution templates are supported.
auth
— (map
)The authentication method to use when sending data to an HTTPS endpoint.
sigv4
— (map
)Use Sig V4 authorization. For more information, see Signature Version 4 Signing Process.
signingRegion
— required — (String
)The signing region.
serviceName
— required — (String
)The service name to use while signing with Sig V4.
roleArn
— required — (String
)The ARN of the signing role.
kafka
— (map
)Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
destinationArn
— required — (String
)The ARN of Kafka action's VPC
TopicRuleDestination
.topic
— required — (String
)The Kafka topic for messages to be sent to the Kafka broker.
key
— (String
)The Kafka message key.
partition
— (String
)The Kafka message partition.
clientProperties
— required — (map<String>
)Properties of the Apache Kafka producer client.
headers
— (Array<map>
)The list of Kafka headers that you specify.
key
— required — (String
)The key of the Kafka header.
value
— required — (String
)The value of the Kafka header.
openSearch
— (map
)Write data to an Amazon OpenSearch Service domain.
roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The OpenSearch index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
location
— (map
)The Amazon Location Service rule action sends device location updates from an MQTT message to an Amazon Location tracker resource.
roleArn
— required — (String
)The IAM role that grants permission to write to the Amazon Location resource.
trackerName
— required — (String
)The name of the tracker resource in Amazon Location in which the location is updated.
deviceId
— required — (String
)The unique ID of the device providing the location data.
timestamp
— (map
)The time that the location data was sampled. The default value is the time the MQTT message was processed.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
latitude
— required — (String
)A string that evaluates to a double value that represents the latitude of the device's location.
longitude
— required — (String
)A string that evaluates to a double value that represents the longitude of the device's location.
tags
— (String
)Metadata which can be used to manage the topic rule.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: --tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
createTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Creates a topic rule destination. The destination must be confirmed prior to use.
Requires permission to access the CreateTopicRuleDestination action.
Service Reference:
Examples:
Calling the createTopicRuleDestination operation
var params = { destinationConfiguration: { /* required */ httpUrlConfiguration: { confirmationUrl: 'STRING_VALUE' /* required */ }, vpcConfiguration: { roleArn: 'STRING_VALUE', /* required */ subnetIds: [ /* required */ 'STRING_VALUE', /* more items */ ], vpcId: 'STRING_VALUE', /* required */ securityGroups: [ 'STRING_VALUE', /* more items */ ] } } }; iot.createTopicRuleDestination(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
destinationConfiguration
— (map
)The topic rule destination configuration.
httpUrlConfiguration
— (map
)Configuration of the HTTP URL.
confirmationUrl
— required — (String
)The URL IoT uses to confirm ownership of or access to the topic rule destination URL.
vpcConfiguration
— (map
)Configuration of the virtual private cloud (VPC) connection.
subnetIds
— required — (Array<String>
)The subnet IDs of the VPC destination.
securityGroups
— (Array<String>
)The security groups of the VPC destination.
vpcId
— required — (String
)The ID of the VPC.
roleArn
— required — (String
)The ARN of a role that has permission to create and attach to elastic network interfaces (ENIs).
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:topicRuleDestination
— (map
)The topic rule destination.
arn
— (String
)The topic rule destination URL.
status
— (String
)The status of the topic rule destination. Valid values are:
- IN_PROGRESS
-
A topic rule destination was created but has not been confirmed. You can set
status
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint. - ENABLED
-
Confirmation was completed, and traffic to this destination is allowed. You can set
status
toDISABLED
by callingUpdateTopicRuleDestination
. - DISABLED
-
Confirmation was completed, and traffic to this destination is not allowed. You can set
status
toENABLED
by callingUpdateTopicRuleDestination
. - ERROR
-
Confirmation could not be completed, for example if the confirmation timed out. You can call
GetTopicRuleDestination
for details about the error. You can setstatus
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint.
"ENABLED"
"IN_PROGRESS"
"DISABLED"
"ERROR"
"DELETING"
createdAt
— (Date
)The date and time when the topic rule destination was created.
lastUpdatedAt
— (Date
)The date and time when the topic rule destination was last updated.
statusReason
— (String
)Additional details or reason why the topic rule destination is in the current status.
httpUrlProperties
— (map
)Properties of the HTTP URL.
confirmationUrl
— (String
)The URL used to confirm the HTTP topic rule destination URL.
vpcProperties
— (map
)Properties of the virtual private cloud (VPC) connection.
subnetIds
— (Array<String>
)The subnet IDs of the VPC destination.
securityGroups
— (Array<String>
)The security groups of the VPC destination.
vpcId
— (String
)The ID of the VPC.
roleArn
— (String
)The ARN of a role that has permission to create and attach to elastic network interfaces (ENIs).
-
(AWS.Response)
—
Returns:
deleteAccountAuditConfiguration(params = {}, callback) ⇒ AWS.Request
Restores the default settings for Device Defender audits for this account. Any configuration data you entered is deleted and all audit checks are reset to disabled.
Requires permission to access the DeleteAccountAuditConfiguration action.
Service Reference:
Examples:
Calling the deleteAccountAuditConfiguration operation
var params = { deleteScheduledAudits: true || false }; iot.deleteAccountAuditConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
deleteScheduledAudits
— (Boolean
)If true, all scheduled audits are deleted.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteAuditSuppression(params = {}, callback) ⇒ AWS.Request
Deletes a Device Defender audit suppression.
Requires permission to access the DeleteAuditSuppression action.
Service Reference:
Examples:
Calling the deleteAuditSuppression operation
var params = { checkName: 'STRING_VALUE', /* required */ resourceIdentifier: { /* required */ account: 'STRING_VALUE', caCertificateId: 'STRING_VALUE', clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', deviceCertificateArn: 'STRING_VALUE', deviceCertificateId: 'STRING_VALUE', iamRoleArn: 'STRING_VALUE', issuerCertificateIdentifier: { issuerCertificateSerialNumber: 'STRING_VALUE', issuerCertificateSubject: 'STRING_VALUE', issuerId: 'STRING_VALUE' }, policyVersionIdentifier: { policyName: 'STRING_VALUE', policyVersionId: 'STRING_VALUE' }, roleAliasArn: 'STRING_VALUE' } }; iot.deleteAuditSuppression(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
checkName
— (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteAuthorizer(params = {}, callback) ⇒ AWS.Request
Deletes an authorizer.
Requires permission to access the DeleteAuthorizer action.
Service Reference:
Examples:
Calling the deleteAuthorizer operation
var params = { authorizerName: 'STRING_VALUE' /* required */ }; iot.deleteAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
authorizerName
— (String
)The name of the authorizer to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteBillingGroup(params = {}, callback) ⇒ AWS.Request
Deletes the billing group.
Requires permission to access the DeleteBillingGroup action.
Service Reference:
Examples:
Calling the deleteBillingGroup operation
var params = { billingGroupName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE' }; iot.deleteBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name of the billing group.
expectedVersion
— (Integer
)The expected version of the billing group. If the version of the billing group does not match the expected version specified in the request, the
DeleteBillingGroup
request is rejected with aVersionConflictException
.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteCACertificate(params = {}, callback) ⇒ AWS.Request
Deletes a registered CA certificate.
Requires permission to access the DeleteCACertificate action.
Service Reference:
Examples:
Calling the deleteCACertificate operation
var params = { certificateId: 'STRING_VALUE' /* required */ }; iot.deleteCACertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate to delete. (The last part of the certificate ARN contains the certificate ID.)
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteCertificate(params = {}, callback) ⇒ AWS.Request
Deletes the specified certificate.
A certificate cannot be deleted if it has a policy or IoT thing attached to it or if its status is set to ACTIVE. To delete a certificate, first use the DetachPolicy action to detach all policies. Next, use the UpdateCertificate action to set the certificate to the INACTIVE status.
Requires permission to access the DeleteCertificate action.
Service Reference:
Examples:
Calling the deleteCertificate operation
var params = { certificateId: 'STRING_VALUE', /* required */ forceDelete: true || false }; iot.deleteCertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
forceDelete
— (Boolean
)Forces the deletion of a certificate if it is inactive and is not attached to an IoT thing.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteCertificateProvider(params = {}, callback) ⇒ AWS.Request
Deletes a certificate provider.
Requires permission to access the DeleteCertificateProvider action.
If you delete the certificate provider resource, the behavior of
CreateCertificateFromCsr
will resume, and IoT will create certificates signed by IoT from a certificate signing request (CSR).Service Reference:
Examples:
Calling the deleteCertificateProvider operation
var params = { certificateProviderName: 'STRING_VALUE' /* required */ }; iot.deleteCertificateProvider(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateProviderName
— (String
)The name of the certificate provider.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteCustomMetric(params = {}, callback) ⇒ AWS.Request
Deletes a Device Defender detect custom metric.
Requires permission to access the DeleteCustomMetric action.
Note: Before you can delete a custom metric, you must first remove the custom metric from all security profiles it's a part of. The security profile associated with the custom metric can be found using the ListSecurityProfiles API withmetricName
set to your custom metric name.Service Reference:
Examples:
Calling the deleteCustomMetric operation
var params = { metricName: 'STRING_VALUE' /* required */ }; iot.deleteCustomMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the custom metric.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteDimension(params = {}, callback) ⇒ AWS.Request
Removes the specified dimension from your Amazon Web Services accounts.
Requires permission to access the DeleteDimension action.
Service Reference:
Examples:
Calling the deleteDimension operation
var params = { name: 'STRING_VALUE' /* required */ }; iot.deleteDimension(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
name
— (String
)The unique identifier for the dimension that you want to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Deletes the specified domain configuration.
Requires permission to access the DeleteDomainConfiguration action.
Service Reference:
Examples:
Calling the deleteDomainConfiguration operation
var params = { domainConfigurationName: 'STRING_VALUE' /* required */ }; iot.deleteDomainConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
domainConfigurationName
— (String
)The name of the domain configuration to be deleted.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteDynamicThingGroup(params = {}, callback) ⇒ AWS.Request
Deletes a dynamic thing group.
Requires permission to access the DeleteDynamicThingGroup action.
Service Reference:
Examples:
Calling the deleteDynamicThingGroup operation
var params = { thingGroupName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE' }; iot.deleteDynamicThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The name of the dynamic thing group to delete.
expectedVersion
— (Integer
)The expected version of the dynamic thing group to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteFleetMetric(params = {}, callback) ⇒ AWS.Request
Deletes the specified fleet metric. Returns successfully with no error if the deletion is successful or you specify a fleet metric that doesn't exist.
Requires permission to access the DeleteFleetMetric action.
Service Reference:
Examples:
Calling the deleteFleetMetric operation
var params = { metricName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE' }; iot.deleteFleetMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the fleet metric to delete.
expectedVersion
— (Integer
)The expected version of the fleet metric to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteJob(params = {}, callback) ⇒ AWS.Request
Deletes a job and its related job executions.
Deleting a job may take time, depending on the number of job executions created for the job and various other factors. While the job is being deleted, the status of the job will be shown as "DELETION_IN_PROGRESS". Attempting to delete or cancel a job whose status is already "DELETION_IN_PROGRESS" will result in an error.
Only 10 jobs may have status "DELETION_IN_PROGRESS" at the same time, or a LimitExceededException will occur.
Requires permission to access the DeleteJob action.
Service Reference:
Examples:
Calling the deleteJob operation
var params = { jobId: 'STRING_VALUE', /* required */ force: true || false, namespaceId: 'STRING_VALUE' }; iot.deleteJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The ID of the job to be deleted.
After a job deletion is completed, you may reuse this jobId when you create a new job. However, this is not recommended, and you must ensure that your devices are not using the jobId to refer to the deleted job.
force
— (Boolean
)(Optional) When true, you can delete a job which is "IN_PROGRESS". Otherwise, you can only delete a job which is in a terminal state ("COMPLETED" or "CANCELED") or an exception will occur. The default is false.
Note: Deleting a job which is "IN_PROGRESS", will cause a device which is executing the job to be unable to access job information or update the job execution status. Use caution and ensure that each device executing a job which is deleted is able to recover to a valid state.namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteJobExecution(params = {}, callback) ⇒ AWS.Request
Deletes a job execution.
Requires permission to access the DeleteJobExecution action.
Service Reference:
Examples:
Calling the deleteJobExecution operation
var params = { executionNumber: 'NUMBER_VALUE', /* required */ jobId: 'STRING_VALUE', /* required */ thingName: 'STRING_VALUE', /* required */ force: true || false, namespaceId: 'STRING_VALUE' }; iot.deleteJobExecution(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The ID of the job whose execution on a particular device will be deleted.
thingName
— (String
)The name of the thing whose job execution will be deleted.
executionNumber
— (Integer
)The ID of the job execution to be deleted. The
executionNumber
refers to the execution of a particular job on a particular device.Note that once a job execution is deleted, the
executionNumber
may be reused by IoT, so be sure you get and use the correct value here.force
— (Boolean
)(Optional) When true, you can delete a job execution which is "IN_PROGRESS". Otherwise, you can only delete a job execution which is in a terminal state ("SUCCEEDED", "FAILED", "REJECTED", "REMOVED" or "CANCELED") or an exception will occur. The default is false.
Note: Deleting a job execution which is "IN_PROGRESS", will cause the device to be unable to access job information or update the job execution status. Use caution and ensure that the device is able to recover to a valid state.namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteJobTemplate(params = {}, callback) ⇒ AWS.Request
Deletes the specified job template.
Service Reference:
Examples:
Calling the deleteJobTemplate operation
var params = { jobTemplateId: 'STRING_VALUE' /* required */ }; iot.deleteJobTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobTemplateId
— (String
)The unique identifier of the job template to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteMitigationAction(params = {}, callback) ⇒ AWS.Request
Deletes a defined mitigation action from your Amazon Web Services accounts.
Requires permission to access the DeleteMitigationAction action.
Service Reference:
Examples:
Calling the deleteMitigationAction operation
var params = { actionName: 'STRING_VALUE' /* required */ }; iot.deleteMitigationAction(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
actionName
— (String
)The name of the mitigation action that you want to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteOTAUpdate(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the deleteOTAUpdate operation
var params = { otaUpdateId: 'STRING_VALUE', /* required */ deleteStream: true || false, forceDeleteAWSJob: true || false }; iot.deleteOTAUpdate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
otaUpdateId
— (String
)The ID of the OTA update to delete.
deleteStream
— (Boolean
)When true, the stream created by the OTAUpdate process is deleted when the OTA update is deleted. Ignored if the stream specified in the OTAUpdate is supplied by the user.
forceDeleteAWSJob
— (Boolean
)When true, deletes the IoT job created by the OTAUpdate process even if it is "IN_PROGRESS". Otherwise, if the job is not in a terminal state ("COMPLETED" or "CANCELED") an exception will occur. The default is false.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deletePackage(params = {}, callback) ⇒ AWS.Request
Deletes a specific version from a software package.
Note: All package versions must be deleted before deleting the software package.
Requires permission to access the DeletePackageVersion action.
Service Reference:
Examples:
Calling the deletePackage operation
var params = { packageName: 'STRING_VALUE', /* required */ clientToken: 'STRING_VALUE' }; iot.deletePackage(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the target software package.
clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deletePackageVersion(params = {}, callback) ⇒ AWS.Request
Deletes a specific version from a software package.
Note: If a package version is designated as default, you must remove the designation from the software package using the UpdatePackage action.
Service Reference:
Examples:
Calling the deletePackageVersion operation
var params = { packageName: 'STRING_VALUE', /* required */ versionName: 'STRING_VALUE', /* required */ clientToken: 'STRING_VALUE' }; iot.deletePackageVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the associated software package.
versionName
— (String
)The name of the target package version.
clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deletePolicy(params = {}, callback) ⇒ AWS.Request
Deletes the specified policy.
A policy cannot be deleted if it has non-default versions or it is attached to any certificate.
To delete a policy, use the DeletePolicyVersion action to delete all non-default versions of the policy; use the DetachPolicy action to detach the policy from any certificate; and then use the DeletePolicy action to delete the policy.
When a policy is deleted using DeletePolicy, its default version is deleted with it.
Note: Because of the distributed nature of Amazon Web Services, it can take up to five minutes after a policy is detached before it's ready to be deleted.Requires permission to access the DeletePolicy action.
Service Reference:
Examples:
Calling the deletePolicy operation
var params = { policyName: 'STRING_VALUE' /* required */ }; iot.deletePolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The name of the policy to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deletePolicyVersion(params = {}, callback) ⇒ AWS.Request
Deletes the specified version of the specified policy. You cannot delete the default version of a policy using this action. To delete the default version of a policy, use DeletePolicy. To find out which version of a policy is marked as the default version, use ListPolicyVersions.
Requires permission to access the DeletePolicyVersion action.
Service Reference:
Examples:
Calling the deletePolicyVersion operation
var params = { policyName: 'STRING_VALUE', /* required */ policyVersionId: 'STRING_VALUE' /* required */ }; iot.deletePolicyVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The policy version ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Deletes a provisioning template.
Requires permission to access the DeleteProvisioningTemplate action.
Service Reference:
Examples:
Calling the deleteProvisioningTemplate operation
var params = { templateName: 'STRING_VALUE' /* required */ }; iot.deleteProvisioningTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the fleet provision template to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteProvisioningTemplateVersion(params = {}, callback) ⇒ AWS.Request
Deletes a provisioning template version.
Requires permission to access the DeleteProvisioningTemplateVersion action.
Service Reference:
Examples:
Calling the deleteProvisioningTemplateVersion operation
var params = { templateName: 'STRING_VALUE', /* required */ versionId: 'NUMBER_VALUE' /* required */ }; iot.deleteProvisioningTemplateVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template version to delete.
versionId
— (Integer
)The provisioning template version ID to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteRegistrationCode(params = {}, callback) ⇒ AWS.Request
Deletes a CA certificate registration code.
Requires permission to access the DeleteRegistrationCode action.
Service Reference:
Examples:
Calling the deleteRegistrationCode operation
var params = { }; iot.deleteRegistrationCode(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteRoleAlias(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the deleteRoleAlias operation
var params = { roleAlias: 'STRING_VALUE' /* required */ }; iot.deleteRoleAlias(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
roleAlias
— (String
)The role alias to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteScheduledAudit(params = {}, callback) ⇒ AWS.Request
Deletes a scheduled audit.
Requires permission to access the DeleteScheduledAudit action.
Service Reference:
Examples:
Calling the deleteScheduledAudit operation
var params = { scheduledAuditName: 'STRING_VALUE' /* required */ }; iot.deleteScheduledAudit(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
scheduledAuditName
— (String
)The name of the scheduled audit you want to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteSecurityProfile(params = {}, callback) ⇒ AWS.Request
Deletes a Device Defender security profile.
Requires permission to access the DeleteSecurityProfile action.
Service Reference:
Examples:
Calling the deleteSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE' }; iot.deleteSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The name of the security profile to be deleted.
expectedVersion
— (Integer
)The expected version of the security profile. A new version is generated whenever the security profile is updated. If you specify a value that is different from the actual version, a
VersionConflictException
is thrown.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteStream(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the deleteStream operation
var params = { streamId: 'STRING_VALUE' /* required */ }; iot.deleteStream(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
streamId
— (String
)The stream ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteThing(params = {}, callback) ⇒ AWS.Request
Deletes the specified thing. Returns successfully with no error if the deletion is successful or you specify a thing that doesn't exist.
Requires permission to access the DeleteThing action.
Service Reference:
Examples:
Calling the deleteThing operation
var params = { thingName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE' }; iot.deleteThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing to delete.
expectedVersion
— (Integer
)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
DeleteThing
request is rejected with aVersionConflictException
.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteThingGroup(params = {}, callback) ⇒ AWS.Request
Deletes a thing group.
Requires permission to access the DeleteThingGroup action.
Service Reference:
Examples:
Calling the deleteThingGroup operation
var params = { thingGroupName: 'STRING_VALUE', /* required */ expectedVersion: 'NUMBER_VALUE' }; iot.deleteThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The name of the thing group to delete.
expectedVersion
— (Integer
)The expected version of the thing group to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteThingType(params = {}, callback) ⇒ AWS.Request
Deletes the specified thing type. You cannot delete a thing type if it has things associated with it. To delete a thing type, first mark it as deprecated by calling DeprecateThingType, then remove any associated things by calling UpdateThing to change the thing type on any associated thing, and finally use DeleteThingType to delete the thing type.
Requires permission to access the DeleteThingType action.
Service Reference:
Examples:
Calling the deleteThingType operation
var params = { thingTypeName: 'STRING_VALUE' /* required */ }; iot.deleteThingType(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingTypeName
— (String
)The name of the thing type.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteTopicRule(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the deleteTopicRule operation
var params = { ruleName: 'STRING_VALUE' /* required */ }; iot.deleteTopicRule(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
ruleName
— (String
)The name of the rule.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Deletes a topic rule destination.
Requires permission to access the DeleteTopicRuleDestination action.
Service Reference:
Examples:
Calling the deleteTopicRuleDestination operation
var params = { arn: 'STRING_VALUE' /* required */ }; iot.deleteTopicRuleDestination(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
arn
— (String
)The ARN of the topic rule destination to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deleteV2LoggingLevel(params = {}, callback) ⇒ AWS.Request
Deletes a logging level.
Requires permission to access the DeleteV2LoggingLevel action.
Service Reference:
Examples:
Calling the deleteV2LoggingLevel operation
var params = { targetName: 'STRING_VALUE', /* required */ targetType: DEFAULT | THING_GROUP | CLIENT_ID | SOURCE_IP | PRINCIPAL_ID /* required */ }; iot.deleteV2LoggingLevel(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
targetType
— (String
)The type of resource for which you are configuring logging. Must be
Possible values include:THING_Group
."DEFAULT"
"THING_GROUP"
"CLIENT_ID"
"SOURCE_IP"
"PRINCIPAL_ID"
targetName
— (String
)The name of the resource for which you are configuring logging.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
deprecateThingType(params = {}, callback) ⇒ AWS.Request
Deprecates a thing type. You can not associate new things with deprecated thing type.
Requires permission to access the DeprecateThingType action.
Service Reference:
Examples:
Calling the deprecateThingType operation
var params = { thingTypeName: 'STRING_VALUE', /* required */ undoDeprecate: true || false }; iot.deprecateThingType(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingTypeName
— (String
)The name of the thing type to deprecate.
undoDeprecate
— (Boolean
)Whether to undeprecate a deprecated thing type. If true, the thing type will not be deprecated anymore and you can associate it with things.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
describeAccountAuditConfiguration(params = {}, callback) ⇒ AWS.Request
Gets information about the Device Defender audit settings for this account. Settings include how audit notifications are sent and which audit checks are enabled or disabled.
Requires permission to access the DescribeAccountAuditConfiguration action.
Service Reference:
Examples:
Calling the describeAccountAuditConfiguration operation
var params = { }; iot.describeAccountAuditConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleArn
— (String
)The ARN of the role that grants permission to IoT to access information about your devices, policies, certificates, and other items as required when performing an audit.
On the first call to
UpdateAccountAuditConfiguration
, this parameter is required.auditNotificationTargetConfigurations
— (map<map>
)Information about the targets to which audit notifications are sent for this account.
targetArn
— (String
)The ARN of the target (SNS topic) to which audit notifications are sent.
roleArn
— (String
)The ARN of the role that grants permission to send notifications to the target.
enabled
— (Boolean
)True if notifications to the target are enabled.
auditCheckConfigurations
— (map<map>
)Which audit checks are enabled and disabled for this account.
enabled
— (Boolean
)True if this audit check is enabled for this account.
-
(AWS.Response)
—
Returns:
describeAuditFinding(params = {}, callback) ⇒ AWS.Request
Gets information about a single audit finding. Properties include the reason for noncompliance, the severity of the issue, and the start time when the audit that returned the finding.
Requires permission to access the DescribeAuditFinding action.
Service Reference:
Examples:
Calling the describeAuditFinding operation
var params = { findingId: 'STRING_VALUE' /* required */ }; iot.describeAuditFinding(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
findingId
— (String
)A unique identifier for a single audit finding. You can use this identifier to apply mitigation actions to the finding.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:finding
— (map
)The findings (results) of the audit.
findingId
— (String
)A unique identifier for this set of audit findings. This identifier is used to apply mitigation tasks to one or more sets of findings.
taskId
— (String
)The ID of the audit that generated this result (finding).
checkName
— (String
)The audit check that generated this result.
taskStartTime
— (Date
)The time the audit started.
findingTime
— (Date
)The time the result (finding) was discovered.
severity
— (String
)The severity of the result (finding).
Possible values include:"CRITICAL"
"HIGH"
"MEDIUM"
"LOW"
nonCompliantResource
— (map
)The resource that was found to be noncompliant with the audit check.
resourceType
— (String
)The type of the noncompliant resource.
Possible values include:"DEVICE_CERTIFICATE"
"CA_CERTIFICATE"
"IOT_POLICY"
"COGNITO_IDENTITY_POOL"
"CLIENT_ID"
"ACCOUNT_SETTINGS"
"ROLE_ALIAS"
"IAM_ROLE"
"ISSUER_CERTIFICATE"
resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
additionalInfo
— (map<String>
)Other information about the noncompliant resource.
relatedResources
— (Array<map>
)The list of related resources.
resourceType
— (String
)The type of resource.
Possible values include:"DEVICE_CERTIFICATE"
"CA_CERTIFICATE"
"IOT_POLICY"
"COGNITO_IDENTITY_POOL"
"CLIENT_ID"
"ACCOUNT_SETTINGS"
"ROLE_ALIAS"
"IAM_ROLE"
"ISSUER_CERTIFICATE"
resourceIdentifier
— (map
)Information that identifies the resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
additionalInfo
— (map<String>
)Other information about the resource.
reasonForNonCompliance
— (String
)The reason the resource was noncompliant.
reasonForNonComplianceCode
— (String
)A code that indicates the reason that the resource was noncompliant.
isSuppressed
— (Boolean
)Indicates whether the audit finding was suppressed or not during reporting.
-
(AWS.Response)
—
Returns:
describeAuditMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Gets information about an audit mitigation task that is used to apply mitigation actions to a set of audit findings. Properties include the actions being applied, the audit checks to which they're being applied, the task status, and aggregated task statistics.
Service Reference:
Examples:
Calling the describeAuditMitigationActionsTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.describeAuditMitigationActionsTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The unique identifier for the audit mitigation task.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskStatus
— (String
)The current status of the task.
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
startTime
— (Date
)The date and time when the task was started.
endTime
— (Date
)The date and time when the task was completed or canceled.
taskStatistics
— (map<map>
)Aggregate counts of the results when the mitigation tasks were applied to the findings for this audit mitigation actions task.
totalFindingsCount
— (Integer
)The total number of findings to which a task is being applied.
failedFindingsCount
— (Integer
)The number of findings for which at least one of the actions failed when applied.
succeededFindingsCount
— (Integer
)The number of findings for which all mitigation actions succeeded when applied.
skippedFindingsCount
— (Integer
)The number of findings skipped because of filter conditions provided in the parameters to the command.
canceledFindingsCount
— (Integer
)The number of findings to which the mitigation action task was canceled when applied.
target
— (map
)Identifies the findings to which the mitigation actions are applied. This can be by audit checks, by audit task, or a set of findings.
auditTaskId
— (String
)If the task will apply a mitigation action to findings from a specific audit, this value uniquely identifies the audit.
findingIds
— (Array<String>
)If the task will apply a mitigation action to one or more listed findings, this value uniquely identifies those findings.
auditCheckToReasonCodeFilter
— (map<Array<String>>
)Specifies a filter in the form of an audit check and set of reason codes that identify the findings from the audit to which the audit mitigation actions task apply.
auditCheckToActionsMapping
— (map<Array<String>>
)Specifies the mitigation actions that should be applied to specific audit checks.
actionsDefinition
— (Array<map>
)Specifies the mitigation actions and their parameters that are applied as part of this task.
name
— (String
)A user-friendly name for the mitigation action.
id
— (String
)A unique identifier for the mitigation action.
roleArn
— (String
)The IAM role ARN used to apply this mitigation action.
actionParams
— (map
)The set of parameters for this mitigation action. The parameters vary, depending on the kind of action you apply.
updateDeviceCertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the device certificate to inactive.
action
— required — (String
)The action that you want to apply to the device certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
updateCACertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the CA certificate to inactive.
action
— required — (String
)The action that you want to apply to the CA certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
addThingsToThingGroupParams
— (map
)Parameters to define a mitigation action that moves devices associated with a certificate to one or more specified thing groups, typically for quarantine.
thingGroupNames
— required — (Array<String>
)The list of groups to which you want to add the things that triggered the mitigation action. You can add a thing to a maximum of 10 groups, but you can't add a thing to more than one group in the same hierarchy.
overrideDynamicGroups
— (Boolean
)Specifies if this mitigation action can move the things that triggered the mitigation action even if they are part of one or more dynamic thing groups.
replaceDefaultPolicyVersionParams
— (map
)Parameters to define a mitigation action that adds a blank policy to restrict permissions.
templateName
— required — (String
)The name of the template to be applied. The only supported value is
Possible values include:BLANK_POLICY
."BLANK_POLICY"
enableIoTLoggingParams
— (map
)Parameters to define a mitigation action that enables Amazon Web Services IoT Core logging at a specified level of detail.
roleArnForLogging
— required — (String
)The Amazon Resource Name (ARN) of the IAM role used for logging.
logLevel
— required — (String
)Specifies the type of information to be logged.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
publishFindingToSnsParams
— (map
)Parameters to define a mitigation action that publishes findings to Amazon Simple Notification Service (Amazon SNS. You can implement your own custom actions in response to the Amazon SNS messages.
topicArn
— required — (String
)The ARN of the topic to which you want to publish the findings.
-
(AWS.Response)
—
Returns:
describeAuditSuppression(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender audit suppression.
Service Reference:
Examples:
Calling the describeAuditSuppression operation
var params = { checkName: 'STRING_VALUE', /* required */ resourceIdentifier: { /* required */ account: 'STRING_VALUE', caCertificateId: 'STRING_VALUE', clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', deviceCertificateArn: 'STRING_VALUE', deviceCertificateId: 'STRING_VALUE', iamRoleArn: 'STRING_VALUE', issuerCertificateIdentifier: { issuerCertificateSerialNumber: 'STRING_VALUE', issuerCertificateSubject: 'STRING_VALUE', issuerId: 'STRING_VALUE' }, policyVersionIdentifier: { policyName: 'STRING_VALUE', policyVersionId: 'STRING_VALUE' }, roleAliasArn: 'STRING_VALUE' } }; iot.describeAuditSuppression(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
checkName
— (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:checkName
— (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
expirationDate
— (Date
)The epoch timestamp in seconds at which this suppression expires.
suppressIndefinitely
— (Boolean
)Indicates whether a suppression should exist indefinitely or not.
description
— (String
)The description of the audit suppression.
-
(AWS.Response)
—
Returns:
describeAuditTask(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender audit.
Requires permission to access the DescribeAuditTask action.
Service Reference:
Examples:
Calling the describeAuditTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.describeAuditTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The ID of the audit whose information you want to get.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskStatus
— (String
)The status of the audit: one of "IN_PROGRESS", "COMPLETED", "FAILED", or "CANCELED".
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
taskType
— (String
)The type of audit: "ON_DEMAND_AUDIT_TASK" or "SCHEDULED_AUDIT_TASK".
Possible values include:"ON_DEMAND_AUDIT_TASK"
"SCHEDULED_AUDIT_TASK"
taskStartTime
— (Date
)The time the audit started.
taskStatistics
— (map
)Statistical information about the audit.
totalChecks
— (Integer
)The number of checks in this audit.
inProgressChecks
— (Integer
)The number of checks in progress.
waitingForDataCollectionChecks
— (Integer
)The number of checks waiting for data collection.
compliantChecks
— (Integer
)The number of checks that found compliant resources.
nonCompliantChecks
— (Integer
)The number of checks that found noncompliant resources.
failedChecks
— (Integer
)The number of checks.
canceledChecks
— (Integer
)The number of checks that did not run because the audit was canceled.
scheduledAuditName
— (String
)The name of the scheduled audit (only if the audit was a scheduled audit).
auditDetails
— (map<map>
)Detailed information about each check performed during this audit.
checkRunStatus
— (String
)The completion status of this check. One of "IN_PROGRESS", "WAITING_FOR_DATA_COLLECTION", "CANCELED", "COMPLETED_COMPLIANT", "COMPLETED_NON_COMPLIANT", or "FAILED".
Possible values include:"IN_PROGRESS"
"WAITING_FOR_DATA_COLLECTION"
"CANCELED"
"COMPLETED_COMPLIANT"
"COMPLETED_NON_COMPLIANT"
"FAILED"
checkCompliant
— (Boolean
)True if the check is complete and found all resources compliant.
totalResourcesCount
— (Integer
)The number of resources on which the check was performed.
nonCompliantResourcesCount
— (Integer
)The number of resources that were found noncompliant during the check.
suppressedNonCompliantResourcesCount
— (Integer
)Describes how many of the non-compliant resources created during the evaluation of an audit check were marked as suppressed.
errorCode
— (String
)The code of any error encountered when this check is performed during this audit. One of "INSUFFICIENT_PERMISSIONS" or "AUDIT_CHECK_DISABLED".
message
— (String
)The message associated with any error encountered when this check is performed during this audit.
-
(AWS.Response)
—
Returns:
describeAuthorizer(params = {}, callback) ⇒ AWS.Request
Describes an authorizer.
Requires permission to access the DescribeAuthorizer action.
Service Reference:
Examples:
Calling the describeAuthorizer operation
var params = { authorizerName: 'STRING_VALUE' /* required */ }; iot.describeAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
authorizerName
— (String
)The name of the authorizer to describe.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authorizerDescription
— (map
)The authorizer description.
authorizerName
— (String
)The authorizer name.
authorizerArn
— (String
)The authorizer ARN.
authorizerFunctionArn
— (String
)The authorizer's Lambda function ARN.
tokenKeyName
— (String
)The key used to extract the token from the HTTP headers.
tokenSigningPublicKeys
— (map<String>
)The public keys used to validate the token signature returned by your custom authentication service.
status
— (String
)The status of the authorizer.
Possible values include:"ACTIVE"
"INACTIVE"
creationDate
— (Date
)The UNIX timestamp of when the authorizer was created.
lastModifiedDate
— (Date
)The UNIX timestamp of when the authorizer was last updated.
signingDisabled
— (Boolean
)Specifies whether IoT validates the token signature in an authorization request.
enableCachingForHttp
— (Boolean
)When
true
, the result from the authorizer’s Lambda function is cached for the time specified inrefreshAfterInSeconds
. The cached result is used while the device reuses the same HTTP connection.
-
(AWS.Response)
—
Returns:
describeBillingGroup(params = {}, callback) ⇒ AWS.Request
Returns information about a billing group.
Requires permission to access the DescribeBillingGroup action.
Service Reference:
Examples:
Calling the describeBillingGroup operation
var params = { billingGroupName: 'STRING_VALUE' /* required */ }; iot.describeBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name of the billing group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:billingGroupName
— (String
)The name of the billing group.
billingGroupId
— (String
)The ID of the billing group.
billingGroupArn
— (String
)The ARN of the billing group.
version
— (Integer
)The version of the billing group.
billingGroupProperties
— (map
)The properties of the billing group.
billingGroupDescription
— (String
)The description of the billing group.
billingGroupMetadata
— (map
)Additional information about the billing group.
creationDate
— (Date
)The date the billing group was created.
-
(AWS.Response)
—
Returns:
describeCACertificate(params = {}, callback) ⇒ AWS.Request
Describes a registered CA certificate.
Requires permission to access the DescribeCACertificate action.
Service Reference:
Examples:
Calling the describeCACertificate operation
var params = { certificateId: 'STRING_VALUE' /* required */ }; iot.describeCACertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The CA certificate identifier.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateDescription
— (map
)The CA certificate description.
certificateArn
— (String
)The CA certificate ARN.
certificateId
— (String
)The CA certificate ID.
status
— (String
)The status of a CA certificate.
Possible values include:"ACTIVE"
"INACTIVE"
certificatePem
— (String
)The CA certificate data, in PEM format.
ownedBy
— (String
)The owner of the CA certificate.
creationDate
— (Date
)The date the CA certificate was created.
autoRegistrationStatus
— (String
)Whether the CA certificate configured for auto registration of device certificates. Valid values are "ENABLE" and "DISABLE"
Possible values include:"ENABLE"
"DISABLE"
lastModifiedDate
— (Date
)The date the CA certificate was last modified.
customerVersion
— (Integer
)The customer version of the CA certificate.
generationId
— (String
)The generation ID of the CA certificate.
validity
— (map
)When the CA certificate is valid.
notBefore
— (Date
)The certificate is not valid before this date.
notAfter
— (Date
)The certificate is not valid after this date.
certificateMode
— (String
)The mode of the CA.
All the device certificates that are registered using this CA will be registered in the same mode as the CA. For more information about certificate mode for device certificates, see certificate mode.
Possible values include:"DEFAULT"
"SNI_ONLY"
registrationConfig
— (map
)Information about the registration configuration.
templateBody
— (String
)The template body.
roleArn
— (String
)The ARN of the role.
templateName
— (String
)The name of the provisioning template.
-
(AWS.Response)
—
Returns:
describeCertificate(params = {}, callback) ⇒ AWS.Request
Gets information about the specified certificate.
Requires permission to access the DescribeCertificate action.
Service Reference:
Examples:
Calling the describeCertificate operation
var params = { certificateId: 'STRING_VALUE' /* required */ }; iot.describeCertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateDescription
— (map
)The description of the certificate.
certificateArn
— (String
)The ARN of the certificate.
certificateId
— (String
)The ID of the certificate.
caCertificateId
— (String
)The certificate ID of the CA certificate used to sign this certificate.
status
— (String
)The status of the certificate.
Possible values include:"ACTIVE"
"INACTIVE"
"REVOKED"
"PENDING_TRANSFER"
"REGISTER_INACTIVE"
"PENDING_ACTIVATION"
certificatePem
— (String
)The certificate data, in PEM format.
ownedBy
— (String
)The ID of the Amazon Web Services account that owns the certificate.
previousOwnedBy
— (String
)The ID of the Amazon Web Services account of the previous owner of the certificate.
creationDate
— (Date
)The date and time the certificate was created.
lastModifiedDate
— (Date
)The date and time the certificate was last modified.
customerVersion
— (Integer
)The customer version of the certificate.
transferData
— (map
)The transfer data.
transferMessage
— (String
)The transfer message.
rejectReason
— (String
)The reason why the transfer was rejected.
transferDate
— (Date
)The date the transfer took place.
acceptDate
— (Date
)The date the transfer was accepted.
rejectDate
— (Date
)The date the transfer was rejected.
generationId
— (String
)The generation ID of the certificate.
validity
— (map
)When the certificate is valid.
notBefore
— (Date
)The certificate is not valid before this date.
notAfter
— (Date
)The certificate is not valid after this date.
certificateMode
— (String
)The mode of the certificate.
DEFAULT
: A certificate inDEFAULT
mode is either generated by Amazon Web Services IoT Core or registered with an issuer certificate authority (CA) inDEFAULT
mode. Devices with certificates inDEFAULT
mode aren't required to send the Server Name Indication (SNI) extension when connecting to Amazon Web Services IoT Core. However, to use features such as custom domains and VPC endpoints, we recommend that you use the SNI extension when connecting to Amazon Web Services IoT Core.SNI_ONLY
: A certificate inSNI_ONLY
mode is registered without an issuer CA. Devices with certificates inSNI_ONLY
mode must send the SNI extension when connecting to Amazon Web Services IoT Core.For more information about the value for SNI extension, see Transport security in IoT.
Possible values include:"DEFAULT"
"SNI_ONLY"
-
(AWS.Response)
—
Returns:
describeCertificateProvider(params = {}, callback) ⇒ AWS.Request
Describes a certificate provider.
Requires permission to access the DescribeCertificateProvider action.
Service Reference:
Examples:
Calling the describeCertificateProvider operation
var params = { certificateProviderName: 'STRING_VALUE' /* required */ }; iot.describeCertificateProvider(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateProviderName
— (String
)The name of the certificate provider.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateProviderName
— (String
)The name of the certificate provider.
certificateProviderArn
— (String
)The ARN of the certificate provider.
lambdaFunctionArn
— (String
)The Lambda function ARN that's associated with the certificate provider.
accountDefaultForOperations
— (Array<String>
)A list of the operations that the certificate provider will use to generate certificates. Valid value:
CreateCertificateFromCsr
.creationDate
— (Date
)The date-time string that indicates when the certificate provider was created.
lastModifiedDate
— (Date
)The date-time string that indicates when the certificate provider was last updated.
-
(AWS.Response)
—
Returns:
describeCustomMetric(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender detect custom metric.
Requires permission to access the DescribeCustomMetric action.
Service Reference:
Examples:
Calling the describeCustomMetric operation
var params = { metricName: 'STRING_VALUE' /* required */ }; iot.describeCustomMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the custom metric.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricName
— (String
)The name of the custom metric.
metricArn
— (String
)The Amazon Resource Number (ARN) of the custom metric.
metricType
— (String
)The type of the custom metric.
The type
number
only takes a single metric value as an input, but while submitting the metrics value in the DeviceMetrics report, it must be passed as an array with a single value."string-list"
"ip-address-list"
"number-list"
"number"
displayName
— (String
)Field represents a friendly name in the console for the custom metric; doesn't have to be unique. Don't use this name as the metric identifier in the device metric report. Can be updated.
creationDate
— (Date
)The creation date of the custom metric in milliseconds since epoch.
lastModifiedDate
— (Date
)The time the custom metric was last modified in milliseconds since epoch.
-
(AWS.Response)
—
Returns:
describeDefaultAuthorizer(params = {}, callback) ⇒ AWS.Request
Describes the default authorizer.
Requires permission to access the DescribeDefaultAuthorizer action.
Service Reference:
Examples:
Calling the describeDefaultAuthorizer operation
var params = { }; iot.describeDefaultAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authorizerDescription
— (map
)The default authorizer's description.
authorizerName
— (String
)The authorizer name.
authorizerArn
— (String
)The authorizer ARN.
authorizerFunctionArn
— (String
)The authorizer's Lambda function ARN.
tokenKeyName
— (String
)The key used to extract the token from the HTTP headers.
tokenSigningPublicKeys
— (map<String>
)The public keys used to validate the token signature returned by your custom authentication service.
status
— (String
)The status of the authorizer.
Possible values include:"ACTIVE"
"INACTIVE"
creationDate
— (Date
)The UNIX timestamp of when the authorizer was created.
lastModifiedDate
— (Date
)The UNIX timestamp of when the authorizer was last updated.
signingDisabled
— (Boolean
)Specifies whether IoT validates the token signature in an authorization request.
enableCachingForHttp
— (Boolean
)When
true
, the result from the authorizer’s Lambda function is cached for the time specified inrefreshAfterInSeconds
. The cached result is used while the device reuses the same HTTP connection.
-
(AWS.Response)
—
Returns:
describeDetectMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender ML Detect mitigation action.
Requires permission to access the DescribeDetectMitigationActionsTask action.
Service Reference:
Examples:
Calling the describeDetectMitigationActionsTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.describeDetectMitigationActionsTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The unique identifier of the task.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskSummary
— (map
)The description of a task.
taskId
— (String
)The unique identifier of the task.
taskStatus
— (String
)The status of the task.
Possible values include:"IN_PROGRESS"
"SUCCESSFUL"
"FAILED"
"CANCELED"
taskStartTime
— (Date
)The date the task started.
taskEndTime
— (Date
)The date the task ended.
target
— (map
)Specifies the ML Detect findings to which the mitigation actions are applied.
violationIds
— (Array<String>
)The unique identifiers of the violations.
securityProfileName
— (String
)The name of the security profile.
behaviorName
— (String
)The name of the behavior.
violationEventOccurrenceRange
— (map
)Specifies the time period of which violation events occurred between.
startTime
— required — (Date
)The start date and time of a time period in which violation events occurred.
endTime
— required — (Date
)The end date and time of a time period in which violation events occurred.
onlyActiveViolationsIncluded
— (Boolean
)Includes only active violations.
suppressedAlertsIncluded
— (Boolean
)Includes suppressed alerts.
actionsDefinition
— (Array<map>
)The definition of the actions.
name
— (String
)A user-friendly name for the mitigation action.
id
— (String
)A unique identifier for the mitigation action.
roleArn
— (String
)The IAM role ARN used to apply this mitigation action.
actionParams
— (map
)The set of parameters for this mitigation action. The parameters vary, depending on the kind of action you apply.
updateDeviceCertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the device certificate to inactive.
action
— required — (String
)The action that you want to apply to the device certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
updateCACertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the CA certificate to inactive.
action
— required — (String
)The action that you want to apply to the CA certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
addThingsToThingGroupParams
— (map
)Parameters to define a mitigation action that moves devices associated with a certificate to one or more specified thing groups, typically for quarantine.
thingGroupNames
— required — (Array<String>
)The list of groups to which you want to add the things that triggered the mitigation action. You can add a thing to a maximum of 10 groups, but you can't add a thing to more than one group in the same hierarchy.
overrideDynamicGroups
— (Boolean
)Specifies if this mitigation action can move the things that triggered the mitigation action even if they are part of one or more dynamic thing groups.
replaceDefaultPolicyVersionParams
— (map
)Parameters to define a mitigation action that adds a blank policy to restrict permissions.
templateName
— required — (String
)The name of the template to be applied. The only supported value is
Possible values include:BLANK_POLICY
."BLANK_POLICY"
enableIoTLoggingParams
— (map
)Parameters to define a mitigation action that enables Amazon Web Services IoT Core logging at a specified level of detail.
roleArnForLogging
— required — (String
)The Amazon Resource Name (ARN) of the IAM role used for logging.
logLevel
— required — (String
)Specifies the type of information to be logged.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
publishFindingToSnsParams
— (map
)Parameters to define a mitigation action that publishes findings to Amazon Simple Notification Service (Amazon SNS. You can implement your own custom actions in response to the Amazon SNS messages.
topicArn
— required — (String
)The ARN of the topic to which you want to publish the findings.
taskStatistics
— (map
)The statistics of a mitigation action task.
actionsExecuted
— (Integer
)The actions that were performed.
actionsSkipped
— (Integer
)The actions that were skipped.
actionsFailed
— (Integer
)The actions that failed.
-
(AWS.Response)
—
Returns:
describeDimension(params = {}, callback) ⇒ AWS.Request
Provides details about a dimension that is defined in your Amazon Web Services accounts.
Requires permission to access the DescribeDimension action.
Service Reference:
Examples:
Calling the describeDimension operation
var params = { name: 'STRING_VALUE' /* required */ }; iot.describeDimension(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
name
— (String
)The unique identifier for the dimension.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:name
— (String
)The unique identifier for the dimension.
arn
— (String
)The Amazon Resource Name (ARN) for the dimension.
type
— (String
)The type of the dimension.
Possible values include:"TOPIC_FILTER"
stringValues
— (Array<String>
)The value or list of values used to scope the dimension. For example, for topic filters, this is the pattern used to match the MQTT topic name.
creationDate
— (Date
)The date the dimension was created.
lastModifiedDate
— (Date
)The date the dimension was last modified.
-
(AWS.Response)
—
Returns:
describeDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Gets summary information about a domain configuration.
Requires permission to access the DescribeDomainConfiguration action.
Service Reference:
Examples:
Calling the describeDomainConfiguration operation
var params = { domainConfigurationName: 'STRING_VALUE' /* required */ }; iot.describeDomainConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
domainConfigurationName
— (String
)The name of the domain configuration.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:domainConfigurationName
— (String
)The name of the domain configuration.
domainConfigurationArn
— (String
)The ARN of the domain configuration.
domainName
— (String
)The name of the domain.
serverCertificates
— (Array<map>
)A list containing summary information about the server certificate included in the domain configuration.
serverCertificateArn
— (String
)The ARN of the server certificate.
serverCertificateStatus
— (String
)The status of the server certificate.
Possible values include:"INVALID"
"VALID"
serverCertificateStatusDetail
— (String
)Details that explain the status of the server certificate.
authorizerConfig
— (map
)An object that specifies the authorization service for a domain.
defaultAuthorizerName
— (String
)The name of the authorization service for a domain configuration.
allowAuthorizerOverride
— (Boolean
)A Boolean that specifies whether the domain configuration's authorization service can be overridden.
domainConfigurationStatus
— (String
)A Boolean value that specifies the current state of the domain configuration.
Possible values include:"ENABLED"
"DISABLED"
serviceType
— (String
)The type of service delivered by the endpoint.
Possible values include:"DATA"
"CREDENTIAL_PROVIDER"
"JOBS"
domainType
— (String
)The type of the domain.
Possible values include:"ENDPOINT"
"AWS_MANAGED"
"CUSTOMER_MANAGED"
lastStatusChangeDate
— (Date
)The date and time the domain configuration's status was last changed.
tlsConfig
— (map
)An object that specifies the TLS configuration for a domain.
securityPolicy
— (String
)The security policy for a domain configuration. For more information, see Security policies in the Amazon Web Services IoT Core developer guide.
serverCertificateConfig
— (map
)The server certificate configuration.
enableOCSPCheck
— (Boolean
)A Boolean value that indicates whether Online Certificate Status Protocol (OCSP) server certificate check is enabled or not.
For more information, see Configuring OCSP server-certificate stapling in domain configuration from Amazon Web Services IoT Core Developer Guide.
-
(AWS.Response)
—
Returns:
describeEndpoint(params = {}, callback) ⇒ AWS.Request
Returns or creates a unique endpoint specific to the Amazon Web Services account making the call.
Note: The first timeDescribeEndpoint
is called, an endpoint is created. All subsequent calls toDescribeEndpoint
return the same endpoint.Requires permission to access the DescribeEndpoint action.
Service Reference:
Examples:
Calling the describeEndpoint operation
var params = { endpointType: 'STRING_VALUE' }; iot.describeEndpoint(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
endpointType
— (String
)The endpoint type. Valid endpoint types include:
-
iot:Data
- Returns a VeriSign signed data endpoint.
-
iot:Data-ATS
- Returns an ATS signed data endpoint.
-
iot:CredentialProvider
- Returns an IoT credentials provider API endpoint.
-
iot:Jobs
- Returns an IoT device management Jobs API endpoint.
We strongly recommend that customers use the newer
iot:Data-ATS
endpoint type to avoid issues related to the widespread distrust of Symantec certificate authorities. ATS Signed Certificates are more secure and are trusted by most popular browsers.-
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:endpointAddress
— (String
)The endpoint. The format of the endpoint is as follows: identifier.iot.region.amazonaws.com.
-
(AWS.Response)
—
Returns:
describeEventConfigurations(params = {}, callback) ⇒ AWS.Request
Describes event configurations.
Requires permission to access the DescribeEventConfigurations action.
Service Reference:
Examples:
Calling the describeEventConfigurations operation
var params = { }; iot.describeEventConfigurations(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:eventConfigurations
— (map<map>
)The event configurations.
Enabled
— (Boolean
)True to enable the configuration.
creationDate
— (Date
)The creation date of the event configuration.
lastModifiedDate
— (Date
)The date the event configurations were last modified.
-
(AWS.Response)
—
Returns:
describeFleetMetric(params = {}, callback) ⇒ AWS.Request
Gets information about the specified fleet metric.
Requires permission to access the DescribeFleetMetric action.
Service Reference:
Examples:
Calling the describeFleetMetric operation
var params = { metricName: 'STRING_VALUE' /* required */ }; iot.describeFleetMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the fleet metric to describe.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricName
— (String
)The name of the fleet metric to describe.
queryString
— (String
)The search query string.
aggregationType
— (map
)The type of the aggregation query.
name
— required — (String
)The name of the aggregation type.
Possible values include:"Statistics"
"Percentiles"
"Cardinality"
values
— (Array<String>
)A list of the values of aggregation types.
period
— (Integer
)The time in seconds between fleet metric emissions. Range [60(1 min), 86400(1 day)] and must be multiple of 60.
aggregationField
— (String
)The field to aggregate.
description
— (String
)The fleet metric description.
queryVersion
— (String
)The query version.
indexName
— (String
)The name of the index to search.
creationDate
— (Date
)The date when the fleet metric is created.
lastModifiedDate
— (Date
)The date when the fleet metric is last modified.
unit
— (String
)Used to support unit transformation such as milliseconds to seconds. The unit must be supported by CW metric.
Possible values include:"Seconds"
"Microseconds"
"Milliseconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
version
— (Integer
)The version of the fleet metric.
metricArn
— (String
)The ARN of the fleet metric to describe.
-
(AWS.Response)
—
Returns:
describeIndex(params = {}, callback) ⇒ AWS.Request
Describes a search index.
Requires permission to access the DescribeIndex action.
Service Reference:
Examples:
Calling the describeIndex operation
var params = { indexName: 'STRING_VALUE' /* required */ }; iot.describeIndex(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
indexName
— (String
)The index name.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:indexName
— (String
)The index name.
indexStatus
— (String
)The index status.
Possible values include:"ACTIVE"
"BUILDING"
"REBUILDING"
schema
— (String
)Contains a value that specifies the type of indexing performed. Valid values are:
-
REGISTRY – Your thing index contains only registry data.
-
REGISTRY_AND_SHADOW - Your thing index contains registry data and shadow data.
-
REGISTRY_AND_CONNECTIVITY_STATUS - Your thing index contains registry data and thing connectivity status data.
-
REGISTRY_AND_SHADOW_AND_CONNECTIVITY_STATUS - Your thing index contains registry data, shadow data, and thing connectivity status data.
-
MULTI_INDEXING_MODE - Your thing index contains multiple data sources. For more information, see GetIndexingConfiguration.
-
-
(AWS.Response)
—
Returns:
describeJob(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the describeJob operation
var params = { jobId: 'STRING_VALUE' /* required */ }; iot.describeJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The unique identifier you assigned to this job when it was created.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:documentSource
— (String
)An S3 link to the job document.
job
— (map
)Information about the job.
jobArn
— (String
)An ARN identifying the job with format "arn:aws:iot:region:account:job/jobId".
jobId
— (String
)The unique identifier you assigned to this job when it was created.
targetSelection
— (String
)Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a device when the thing representing the device is added to a target group, even after the job was completed by all things originally in the group.
Note: We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.Possible values include:"CONTINUOUS"
"SNAPSHOT"
status
— (String
)The status of the job, one of
Possible values include:IN_PROGRESS
,CANCELED
,DELETION_IN_PROGRESS
orCOMPLETED
."IN_PROGRESS"
"CANCELED"
"COMPLETED"
"DELETION_IN_PROGRESS"
"SCHEDULED"
forceCanceled
— (Boolean
)Will be
true
if the job was canceled with the optionalforce
parameter set totrue
.reasonCode
— (String
)If the job was updated, provides the reason code for the update.
comment
— (String
)If the job was updated, describes the reason for the update.
targets
— (Array<String>
)A list of IoT things and thing groups to which the job should be sent.
description
— (String
)A short text description of the job.
presignedUrlConfig
— (map
)Configuration for pre-signed S3 URLs.
roleArn
— (String
)The ARN of an IAM role that grants permission to download files from the S3 bucket where the job data/updates are stored. The role must also grant permission for IoT to download the files.
For information about addressing the confused deputy problem, see cross-service confused deputy prevention in the Amazon Web Services IoT Core developer guide.
expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 3600 seconds. Pre-signed URLs are generated when Jobs receives an MQTT request for the job document.
jobExecutionsRolloutConfig
— (map
)Allows you to create a staged rollout of a job.
maximumPerMinute
— (Integer
)The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute at the start of job rollout. This parameter allows you to define the initial rate of rollout.
incrementFactor
— required — (Float
)The exponential factor to increase the rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
numberOfNotifiedThings
— (Integer
)The threshold for number of notified things that will initiate the increase in rate of rollout.
numberOfSucceededThings
— (Integer
)The threshold for number of succeeded things that will initiate the increase in rate of rollout.
abortConfig
— (map
)Configuration for criteria to abort the job.
criteriaList
— required — (Array<map>
)The list of criteria that determine when and how to abort the job.
failureType
— required — (String
)The type of job execution failures that can initiate a job abort.
Possible values include:"FAILED"
"REJECTED"
"TIMED_OUT"
"ALL"
action
— required — (String
)The type of job action to take to initiate the job abort.
Possible values include:"CANCEL"
thresholdPercentage
— required — (Float
)The minimum percentage of job execution failures that must occur to initiate the job abort.
Amazon Web Services IoT Core supports up to two digits after the decimal (for example, 10.9 and 10.99, but not 10.999).
minNumberOfExecutedThings
— required — (Integer
)The minimum number of things which must receive job execution notifications before the job can be aborted.
createdAt
— (Date
)The time, in seconds since the epoch, when the job was created.
lastUpdatedAt
— (Date
)The time, in seconds since the epoch, when the job was last updated.
completedAt
— (Date
)The time, in seconds since the epoch, when the job was completed.
jobProcessDetails
— (map
)Details about the job process.
processingTargets
— (Array<String>
)The target devices to which the job execution is being rolled out. This value will be null after the job execution has finished rolling out to all the target devices.
numberOfCanceledThings
— (Integer
)The number of things that cancelled the job.
numberOfSucceededThings
— (Integer
)The number of things which successfully completed the job.
numberOfFailedThings
— (Integer
)The number of things that failed executing the job.
numberOfRejectedThings
— (Integer
)The number of things that rejected the job.
numberOfQueuedThings
— (Integer
)The number of things that are awaiting execution of the job.
numberOfInProgressThings
— (Integer
)The number of things currently executing the job.
numberOfRemovedThings
— (Integer
)The number of things that are no longer scheduled to execute the job because they have been deleted or have been removed from the group that was a target of the job.
numberOfTimedOutThings
— (Integer
)The number of things whose job execution status is
TIMED_OUT
.
timeoutConfig
— (map
)Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to
IN_PROGRESS
. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set toTIMED_OUT
.inProgressTimeoutInMinutes
— (Integer
)Specifies the amount of time, in minutes, this device has to finish execution of this job. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The in progress timer can't be updated and will apply to all job executions for the job. Whenever a job execution remains in the IN_PROGRESS status for longer than this interval, the job execution will fail and switch to the terminal
TIMED_OUT
status.
namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.jobTemplateArn
— (String
)The ARN of the job template used to create the job.
jobExecutionsRetryConfig
— (map
)The configuration for the criteria to retry the job.
criteriaList
— required — (Array<map>
)The list of criteria that determines how many retries are allowed for each failure type for a job.
failureType
— required — (String
)The type of job execution failures that can initiate a job retry.
Possible values include:"FAILED"
"TIMED_OUT"
"ALL"
numberOfRetries
— required — (Integer
)The number of retries allowed for a failure type for the job.
documentParameters
— (map<String>
)A key-value map that pairs the patterns that need to be replaced in a managed template job document schema. You can use the description of each key as a guidance to specify the inputs during runtime when creating a job.
Note:documentParameters
can only be used when creating jobs from Amazon Web Services managed templates. This parameter can't be used with custom job templates or to create jobs from them.isConcurrent
— (Boolean
)Indicates whether a job is concurrent. Will be true when a job is rolling out new job executions or canceling previously created executions, otherwise false.
schedulingConfig
— (map
)The configuration that allows you to schedule a job for a future date and time in addition to specifying the end behavior for each job execution.
startTime
— (String
)The time a job will begin rollout of the job document to all devices in the target group for a job. The
startTime
can be scheduled up to a year in advance and must be scheduled a minimum of thirty minutes from the current time. The date and time format for thestartTime
is YYYY-MM-DD for the date and HH:MM for the time.For more information on the syntax for
startTime
when using an API command or the Command Line Interface, see Timestamp.endTime
— (String
)The time a job will stop rollout of the job document to all devices in the target group for a job. The
endTime
must take place no later than two years from the current time and be scheduled a minimum of thirty minutes from the current time. The minimum duration betweenstartTime
andendTime
is thirty minutes. The maximum duration betweenstartTime
andendTime
is two years. The date and time format for theendTime
is YYYY-MM-DD for the date and HH:MM for the time.For more information on the syntax for
endTime
when using an API command or the Command Line Interface, see Timestamp.endBehavior
— (String
)Specifies the end behavior for all job executions after a job reaches the selected
Possible values include:endTime
. IfendTime
is not selected when creating the job, thenendBehavior
does not apply."STOP_ROLLOUT"
"CANCEL"
"FORCE_CANCEL"
maintenanceWindows
— (Array<map>
)An optional configuration within the
SchedulingConfig
to setup a recurring maintenance window with a predetermined start time and duration for the rollout of a job document to all devices in a target group for a job.startTime
— required — (String
)Displays the start time of the next maintenance window.
durationInMinutes
— required — (Integer
)Displays the duration of the next maintenance window.
scheduledJobRollouts
— (Array<map>
)Displays the next seven maintenance window occurrences and their start times.
startTime
— (String
)Displays the start times of the next seven maintenance window occurrences.
destinationPackageVersions
— (Array<String>
)The package version Amazon Resource Names (ARNs) that are installed on the device when the job successfully completes. The package version must be in either the Published or Deprecated state when the job deploys. For more information, see Package version lifecycle.The package version must be in either the Published or Deprecated state when the job deploys. For more information, see Package version lifecycle.
Note:The following Length Constraints relates to a single ARN. Up to 25 package version ARNs are allowed.
-
(AWS.Response)
—
Returns:
describeJobExecution(params = {}, callback) ⇒ AWS.Request
Describes a job execution.
Requires permission to access the DescribeJobExecution action.
Service Reference:
Examples:
Calling the describeJobExecution operation
var params = { jobId: 'STRING_VALUE', /* required */ thingName: 'STRING_VALUE', /* required */ executionNumber: 'NUMBER_VALUE' }; iot.describeJobExecution(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The unique identifier you assigned to this job when it was created.
thingName
— (String
)The name of the thing on which the job execution is running.
executionNumber
— (Integer
)A string (consisting of the digits "0" through "9" which is used to specify a particular job execution on a particular device.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:execution
— (map
)Information about the job execution.
jobId
— (String
)The unique identifier you assigned to the job when it was created.
status
— (String
)The status of the job execution (IN_PROGRESS, QUEUED, FAILED, SUCCEEDED, TIMED_OUT, CANCELED, or REJECTED).
Possible values include:"QUEUED"
"IN_PROGRESS"
"SUCCEEDED"
"FAILED"
"TIMED_OUT"
"REJECTED"
"REMOVED"
"CANCELED"
forceCanceled
— (Boolean
)Will be
true
if the job execution was canceled with the optionalforce
parameter set totrue
.statusDetails
— (map
)A collection of name/value pairs that describe the status of the job execution.
detailsMap
— (map<String>
)The job execution status.
thingArn
— (String
)The ARN of the thing on which the job execution is running.
queuedAt
— (Date
)The time, in seconds since the epoch, when the job execution was queued.
startedAt
— (Date
)The time, in seconds since the epoch, when the job execution started.
lastUpdatedAt
— (Date
)The time, in seconds since the epoch, when the job execution was last updated.
executionNumber
— (Integer
)A string (consisting of the digits "0" through "9") which identifies this particular job execution on this particular device. It can be used in commands which return or update job execution information.
versionNumber
— (Integer
)The version of the job execution. Job execution versions are incremented each time they are updated by a device.
approximateSecondsBeforeTimedOut
— (Integer
)The estimated number of seconds that remain before the job execution status will be changed to
TIMED_OUT
. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The actual job execution timeout can occur up to 60 seconds later than the estimated duration. This value will not be included if the job execution has reached a terminal status.
-
(AWS.Response)
—
Returns:
describeJobTemplate(params = {}, callback) ⇒ AWS.Request
Returns information about a job template.
Service Reference:
Examples:
Calling the describeJobTemplate operation
var params = { jobTemplateId: 'STRING_VALUE' /* required */ }; iot.describeJobTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobTemplateId
— (String
)The unique identifier of the job template.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:jobTemplateArn
— (String
)The ARN of the job template.
jobTemplateId
— (String
)The unique identifier of the job template.
description
— (String
)A description of the job template.
documentSource
— (String
)An S3 link to the job document.
document
— (String
)The job document.
createdAt
— (Date
)The time, in seconds since the epoch, when the job template was created.
presignedUrlConfig
— (map
)Configuration for pre-signed S3 URLs.
roleArn
— (String
)The ARN of an IAM role that grants permission to download files from the S3 bucket where the job data/updates are stored. The role must also grant permission for IoT to download the files.
For information about addressing the confused deputy problem, see cross-service confused deputy prevention in the Amazon Web Services IoT Core developer guide.
expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 3600 seconds. Pre-signed URLs are generated when Jobs receives an MQTT request for the job document.
jobExecutionsRolloutConfig
— (map
)Allows you to create a staged rollout of a job.
maximumPerMinute
— (Integer
)The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute at the start of job rollout. This parameter allows you to define the initial rate of rollout.
incrementFactor
— required — (Float
)The exponential factor to increase the rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
numberOfNotifiedThings
— (Integer
)The threshold for number of notified things that will initiate the increase in rate of rollout.
numberOfSucceededThings
— (Integer
)The threshold for number of succeeded things that will initiate the increase in rate of rollout.
abortConfig
— (map
)The criteria that determine when and how a job abort takes place.
criteriaList
— required — (Array<map>
)The list of criteria that determine when and how to abort the job.
failureType
— required — (String
)The type of job execution failures that can initiate a job abort.
Possible values include:"FAILED"
"REJECTED"
"TIMED_OUT"
"ALL"
action
— required — (String
)The type of job action to take to initiate the job abort.
Possible values include:"CANCEL"
thresholdPercentage
— required — (Float
)The minimum percentage of job execution failures that must occur to initiate the job abort.
Amazon Web Services IoT Core supports up to two digits after the decimal (for example, 10.9 and 10.99, but not 10.999).
minNumberOfExecutedThings
— required — (Integer
)The minimum number of things which must receive job execution notifications before the job can be aborted.
timeoutConfig
— (map
)Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to
IN_PROGRESS
. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set toTIMED_OUT
.inProgressTimeoutInMinutes
— (Integer
)Specifies the amount of time, in minutes, this device has to finish execution of this job. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The in progress timer can't be updated and will apply to all job executions for the job. Whenever a job execution remains in the IN_PROGRESS status for longer than this interval, the job execution will fail and switch to the terminal
TIMED_OUT
status.
jobExecutionsRetryConfig
— (map
)The configuration that determines how many retries are allowed for each failure type for a job.
criteriaList
— required — (Array<map>
)The list of criteria that determines how many retries are allowed for each failure type for a job.
failureType
— required — (String
)The type of job execution failures that can initiate a job retry.
Possible values include:"FAILED"
"TIMED_OUT"
"ALL"
numberOfRetries
— required — (Integer
)The number of retries allowed for a failure type for the job.
maintenanceWindows
— (Array<map>
)Allows you to configure an optional maintenance window for the rollout of a job document to all devices in the target group for a job.
startTime
— required — (String
)Displays the start time of the next maintenance window.
durationInMinutes
— required — (Integer
)Displays the duration of the next maintenance window.
destinationPackageVersions
— (Array<String>
)The package version Amazon Resource Names (ARNs) that are installed on the device when the job successfully completes. The package version must be in either the Published or Deprecated state when the job deploys. For more information, see Package version lifecycle.
Note:The following Length Constraints relates to a single ARN. Up to 25 package version ARNs are allowed.
-
(AWS.Response)
—
Returns:
describeManagedJobTemplate(params = {}, callback) ⇒ AWS.Request
View details of a managed job template.
Service Reference:
Examples:
Calling the describeManagedJobTemplate operation
var params = { templateName: 'STRING_VALUE', /* required */ templateVersion: 'STRING_VALUE' }; iot.describeManagedJobTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The unique name of a managed job template, which is required.
templateVersion
— (String
)An optional parameter to specify version of a managed template. If not specified, the pre-defined default version is returned.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:templateName
— (String
)The unique name of a managed template, such as
AWS-Reboot
.templateArn
— (String
)The unique Amazon Resource Name (ARN) of the managed template.
description
— (String
)The unique description of a managed template.
templateVersion
— (String
)The version for a managed template.
environments
— (Array<String>
)A list of environments that are supported with the managed job template.
documentParameters
— (Array<map>
)A map of key-value pairs that you can use as guidance to specify the inputs for creating a job from a managed template.
Note:documentParameters
can only be used when creating jobs from Amazon Web Services managed templates. This parameter can't be used with custom job templates or to create jobs from them.key
— (String
)Key of the map field containing the patterns that need to be replaced in a managed template job document schema.
description
— (String
)Description of the map field containing the patterns that need to be replaced in a managed template job document schema.
regex
— (String
)A regular expression of the patterns that need to be replaced in a managed template job document schema.
example
— (String
)An example illustrating a pattern that need to be replaced in a managed template job document schema.
optional
— (Boolean
)Specifies whether a pattern that needs to be replaced in a managed template job document schema is optional or required.
document
— (String
)The document schema for a managed job template.
-
(AWS.Response)
—
Returns:
describeMitigationAction(params = {}, callback) ⇒ AWS.Request
Gets information about a mitigation action.
Requires permission to access the DescribeMitigationAction action.
Service Reference:
Examples:
Calling the describeMitigationAction operation
var params = { actionName: 'STRING_VALUE' /* required */ }; iot.describeMitigationAction(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
actionName
— (String
)The friendly name that uniquely identifies the mitigation action.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:actionName
— (String
)The friendly name that uniquely identifies the mitigation action.
actionType
— (String
)The type of mitigation action.
Possible values include:"UPDATE_DEVICE_CERTIFICATE"
"UPDATE_CA_CERTIFICATE"
"ADD_THINGS_TO_THING_GROUP"
"REPLACE_DEFAULT_POLICY_VERSION"
"ENABLE_IOT_LOGGING"
"PUBLISH_FINDING_TO_SNS"
actionArn
— (String
)The ARN that identifies this migration action.
actionId
— (String
)A unique identifier for this action.
roleArn
— (String
)The ARN of the IAM role used to apply this action.
actionParams
— (map
)Parameters that control how the mitigation action is applied, specific to the type of mitigation action.
updateDeviceCertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the device certificate to inactive.
action
— required — (String
)The action that you want to apply to the device certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
updateCACertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the CA certificate to inactive.
action
— required — (String
)The action that you want to apply to the CA certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
addThingsToThingGroupParams
— (map
)Parameters to define a mitigation action that moves devices associated with a certificate to one or more specified thing groups, typically for quarantine.
thingGroupNames
— required — (Array<String>
)The list of groups to which you want to add the things that triggered the mitigation action. You can add a thing to a maximum of 10 groups, but you can't add a thing to more than one group in the same hierarchy.
overrideDynamicGroups
— (Boolean
)Specifies if this mitigation action can move the things that triggered the mitigation action even if they are part of one or more dynamic thing groups.
replaceDefaultPolicyVersionParams
— (map
)Parameters to define a mitigation action that adds a blank policy to restrict permissions.
templateName
— required — (String
)The name of the template to be applied. The only supported value is
Possible values include:BLANK_POLICY
."BLANK_POLICY"
enableIoTLoggingParams
— (map
)Parameters to define a mitigation action that enables Amazon Web Services IoT Core logging at a specified level of detail.
roleArnForLogging
— required — (String
)The Amazon Resource Name (ARN) of the IAM role used for logging.
logLevel
— required — (String
)Specifies the type of information to be logged.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
publishFindingToSnsParams
— (map
)Parameters to define a mitigation action that publishes findings to Amazon Simple Notification Service (Amazon SNS. You can implement your own custom actions in response to the Amazon SNS messages.
topicArn
— required — (String
)The ARN of the topic to which you want to publish the findings.
creationDate
— (Date
)The date and time when the mitigation action was added to your Amazon Web Services accounts.
lastModifiedDate
— (Date
)The date and time when the mitigation action was last changed.
-
(AWS.Response)
—
Returns:
describeProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Returns information about a provisioning template.
Requires permission to access the DescribeProvisioningTemplate action.
Service Reference:
Examples:
Calling the describeProvisioningTemplate operation
var params = { templateName: 'STRING_VALUE' /* required */ }; iot.describeProvisioningTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:templateArn
— (String
)The ARN of the provisioning template.
templateName
— (String
)The name of the provisioning template.
description
— (String
)The description of the provisioning template.
creationDate
— (Date
)The date when the provisioning template was created.
lastModifiedDate
— (Date
)The date when the provisioning template was last modified.
defaultVersionId
— (Integer
)The default fleet template version ID.
templateBody
— (String
)The JSON formatted contents of the provisioning template.
enabled
— (Boolean
)True if the provisioning template is enabled, otherwise false.
provisioningRoleArn
— (String
)The ARN of the role associated with the provisioning template. This IoT role grants permission to provision a device.
preProvisioningHook
— (map
)Gets information about a pre-provisioned hook.
payloadVersion
— (String
)The payload that was sent to the target function.
Note: Only Lambda functions are currently supported.
targetArn
— required — (String
)The ARN of the target function.
Note: Only Lambda functions are currently supported.
type
— (String
)The type you define in a provisioning template. You can create a template with only one type. You can't change the template type after its creation. The default value is
Possible values include:FLEET_PROVISIONING
. For more information about provisioning template, see: Provisioning template."FLEET_PROVISIONING"
"JITP"
-
(AWS.Response)
—
Returns:
describeProvisioningTemplateVersion(params = {}, callback) ⇒ AWS.Request
Returns information about a provisioning template version.
Requires permission to access the DescribeProvisioningTemplateVersion action.
Service Reference:
Examples:
Calling the describeProvisioningTemplateVersion operation
var params = { templateName: 'STRING_VALUE', /* required */ versionId: 'NUMBER_VALUE' /* required */ }; iot.describeProvisioningTemplateVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The template name.
versionId
— (Integer
)The provisioning template version ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:versionId
— (Integer
)The provisioning template version ID.
creationDate
— (Date
)The date when the provisioning template version was created.
templateBody
— (String
)The JSON formatted contents of the provisioning template version.
isDefaultVersion
— (Boolean
)True if the provisioning template version is the default version.
-
(AWS.Response)
—
Returns:
describeRoleAlias(params = {}, callback) ⇒ AWS.Request
Describes a role alias.
Requires permission to access the DescribeRoleAlias action.
Service Reference:
Examples:
Calling the describeRoleAlias operation
var params = { roleAlias: 'STRING_VALUE' /* required */ }; iot.describeRoleAlias(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
roleAlias
— (String
)The role alias to describe.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleAliasDescription
— (map
)The role alias description.
roleAlias
— (String
)The role alias.
roleAliasArn
— (String
)The ARN of the role alias.
roleArn
— (String
)The role ARN.
owner
— (String
)The role alias owner.
credentialDurationSeconds
— (Integer
)The number of seconds for which the credential is valid.
creationDate
— (Date
)The UNIX timestamp of when the role alias was created.
lastModifiedDate
— (Date
)The UNIX timestamp of when the role alias was last modified.
-
(AWS.Response)
—
Returns:
describeScheduledAudit(params = {}, callback) ⇒ AWS.Request
Gets information about a scheduled audit.
Requires permission to access the DescribeScheduledAudit action.
Service Reference:
Examples:
Calling the describeScheduledAudit operation
var params = { scheduledAuditName: 'STRING_VALUE' /* required */ }; iot.describeScheduledAudit(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
scheduledAuditName
— (String
)The name of the scheduled audit whose information you want to get.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:frequency
— (String
)How often the scheduled audit takes place, either one of
Possible values include:DAILY
,WEEKLY
,BIWEEKLY
, orMONTHLY
. The start time of each audit is determined by the system."DAILY"
"WEEKLY"
"BIWEEKLY"
"MONTHLY"
dayOfMonth
— (String
)The day of the month on which the scheduled audit takes place. This is will be
1
through31
orLAST
. If days29
-31
are specified, and the month does not have that many days, the audit takes place on theLAST
day of the month.dayOfWeek
— (String
)The day of the week on which the scheduled audit takes place, either one of
Possible values include:SUN
,MON
,TUE
,WED
,THU
,FRI
, orSAT
."SUN"
"MON"
"TUE"
"WED"
"THU"
"FRI"
"SAT"
targetCheckNames
— (Array<String>
)Which checks are performed during the scheduled audit. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)scheduledAuditName
— (String
)The name of the scheduled audit.
scheduledAuditArn
— (String
)The ARN of the scheduled audit.
-
(AWS.Response)
—
Returns:
describeSecurityProfile(params = {}, callback) ⇒ AWS.Request
Gets information about a Device Defender security profile.
Requires permission to access the DescribeSecurityProfile action.
Service Reference:
Examples:
Calling the describeSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE' /* required */ }; iot.describeSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The name of the security profile whose information you want to get.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:securityProfileName
— (String
)The name of the security profile.
securityProfileArn
— (String
)The ARN of the security profile.
securityProfileDescription
— (String
)A description of the security profile (associated with the security profile when it was created or updated).
behaviors
— (Array<map>
)Specifies the behaviors that, when violated by a device (thing), cause an alert.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
alertTargets
— (map<map>
)Where the alerts are sent. (Alerts are always sent to the console.)
alertTargetArn
— required — (String
)The Amazon Resource Name (ARN) of the notification target to which alerts are sent.
roleArn
— required — (String
)The ARN of the role that grants permission to send alerts to the notification target.
additionalMetricsToRetain
— (Array<String>
)Please use DescribeSecurityProfileResponse$additionalMetricsToRetainV2 instead.
A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's
behaviors
, but it is also retained for any metric specified here.additionalMetricsToRetainV2
— (Array<map>
)A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's behaviors, but it is also retained for any metric specified here.
metric
— required — (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension of a metric. This can't be used with custom metrics.
dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
exportMetric
— (Boolean
)The value indicates exporting metrics related to the
MetricToRetain
when it's true.
version
— (Integer
)The version of the security profile. A new version is generated whenever the security profile is updated.
creationDate
— (Date
)The time the security profile was created.
lastModifiedDate
— (Date
)The time the security profile was last modified.
metricsExportConfig
— (map
)Specifies the MQTT topic and role ARN required for metric export.
mqttTopic
— required — (String
)The MQTT topic that Device Defender Detect should publish messages to for metrics export.
roleArn
— required — (String
)This role ARN has permission to publish MQTT messages, after which Device Defender Detect can assume the role and publish messages on your behalf.
-
(AWS.Response)
—
Returns:
describeStream(params = {}, callback) ⇒ AWS.Request
Gets information about a stream.
Requires permission to access the DescribeStream action.
Service Reference:
Examples:
Calling the describeStream operation
var params = { streamId: 'STRING_VALUE' /* required */ }; iot.describeStream(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
streamId
— (String
)The stream ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:streamInfo
— (map
)Information about the stream.
streamId
— (String
)The stream ID.
streamArn
— (String
)The stream ARN.
streamVersion
— (Integer
)The stream version.
description
— (String
)The description of the stream.
files
— (Array<map>
)The files to stream.
fileId
— (Integer
)The file ID.
s3Location
— (map
)The location of the file in S3.
bucket
— (String
)The S3 bucket.
key
— (String
)The S3 key.
version
— (String
)The S3 bucket version.
createdAt
— (Date
)The date when the stream was created.
lastUpdatedAt
— (Date
)The date when the stream was last updated.
roleArn
— (String
)An IAM role IoT assumes to access your S3 files.
-
(AWS.Response)
—
Returns:
describeThing(params = {}, callback) ⇒ AWS.Request
Gets information about the specified thing.
Requires permission to access the DescribeThing action.
Service Reference:
Examples:
Calling the describeThing operation
var params = { thingName: 'STRING_VALUE' /* required */ }; iot.describeThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:defaultClientId
— (String
)The default MQTT client ID. For a typical device, the thing name is also used as the default MQTT client ID. Although we don’t require a mapping between a thing's registry name and its use of MQTT client IDs, certificates, or shadow state, we recommend that you choose a thing name and use it as the MQTT client ID for the registry and the Device Shadow service.
This lets you better organize your IoT fleet without removing the flexibility of the underlying device certificate model or shadows.
thingName
— (String
)The name of the thing.
thingId
— (String
)The ID of the thing to describe.
thingArn
— (String
)The ARN of the thing to describe.
thingTypeName
— (String
)The thing type name.
attributes
— (map<String>
)The thing attributes.
version
— (Integer
)The current version of the thing record in the registry.
Note: To avoid unintentional changes to the information in the registry, you can pass the version information in theexpectedVersion
parameter of theUpdateThing
andDeleteThing
calls.billingGroupName
— (String
)The name of the billing group the thing belongs to.
-
(AWS.Response)
—
Returns:
describeThingGroup(params = {}, callback) ⇒ AWS.Request
Describe a thing group.
Requires permission to access the DescribeThingGroup action.
Service Reference:
Examples:
Calling the describeThingGroup operation
var params = { thingGroupName: 'STRING_VALUE' /* required */ }; iot.describeThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The name of the thing group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingGroupName
— (String
)The name of the thing group.
thingGroupId
— (String
)The thing group ID.
thingGroupArn
— (String
)The thing group ARN.
version
— (Integer
)The version of the thing group.
thingGroupProperties
— (map
)The thing group properties.
thingGroupDescription
— (String
)The thing group description.
attributePayload
— (map
)The thing group attributes in JSON format.
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
thingGroupMetadata
— (map
)Thing group metadata.
parentGroupName
— (String
)The parent thing group name.
rootToParentThingGroups
— (Array<map>
)The root parent thing group.
groupName
— (String
)The group name.
groupArn
— (String
)The group ARN.
creationDate
— (Date
)The UNIX timestamp of when the thing group was created.
indexName
— (String
)The dynamic thing group index name.
queryString
— (String
)The dynamic thing group search query string.
queryVersion
— (String
)The dynamic thing group query version.
status
— (String
)The dynamic thing group status.
Possible values include:"ACTIVE"
"BUILDING"
"REBUILDING"
-
(AWS.Response)
—
Returns:
describeThingRegistrationTask(params = {}, callback) ⇒ AWS.Request
Describes a bulk thing provisioning task.
Requires permission to access the DescribeThingRegistrationTask action.
Service Reference:
Examples:
Calling the describeThingRegistrationTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.describeThingRegistrationTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The task ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskId
— (String
)The task ID.
creationDate
— (Date
)The task creation date.
lastModifiedDate
— (Date
)The date when the task was last modified.
templateBody
— (String
)The task's template.
inputFileBucket
— (String
)The S3 bucket that contains the input file.
inputFileKey
— (String
)The input file key.
roleArn
— (String
)The role ARN that grants access to the input file bucket.
status
— (String
)The status of the bulk thing provisioning task.
Possible values include:"InProgress"
"Completed"
"Failed"
"Cancelled"
"Cancelling"
message
— (String
)The message.
successCount
— (Integer
)The number of things successfully provisioned.
failureCount
— (Integer
)The number of things that failed to be provisioned.
percentageProgress
— (Integer
)The progress of the bulk provisioning task expressed as a percentage.
-
(AWS.Response)
—
Returns:
describeThingType(params = {}, callback) ⇒ AWS.Request
Gets information about the specified thing type.
Requires permission to access the DescribeThingType action.
Service Reference:
Examples:
Calling the describeThingType operation
var params = { thingTypeName: 'STRING_VALUE' /* required */ }; iot.describeThingType(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingTypeName
— (String
)The name of the thing type.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingTypeName
— (String
)The name of the thing type.
thingTypeId
— (String
)The thing type ID.
thingTypeArn
— (String
)The thing type ARN.
thingTypeProperties
— (map
)The ThingTypeProperties contains information about the thing type including description, and a list of searchable thing attribute names.
thingTypeDescription
— (String
)The description of the thing type.
searchableAttributes
— (Array<String>
)A list of searchable thing attribute names.
thingTypeMetadata
— (map
)The ThingTypeMetadata contains additional information about the thing type including: creation date and time, a value indicating whether the thing type is deprecated, and a date and time when it was deprecated.
deprecated
— (Boolean
)Whether the thing type is deprecated. If true, no new things could be associated with this type.
deprecationDate
— (Date
)The date and time when the thing type was deprecated.
creationDate
— (Date
)The date and time when the thing type was created.
-
(AWS.Response)
—
Returns:
detachPolicy(params = {}, callback) ⇒ AWS.Request
Detaches a policy from the specified target.
Note: Because of the distributed nature of Amazon Web Services, it can take up to five minutes after a policy is detached before it's ready to be deleted.Requires permission to access the DetachPolicy action.
Service Reference:
Examples:
Calling the detachPolicy operation
var params = { policyName: 'STRING_VALUE', /* required */ target: 'STRING_VALUE' /* required */ }; iot.detachPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy to detach.
target
— (String
)The target from which the policy will be detached.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
detachPrincipalPolicy(params = {}, callback) ⇒ AWS.Request
Removes the specified policy from the specified certificate.
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements. Use DetachPolicy instead.
Requires permission to access the DetachPrincipalPolicy action.
Service Reference:
Examples:
Calling the detachPrincipalPolicy operation
var params = { policyName: 'STRING_VALUE', /* required */ principal: 'STRING_VALUE' /* required */ }; iot.detachPrincipalPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The name of the policy to detach.
principal
— (String
)The principal.
Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
detachSecurityProfile(params = {}, callback) ⇒ AWS.Request
Disassociates a Device Defender security profile from a thing group or from this account.
Requires permission to access the DetachSecurityProfile action.
Service Reference:
Examples:
Calling the detachSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE', /* required */ securityProfileTargetArn: 'STRING_VALUE' /* required */ }; iot.detachSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The security profile that is detached.
securityProfileTargetArn
— (String
)The ARN of the thing group from which the security profile is detached.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
detachThingPrincipal(params = {}, callback) ⇒ AWS.Request
Detaches the specified principal from the specified thing. A principal can be X.509 certificates, IAM users, groups, and roles, Amazon Cognito identities or federated identities.
Note: This call is asynchronous. It might take several seconds for the detachment to propagate.Requires permission to access the DetachThingPrincipal action.
Service Reference:
Examples:
Calling the detachThingPrincipal operation
var params = { principal: 'STRING_VALUE', /* required */ thingName: 'STRING_VALUE' /* required */ }; iot.detachThingPrincipal(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing.
principal
— (String
)If the principal is a certificate, this value must be ARN of the certificate. If the principal is an Amazon Cognito identity, this value must be the ID of the Amazon Cognito identity.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
disableTopicRule(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the disableTopicRule operation
var params = { ruleName: 'STRING_VALUE' /* required */ }; iot.disableTopicRule(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
ruleName
— (String
)The name of the rule to disable.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
enableTopicRule(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the enableTopicRule operation
var params = { ruleName: 'STRING_VALUE' /* required */ }; iot.enableTopicRule(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
ruleName
— (String
)The name of the topic rule to enable.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
getBehaviorModelTrainingSummaries(params = {}, callback) ⇒ AWS.Request
Returns a Device Defender's ML Detect Security Profile training model's status.
Requires permission to access the GetBehaviorModelTrainingSummaries action.
Service Reference:
Examples:
Calling the getBehaviorModelTrainingSummaries operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', securityProfileName: 'STRING_VALUE' }; iot.getBehaviorModelTrainingSummaries(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The name of the security profile.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 10.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:summaries
— (Array<map>
)A list of all ML Detect behaviors and their model status for a given Security Profile.
securityProfileName
— (String
)The name of the security profile.
behaviorName
— (String
)The name of the behavior.
trainingDataCollectionStartDate
— (Date
)The date a training model started collecting data.
modelStatus
— (String
)The status of the behavior model.
Possible values include:"PENDING_BUILD"
"ACTIVE"
"EXPIRED"
datapointsCollectionPercentage
— (Float
)The percentage of datapoints collected.
lastModelRefreshDate
— (Date
)The date the model was last refreshed.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
getBucketsAggregation(params = {}, callback) ⇒ AWS.Request
Aggregates on indexed data with search queries pertaining to particular fields.
Requires permission to access the GetBucketsAggregation action.
Service Reference:
Examples:
Calling the getBucketsAggregation operation
var params = { aggregationField: 'STRING_VALUE', /* required */ bucketsAggregationType: { /* required */ termsAggregation: { maxBuckets: 'NUMBER_VALUE' } }, queryString: 'STRING_VALUE', /* required */ indexName: 'STRING_VALUE', queryVersion: 'STRING_VALUE' }; iot.getBucketsAggregation(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
indexName
— (String
)The name of the index to search.
queryString
— (String
)The search query string.
aggregationField
— (String
)The aggregation field.
queryVersion
— (String
)The version of the query.
bucketsAggregationType
— (map
)The basic control of the response shape and the bucket aggregation type to perform.
termsAggregation
— (map
)Performs an aggregation that will return a list of buckets. The list of buckets is a ranked list of the number of occurrences of an aggregation field value.
maxBuckets
— (Integer
)The number of buckets to return in the response. Default to 10.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:totalCount
— (Integer
)The total number of things that fit the query string criteria.
buckets
— (Array<map>
)The main part of the response with a list of buckets. Each bucket contains a
keyValue
and acount
.keyValue
: The aggregation field value counted for the particular bucket.count
: The number of documents that have that value.keyValue
— (String
)The value counted for the particular bucket.
count
— (Integer
)The number of documents that have the value counted for the particular bucket.
-
(AWS.Response)
—
Returns:
getCardinality(params = {}, callback) ⇒ AWS.Request
Returns the approximate count of unique values that match the query.
Requires permission to access the GetCardinality action.
Service Reference:
Examples:
Calling the getCardinality operation
var params = { queryString: 'STRING_VALUE', /* required */ aggregationField: 'STRING_VALUE', indexName: 'STRING_VALUE', queryVersion: 'STRING_VALUE' }; iot.getCardinality(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
indexName
— (String
)The name of the index to search.
queryString
— (String
)The search query string.
aggregationField
— (String
)The field to aggregate.
queryVersion
— (String
)The query version.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:cardinality
— (Integer
)The approximate count of unique values that match the query.
-
(AWS.Response)
—
Returns:
getEffectivePolicies(params = {}, callback) ⇒ AWS.Request
Gets a list of the policies that have an effect on the authorization behavior of the specified device when it connects to the IoT device gateway.
Requires permission to access the GetEffectivePolicies action.
Service Reference:
Examples:
Calling the getEffectivePolicies operation
var params = { cognitoIdentityPoolId: 'STRING_VALUE', principal: 'STRING_VALUE', thingName: 'STRING_VALUE' }; iot.getEffectivePolicies(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
principal
— (String
)The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
cognitoIdentityPoolId
— (String
)The Cognito identity pool ID.
thingName
— (String
)The thing name.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:effectivePolicies
— (Array<map>
)The effective policies.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
policyDocument
— (String
)The IAM policy document.
-
(AWS.Response)
—
Returns:
getIndexingConfiguration(params = {}, callback) ⇒ AWS.Request
Gets the indexing configuration.
Requires permission to access the GetIndexingConfiguration action.
Service Reference:
Examples:
Calling the getIndexingConfiguration operation
var params = { }; iot.getIndexingConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingIndexingConfiguration
— (map
)Thing indexing configuration.
thingIndexingMode
— required — (String
)Thing indexing mode. Valid values are:
-
REGISTRY – Your thing index contains registry data only.
-
REGISTRY_AND_SHADOW - Your thing index contains registry and shadow data.
-
OFF - Thing indexing is disabled.
"OFF"
"REGISTRY"
"REGISTRY_AND_SHADOW"
-
thingConnectivityIndexingMode
— (String
)Thing connectivity indexing mode. Valid values are:
-
STATUS – Your thing index contains connectivity status. To enable thing connectivity indexing, thingIndexMode must not be set to OFF.
-
OFF - Thing connectivity status indexing is disabled.
"OFF"
"STATUS"
-
deviceDefenderIndexingMode
— (String
)Device Defender indexing mode. Valid values are:
-
VIOLATIONS – Your thing index contains Device Defender violations. To enable Device Defender indexing, deviceDefenderIndexingMode must not be set to OFF.
-
OFF - Device Defender indexing is disabled.
For more information about Device Defender violations, see Device Defender Detect.
Possible values include:"OFF"
"VIOLATIONS"
-
namedShadowIndexingMode
— (String
)Named shadow indexing mode. Valid values are:
-
ON – Your thing index contains named shadow. To enable thing named shadow indexing, namedShadowIndexingMode must not be set to OFF.
-
OFF - Named shadow indexing is disabled.
For more information about Shadows, see IoT Device Shadow service.
Possible values include:"OFF"
"ON"
-
managedFields
— (Array<map>
)Contains fields that are indexed and whose types are already known by the Fleet Indexing service. This is an optional field. For more information, see Managed fields in the Amazon Web Services IoT Core Developer Guide.
Note: You can't modify managed fields by updating fleet indexing configuration.name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
customFields
— (Array<map>
)Contains custom field names and their data type.
name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
filter
— (map
)Provides additional selections for named shadows and geolocation data.
To add named shadows to your fleet indexing configuration, set
namedShadowIndexingMode
to be ON and specify your shadow names innamedShadowNames
filter.To add geolocation data to your fleet indexing configuration:
-
If you store geolocation data in a class/unnamed shadow, set
thingIndexingMode
to beREGISTRY_AND_SHADOW
and specify your geolocation data ingeoLocations
filter. -
If you store geolocation data in a named shadow, set
namedShadowIndexingMode
to beON
, add the shadow name innamedShadowNames
filter, and specify your geolocation data ingeoLocations
filter. For more information, see Managing fleet indexing.
namedShadowNames
— (Array<String>
)The shadow names that you select to index. The default maximum number of shadow names for indexing is 10. To increase the limit, see Amazon Web Services IoT Device Management Quotas in the Amazon Web Services General Reference.
geoLocations
— (Array<map>
)The list of geolocation targets that you select to index. The default maximum number of geolocation targets for indexing is
1
. To increase the limit, see Amazon Web Services IoT Device Management Quotas in the Amazon Web Services General Reference.name
— (String
)The
name
of the geolocation target field. If the target field is part of a named shadow, you must select the named shadow using thenamedShadow
filter.order
— (String
)The
Possible values include:order
of the geolocation target field. This field is optional. The default value isLatLon
."LatLon"
"LonLat"
-
thingGroupIndexingConfiguration
— (map
)The index configuration.
thingGroupIndexingMode
— required — (String
)Thing group indexing mode.
Possible values include:"OFF"
"ON"
managedFields
— (Array<map>
)Contains fields that are indexed and whose types are already known by the Fleet Indexing service. This is an optional field. For more information, see Managed fields in the Amazon Web Services IoT Core Developer Guide.
Note: You can't modify managed fields by updating fleet indexing configuration.name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
customFields
— (Array<map>
)A list of thing group fields to index. This list cannot contain any managed fields. Use the GetIndexingConfiguration API to get a list of managed fields.
Contains custom field names and their data type.
name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
-
(AWS.Response)
—
Returns:
getJobDocument(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the getJobDocument operation
var params = { jobId: 'STRING_VALUE' /* required */ }; iot.getJobDocument(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The unique identifier you assigned to this job when it was created.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:document
— (String
)The job document content.
-
(AWS.Response)
—
Returns:
getLoggingOptions(params = {}, callback) ⇒ AWS.Request
Gets the logging options.
NOTE: use of this command is not recommended. Use
GetV2LoggingOptions
instead.Requires permission to access the GetLoggingOptions action.
Service Reference:
Examples:
Calling the getLoggingOptions operation
var params = { }; iot.getLoggingOptions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleArn
— (String
)The ARN of the IAM role that grants access.
logLevel
— (String
)The logging level.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
-
(AWS.Response)
—
Returns:
getOTAUpdate(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the getOTAUpdate operation
var params = { otaUpdateId: 'STRING_VALUE' /* required */ }; iot.getOTAUpdate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
otaUpdateId
— (String
)The OTA update ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:otaUpdateInfo
— (map
)The OTA update info.
otaUpdateId
— (String
)The OTA update ID.
otaUpdateArn
— (String
)The OTA update ARN.
creationDate
— (Date
)The date when the OTA update was created.
lastModifiedDate
— (Date
)The date when the OTA update was last updated.
description
— (String
)A description of the OTA update.
targets
— (Array<String>
)The targets of the OTA update.
protocols
— (Array<String>
)The protocol used to transfer the OTA update image. Valid values are [HTTP], [MQTT], [HTTP, MQTT]. When both HTTP and MQTT are specified, the target device can choose the protocol.
awsJobExecutionsRolloutConfig
— (map
)Configuration for the rollout of OTA updates.
maximumPerMinute
— (Integer
)The maximum number of OTA update job executions started per minute.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate increase for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute, at the start of the job rollout. This is the initial rate of the rollout.
incrementFactor
— required — (Float
)The rate of increase for a job rollout. The number of things notified is multiplied by this factor.
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
numberOfNotifiedThings
— (Integer
)When this number of things have been notified, it will initiate an increase in the rollout rate.
numberOfSucceededThings
— (Integer
)When this number of things have succeeded in their job execution, it will initiate an increase in the rollout rate.
awsJobPresignedUrlConfig
— (map
)Configuration information for pre-signed URLs. Valid when
protocols
contains HTTP.expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 1800 seconds. Pre-signed URLs are generated when a request for the job document is received.
targetSelection
— (String
)Specifies whether the OTA update will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the OTA update (SNAPSHOT). If continuous, the OTA update may also be run on a thing when a change is detected in a target. For example, an OTA update will run on a thing when the thing is added to a target group, even after the OTA update was completed by all things originally in the group.
Possible values include:"CONTINUOUS"
"SNAPSHOT"
otaUpdateFiles
— (Array<map>
)A list of files associated with the OTA update.
fileName
— (String
)The name of the file.
fileType
— (Integer
)An integer value you can include in the job document to allow your devices to identify the type of file received from the cloud.
fileVersion
— (String
)The file version.
fileLocation
— (map
)The location of the updated firmware.
stream
— (map
)The stream that contains the OTA update.
streamId
— (String
)The stream ID.
fileId
— (Integer
)The ID of a file associated with a stream.
s3Location
— (map
)The location of the updated firmware in S3.
bucket
— (String
)The S3 bucket.
key
— (String
)The S3 key.
version
— (String
)The S3 bucket version.
codeSigning
— (map
)The code signing method of the file.
awsSignerJobId
— (String
)The ID of the
AWSSignerJob
which was created to sign the file.startSigningJobParameter
— (map
)Describes the code-signing job.
signingProfileParameter
— (map
)Describes the code-signing profile.
certificateArn
— (String
)Certificate ARN.
platform
— (String
)The hardware platform of your device.
certificatePathOnDevice
— (String
)The location of the code-signing certificate on your device.
signingProfileName
— (String
)The code-signing profile name.
destination
— (map
)The location to write the code-signed file.
s3Destination
— (map
)Describes the location in S3 of the updated firmware.
bucket
— (String
)The S3 bucket that contains the updated firmware.
prefix
— (String
)The S3 prefix.
customCodeSigning
— (map
)A custom method for code signing a file.
signature
— (map
)The signature for the file.
inlineDocument
— (Buffer, Typed Array, Blob, String
)A base64 encoded binary representation of the code signing signature.
certificateChain
— (map
)The certificate chain.
certificateName
— (String
)The name of the certificate.
inlineDocument
— (String
)A base64 encoded binary representation of the code signing certificate chain.
hashAlgorithm
— (String
)The hash algorithm used to code sign the file. You can use a string as the algorithm name if the target over-the-air (OTA) update devices are able to verify the signature that was generated using the same signature algorithm. For example, FreeRTOS uses
SHA256
orSHA1
, so you can pass either of them based on which was used for generating the signature.signatureAlgorithm
— (String
)The signature algorithm used to code sign the file. You can use a string as the algorithm name if the target over-the-air (OTA) update devices are able to verify the signature that was generated using the same signature algorithm. For example, FreeRTOS uses
ECDSA
orRSA
, so you can pass either of them based on which was used for generating the signature.
attributes
— (map<String>
)A list of name-attribute pairs. They won't be sent to devices as a part of the Job document.
otaUpdateStatus
— (String
)The status of the OTA update.
Possible values include:"CREATE_PENDING"
"CREATE_IN_PROGRESS"
"CREATE_COMPLETE"
"CREATE_FAILED"
"DELETE_IN_PROGRESS"
"DELETE_FAILED"
awsIotJobId
— (String
)The IoT job ID associated with the OTA update.
awsIotJobArn
— (String
)The IoT job ARN associated with the OTA update.
errorInfo
— (map
)Error information associated with the OTA update.
code
— (String
)The error code.
message
— (String
)The error message.
additionalParameters
— (map<String>
)A collection of name/value pairs
-
(AWS.Response)
—
Returns:
getPackage(params = {}, callback) ⇒ AWS.Request
Gets information about the specified software package.
Requires permission to access the GetPackage action.
Service Reference:
Examples:
Calling the getPackage operation
var params = { packageName: 'STRING_VALUE' /* required */ }; iot.getPackage(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the target software package.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:packageName
— (String
)The name of the software package.
packageArn
— (String
)The ARN for the package.
description
— (String
)The package description.
defaultVersionName
— (String
)The name of the default package version.
creationDate
— (Date
)The date the package was created.
lastModifiedDate
— (Date
)The date when the package was last updated.
-
(AWS.Response)
—
Returns:
getPackageConfiguration(params = {}, callback) ⇒ AWS.Request
Gets information about the specified software package's configuration.
Requires permission to access the GetPackageConfiguration action.
Service Reference:
Examples:
Calling the getPackageConfiguration operation
var params = { }; iot.getPackageConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:versionUpdateByJobsConfig
— (map
)The version that is associated to a specific job.
enabled
— (Boolean
)Indicates whether the Job is enabled or not.
roleArn
— (String
)The Amazon Resource Name (ARN) of the role that grants permission to the IoT jobs service to update the reserved named shadow when the job successfully completes.
-
(AWS.Response)
—
Returns:
getPackageVersion(params = {}, callback) ⇒ AWS.Request
Gets information about the specified package version.
Requires permission to access the GetPackageVersion action.
Service Reference:
Examples:
Calling the getPackageVersion operation
var params = { packageName: 'STRING_VALUE', /* required */ versionName: 'STRING_VALUE' /* required */ }; iot.getPackageVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the associated package.
versionName
— (String
)The name of the target package version.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:packageVersionArn
— (String
)The ARN for the package version.
packageName
— (String
)The name of the software package.
versionName
— (String
)The name of the package version.
description
— (String
)The package version description.
attributes
— (map<String>
)Metadata that were added to the package version that can be used to define a package version’s configuration.
status
— (String
)The status associated to the package version. For more information, see Package version lifecycle.
Possible values include:"DRAFT"
"PUBLISHED"
"DEPRECATED"
errorReason
— (String
)Error reason for a package version failure during creation or update.
creationDate
— (Date
)The date when the package version was created.
lastModifiedDate
— (Date
)The date when the package version was last updated.
-
(AWS.Response)
—
Returns:
getPercentiles(params = {}, callback) ⇒ AWS.Request
Groups the aggregated values that match the query into percentile groupings. The default percentile groupings are: 1,5,25,50,75,95,99, although you can specify your own when you call
GetPercentiles
. This function returns a value for each percentile group specified (or the default percentile groupings). The percentile group "1" contains the aggregated field value that occurs in approximately one percent of the values that match the query. The percentile group "5" contains the aggregated field value that occurs in approximately five percent of the values that match the query, and so on. The result is an approximation, the more values that match the query, the more accurate the percentile values.Requires permission to access the GetPercentiles action.
Service Reference:
Examples:
Calling the getPercentiles operation
var params = { queryString: 'STRING_VALUE', /* required */ aggregationField: 'STRING_VALUE', indexName: 'STRING_VALUE', percents: [ 'NUMBER_VALUE', /* more items */ ], queryVersion: 'STRING_VALUE' }; iot.getPercentiles(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
indexName
— (String
)The name of the index to search.
queryString
— (String
)The search query string.
aggregationField
— (String
)The field to aggregate.
queryVersion
— (String
)The query version.
percents
— (Array<Float>
)The percentile groups returned.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:percentiles
— (Array<map>
)The percentile values of the aggregated fields.
percent
— (Float
)The percentile.
value
— (Float
)The value of the percentile.
-
(AWS.Response)
—
Returns:
getPolicy(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the getPolicy operation
var params = { policyName: 'STRING_VALUE' /* required */ }; iot.getPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The name of the policy.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
policyDocument
— (String
)The JSON document that describes the policy.
defaultVersionId
— (String
)The default policy version ID.
creationDate
— (Date
)The date the policy was created.
lastModifiedDate
— (Date
)The date the policy was last modified.
generationId
— (String
)The generation ID of the policy.
-
(AWS.Response)
—
Returns:
getPolicyVersion(params = {}, callback) ⇒ AWS.Request
Gets information about the specified policy version.
Requires permission to access the GetPolicyVersion action.
Service Reference:
Examples:
Calling the getPolicyVersion operation
var params = { policyName: 'STRING_VALUE', /* required */ policyVersionId: 'STRING_VALUE' /* required */ }; iot.getPolicyVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The policy version ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policyArn
— (String
)The policy ARN.
policyName
— (String
)The policy name.
policyDocument
— (String
)The JSON document that describes the policy.
policyVersionId
— (String
)The policy version ID.
isDefaultVersion
— (Boolean
)Specifies whether the policy version is the default.
creationDate
— (Date
)The date the policy was created.
lastModifiedDate
— (Date
)The date the policy was last modified.
generationId
— (String
)The generation ID of the policy version.
-
(AWS.Response)
—
Returns:
getRegistrationCode(params = {}, callback) ⇒ AWS.Request
Gets a registration code used to register a CA certificate with IoT.
IoT will create a registration code as part of this API call if the registration code doesn't exist or has been deleted. If you already have a registration code, this API call will return the same registration code.
Requires permission to access the GetRegistrationCode action.
Service Reference:
Examples:
Calling the getRegistrationCode operation
var params = { }; iot.getRegistrationCode(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:registrationCode
— (String
)The CA certificate registration code.
-
(AWS.Response)
—
Returns:
getStatistics(params = {}, callback) ⇒ AWS.Request
Returns the count, average, sum, minimum, maximum, sum of squares, variance, and standard deviation for the specified aggregated field. If the aggregation field is of type
String
, only the count statistic is returned.Requires permission to access the GetStatistics action.
Service Reference:
Examples:
Calling the getStatistics operation
var params = { queryString: 'STRING_VALUE', /* required */ aggregationField: 'STRING_VALUE', indexName: 'STRING_VALUE', queryVersion: 'STRING_VALUE' }; iot.getStatistics(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
indexName
— (String
)The name of the index to search. The default value is
AWS_Things
.queryString
— (String
)The query used to search. You can specify "*" for the query string to get the count of all indexed things in your Amazon Web Services account.
aggregationField
— (String
)The aggregation field name.
queryVersion
— (String
)The version of the query used to search.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:statistics
— (map
)The statistics returned by the Fleet Indexing service based on the query and aggregation field.
count
— (Integer
)The count of things that match the query string criteria and contain a valid aggregation field value.
average
— (Float
)The average of the aggregated field values.
sum
— (Float
)The sum of the aggregated field values.
minimum
— (Float
)The minimum aggregated field value.
maximum
— (Float
)The maximum aggregated field value.
sumOfSquares
— (Float
)The sum of the squares of the aggregated field values.
variance
— (Float
)The variance of the aggregated field values.
stdDeviation
— (Float
)The standard deviation of the aggregated field values.
-
(AWS.Response)
—
Returns:
getTopicRule(params = {}, callback) ⇒ AWS.Request
Gets information about the rule.
Requires permission to access the GetTopicRule action.
Service Reference:
Examples:
Calling the getTopicRule operation
var params = { ruleName: 'STRING_VALUE' /* required */ }; iot.getTopicRule(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
ruleName
— (String
)The name of the rule.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:ruleArn
— (String
)The rule ARN.
rule
— (map
)The rule.
ruleName
— (String
)The name of the rule.
sql
— (String
)The SQL statement used to query the topic. When using a SQL query with multiple lines, be sure to escape the newline characters.
description
— (String
)The description of the rule.
createdAt
— (Date
)The date and time the rule was created.
actions
— (Array<map>
)The actions associated with the rule.
dynamoDB
— (map
)Write to a DynamoDB table.
tableName
— required — (String
)The name of the DynamoDB table.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
operation
— (String
)The type of operation to be performed. This follows the substitution template, so it can be
${operation}
, but the substitution must result in one of the following:INSERT
,UPDATE
, orDELETE
.hashKeyField
— required — (String
)The hash key name.
hashKeyValue
— required — (String
)The hash key value.
hashKeyType
— (String
)The hash key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
rangeKeyField
— (String
)The range key name.
rangeKeyValue
— (String
)The range key value.
rangeKeyType
— (String
)The range key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
payloadField
— (String
)The action payload. This name can be customized.
dynamoDBv2
— (map
)Write to a DynamoDB table. This is a new version of the DynamoDB action. It allows you to write each attribute in an MQTT message payload into a separate DynamoDB column.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
putItem
— required — (map
)Specifies the DynamoDB table to which the message data will be written. For example:
{ "dynamoDBv2": { "roleArn": "aws:iam:12341251:my-role" "putItem": { "tableName": "my-table" } } }
Each attribute in the message payload will be written to a separate column in the DynamoDB database.
tableName
— required — (String
)The table where the message data will be written.
lambda
— (map
)Invoke a Lambda function.
functionArn
— required — (String
)The ARN of the Lambda function.
sns
— (map
)Publish to an Amazon SNS topic.
targetArn
— required — (String
)The ARN of the SNS topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
messageFormat
— (String
)(Optional) The message format of the message to publish. Accepted values are "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this setting to determine if the payload should be parsed and relevant platform-specific bits of the payload should be extracted. To read more about SNS message formats, see https://docs.aws.amazon.com/sns/latest/dg/json-formats.html refer to their official documentation.
Possible values include:"RAW"
"JSON"
sqs
— (map
)Publish to an Amazon SQS queue.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
queueUrl
— required — (String
)The URL of the Amazon SQS queue.
useBase64
— (Boolean
)Specifies whether to use Base64 encoding.
kinesis
— (map
)Write data to an Amazon Kinesis stream.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the Amazon Kinesis stream.
streamName
— required — (String
)The name of the Amazon Kinesis stream.
partitionKey
— (String
)The partition key.
republish
— (map
)Publish to another MQTT topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
topic
— required — (String
)The name of the MQTT topic.
qos
— (Integer
)The Quality of Service (QoS) level to use when republishing messages. The default value is 0.
headers
— (map
)MQTT Version 5.0 headers information. For more information, see MQTT from the Amazon Web Services IoT Core Developer Guide.
payloadFormatIndicator
— (String
)An
Enum
string value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTES
andUTF8_DATA
.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates.
contentType
— (String
)A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type from the MQTT Version 5.0 specification.
Supports substitution templates.
responseTopic
— (String
)A UTF-8 encoded string that's used as the topic name for a response message. The response topic is used to describe the topic which the receiver should publish to as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic from the MQTT Version 5.0 specification.
Supports substitution templates.
correlationData
— (String
)The base64-encoded binary data used by the sender of the request message to identify which request the response message is for when it's received.
For more information, see Correlation Data from the MQTT Version 5.0 specification.
Note: This binary data must be based64-encoded.Supports substitution templates.
messageExpiry
— (String
)A user-defined integer value that will persist a message at the message broker for a specified amount of time to ensure that the message will expire if it's no longer relevant to the subscriber. The value of
messageExpiry
represents the number of seconds before it expires. For more information about the limits ofmessageExpiry
, see Amazon Web Services IoT Core message broker and protocol limits and quotas from the Amazon Web Services Reference Guide.Supports substitution templates.
userProperties
— (Array<map>
)An array of key-value pairs that you define in the MQTT5 header.
key
— required — (String
)A key to be specified in
UserProperty
.value
— required — (String
)A value to be specified in
UserProperty
.
s3
— (map
)Write to an Amazon S3 bucket.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
bucketName
— required — (String
)The Amazon S3 bucket.
key
— required — (String
)The object key. For more information, see Actions, resources, and condition keys for Amazon S3.
cannedAcl
— (String
)The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs.
Possible values include:"private"
"public-read"
"public-read-write"
"aws-exec-read"
"authenticated-read"
"bucket-owner-read"
"bucket-owner-full-control"
"log-delivery-write"
firehose
— (map
)Write to an Amazon Kinesis Firehose stream.
roleArn
— required — (String
)The IAM role that grants access to the Amazon Kinesis Firehose stream.
deliveryStreamName
— required — (String
)The delivery stream name.
separator
— (String
)A character separator that will be used to separate records written to the Firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows newline), ',' (comma).
batchMode
— (Boolean
)Whether to deliver the Kinesis Data Firehose stream as a batch by using
PutRecordBatch
. The default value isfalse
.When
batchMode
istrue
and the rule's SQL statement evaluates to an Array, each Array element forms one record in thePutRecordBatch
request. The resulting array can't have more than 500 records.
cloudwatchMetric
— (map
)Capture a CloudWatch metric.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch metric.
metricNamespace
— required — (String
)The CloudWatch metric namespace name.
metricName
— required — (String
)The CloudWatch metric name.
metricValue
— required — (String
)The CloudWatch metric value.
metricUnit
— required — (String
)The metric unit supported by CloudWatch.
metricTimestamp
— (String
)An optional Unix timestamp.
cloudwatchAlarm
— (map
)Change the state of a CloudWatch alarm.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch alarm.
alarmName
— required — (String
)The CloudWatch alarm name.
stateReason
— required — (String
)The reason for the alarm change.
stateValue
— required — (String
)The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
cloudwatchLogs
— (map
)Send data to CloudWatch Logs.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch log.
logGroupName
— required — (String
)The CloudWatch log group to which the action sends data.
batchMode
— (Boolean
)Indicates whether batches of log records will be extracted and uploaded into CloudWatch. Values include
true
orfalse
(default).
elasticsearch
— (map
)Write data to an Amazon OpenSearch Service domain.
Note: TheElasticsearch
action can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearch
rule action instead. For more information, see OpenSearchAction.roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
salesforce
— (map
)Send a message to a Salesforce IoT Cloud Input Stream.
token
— required — (String
)The token used to authenticate access to the Salesforce IoT Cloud Input Stream. The token is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
url
— required — (String
)The URL exposed by the Salesforce IoT Cloud Input Stream. The URL is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
iotAnalytics
— (map
)Sends message data to an IoT Analytics channel.
channelArn
— (String
)(deprecated) The ARN of the IoT Analytics channel to which message data will be sent.
channelName
— (String
)The name of the IoT Analytics channel to which message data will be sent.
batchMode
— (Boolean
)Whether to process the action as a batch. The default value is
false
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed byBatchPutMessage
to the IoT Analytics channel. The resulting array can't have more than 100 messages.roleArn
— (String
)The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
iotEvents
— (map
)Sends an input to an IoT Events detector.
inputName
— required — (String
)The name of the IoT Events input.
messageId
— (String
)The ID of the message. The default
messageId
is a new UUID value.When
batchMode
istrue
, you can't specify amessageId
--a new UUID value will be assigned.Assign a value to this property to ensure that only one input (message) with a given
messageId
will be processed by an IoT Events detector.batchMode
— (Boolean
)Whether to process the event actions as a batch. The default value is
false
.When
batchMode
istrue
, you can't specify amessageId
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when it's sent to IoT Events by callingBatchPutMessage
. The resulting array can't have more than 10 messages.roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an input to an IoT Events detector. ("Action":"iotevents:BatchPutMessage").
iotSiteWise
— (map
)Sends data from the MQTT message that triggered the rule to IoT SiteWise asset properties.
putAssetPropertyValueEntries
— required — (Array<map>
)A list of asset property value entries.
entryId
— (String
)Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
assetId
— (String
)The ID of the IoT SiteWise asset. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyId
— (String
)The ID of the asset's property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyAlias
— (String
)The name of the property alias associated with your asset property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyValues
— required — (Array<map>
)A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
value
— required — (map
)The value of the asset property.
stringValue
— (String
)Optional. The string value of the value entry. Accepts substitution templates.
integerValue
— (String
)Optional. A string that contains the integer value of the value entry. Accepts substitution templates.
doubleValue
— (String
)Optional. A string that contains the double value of the value entry. Accepts substitution templates.
booleanValue
— (String
)Optional. A string that contains the boolean value (
true
orfalse
) of the value entry. Accepts substitution templates.
timestamp
— required — (map
)The asset property value timestamp.
timeInSeconds
— required — (String
)A string that contains the time in seconds since epoch. Accepts substitution templates.
offsetInNanos
— (String
)Optional. A string that contains the nanosecond time offset. Accepts substitution templates.
quality
— (String
)Optional. A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD
,BAD
, orUNCERTAIN
.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an asset property value to IoT SiteWise. (
"Action": "iotsitewise:BatchPutAssetPropertyValue"
). The trust policy can restrict access to specific asset hierarchy paths.
stepFunctions
— (map
)Starts execution of a Step Functions state machine.
executionNamePrefix
— (String
)(Optional) A name will be given to the state machine execution consisting of this prefix followed by a UUID. Step Functions automatically creates a unique name for each state machine execution if one is not provided.
stateMachineName
— required — (String
)The name of the Step Functions state machine whose execution will be started.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to start execution of a state machine ("Action":"states:StartExecution").
timestream
— (map
)The Timestream rule action writes attributes (measures) from an MQTT message into an Amazon Timestream table. For more information, see the Timestream topic rule action documentation.
roleArn
— required — (String
)The ARN of the role that grants permission to write to the Amazon Timestream database table.
databaseName
— required — (String
)The name of an Amazon Timestream database.
tableName
— required — (String
)The name of the database table into which to write the measure records.
dimensions
— required — (Array<map>
)Metadata attributes of the time series that are written in each measure record.
name
— required — (String
)The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.
Dimensions cannot be named:
measure_name
,measure_value
, ortime
. These names are reserved. Dimension names cannot start withts_
ormeasure_value
and they cannot contain the colon (:
) character.value
— required — (String
)The value to write in this column of the database record.
timestamp
— (map
)Specifies an application-defined value to replace the default value assigned to the Timestream record's timestamp in the
time
column.You can use this property to specify the value and the precision of the Timestream record's timestamp. You can specify a value from the message payload or a value computed by a substitution template.
If omitted, the topic rule action assigns the timestamp, in milliseconds, at the time it processed the rule.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— required — (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
http
— (map
)Send data to an HTTPS endpoint.
url
— required — (String
)The endpoint URL. If substitution templates are used in the URL, you must also specify a
confirmationUrl
. If this is a new destination, a newTopicRuleDestination
is created if possible.confirmationUrl
— (String
)The URL to which IoT sends a confirmation message. The value of the confirmation URL must be a prefix of the endpoint URL. If you do not specify a confirmation URL IoT uses the endpoint URL as the confirmation URL. If you use substitution templates in the confirmationUrl, you must create and enable topic rule destinations that match each possible value of the substitution template before traffic is allowed to your endpoint URL.
headers
— (Array<map>
)The HTTP headers to send with the message data.
key
— required — (String
)The HTTP header key.
value
— required — (String
)The HTTP header value. Substitution templates are supported.
auth
— (map
)The authentication method to use when sending data to an HTTPS endpoint.
sigv4
— (map
)Use Sig V4 authorization. For more information, see Signature Version 4 Signing Process.
signingRegion
— required — (String
)The signing region.
serviceName
— required — (String
)The service name to use while signing with Sig V4.
roleArn
— required — (String
)The ARN of the signing role.
kafka
— (map
)Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
destinationArn
— required — (String
)The ARN of Kafka action's VPC
TopicRuleDestination
.topic
— required — (String
)The Kafka topic for messages to be sent to the Kafka broker.
key
— (String
)The Kafka message key.
partition
— (String
)The Kafka message partition.
clientProperties
— required — (map<String>
)Properties of the Apache Kafka producer client.
headers
— (Array<map>
)The list of Kafka headers that you specify.
key
— required — (String
)The key of the Kafka header.
value
— required — (String
)The value of the Kafka header.
openSearch
— (map
)Write data to an Amazon OpenSearch Service domain.
roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The OpenSearch index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
location
— (map
)The Amazon Location Service rule action sends device location updates from an MQTT message to an Amazon Location tracker resource.
roleArn
— required — (String
)The IAM role that grants permission to write to the Amazon Location resource.
trackerName
— required — (String
)The name of the tracker resource in Amazon Location in which the location is updated.
deviceId
— required — (String
)The unique ID of the device providing the location data.
timestamp
— (map
)The time that the location data was sampled. The default value is the time the MQTT message was processed.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
latitude
— required — (String
)A string that evaluates to a double value that represents the latitude of the device's location.
longitude
— required — (String
)A string that evaluates to a double value that represents the longitude of the device's location.
ruleDisabled
— (Boolean
)Specifies whether the rule is disabled.
awsIotSqlVersion
— (String
)The version of the SQL rules engine to use when evaluating the rule.
errorAction
— (map
)The action to perform when an error occurs.
dynamoDB
— (map
)Write to a DynamoDB table.
tableName
— required — (String
)The name of the DynamoDB table.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
operation
— (String
)The type of operation to be performed. This follows the substitution template, so it can be
${operation}
, but the substitution must result in one of the following:INSERT
,UPDATE
, orDELETE
.hashKeyField
— required — (String
)The hash key name.
hashKeyValue
— required — (String
)The hash key value.
hashKeyType
— (String
)The hash key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
rangeKeyField
— (String
)The range key name.
rangeKeyValue
— (String
)The range key value.
rangeKeyType
— (String
)The range key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
payloadField
— (String
)The action payload. This name can be customized.
dynamoDBv2
— (map
)Write to a DynamoDB table. This is a new version of the DynamoDB action. It allows you to write each attribute in an MQTT message payload into a separate DynamoDB column.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
putItem
— required — (map
)Specifies the DynamoDB table to which the message data will be written. For example:
{ "dynamoDBv2": { "roleArn": "aws:iam:12341251:my-role" "putItem": { "tableName": "my-table" } } }
Each attribute in the message payload will be written to a separate column in the DynamoDB database.
tableName
— required — (String
)The table where the message data will be written.
lambda
— (map
)Invoke a Lambda function.
functionArn
— required — (String
)The ARN of the Lambda function.
sns
— (map
)Publish to an Amazon SNS topic.
targetArn
— required — (String
)The ARN of the SNS topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
messageFormat
— (String
)(Optional) The message format of the message to publish. Accepted values are "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this setting to determine if the payload should be parsed and relevant platform-specific bits of the payload should be extracted. To read more about SNS message formats, see https://docs.aws.amazon.com/sns/latest/dg/json-formats.html refer to their official documentation.
Possible values include:"RAW"
"JSON"
sqs
— (map
)Publish to an Amazon SQS queue.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
queueUrl
— required — (String
)The URL of the Amazon SQS queue.
useBase64
— (Boolean
)Specifies whether to use Base64 encoding.
kinesis
— (map
)Write data to an Amazon Kinesis stream.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the Amazon Kinesis stream.
streamName
— required — (String
)The name of the Amazon Kinesis stream.
partitionKey
— (String
)The partition key.
republish
— (map
)Publish to another MQTT topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
topic
— required — (String
)The name of the MQTT topic.
qos
— (Integer
)The Quality of Service (QoS) level to use when republishing messages. The default value is 0.
headers
— (map
)MQTT Version 5.0 headers information. For more information, see MQTT from the Amazon Web Services IoT Core Developer Guide.
payloadFormatIndicator
— (String
)An
Enum
string value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTES
andUTF8_DATA
.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates.
contentType
— (String
)A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type from the MQTT Version 5.0 specification.
Supports substitution templates.
responseTopic
— (String
)A UTF-8 encoded string that's used as the topic name for a response message. The response topic is used to describe the topic which the receiver should publish to as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic from the MQTT Version 5.0 specification.
Supports substitution templates.
correlationData
— (String
)The base64-encoded binary data used by the sender of the request message to identify which request the response message is for when it's received.
For more information, see Correlation Data from the MQTT Version 5.0 specification.
Note: This binary data must be based64-encoded.Supports substitution templates.
messageExpiry
— (String
)A user-defined integer value that will persist a message at the message broker for a specified amount of time to ensure that the message will expire if it's no longer relevant to the subscriber. The value of
messageExpiry
represents the number of seconds before it expires. For more information about the limits ofmessageExpiry
, see Amazon Web Services IoT Core message broker and protocol limits and quotas from the Amazon Web Services Reference Guide.Supports substitution templates.
userProperties
— (Array<map>
)An array of key-value pairs that you define in the MQTT5 header.
key
— required — (String
)A key to be specified in
UserProperty
.value
— required — (String
)A value to be specified in
UserProperty
.
s3
— (map
)Write to an Amazon S3 bucket.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
bucketName
— required — (String
)The Amazon S3 bucket.
key
— required — (String
)The object key. For more information, see Actions, resources, and condition keys for Amazon S3.
cannedAcl
— (String
)The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs.
Possible values include:"private"
"public-read"
"public-read-write"
"aws-exec-read"
"authenticated-read"
"bucket-owner-read"
"bucket-owner-full-control"
"log-delivery-write"
firehose
— (map
)Write to an Amazon Kinesis Firehose stream.
roleArn
— required — (String
)The IAM role that grants access to the Amazon Kinesis Firehose stream.
deliveryStreamName
— required — (String
)The delivery stream name.
separator
— (String
)A character separator that will be used to separate records written to the Firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows newline), ',' (comma).
batchMode
— (Boolean
)Whether to deliver the Kinesis Data Firehose stream as a batch by using
PutRecordBatch
. The default value isfalse
.When
batchMode
istrue
and the rule's SQL statement evaluates to an Array, each Array element forms one record in thePutRecordBatch
request. The resulting array can't have more than 500 records.
cloudwatchMetric
— (map
)Capture a CloudWatch metric.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch metric.
metricNamespace
— required — (String
)The CloudWatch metric namespace name.
metricName
— required — (String
)The CloudWatch metric name.
metricValue
— required — (String
)The CloudWatch metric value.
metricUnit
— required — (String
)The metric unit supported by CloudWatch.
metricTimestamp
— (String
)An optional Unix timestamp.
cloudwatchAlarm
— (map
)Change the state of a CloudWatch alarm.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch alarm.
alarmName
— required — (String
)The CloudWatch alarm name.
stateReason
— required — (String
)The reason for the alarm change.
stateValue
— required — (String
)The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
cloudwatchLogs
— (map
)Send data to CloudWatch Logs.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch log.
logGroupName
— required — (String
)The CloudWatch log group to which the action sends data.
batchMode
— (Boolean
)Indicates whether batches of log records will be extracted and uploaded into CloudWatch. Values include
true
orfalse
(default).
elasticsearch
— (map
)Write data to an Amazon OpenSearch Service domain.
Note: TheElasticsearch
action can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearch
rule action instead. For more information, see OpenSearchAction.roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
salesforce
— (map
)Send a message to a Salesforce IoT Cloud Input Stream.
token
— required — (String
)The token used to authenticate access to the Salesforce IoT Cloud Input Stream. The token is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
url
— required — (String
)The URL exposed by the Salesforce IoT Cloud Input Stream. The URL is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
iotAnalytics
— (map
)Sends message data to an IoT Analytics channel.
channelArn
— (String
)(deprecated) The ARN of the IoT Analytics channel to which message data will be sent.
channelName
— (String
)The name of the IoT Analytics channel to which message data will be sent.
batchMode
— (Boolean
)Whether to process the action as a batch. The default value is
false
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed byBatchPutMessage
to the IoT Analytics channel. The resulting array can't have more than 100 messages.roleArn
— (String
)The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
iotEvents
— (map
)Sends an input to an IoT Events detector.
inputName
— required — (String
)The name of the IoT Events input.
messageId
— (String
)The ID of the message. The default
messageId
is a new UUID value.When
batchMode
istrue
, you can't specify amessageId
--a new UUID value will be assigned.Assign a value to this property to ensure that only one input (message) with a given
messageId
will be processed by an IoT Events detector.batchMode
— (Boolean
)Whether to process the event actions as a batch. The default value is
false
.When
batchMode
istrue
, you can't specify amessageId
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when it's sent to IoT Events by callingBatchPutMessage
. The resulting array can't have more than 10 messages.roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an input to an IoT Events detector. ("Action":"iotevents:BatchPutMessage").
iotSiteWise
— (map
)Sends data from the MQTT message that triggered the rule to IoT SiteWise asset properties.
putAssetPropertyValueEntries
— required — (Array<map>
)A list of asset property value entries.
entryId
— (String
)Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
assetId
— (String
)The ID of the IoT SiteWise asset. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyId
— (String
)The ID of the asset's property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyAlias
— (String
)The name of the property alias associated with your asset property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyValues
— required — (Array<map>
)A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
value
— required — (map
)The value of the asset property.
stringValue
— (String
)Optional. The string value of the value entry. Accepts substitution templates.
integerValue
— (String
)Optional. A string that contains the integer value of the value entry. Accepts substitution templates.
doubleValue
— (String
)Optional. A string that contains the double value of the value entry. Accepts substitution templates.
booleanValue
— (String
)Optional. A string that contains the boolean value (
true
orfalse
) of the value entry. Accepts substitution templates.
timestamp
— required — (map
)The asset property value timestamp.
timeInSeconds
— required — (String
)A string that contains the time in seconds since epoch. Accepts substitution templates.
offsetInNanos
— (String
)Optional. A string that contains the nanosecond time offset. Accepts substitution templates.
quality
— (String
)Optional. A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD
,BAD
, orUNCERTAIN
.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an asset property value to IoT SiteWise. (
"Action": "iotsitewise:BatchPutAssetPropertyValue"
). The trust policy can restrict access to specific asset hierarchy paths.
stepFunctions
— (map
)Starts execution of a Step Functions state machine.
executionNamePrefix
— (String
)(Optional) A name will be given to the state machine execution consisting of this prefix followed by a UUID. Step Functions automatically creates a unique name for each state machine execution if one is not provided.
stateMachineName
— required — (String
)The name of the Step Functions state machine whose execution will be started.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to start execution of a state machine ("Action":"states:StartExecution").
timestream
— (map
)The Timestream rule action writes attributes (measures) from an MQTT message into an Amazon Timestream table. For more information, see the Timestream topic rule action documentation.
roleArn
— required — (String
)The ARN of the role that grants permission to write to the Amazon Timestream database table.
databaseName
— required — (String
)The name of an Amazon Timestream database.
tableName
— required — (String
)The name of the database table into which to write the measure records.
dimensions
— required — (Array<map>
)Metadata attributes of the time series that are written in each measure record.
name
— required — (String
)The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.
Dimensions cannot be named:
measure_name
,measure_value
, ortime
. These names are reserved. Dimension names cannot start withts_
ormeasure_value
and they cannot contain the colon (:
) character.value
— required — (String
)The value to write in this column of the database record.
timestamp
— (map
)Specifies an application-defined value to replace the default value assigned to the Timestream record's timestamp in the
time
column.You can use this property to specify the value and the precision of the Timestream record's timestamp. You can specify a value from the message payload or a value computed by a substitution template.
If omitted, the topic rule action assigns the timestamp, in milliseconds, at the time it processed the rule.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— required — (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
http
— (map
)Send data to an HTTPS endpoint.
url
— required — (String
)The endpoint URL. If substitution templates are used in the URL, you must also specify a
confirmationUrl
. If this is a new destination, a newTopicRuleDestination
is created if possible.confirmationUrl
— (String
)The URL to which IoT sends a confirmation message. The value of the confirmation URL must be a prefix of the endpoint URL. If you do not specify a confirmation URL IoT uses the endpoint URL as the confirmation URL. If you use substitution templates in the confirmationUrl, you must create and enable topic rule destinations that match each possible value of the substitution template before traffic is allowed to your endpoint URL.
headers
— (Array<map>
)The HTTP headers to send with the message data.
key
— required — (String
)The HTTP header key.
value
— required — (String
)The HTTP header value. Substitution templates are supported.
auth
— (map
)The authentication method to use when sending data to an HTTPS endpoint.
sigv4
— (map
)Use Sig V4 authorization. For more information, see Signature Version 4 Signing Process.
signingRegion
— required — (String
)The signing region.
serviceName
— required — (String
)The service name to use while signing with Sig V4.
roleArn
— required — (String
)The ARN of the signing role.
kafka
— (map
)Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
destinationArn
— required — (String
)The ARN of Kafka action's VPC
TopicRuleDestination
.topic
— required — (String
)The Kafka topic for messages to be sent to the Kafka broker.
key
— (String
)The Kafka message key.
partition
— (String
)The Kafka message partition.
clientProperties
— required — (map<String>
)Properties of the Apache Kafka producer client.
headers
— (Array<map>
)The list of Kafka headers that you specify.
key
— required — (String
)The key of the Kafka header.
value
— required — (String
)The value of the Kafka header.
openSearch
— (map
)Write data to an Amazon OpenSearch Service domain.
roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The OpenSearch index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
location
— (map
)The Amazon Location Service rule action sends device location updates from an MQTT message to an Amazon Location tracker resource.
roleArn
— required — (String
)The IAM role that grants permission to write to the Amazon Location resource.
trackerName
— required — (String
)The name of the tracker resource in Amazon Location in which the location is updated.
deviceId
— required — (String
)The unique ID of the device providing the location data.
timestamp
— (map
)The time that the location data was sampled. The default value is the time the MQTT message was processed.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
latitude
— required — (String
)A string that evaluates to a double value that represents the latitude of the device's location.
longitude
— required — (String
)A string that evaluates to a double value that represents the longitude of the device's location.
-
(AWS.Response)
—
Returns:
getTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Gets information about a topic rule destination.
Requires permission to access the GetTopicRuleDestination action.
Service Reference:
Examples:
Calling the getTopicRuleDestination operation
var params = { arn: 'STRING_VALUE' /* required */ }; iot.getTopicRuleDestination(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
arn
— (String
)The ARN of the topic rule destination.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:topicRuleDestination
— (map
)The topic rule destination.
arn
— (String
)The topic rule destination URL.
status
— (String
)The status of the topic rule destination. Valid values are:
- IN_PROGRESS
-
A topic rule destination was created but has not been confirmed. You can set
status
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint. - ENABLED
-
Confirmation was completed, and traffic to this destination is allowed. You can set
status
toDISABLED
by callingUpdateTopicRuleDestination
. - DISABLED
-
Confirmation was completed, and traffic to this destination is not allowed. You can set
status
toENABLED
by callingUpdateTopicRuleDestination
. - ERROR
-
Confirmation could not be completed, for example if the confirmation timed out. You can call
GetTopicRuleDestination
for details about the error. You can setstatus
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint.
"ENABLED"
"IN_PROGRESS"
"DISABLED"
"ERROR"
"DELETING"
createdAt
— (Date
)The date and time when the topic rule destination was created.
lastUpdatedAt
— (Date
)The date and time when the topic rule destination was last updated.
statusReason
— (String
)Additional details or reason why the topic rule destination is in the current status.
httpUrlProperties
— (map
)Properties of the HTTP URL.
confirmationUrl
— (String
)The URL used to confirm the HTTP topic rule destination URL.
vpcProperties
— (map
)Properties of the virtual private cloud (VPC) connection.
subnetIds
— (Array<String>
)The subnet IDs of the VPC destination.
securityGroups
— (Array<String>
)The security groups of the VPC destination.
vpcId
— (String
)The ID of the VPC.
roleArn
— (String
)The ARN of a role that has permission to create and attach to elastic network interfaces (ENIs).
-
(AWS.Response)
—
Returns:
getV2LoggingOptions(params = {}, callback) ⇒ AWS.Request
Gets the fine grained logging options.
Requires permission to access the GetV2LoggingOptions action.
Service Reference:
Examples:
Calling the getV2LoggingOptions operation
var params = { }; iot.getV2LoggingOptions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleArn
— (String
)The IAM role ARN IoT uses to write to your CloudWatch logs.
defaultLogLevel
— (String
)The default log level.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
disableAllLogs
— (Boolean
)Disables all logs.
-
(AWS.Response)
—
Returns:
listActiveViolations(params = {}, callback) ⇒ AWS.Request
Lists the active violations for a given Device Defender security profile.
Requires permission to access the ListActiveViolations action.
Service Reference:
Examples:
Calling the listActiveViolations operation
var params = { behaviorCriteriaType: STATIC | STATISTICAL | MACHINE_LEARNING, listSuppressedAlerts: true || false, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', securityProfileName: 'STRING_VALUE', thingName: 'STRING_VALUE', verificationState: FALSE_POSITIVE | BENIGN_POSITIVE | TRUE_POSITIVE | UNKNOWN }; iot.listActiveViolations(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing whose active violations are listed.
securityProfileName
— (String
)The name of the Device Defender security profile for which violations are listed.
behaviorCriteriaType
— (String
)The criteria for a behavior.
Possible values include:"STATIC"
"STATISTICAL"
"MACHINE_LEARNING"
listSuppressedAlerts
— (Boolean
)A list of all suppressed alerts.
verificationState
— (String
)The verification state of the violation (detect alarm).
Possible values include:"FALSE_POSITIVE"
"BENIGN_POSITIVE"
"TRUE_POSITIVE"
"UNKNOWN"
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:activeViolations
— (Array<map>
)The list of active violations.
violationId
— (String
)The ID of the active violation.
thingName
— (String
)The name of the thing responsible for the active violation.
securityProfileName
— (String
)The security profile with the behavior is in violation.
behavior
— (map
)The behavior that is being violated.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
lastViolationValue
— (map
)The value of the metric (the measurement) that caused the most recent violation.
count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
violationEventAdditionalInfo
— (map
)The details of a violation event.
confidenceLevel
— (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
verificationState
— (String
)The verification state of the violation (detect alarm).
Possible values include:"FALSE_POSITIVE"
"BENIGN_POSITIVE"
"TRUE_POSITIVE"
"UNKNOWN"
verificationStateDescription
— (String
)The description of the verification state of the violation.
lastViolationTime
— (Date
)The time the most recent violation occurred.
violationStartTime
— (Date
)The time the violation started.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listAttachedPolicies(params = {}, callback) ⇒ AWS.Request
Lists the policies attached to the specified thing group.
Requires permission to access the ListAttachedPolicies action.
Service Reference:
Examples:
Calling the listAttachedPolicies operation
var params = { target: 'STRING_VALUE', /* required */ marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE', recursive: true || false }; iot.listAttachedPolicies(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
target
— (String
)The group or principal for which the policies will be listed. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
recursive
— (Boolean
)When true, recursively list attached policies.
marker
— (String
)The token to retrieve the next set of results.
pageSize
— (Integer
)The maximum number of results to be returned per request.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policies
— (Array<map>
)The policies.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
nextMarker
— (String
)The token to retrieve the next set of results, or
null
if there are no more results.
-
(AWS.Response)
—
Returns:
listAuditFindings(params = {}, callback) ⇒ AWS.Request
Lists the findings (results) of a Device Defender audit or of the audits performed during a specified time period. (Findings are retained for 90 days.)
Requires permission to access the ListAuditFindings action.
Service Reference:
Examples:
Calling the listAuditFindings operation
var params = { checkName: 'STRING_VALUE', endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, listSuppressedFindings: true || false, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', resourceIdentifier: { account: 'STRING_VALUE', caCertificateId: 'STRING_VALUE', clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', deviceCertificateArn: 'STRING_VALUE', deviceCertificateId: 'STRING_VALUE', iamRoleArn: 'STRING_VALUE', issuerCertificateIdentifier: { issuerCertificateSerialNumber: 'STRING_VALUE', issuerCertificateSubject: 'STRING_VALUE', issuerId: 'STRING_VALUE' }, policyVersionIdentifier: { policyName: 'STRING_VALUE', policyVersionId: 'STRING_VALUE' }, roleAliasArn: 'STRING_VALUE' }, startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, taskId: 'STRING_VALUE' }; iot.listAuditFindings(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)A filter to limit results to the audit with the specified ID. You must specify either the taskId or the startTime and endTime, but not both.
checkName
— (String
)A filter to limit results to the findings for the specified audit check.
resourceIdentifier
— (map
)Information identifying the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
nextToken
— (String
)The token for the next set of results.
startTime
— (Date
)A filter to limit results to those found after the specified time. You must specify either the startTime and endTime or the taskId, but not both.
endTime
— (Date
)A filter to limit results to those found before the specified time. You must specify either the startTime and endTime or the taskId, but not both.
listSuppressedFindings
— (Boolean
)Boolean flag indicating whether only the suppressed findings or the unsuppressed findings should be listed. If this parameter isn't provided, the response will list both suppressed and unsuppressed findings.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:findings
— (Array<map>
)The findings (results) of the audit.
findingId
— (String
)A unique identifier for this set of audit findings. This identifier is used to apply mitigation tasks to one or more sets of findings.
taskId
— (String
)The ID of the audit that generated this result (finding).
checkName
— (String
)The audit check that generated this result.
taskStartTime
— (Date
)The time the audit started.
findingTime
— (Date
)The time the result (finding) was discovered.
severity
— (String
)The severity of the result (finding).
Possible values include:"CRITICAL"
"HIGH"
"MEDIUM"
"LOW"
nonCompliantResource
— (map
)The resource that was found to be noncompliant with the audit check.
resourceType
— (String
)The type of the noncompliant resource.
Possible values include:"DEVICE_CERTIFICATE"
"CA_CERTIFICATE"
"IOT_POLICY"
"COGNITO_IDENTITY_POOL"
"CLIENT_ID"
"ACCOUNT_SETTINGS"
"ROLE_ALIAS"
"IAM_ROLE"
"ISSUER_CERTIFICATE"
resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
additionalInfo
— (map<String>
)Other information about the noncompliant resource.
relatedResources
— (Array<map>
)The list of related resources.
resourceType
— (String
)The type of resource.
Possible values include:"DEVICE_CERTIFICATE"
"CA_CERTIFICATE"
"IOT_POLICY"
"COGNITO_IDENTITY_POOL"
"CLIENT_ID"
"ACCOUNT_SETTINGS"
"ROLE_ALIAS"
"IAM_ROLE"
"ISSUER_CERTIFICATE"
resourceIdentifier
— (map
)Information that identifies the resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
additionalInfo
— (map<String>
)Other information about the resource.
reasonForNonCompliance
— (String
)The reason the resource was noncompliant.
reasonForNonComplianceCode
— (String
)A code that indicates the reason that the resource was noncompliant.
isSuppressed
— (Boolean
)Indicates whether the audit finding was suppressed or not during reporting.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listAuditMitigationActionsExecutions(params = {}, callback) ⇒ AWS.Request
Gets the status of audit mitigation action tasks that were executed.
Requires permission to access the ListAuditMitigationActionsExecutions action.
Service Reference:
Examples:
Calling the listAuditMitigationActionsExecutions operation
var params = { findingId: 'STRING_VALUE', /* required */ taskId: 'STRING_VALUE', /* required */ actionStatus: IN_PROGRESS | COMPLETED | FAILED | CANCELED | SKIPPED | PENDING, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listAuditMitigationActionsExecutions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)Specify this filter to limit results to actions for a specific audit mitigation actions task.
actionStatus
— (String
)Specify this filter to limit results to those with a specific status.
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
"SKIPPED"
"PENDING"
findingId
— (String
)Specify this filter to limit results to those that were applied to a specific audit finding.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:actionsExecutions
— (Array<map>
)A set of task execution results based on the input parameters. Details include the mitigation action applied, start time, and task status.
taskId
— (String
)The unique identifier for the task that applies the mitigation action.
findingId
— (String
)The unique identifier for the findings to which the task and associated mitigation action are applied.
actionName
— (String
)The friendly name of the mitigation action being applied by the task.
actionId
— (String
)The unique identifier for the mitigation action being applied by the task.
status
— (String
)The current status of the task being executed.
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
"SKIPPED"
"PENDING"
startTime
— (Date
)The date and time when the task was started.
endTime
— (Date
)The date and time when the task was completed or canceled. Blank if the task is still running.
errorCode
— (String
)If an error occurred, the code that indicates which type of error occurred.
message
— (String
)If an error occurred, a message that describes the error.
nextToken
— (String
)The token for the next set of results.
-
(AWS.Response)
—
Returns:
listAuditMitigationActionsTasks(params = {}, callback) ⇒ AWS.Request
Gets a list of audit mitigation action tasks that match the specified filters.
Requires permission to access the ListAuditMitigationActionsTasks action.
Service Reference:
Examples:
Calling the listAuditMitigationActionsTasks operation
var params = { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ auditTaskId: 'STRING_VALUE', findingId: 'STRING_VALUE', maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', taskStatus: IN_PROGRESS | COMPLETED | FAILED | CANCELED }; iot.listAuditMitigationActionsTasks(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
auditTaskId
— (String
)Specify this filter to limit results to tasks that were applied to results for a specific audit.
findingId
— (String
)Specify this filter to limit results to tasks that were applied to a specific audit finding.
taskStatus
— (String
)Specify this filter to limit results to tasks that are in a specific state.
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
nextToken
— (String
)The token for the next set of results.
startTime
— (Date
)Specify this filter to limit results to tasks that began on or after a specific date and time.
endTime
— (Date
)Specify this filter to limit results to tasks that were completed or canceled on or before a specific date and time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:tasks
— (Array<map>
)The collection of audit mitigation tasks that matched the filter criteria.
taskId
— (String
)The unique identifier for the task.
startTime
— (Date
)The time at which the audit mitigation actions task was started.
taskStatus
— (String
)The current state of the audit mitigation actions task.
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
nextToken
— (String
)The token for the next set of results.
-
(AWS.Response)
—
Returns:
listAuditSuppressions(params = {}, callback) ⇒ AWS.Request
Lists your Device Defender audit listings.
Requires permission to access the ListAuditSuppressions action.
Service Reference:
Examples:
Calling the listAuditSuppressions operation
var params = { ascendingOrder: true || false, checkName: 'STRING_VALUE', maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', resourceIdentifier: { account: 'STRING_VALUE', caCertificateId: 'STRING_VALUE', clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', deviceCertificateArn: 'STRING_VALUE', deviceCertificateId: 'STRING_VALUE', iamRoleArn: 'STRING_VALUE', issuerCertificateIdentifier: { issuerCertificateSerialNumber: 'STRING_VALUE', issuerCertificateSubject: 'STRING_VALUE', issuerId: 'STRING_VALUE' }, policyVersionIdentifier: { policyName: 'STRING_VALUE', policyVersionId: 'STRING_VALUE' }, roleAliasArn: 'STRING_VALUE' } }; iot.listAuditSuppressions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
checkName
— (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
ascendingOrder
— (Boolean
)Determines whether suppressions are listed in ascending order by expiration date or not. If parameter isn't provided,
ascendingOrder=true
.nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:suppressions
— (Array<map>
)List of audit suppressions.
checkName
— required — (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— required — (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
expirationDate
— (Date
)The expiration date (epoch timestamp in seconds) that you want the suppression to adhere to.
suppressIndefinitely
— (Boolean
)Indicates whether a suppression should exist indefinitely or not.
description
— (String
)The description of the audit suppression.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listAuditTasks(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender audits that have been performed during a given time period.
Requires permission to access the ListAuditTasks action.
Service Reference:
Examples:
Calling the listAuditTasks operation
var params = { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', taskStatus: IN_PROGRESS | COMPLETED | FAILED | CANCELED, taskType: ON_DEMAND_AUDIT_TASK | SCHEDULED_AUDIT_TASK }; iot.listAuditTasks(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
startTime
— (Date
)The beginning of the time period. Audit information is retained for a limited time (90 days). Requesting a start time prior to what is retained results in an "InvalidRequestException".
endTime
— (Date
)The end of the time period.
taskType
— (String
)A filter to limit the output to the specified type of audit: can be one of "ON_DEMAND_AUDIT_TASK" or "SCHEDULED__AUDIT_TASK".
Possible values include:"ON_DEMAND_AUDIT_TASK"
"SCHEDULED_AUDIT_TASK"
taskStatus
— (String
)A filter to limit the output to audits with the specified completion status: can be one of "IN_PROGRESS", "COMPLETED", "FAILED", or "CANCELED".
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:tasks
— (Array<map>
)The audits that were performed during the specified time period.
taskId
— (String
)The ID of this audit.
taskStatus
— (String
)The status of this audit. One of "IN_PROGRESS", "COMPLETED", "FAILED", or "CANCELED".
Possible values include:"IN_PROGRESS"
"COMPLETED"
"FAILED"
"CANCELED"
taskType
— (String
)The type of this audit. One of "ON_DEMAND_AUDIT_TASK" or "SCHEDULED_AUDIT_TASK".
Possible values include:"ON_DEMAND_AUDIT_TASK"
"SCHEDULED_AUDIT_TASK"
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listAuthorizers(params = {}, callback) ⇒ AWS.Request
Lists the authorizers registered in your account.
Requires permission to access the ListAuthorizers action.
Service Reference:
Examples:
Calling the listAuthorizers operation
var params = { ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE', status: ACTIVE | INACTIVE }; iot.listAuthorizers(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
pageSize
— (Integer
)The maximum number of results to return at one time.
marker
— (String
)A marker used to get the next set of results.
ascendingOrder
— (Boolean
)Return the list of authorizers in ascending alphabetical order.
status
— (String
)The status of the list authorizers request.
Possible values include:"ACTIVE"
"INACTIVE"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authorizers
— (Array<map>
)The authorizers.
authorizerName
— (String
)The authorizer name.
authorizerArn
— (String
)The authorizer ARN.
nextMarker
— (String
)A marker used to get the next set of results.
-
(AWS.Response)
—
Returns:
listBillingGroups(params = {}, callback) ⇒ AWS.Request
Lists the billing groups you have created.
Requires permission to access the ListBillingGroups action.
Service Reference:
Examples:
Calling the listBillingGroups operation
var params = { maxResults: 'NUMBER_VALUE', namePrefixFilter: 'STRING_VALUE', nextToken: 'STRING_VALUE' }; iot.listBillingGroups(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return per request.
namePrefixFilter
— (String
)Limit the results to billing groups whose names have the given prefix.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:billingGroups
— (Array<map>
)The list of billing groups.
groupName
— (String
)The group name.
groupArn
— (String
)The group ARN.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listCACertificates(params = {}, callback) ⇒ AWS.Request
Lists the CA certificates registered for your Amazon Web Services account.
The results are paginated with a default page size of 25. You can use the returned marker to retrieve additional results.
Requires permission to access the ListCACertificates action.
Service Reference:
Examples:
Calling the listCACertificates operation
var params = { ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE', templateName: 'STRING_VALUE' }; iot.listCACertificates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
pageSize
— (Integer
)The result page size.
marker
— (String
)The marker for the next set of results.
ascendingOrder
— (Boolean
)Determines the order of the results.
templateName
— (String
)The name of the provisioning template.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificates
— (Array<map>
)The CA certificates registered in your Amazon Web Services account.
certificateArn
— (String
)The ARN of the CA certificate.
certificateId
— (String
)The ID of the CA certificate.
status
— (String
)The status of the CA certificate.
The status value REGISTER_INACTIVE is deprecated and should not be used.
Possible values include:"ACTIVE"
"INACTIVE"
creationDate
— (Date
)The date the CA certificate was created.
nextMarker
— (String
)The current position within the list of CA certificates.
-
(AWS.Response)
—
Returns:
listCertificateProviders(params = {}, callback) ⇒ AWS.Request
Lists all your certificate providers in your Amazon Web Services account.
Requires permission to access the ListCertificateProviders action.
Service Reference:
Examples:
Calling the listCertificateProviders operation
var params = { ascendingOrder: true || false, nextToken: 'STRING_VALUE' }; iot.listCertificateProviders(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token for the next set of results, or
null
if there are no more results.ascendingOrder
— (Boolean
)Returns the list of certificate providers in ascending alphabetical order.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateProviders
— (Array<map>
)The list of certificate providers in your Amazon Web Services account.
certificateProviderName
— (String
)The name of the certificate provider.
certificateProviderArn
— (String
)The ARN of the certificate provider.
nextToken
— (String
)The token for the next set of results, or
null
if there are no more results.
-
(AWS.Response)
—
Returns:
listCertificates(params = {}, callback) ⇒ AWS.Request
Lists the certificates registered in your Amazon Web Services account.
The results are paginated with a default page size of 25. You can use the returned marker to retrieve additional results.
Requires permission to access the ListCertificates action.
Service Reference:
Examples:
Calling the listCertificates operation
var params = { ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listCertificates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
pageSize
— (Integer
)The result page size.
marker
— (String
)The marker for the next set of results.
ascendingOrder
— (Boolean
)Specifies the order for results. If True, the results are returned in ascending order, based on the creation date.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificates
— (Array<map>
)The descriptions of the certificates.
certificateArn
— (String
)The ARN of the certificate.
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
status
— (String
)The status of the certificate.
The status value REGISTER_INACTIVE is deprecated and should not be used.
Possible values include:"ACTIVE"
"INACTIVE"
"REVOKED"
"PENDING_TRANSFER"
"REGISTER_INACTIVE"
"PENDING_ACTIVATION"
certificateMode
— (String
)The mode of the certificate.
DEFAULT
: A certificate inDEFAULT
mode is either generated by Amazon Web Services IoT Core or registered with an issuer certificate authority (CA) inDEFAULT
mode. Devices with certificates inDEFAULT
mode aren't required to send the Server Name Indication (SNI) extension when connecting to Amazon Web Services IoT Core. However, to use features such as custom domains and VPC endpoints, we recommend that you use the SNI extension when connecting to Amazon Web Services IoT Core.SNI_ONLY
: A certificate inSNI_ONLY
mode is registered without an issuer CA. Devices with certificates inSNI_ONLY
mode must send the SNI extension when connecting to Amazon Web Services IoT Core."DEFAULT"
"SNI_ONLY"
creationDate
— (Date
)The date and time the certificate was created.
nextMarker
— (String
)The marker for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listCertificatesByCA(params = {}, callback) ⇒ AWS.Request
List the device certificates signed by the specified CA certificate.
Requires permission to access the ListCertificatesByCA action.
Service Reference:
Examples:
Calling the listCertificatesByCA operation
var params = { caCertificateId: 'STRING_VALUE', /* required */ ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listCertificatesByCA(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
caCertificateId
— (String
)The ID of the CA certificate. This operation will list all registered device certificate that were signed by this CA certificate.
pageSize
— (Integer
)The result page size.
marker
— (String
)The marker for the next set of results.
ascendingOrder
— (Boolean
)Specifies the order for results. If True, the results are returned in ascending order, based on the creation date.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificates
— (Array<map>
)The device certificates signed by the specified CA certificate.
certificateArn
— (String
)The ARN of the certificate.
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
status
— (String
)The status of the certificate.
The status value REGISTER_INACTIVE is deprecated and should not be used.
Possible values include:"ACTIVE"
"INACTIVE"
"REVOKED"
"PENDING_TRANSFER"
"REGISTER_INACTIVE"
"PENDING_ACTIVATION"
certificateMode
— (String
)The mode of the certificate.
DEFAULT
: A certificate inDEFAULT
mode is either generated by Amazon Web Services IoT Core or registered with an issuer certificate authority (CA) inDEFAULT
mode. Devices with certificates inDEFAULT
mode aren't required to send the Server Name Indication (SNI) extension when connecting to Amazon Web Services IoT Core. However, to use features such as custom domains and VPC endpoints, we recommend that you use the SNI extension when connecting to Amazon Web Services IoT Core.SNI_ONLY
: A certificate inSNI_ONLY
mode is registered without an issuer CA. Devices with certificates inSNI_ONLY
mode must send the SNI extension when connecting to Amazon Web Services IoT Core."DEFAULT"
"SNI_ONLY"
creationDate
— (Date
)The date and time the certificate was created.
nextMarker
— (String
)The marker for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listCustomMetrics(params = {}, callback) ⇒ AWS.Request
Lists your Device Defender detect custom metrics.
Requires permission to access the ListCustomMetrics action.
Service Reference:
Examples:
Calling the listCustomMetrics operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listCustomMetrics(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricNames
— (Array<String>
)The name of the custom metric.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listDetectMitigationActionsExecutions(params = {}, callback) ⇒ AWS.Request
Lists mitigation actions executions for a Device Defender ML Detect Security Profile.
Requires permission to access the ListDetectMitigationActionsExecutions action.
Service Reference:
Examples:
Calling the listDetectMitigationActionsExecutions operation
var params = { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, taskId: 'STRING_VALUE', thingName: 'STRING_VALUE', violationId: 'STRING_VALUE' }; iot.listDetectMitigationActionsExecutions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The unique identifier of the task.
violationId
— (String
)The unique identifier of the violation.
thingName
— (String
)The name of the thing whose mitigation actions are listed.
startTime
— (Date
)A filter to limit results to those found after the specified time. You must specify either the startTime and endTime or the taskId, but not both.
endTime
— (Date
)The end of the time period for which ML Detect mitigation actions executions are returned.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:actionsExecutions
— (Array<map>
)List of actions executions.
taskId
— (String
)The unique identifier of the task.
violationId
— (String
)The unique identifier of the violation.
actionName
— (String
)The friendly name that uniquely identifies the mitigation action.
thingName
— (String
)The name of the thing.
executionStartDate
— (Date
)The date a mitigation action was started.
executionEndDate
— (Date
)The date a mitigation action ended.
status
— (String
)The status of a mitigation action.
Possible values include:"IN_PROGRESS"
"SUCCESSFUL"
"FAILED"
"SKIPPED"
errorCode
— (String
)The error code of a mitigation action.
message
— (String
)The message of a mitigation action.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listDetectMitigationActionsTasks(params = {}, callback) ⇒ AWS.Request
List of Device Defender ML Detect mitigation actions tasks.
Requires permission to access the ListDetectMitigationActionsTasks action.
Service Reference:
Examples:
Calling the listDetectMitigationActionsTasks operation
var params = { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listDetectMitigationActionsTasks(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
nextToken
— (String
)The token for the next set of results.
startTime
— (Date
)A filter to limit results to those found after the specified time. You must specify either the startTime and endTime or the taskId, but not both.
endTime
— (Date
)The end of the time period for which ML Detect mitigation actions tasks are returned.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:tasks
— (Array<map>
)The collection of ML Detect mitigation tasks that matched the filter criteria.
taskId
— (String
)The unique identifier of the task.
taskStatus
— (String
)The status of the task.
Possible values include:"IN_PROGRESS"
"SUCCESSFUL"
"FAILED"
"CANCELED"
taskStartTime
— (Date
)The date the task started.
taskEndTime
— (Date
)The date the task ended.
target
— (map
)Specifies the ML Detect findings to which the mitigation actions are applied.
violationIds
— (Array<String>
)The unique identifiers of the violations.
securityProfileName
— (String
)The name of the security profile.
behaviorName
— (String
)The name of the behavior.
violationEventOccurrenceRange
— (map
)Specifies the time period of which violation events occurred between.
startTime
— required — (Date
)The start date and time of a time period in which violation events occurred.
endTime
— required — (Date
)The end date and time of a time period in which violation events occurred.
onlyActiveViolationsIncluded
— (Boolean
)Includes only active violations.
suppressedAlertsIncluded
— (Boolean
)Includes suppressed alerts.
actionsDefinition
— (Array<map>
)The definition of the actions.
name
— (String
)A user-friendly name for the mitigation action.
id
— (String
)A unique identifier for the mitigation action.
roleArn
— (String
)The IAM role ARN used to apply this mitigation action.
actionParams
— (map
)The set of parameters for this mitigation action. The parameters vary, depending on the kind of action you apply.
updateDeviceCertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the device certificate to inactive.
action
— required — (String
)The action that you want to apply to the device certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
updateCACertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the CA certificate to inactive.
action
— required — (String
)The action that you want to apply to the CA certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
addThingsToThingGroupParams
— (map
)Parameters to define a mitigation action that moves devices associated with a certificate to one or more specified thing groups, typically for quarantine.
thingGroupNames
— required — (Array<String>
)The list of groups to which you want to add the things that triggered the mitigation action. You can add a thing to a maximum of 10 groups, but you can't add a thing to more than one group in the same hierarchy.
overrideDynamicGroups
— (Boolean
)Specifies if this mitigation action can move the things that triggered the mitigation action even if they are part of one or more dynamic thing groups.
replaceDefaultPolicyVersionParams
— (map
)Parameters to define a mitigation action that adds a blank policy to restrict permissions.
templateName
— required — (String
)The name of the template to be applied. The only supported value is
Possible values include:BLANK_POLICY
."BLANK_POLICY"
enableIoTLoggingParams
— (map
)Parameters to define a mitigation action that enables Amazon Web Services IoT Core logging at a specified level of detail.
roleArnForLogging
— required — (String
)The Amazon Resource Name (ARN) of the IAM role used for logging.
logLevel
— required — (String
)Specifies the type of information to be logged.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
publishFindingToSnsParams
— (map
)Parameters to define a mitigation action that publishes findings to Amazon Simple Notification Service (Amazon SNS. You can implement your own custom actions in response to the Amazon SNS messages.
topicArn
— required — (String
)The ARN of the topic to which you want to publish the findings.
taskStatistics
— (map
)The statistics of a mitigation action task.
actionsExecuted
— (Integer
)The actions that were performed.
actionsSkipped
— (Integer
)The actions that were skipped.
actionsFailed
— (Integer
)The actions that failed.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listDimensions(params = {}, callback) ⇒ AWS.Request
List the set of dimensions that are defined for your Amazon Web Services accounts.
Requires permission to access the ListDimensions action.
Service Reference:
Examples:
Calling the listDimensions operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listDimensions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to retrieve at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:dimensionNames
— (Array<String>
)A list of the names of the defined dimensions. Use
DescribeDimension
to get details for a dimension.nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listDomainConfigurations(params = {}, callback) ⇒ AWS.Request
Gets a list of domain configurations for the user. This list is sorted alphabetically by domain configuration name.
Requires permission to access the ListDomainConfigurations action.
Service Reference:
Examples:
Calling the listDomainConfigurations operation
var params = { marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE', serviceType: DATA | CREDENTIAL_PROVIDER | JOBS }; iot.listDomainConfigurations(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
marker
— (String
)The marker for the next set of results.
pageSize
— (Integer
)The result page size.
serviceType
— (String
)The type of service delivered by the endpoint.
Possible values include:"DATA"
"CREDENTIAL_PROVIDER"
"JOBS"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:domainConfigurations
— (Array<map>
)A list of objects that contain summary information about the user's domain configurations.
domainConfigurationName
— (String
)The name of the domain configuration. This value must be unique to a region.
domainConfigurationArn
— (String
)The ARN of the domain configuration.
serviceType
— (String
)The type of service delivered by the endpoint.
Possible values include:"DATA"
"CREDENTIAL_PROVIDER"
"JOBS"
nextMarker
— (String
)The marker for the next set of results.
-
(AWS.Response)
—
Returns:
listFleetMetrics(params = {}, callback) ⇒ AWS.Request
Lists all your fleet metrics.
Requires permission to access the ListFleetMetrics action.
Service Reference:
Examples:
Calling the listFleetMetrics operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listFleetMetrics(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwisenull
to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return in this operation.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:fleetMetrics
— (Array<map>
)The list of fleet metrics objects.
metricName
— (String
)The fleet metric name.
metricArn
— (String
)The fleet metric ARN.
nextToken
— (String
)The token for the next set of results. Will not be returned if the operation has returned all results.
-
(AWS.Response)
—
Returns:
listIndices(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the listIndices operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listIndices(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token used to get the next set of results, or
null
if there are no additional results.maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:indexNames
— (Array<String>
)The index names.
nextToken
— (String
)The token used to get the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listJobExecutionsForJob(params = {}, callback) ⇒ AWS.Request
Lists the job executions for a job.
Requires permission to access the ListJobExecutionsForJob action.
Service Reference:
Examples:
Calling the listJobExecutionsForJob operation
var params = { jobId: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', status: QUEUED | IN_PROGRESS | SUCCEEDED | FAILED | TIMED_OUT | REJECTED | REMOVED | CANCELED }; iot.listJobExecutionsForJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The unique identifier you assigned to this job when it was created.
status
— (String
)The status of the job.
Possible values include:"QUEUED"
"IN_PROGRESS"
"SUCCEEDED"
"FAILED"
"TIMED_OUT"
"REJECTED"
"REMOVED"
"CANCELED"
maxResults
— (Integer
)The maximum number of results to be returned per request.
nextToken
— (String
)The token to retrieve the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:executionSummaries
— (Array<map>
)A list of job execution summaries.
thingArn
— (String
)The ARN of the thing on which the job execution is running.
jobExecutionSummary
— (map
)Contains a subset of information about a job execution.
status
— (String
)The status of the job execution.
Possible values include:"QUEUED"
"IN_PROGRESS"
"SUCCEEDED"
"FAILED"
"TIMED_OUT"
"REJECTED"
"REMOVED"
"CANCELED"
queuedAt
— (Date
)The time, in seconds since the epoch, when the job execution was queued.
startedAt
— (Date
)The time, in seconds since the epoch, when the job execution started.
lastUpdatedAt
— (Date
)The time, in seconds since the epoch, when the job execution was last updated.
executionNumber
— (Integer
)A string (consisting of the digits "0" through "9") which identifies this particular job execution on this particular device. It can be used later in commands which return or update job execution information.
retryAttempt
— (Integer
)The number that indicates how many retry attempts have been completed for this job on this device.
nextToken
— (String
)The token for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listJobExecutionsForThing(params = {}, callback) ⇒ AWS.Request
Lists the job executions for the specified thing.
Requires permission to access the ListJobExecutionsForThing action.
Service Reference:
Examples:
Calling the listJobExecutionsForThing operation
var params = { thingName: 'STRING_VALUE', /* required */ jobId: 'STRING_VALUE', maxResults: 'NUMBER_VALUE', namespaceId: 'STRING_VALUE', nextToken: 'STRING_VALUE', status: QUEUED | IN_PROGRESS | SUCCEEDED | FAILED | TIMED_OUT | REJECTED | REMOVED | CANCELED }; iot.listJobExecutionsForThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The thing name.
status
— (String
)An optional filter that lets you search for jobs that have the specified status.
Possible values include:"QUEUED"
"IN_PROGRESS"
"SUCCEEDED"
"FAILED"
"TIMED_OUT"
"REJECTED"
"REMOVED"
"CANCELED"
namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.maxResults
— (Integer
)The maximum number of results to be returned per request.
nextToken
— (String
)The token to retrieve the next set of results.
jobId
— (String
)The unique identifier you assigned to this job when it was created.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:executionSummaries
— (Array<map>
)A list of job execution summaries.
jobId
— (String
)The unique identifier you assigned to this job when it was created.
jobExecutionSummary
— (map
)Contains a subset of information about a job execution.
status
— (String
)The status of the job execution.
Possible values include:"QUEUED"
"IN_PROGRESS"
"SUCCEEDED"
"FAILED"
"TIMED_OUT"
"REJECTED"
"REMOVED"
"CANCELED"
queuedAt
— (Date
)The time, in seconds since the epoch, when the job execution was queued.
startedAt
— (Date
)The time, in seconds since the epoch, when the job execution started.
lastUpdatedAt
— (Date
)The time, in seconds since the epoch, when the job execution was last updated.
executionNumber
— (Integer
)A string (consisting of the digits "0" through "9") which identifies this particular job execution on this particular device. It can be used later in commands which return or update job execution information.
retryAttempt
— (Integer
)The number that indicates how many retry attempts have been completed for this job on this device.
nextToken
— (String
)The token for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listJobs(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the listJobs operation
var params = { maxResults: 'NUMBER_VALUE', namespaceId: 'STRING_VALUE', nextToken: 'STRING_VALUE', status: IN_PROGRESS | CANCELED | COMPLETED | DELETION_IN_PROGRESS | SCHEDULED, targetSelection: CONTINUOUS | SNAPSHOT, thingGroupId: 'STRING_VALUE', thingGroupName: 'STRING_VALUE' }; iot.listJobs(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
status
— (String
)An optional filter that lets you search for jobs that have the specified status.
Possible values include:"IN_PROGRESS"
"CANCELED"
"COMPLETED"
"DELETION_IN_PROGRESS"
"SCHEDULED"
targetSelection
— (String
)Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a thing when the thing is added to a target group, even after the job was completed by all things originally in the group.
Note: We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.Possible values include:"CONTINUOUS"
"SNAPSHOT"
maxResults
— (Integer
)The maximum number of results to return per request.
nextToken
— (String
)The token to retrieve the next set of results.
thingGroupName
— (String
)A filter that limits the returned jobs to those for the specified group.
thingGroupId
— (String
)A filter that limits the returned jobs to those for the specified group.
namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:jobs
— (Array<map>
)A list of jobs.
jobArn
— (String
)The job ARN.
jobId
— (String
)The unique identifier you assigned to this job when it was created.
thingGroupId
— (String
)The ID of the thing group.
targetSelection
— (String
)Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a thing when the thing is added to a target group, even after the job was completed by all things originally in the group.
Note: We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.Possible values include:"CONTINUOUS"
"SNAPSHOT"
status
— (String
)The job summary status.
Possible values include:"IN_PROGRESS"
"CANCELED"
"COMPLETED"
"DELETION_IN_PROGRESS"
"SCHEDULED"
createdAt
— (Date
)The time, in seconds since the epoch, when the job was created.
lastUpdatedAt
— (Date
)The time, in seconds since the epoch, when the job was last updated.
completedAt
— (Date
)The time, in seconds since the epoch, when the job completed.
isConcurrent
— (Boolean
)Indicates whether a job is concurrent. Will be true when a job is rolling out new job executions or canceling previously created executions, otherwise false.
nextToken
— (String
)The token for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listJobTemplates(params = {}, callback) ⇒ AWS.Request
Returns a list of job templates.
Requires permission to access the ListJobTemplates action.
Service Reference:
Examples:
Calling the listJobTemplates operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listJobTemplates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results to return in the list.
nextToken
— (String
)The token to use to return the next set of results in the list.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:jobTemplates
— (Array<map>
)A list of objects that contain information about the job templates.
jobTemplateArn
— (String
)The ARN of the job template.
jobTemplateId
— (String
)The unique identifier of the job template.
description
— (String
)A description of the job template.
createdAt
— (Date
)The time, in seconds since the epoch, when the job template was created.
nextToken
— (String
)The token for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listManagedJobTemplates(params = {}, callback) ⇒ AWS.Request
Returns a list of managed job templates.
Service Reference:
Examples:
Calling the listManagedJobTemplates operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', templateName: 'STRING_VALUE' }; iot.listManagedJobTemplates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)An optional parameter for template name. If specified, only the versions of the managed job templates that have the specified template name will be returned.
maxResults
— (Integer
)Maximum number of entries that can be returned.
nextToken
— (String
)The token to retrieve the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:managedJobTemplates
— (Array<map>
)A list of managed job templates that are returned.
templateArn
— (String
)The Amazon Resource Name (ARN) for a managed template.
templateName
— (String
)The unique Name for a managed template.
description
— (String
)The description for a managed template.
environments
— (Array<String>
)A list of environments that are supported with the managed job template.
templateVersion
— (String
)The version for a managed template.
nextToken
— (String
)The token to retrieve the next set of results.
-
(AWS.Response)
—
Returns:
listMetricValues(params = {}, callback) ⇒ AWS.Request
Lists the values reported for an IoT Device Defender metric (device-side metric, cloud-side metric, or custom metric) by the given thing during the specified time period.
Service Reference:
Examples:
Calling the listMetricValues operation
var params = { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ metricName: 'STRING_VALUE', /* required */ startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ thingName: 'STRING_VALUE', /* required */ dimensionName: 'STRING_VALUE', dimensionValueOperator: IN | NOT_IN, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listMetricValues(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The name of the thing for which security profile metric values are returned.
metricName
— (String
)The name of the security profile metric for which values are returned.
dimensionName
— (String
)The dimension name.
dimensionValueOperator
— (String
)The dimension value operator.
Possible values include:"IN"
"NOT_IN"
startTime
— (Date
)The start of the time period for which metric values are returned.
endTime
— (Date
)The end of the time period for which metric values are returned.
maxResults
— (Integer
)The maximum number of results to return at one time.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricDatumList
— (Array<map>
)The data the thing reports for the metric during the specified time period.
timestamp
— (Date
)The time the metric value was reported.
value
— (map
)The value reported for the metric.
count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listMitigationActions(params = {}, callback) ⇒ AWS.Request
Gets a list of all mitigation actions that match the specified filter criteria.
Requires permission to access the ListMitigationActions action.
Service Reference:
Examples:
Calling the listMitigationActions operation
var params = { actionType: UPDATE_DEVICE_CERTIFICATE | UPDATE_CA_CERTIFICATE | ADD_THINGS_TO_THING_GROUP | REPLACE_DEFAULT_POLICY_VERSION | ENABLE_IOT_LOGGING | PUBLISH_FINDING_TO_SNS, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listMitigationActions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
actionType
— (String
)Specify a value to limit the result to mitigation actions with a specific action type.
Possible values include:"UPDATE_DEVICE_CERTIFICATE"
"UPDATE_CA_CERTIFICATE"
"ADD_THINGS_TO_THING_GROUP"
"REPLACE_DEFAULT_POLICY_VERSION"
"ENABLE_IOT_LOGGING"
"PUBLISH_FINDING_TO_SNS"
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:actionIdentifiers
— (Array<map>
)A set of actions that matched the specified filter criteria.
actionName
— (String
)The friendly name of the mitigation action.
actionArn
— (String
)The IAM role ARN used to apply this mitigation action.
creationDate
— (Date
)The date when this mitigation action was created.
nextToken
— (String
)The token for the next set of results.
-
(AWS.Response)
—
Returns:
listOTAUpdates(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the listOTAUpdates operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', otaUpdateStatus: CREATE_PENDING | CREATE_IN_PROGRESS | CREATE_COMPLETE | CREATE_FAILED | DELETE_IN_PROGRESS | DELETE_FAILED }; iot.listOTAUpdates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results to return at one time.
nextToken
— (String
)A token used to retrieve the next set of results.
otaUpdateStatus
— (String
)The OTA update job status.
Possible values include:"CREATE_PENDING"
"CREATE_IN_PROGRESS"
"CREATE_COMPLETE"
"CREATE_FAILED"
"DELETE_IN_PROGRESS"
"DELETE_FAILED"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:otaUpdates
— (Array<map>
)A list of OTA update jobs.
otaUpdateId
— (String
)The OTA update ID.
otaUpdateArn
— (String
)The OTA update ARN.
creationDate
— (Date
)The date when the OTA update was created.
nextToken
— (String
)A token to use to get the next set of results.
-
(AWS.Response)
—
Returns:
listOutgoingCertificates(params = {}, callback) ⇒ AWS.Request
Lists certificates that are being transferred but not yet accepted.
Requires permission to access the ListOutgoingCertificates action.
Service Reference:
Examples:
Calling the listOutgoingCertificates operation
var params = { ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listOutgoingCertificates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
pageSize
— (Integer
)The result page size.
marker
— (String
)The marker for the next set of results.
ascendingOrder
— (Boolean
)Specifies the order for results. If True, the results are returned in ascending order, based on the creation date.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:outgoingCertificates
— (Array<map>
)The certificates that are being transferred but not yet accepted.
certificateArn
— (String
)The certificate ARN.
certificateId
— (String
)The certificate ID.
transferredTo
— (String
)The Amazon Web Services account to which the transfer was made.
transferDate
— (Date
)The date the transfer was initiated.
transferMessage
— (String
)The transfer message.
creationDate
— (Date
)The certificate creation date.
nextMarker
— (String
)The marker for the next set of results.
-
(AWS.Response)
—
Returns:
listPackages(params = {}, callback) ⇒ AWS.Request
Lists the software packages associated to the account.
Requires permission to access the ListPackages action.
Service Reference:
Examples:
Calling the listPackages operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listPackages(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results returned at one time.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:packageSummaries
— (Array<map>
)The software package summary.
packageName
— (String
)The name for the target software package.
defaultVersionName
— (String
)The name of the default package version.
creationDate
— (Date
)The date that the package was created.
lastModifiedDate
— (Date
)The date that the package was last updated.
nextToken
— (String
)The token for the next set of results.
-
(AWS.Response)
—
Returns:
listPackageVersions(params = {}, callback) ⇒ AWS.Request
Lists the software package versions associated to the account.
Requires permission to access the ListPackageVersions action.
Service Reference:
Examples:
Calling the listPackageVersions operation
var params = { packageName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', status: DRAFT | PUBLISHED | DEPRECATED }; iot.listPackageVersions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the target software package.
status
— (String
)The status of the package version. For more information, see Package version lifecycle.
Possible values include:"DRAFT"
"PUBLISHED"
"DEPRECATED"
maxResults
— (Integer
)The maximum number of results to return at one time.
nextToken
— (String
)The token for the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:packageVersionSummaries
— (Array<map>
)Lists the package versions associated to the package.
packageName
— (String
)The name of the associated software package.
versionName
— (String
)The name of the target package version.
status
— (String
)The status of the package version. For more information, see Package version lifecycle.
Possible values include:"DRAFT"
"PUBLISHED"
"DEPRECATED"
creationDate
— (Date
)The date that the package version was created.
lastModifiedDate
— (Date
)The date that the package version was last updated.
nextToken
— (String
)The token for the next set of results.
-
(AWS.Response)
—
Returns:
listPolicies(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the listPolicies operation
var params = { ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listPolicies(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
marker
— (String
)The marker for the next set of results.
pageSize
— (Integer
)The result page size.
ascendingOrder
— (Boolean
)Specifies the order for results. If true, the results are returned in ascending creation order.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policies
— (Array<map>
)The descriptions of the policies.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
nextMarker
— (String
)The marker for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listPolicyPrincipals(params = {}, callback) ⇒ AWS.Request
Lists the principals associated with the specified policy.
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements. Use ListTargetsForPolicy instead.
Requires permission to access the ListPolicyPrincipals action.
Service Reference:
Examples:
Calling the listPolicyPrincipals operation
var params = { policyName: 'STRING_VALUE', /* required */ ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listPolicyPrincipals(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
marker
— (String
)The marker for the next set of results.
pageSize
— (Integer
)The result page size.
ascendingOrder
— (Boolean
)Specifies the order for results. If true, the results are returned in ascending creation order.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:principals
— (Array<String>
)The descriptions of the principals.
nextMarker
— (String
)The marker for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listPolicyVersions(params = {}, callback) ⇒ AWS.Request
Lists the versions of the specified policy and identifies the default version.
Requires permission to access the ListPolicyVersions action.
Service Reference:
Examples:
Calling the listPolicyVersions operation
var params = { policyName: 'STRING_VALUE' /* required */ }; iot.listPolicyVersions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policyVersions
— (Array<map>
)The policy versions.
versionId
— (String
)The policy version ID.
isDefaultVersion
— (Boolean
)Specifies whether the policy version is the default.
createDate
— (Date
)The date and time the policy was created.
-
(AWS.Response)
—
Returns:
listPrincipalPolicies(params = {}, callback) ⇒ AWS.Request
Lists the policies attached to the specified principal. If you use an Cognito identity, the ID must be in AmazonCognito Identity format.
Note: This action is deprecated and works as expected for backward compatibility, but we won't add enhancements. Use ListAttachedPolicies instead.
Requires permission to access the ListPrincipalPolicies action.
Service Reference:
Examples:
Calling the listPrincipalPolicies operation
var params = { principal: 'STRING_VALUE', /* required */ ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listPrincipalPolicies(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
principal
— (String
)The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
marker
— (String
)The marker for the next set of results.
pageSize
— (Integer
)The result page size.
ascendingOrder
— (Boolean
)Specifies the order for results. If true, results are returned in ascending creation order.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:policies
— (Array<map>
)The policies.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
nextMarker
— (String
)The marker for the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listPrincipalThings(params = {}, callback) ⇒ AWS.Request
Lists the things associated with the specified principal. A principal can be X.509 certificates, IAM users, groups, and roles, Amazon Cognito identities or federated identities.
Requires permission to access the ListPrincipalThings action.
Service Reference:
Examples:
Calling the listPrincipalThings operation
var params = { principal: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listPrincipalThings(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return in this operation.
principal
— (String
)The principal.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:things
— (Array<String>
)The things.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listProvisioningTemplates(params = {}, callback) ⇒ AWS.Request
Lists the provisioning templates in your Amazon Web Services account.
Requires permission to access the ListProvisioningTemplates action.
Service Reference:
Examples:
Calling the listProvisioningTemplates operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listProvisioningTemplates(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results to return at one time.
nextToken
— (String
)A token to retrieve the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:templates
— (Array<map>
)A list of provisioning templates
templateArn
— (String
)The ARN of the provisioning template.
templateName
— (String
)The name of the provisioning template.
description
— (String
)The description of the provisioning template.
creationDate
— (Date
)The date when the provisioning template summary was created.
lastModifiedDate
— (Date
)The date when the provisioning template summary was last modified.
enabled
— (Boolean
)True if the fleet provision template is enabled, otherwise false.
type
— (String
)The type you define in a provisioning template. You can create a template with only one type. You can't change the template type after its creation. The default value is
Possible values include:FLEET_PROVISIONING
. For more information about provisioning template, see: Provisioning template."FLEET_PROVISIONING"
"JITP"
nextToken
— (String
)A token to retrieve the next set of results.
-
(AWS.Response)
—
Returns:
listProvisioningTemplateVersions(params = {}, callback) ⇒ AWS.Request
A list of provisioning template versions.
Requires permission to access the ListProvisioningTemplateVersions action.
Service Reference:
Examples:
Calling the listProvisioningTemplateVersions operation
var params = { templateName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listProvisioningTemplateVersions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template.
maxResults
— (Integer
)The maximum number of results to return at one time.
nextToken
— (String
)A token to retrieve the next set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:versions
— (Array<map>
)The list of provisioning template versions.
versionId
— (Integer
)The ID of the fleet provisioning template version.
creationDate
— (Date
)The date when the provisioning template version was created
isDefaultVersion
— (Boolean
)True if the provisioning template version is the default version, otherwise false.
nextToken
— (String
)A token to retrieve the next set of results.
-
(AWS.Response)
—
Returns:
listRelatedResourcesForAuditFinding(params = {}, callback) ⇒ AWS.Request
The related resources of an Audit finding. The following resources can be returned from calling this API:
-
DEVICE_CERTIFICATE
-
CA_CERTIFICATE
-
IOT_POLICY
-
COGNITO_IDENTITY_POOL
-
CLIENT_ID
-
ACCOUNT_SETTINGS
-
ROLE_ALIAS
-
IAM_ROLE
-
ISSUER_CERTIFICATE
Note: This API is similar to DescribeAuditFinding's RelatedResources but provides pagination and is not limited to 10 resources. When calling DescribeAuditFinding for the intermediate CA revoked for active device certificates check, RelatedResources will not be populated. You must use this API, ListRelatedResourcesForAuditFinding, to list the certificates.Service Reference:
Examples:
Calling the listRelatedResourcesForAuditFinding operation
var params = { findingId: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listRelatedResourcesForAuditFinding(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
findingId
— (String
)The finding Id.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:relatedResources
— (Array<map>
)The related resources.
resourceType
— (String
)The type of resource.
Possible values include:"DEVICE_CERTIFICATE"
"CA_CERTIFICATE"
"IOT_POLICY"
"COGNITO_IDENTITY_POOL"
"CLIENT_ID"
"ACCOUNT_SETTINGS"
"ROLE_ALIAS"
"IAM_ROLE"
"ISSUER_CERTIFICATE"
resourceIdentifier
— (map
)Information that identifies the resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
additionalInfo
— (map<String>
)Other information about the resource.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
for the first API call.
-
(AWS.Response)
—
Returns:
listRoleAliases(params = {}, callback) ⇒ AWS.Request
Lists the role aliases registered in your account.
Requires permission to access the ListRoleAliases action.
Service Reference:
Examples:
Calling the listRoleAliases operation
var params = { ascendingOrder: true || false, marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listRoleAliases(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
pageSize
— (Integer
)The maximum number of results to return at one time.
marker
— (String
)A marker used to get the next set of results.
ascendingOrder
— (Boolean
)Return the list of role aliases in ascending alphabetical order.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleAliases
— (Array<String>
)The role aliases.
nextMarker
— (String
)A marker used to get the next set of results.
-
(AWS.Response)
—
Returns:
listScheduledAudits(params = {}, callback) ⇒ AWS.Request
Lists all of your scheduled audits.
Requires permission to access the ListScheduledAudits action.
Service Reference:
Examples:
Calling the listScheduledAudits operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listScheduledAudits(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time. The default is 25.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:scheduledAudits
— (Array<map>
)The list of scheduled audits.
scheduledAuditName
— (String
)The name of the scheduled audit.
scheduledAuditArn
— (String
)The ARN of the scheduled audit.
frequency
— (String
)How often the scheduled audit occurs.
Possible values include:"DAILY"
"WEEKLY"
"BIWEEKLY"
"MONTHLY"
dayOfMonth
— (String
)The day of the month on which the scheduled audit is run (if the
frequency
is "MONTHLY"). If days 29-31 are specified, and the month does not have that many days, the audit takes place on the "LAST" day of the month.dayOfWeek
— (String
)The day of the week on which the scheduled audit is run (if the
Possible values include:frequency
is "WEEKLY" or "BIWEEKLY")."SUN"
"MON"
"TUE"
"WED"
"THU"
"FRI"
"SAT"
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listSecurityProfiles(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender security profiles you've created. You can filter security profiles by dimension or custom metric.
Requires permission to access the ListSecurityProfiles action.
Note:dimensionName
andmetricName
cannot be used in the same request.Service Reference:
Examples:
Calling the listSecurityProfiles operation
var params = { dimensionName: 'STRING_VALUE', maxResults: 'NUMBER_VALUE', metricName: 'STRING_VALUE', nextToken: 'STRING_VALUE' }; iot.listSecurityProfiles(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time.
dimensionName
— (String
)A filter to limit results to the security profiles that use the defined dimension. Cannot be used with
metricName
metricName
— (String
)The name of the custom metric. Cannot be used with
dimensionName
.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:securityProfileIdentifiers
— (Array<map>
)A list of security profile identifiers (names and ARNs).
name
— required — (String
)The name you've given to the security profile.
arn
— required — (String
)The ARN of the security profile.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listSecurityProfilesForTarget(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender security profiles attached to a target (thing group).
Requires permission to access the ListSecurityProfilesForTarget action.
Service Reference:
Examples:
Calling the listSecurityProfilesForTarget operation
var params = { securityProfileTargetArn: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', recursive: true || false }; iot.listSecurityProfilesForTarget(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time.
recursive
— (Boolean
)If true, return child groups too.
securityProfileTargetArn
— (String
)The ARN of the target (thing group) whose attached security profiles you want to get.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:securityProfileTargetMappings
— (Array<map>
)A list of security profiles and their associated targets.
securityProfileIdentifier
— (map
)Information that identifies the security profile.
name
— required — (String
)The name you've given to the security profile.
arn
— required — (String
)The ARN of the security profile.
target
— (map
)Information about the target (thing group) associated with the security profile.
arn
— required — (String
)The ARN of the security profile.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listStreams(params = {}, callback) ⇒ AWS.Request
Lists all of the streams in your Amazon Web Services account.
Requires permission to access the ListStreams action.
Service Reference:
Examples:
Calling the listStreams operation
var params = { ascendingOrder: true || false, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listStreams(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results to return at a time.
nextToken
— (String
)A token used to get the next set of results.
ascendingOrder
— (Boolean
)Set to true to return the list of streams in ascending order.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:streams
— (Array<map>
)A list of streams.
streamId
— (String
)The stream ID.
streamArn
— (String
)The stream ARN.
streamVersion
— (Integer
)The stream version.
description
— (String
)A description of the stream.
nextToken
— (String
)A token used to get the next set of results.
-
(AWS.Response)
—
Returns:
listTagsForResource(params = {}, callback) ⇒ AWS.Request
Lists the tags (metadata) you have assigned to the resource.
Requires permission to access the ListTagsForResource action.
Service Reference:
Examples:
Calling the listTagsForResource operation
var params = { resourceArn: 'STRING_VALUE', /* required */ nextToken: 'STRING_VALUE' }; iot.listTagsForResource(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
resourceArn
— (String
)The ARN of the resource.
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:tags
— (Array<map>
)The list of tags assigned to the resource.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listTargetsForPolicy(params = {}, callback) ⇒ AWS.Request
List targets for the specified policy.
Requires permission to access the ListTargetsForPolicy action.
Service Reference:
Examples:
Calling the listTargetsForPolicy operation
var params = { policyName: 'STRING_VALUE', /* required */ marker: 'STRING_VALUE', pageSize: 'NUMBER_VALUE' }; iot.listTargetsForPolicy(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
marker
— (String
)A marker used to get the next set of results.
pageSize
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:targets
— (Array<String>
)The policy targets.
nextMarker
— (String
)A marker used to get the next set of results.
-
(AWS.Response)
—
Returns:
listTargetsForSecurityProfile(params = {}, callback) ⇒ AWS.Request
Lists the targets (thing groups) associated with a given Device Defender security profile.
Requires permission to access the ListTargetsForSecurityProfile action.
Service Reference:
Examples:
Calling the listTargetsForSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listTargetsForSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The security profile.
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:securityProfileTargets
— (Array<map>
)The thing groups to which the security profile is attached.
arn
— required — (String
)The ARN of the security profile.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
listThingGroups(params = {}, callback) ⇒ AWS.Request
List the thing groups in your account.
Requires permission to access the ListThingGroups action.
Service Reference:
Examples:
Calling the listThingGroups operation
var params = { maxResults: 'NUMBER_VALUE', namePrefixFilter: 'STRING_VALUE', nextToken: 'STRING_VALUE', parentGroup: 'STRING_VALUE', recursive: true || false }; iot.listThingGroups(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return at one time.
parentGroup
— (String
)A filter that limits the results to those with the specified parent group.
namePrefixFilter
— (String
)A filter that limits the results to those with the specified name prefix.
recursive
— (Boolean
)If true, return child groups as well.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingGroups
— (Array<map>
)The thing groups.
groupName
— (String
)The group name.
groupArn
— (String
)The group ARN.
nextToken
— (String
)The token to use to get the next set of results. Will not be returned if operation has returned all results.
-
(AWS.Response)
—
Returns:
listThingGroupsForThing(params = {}, callback) ⇒ AWS.Request
List the thing groups to which the specified thing belongs.
Requires permission to access the ListThingGroupsForThing action.
Service Reference:
Examples:
Calling the listThingGroupsForThing operation
var params = { thingName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listThingGroupsForThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The thing name.
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingGroups
— (Array<map>
)The thing groups.
groupName
— (String
)The group name.
groupArn
— (String
)The group ARN.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listThingPrincipals(params = {}, callback) ⇒ AWS.Request
Lists the principals associated with the specified thing. A principal can be X.509 certificates, IAM users, groups, and roles, Amazon Cognito identities or federated identities.
Requires permission to access the ListThingPrincipals action.
Service Reference:
Examples:
Calling the listThingPrincipals operation
var params = { thingName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listThingPrincipals(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return in this operation.
thingName
— (String
)The name of the thing.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:principals
— (Array<String>
)The principals associated with the thing.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listThingRegistrationTaskReports(params = {}, callback) ⇒ AWS.Request
Information about the thing registration tasks.
Service Reference:
Examples:
Calling the listThingRegistrationTaskReports operation
var params = { reportType: ERRORS | RESULTS, /* required */ taskId: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listThingRegistrationTaskReports(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The id of the task.
reportType
— (String
)The type of task report.
Possible values include:"ERRORS"
"RESULTS"
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return per request.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:resourceLinks
— (Array<String>
)Links to the task resources.
reportType
— (String
)The type of task report.
Possible values include:"ERRORS"
"RESULTS"
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listThingRegistrationTasks(params = {}, callback) ⇒ AWS.Request
List bulk thing provisioning tasks.
Requires permission to access the ListThingRegistrationTasks action.
Service Reference:
Examples:
Calling the listThingRegistrationTasks operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', status: InProgress | Completed | Failed | Cancelled | Cancelling }; iot.listThingRegistrationTasks(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return at one time.
status
— (String
)The status of the bulk thing provisioning task.
Possible values include:"InProgress"
"Completed"
"Failed"
"Cancelled"
"Cancelling"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskIds
— (Array<String>
)A list of bulk thing provisioning task IDs.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listThings(params = {}, callback) ⇒ AWS.Request
Lists your things. Use the attributeName and attributeValue parameters to filter your things. For example, calling
ListThings
with attributeName=Color and attributeValue=Red retrieves all things in the registry that contain an attribute Color with the value Red. For more information, see List Things from the Amazon Web Services IoT Core Developer Guide.Requires permission to access the ListThings action.
Note: You will not be charged for calling this API if anAccess denied
error is returned. You will also not be charged if no attributes or pagination token was provided in request and no pagination token and no results were returned.Service Reference:
Examples:
Calling the listThings operation
var params = { attributeName: 'STRING_VALUE', attributeValue: 'STRING_VALUE', maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', thingTypeName: 'STRING_VALUE', usePrefixAttributeValue: true || false }; iot.listThings(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return in this operation.
attributeName
— (String
)The attribute name used to search for things.
attributeValue
— (String
)The attribute value used to search for things.
thingTypeName
— (String
)The name of the thing type used to search for things.
usePrefixAttributeValue
— (Boolean
)When
true
, the action returns the thing resources with attribute values that start with theattributeValue
provided.When
false
, or not present, the action returns only the thing resources with attribute values that match the entireattributeValue
provided.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:things
— (Array<map>
)The things.
thingName
— (String
)The name of the thing.
thingTypeName
— (String
)The name of the thing type, if the thing has been associated with a type.
thingArn
— (String
)The thing ARN.
attributes
— (map<String>
)A list of thing attributes which are name-value pairs.
version
— (Integer
)The version of the thing record in the registry.
nextToken
— (String
)The token to use to get the next set of results. Will not be returned if operation has returned all results.
-
(AWS.Response)
—
Returns:
listThingsInBillingGroup(params = {}, callback) ⇒ AWS.Request
Lists the things you have added to the given billing group.
Requires permission to access the ListThingsInBillingGroup action.
Service Reference:
Examples:
Calling the listThingsInBillingGroup operation
var params = { billingGroupName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listThingsInBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name of the billing group.
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return per request.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:things
— (Array<String>
)A list of things in the billing group.
nextToken
— (String
)The token to use to get the next set of results. Will not be returned if operation has returned all results.
-
(AWS.Response)
—
Returns:
listThingsInThingGroup(params = {}, callback) ⇒ AWS.Request
Lists the things in the specified group.
Requires permission to access the ListThingsInThingGroup action.
Service Reference:
Examples:
Calling the listThingsInThingGroup operation
var params = { thingGroupName: 'STRING_VALUE', /* required */ maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', recursive: true || false }; iot.listThingsInThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The thing group name.
recursive
— (Boolean
)When true, list things in this thing group and in all child groups as well.
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:things
— (Array<String>
)The things in the specified thing group.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listThingTypes(params = {}, callback) ⇒ AWS.Request
Lists the existing thing types.
Requires permission to access the ListThingTypes action.
Service Reference:
Examples:
Calling the listThingTypes operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', thingTypeName: 'STRING_VALUE' }; iot.listThingTypes(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return in this operation.
thingTypeName
— (String
)The name of the thing type.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:thingTypes
— (Array<map>
)The thing types.
thingTypeName
— (String
)The name of the thing type.
thingTypeArn
— (String
)The thing type ARN.
thingTypeProperties
— (map
)The ThingTypeProperties for the thing type.
thingTypeDescription
— (String
)The description of the thing type.
searchableAttributes
— (Array<String>
)A list of searchable thing attribute names.
thingTypeMetadata
— (map
)The ThingTypeMetadata contains additional information about the thing type including: creation date and time, a value indicating whether the thing type is deprecated, and a date and time when it was deprecated.
deprecated
— (Boolean
)Whether the thing type is deprecated. If true, no new things could be associated with this type.
deprecationDate
— (Date
)The date and time when the thing type was deprecated.
creationDate
— (Date
)The date and time when the thing type was created.
nextToken
— (String
)The token for the next set of results. Will not be returned if operation has returned all results.
-
(AWS.Response)
—
Returns:
listTopicRuleDestinations(params = {}, callback) ⇒ AWS.Request
Lists all the topic rule destinations in your Amazon Web Services account.
Requires permission to access the ListTopicRuleDestinations action.
Service Reference:
Examples:
Calling the listTopicRuleDestinations operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE' }; iot.listTopicRuleDestinations(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
maxResults
— (Integer
)The maximum number of results to return at one time.
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:destinationSummaries
— (Array<map>
)Information about a topic rule destination.
arn
— (String
)The topic rule destination ARN.
status
— (String
)The status of the topic rule destination. Valid values are:
- IN_PROGRESS
-
A topic rule destination was created but has not been confirmed. You can set
status
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint. - ENABLED
-
Confirmation was completed, and traffic to this destination is allowed. You can set
status
toDISABLED
by callingUpdateTopicRuleDestination
. - DISABLED
-
Confirmation was completed, and traffic to this destination is not allowed. You can set
status
toENABLED
by callingUpdateTopicRuleDestination
. - ERROR
-
Confirmation could not be completed, for example if the confirmation timed out. You can call
GetTopicRuleDestination
for details about the error. You can setstatus
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint.
"ENABLED"
"IN_PROGRESS"
"DISABLED"
"ERROR"
"DELETING"
createdAt
— (Date
)The date and time when the topic rule destination was created.
lastUpdatedAt
— (Date
)The date and time when the topic rule destination was last updated.
statusReason
— (String
)The reason the topic rule destination is in the current status.
httpUrlSummary
— (map
)Information about the HTTP URL.
confirmationUrl
— (String
)The URL used to confirm ownership of or access to the HTTP topic rule destination URL.
vpcDestinationSummary
— (map
)Information about the virtual private cloud (VPC) connection.
subnetIds
— (Array<String>
)The subnet IDs of the VPC destination.
securityGroups
— (Array<String>
)The security groups of the VPC destination.
vpcId
— (String
)The ID of the VPC.
roleArn
— (String
)The ARN of a role that has permission to create and attach to elastic network interfaces (ENIs).
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listTopicRules(params = {}, callback) ⇒ AWS.Request
Lists the rules for the specific topic.
Requires permission to access the ListTopicRules action.
Service Reference:
Examples:
Calling the listTopicRules operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', ruleDisabled: true || false, topic: 'STRING_VALUE' }; iot.listTopicRules(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
topic
— (String
)The topic.
maxResults
— (Integer
)The maximum number of results to return.
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.ruleDisabled
— (Boolean
)Specifies whether the rule is disabled.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:rules
— (Array<map>
)The rules.
ruleArn
— (String
)The rule ARN.
ruleName
— (String
)The name of the rule.
topicPattern
— (String
)The pattern for the topic names that apply.
createdAt
— (Date
)The date and time the rule was created.
ruleDisabled
— (Boolean
)Specifies whether the rule is disabled.
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listV2LoggingLevels(params = {}, callback) ⇒ AWS.Request
Lists logging levels.
Requires permission to access the ListV2LoggingLevels action.
Service Reference:
Examples:
Calling the listV2LoggingLevels operation
var params = { maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', targetType: DEFAULT | THING_GROUP | CLIENT_ID | SOURCE_IP | PRINCIPAL_ID }; iot.listV2LoggingLevels(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
targetType
— (String
)The type of resource for which you are configuring logging. Must be
Possible values include:THING_Group
."DEFAULT"
"THING_GROUP"
"CLIENT_ID"
"SOURCE_IP"
"PRINCIPAL_ID"
nextToken
— (String
)To retrieve the next set of results, the
nextToken
value from a previous response; otherwise null to receive the first set of results.maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:logTargetConfigurations
— (Array<map>
)The logging configuration for a target.
logTarget
— (map
)A log target
targetType
— required — (String
)The target type.
Possible values include:"DEFAULT"
"THING_GROUP"
"CLIENT_ID"
"SOURCE_IP"
"PRINCIPAL_ID"
targetName
— (String
)The target name.
logLevel
— (String
)The logging level.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
nextToken
— (String
)The token to use to get the next set of results, or null if there are no additional results.
-
(AWS.Response)
—
Returns:
listViolationEvents(params = {}, callback) ⇒ AWS.Request
Lists the Device Defender security profile violations discovered during the given time period. You can use filters to limit the results to those alerts issued for a particular security profile, behavior, or thing (device).
Requires permission to access the ListViolationEvents action.
Service Reference:
Examples:
Calling the listViolationEvents operation
var params = { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ behaviorCriteriaType: STATIC | STATISTICAL | MACHINE_LEARNING, listSuppressedAlerts: true || false, maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', securityProfileName: 'STRING_VALUE', thingName: 'STRING_VALUE', verificationState: FALSE_POSITIVE | BENIGN_POSITIVE | TRUE_POSITIVE | UNKNOWN }; iot.listViolationEvents(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
startTime
— (Date
)The start time for the alerts to be listed.
endTime
— (Date
)The end time for the alerts to be listed.
thingName
— (String
)A filter to limit results to those alerts caused by the specified thing.
securityProfileName
— (String
)A filter to limit results to those alerts generated by the specified security profile.
behaviorCriteriaType
— (String
)The criteria for a behavior.
Possible values include:"STATIC"
"STATISTICAL"
"MACHINE_LEARNING"
listSuppressedAlerts
— (Boolean
)A list of all suppressed alerts.
verificationState
— (String
)The verification state of the violation (detect alarm).
Possible values include:"FALSE_POSITIVE"
"BENIGN_POSITIVE"
"TRUE_POSITIVE"
"UNKNOWN"
nextToken
— (String
)The token for the next set of results.
maxResults
— (Integer
)The maximum number of results to return at one time.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:violationEvents
— (Array<map>
)The security profile violation alerts issued for this account during the given time period, potentially filtered by security profile, behavior violated, or thing (device) violating.
violationId
— (String
)The ID of the violation event.
thingName
— (String
)The name of the thing responsible for the violation event.
securityProfileName
— (String
)The name of the security profile whose behavior was violated.
behavior
— (map
)The behavior that was violated.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
metricValue
— (map
)The value of the metric (the measurement).
count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
violationEventAdditionalInfo
— (map
)The details of a violation event.
confidenceLevel
— (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
violationEventType
— (String
)The type of violation event.
Possible values include:"in-alarm"
"alarm-cleared"
"alarm-invalidated"
verificationState
— (String
)The verification state of the violation (detect alarm).
Possible values include:"FALSE_POSITIVE"
"BENIGN_POSITIVE"
"TRUE_POSITIVE"
"UNKNOWN"
verificationStateDescription
— (String
)The description of the verification state of the violation.
violationEventTime
— (Date
)The time the violation event occurred.
nextToken
— (String
)A token that can be used to retrieve the next set of results, or
null
if there are no additional results.
-
(AWS.Response)
—
Returns:
putVerificationStateOnViolation(params = {}, callback) ⇒ AWS.Request
Set a verification state and provide a description of that verification state on a violation (detect alarm).
Service Reference:
Examples:
Calling the putVerificationStateOnViolation operation
var params = { verificationState: FALSE_POSITIVE | BENIGN_POSITIVE | TRUE_POSITIVE | UNKNOWN, /* required */ violationId: 'STRING_VALUE', /* required */ verificationStateDescription: 'STRING_VALUE' }; iot.putVerificationStateOnViolation(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
violationId
— (String
)The violation ID.
verificationState
— (String
)The verification state of the violation.
Possible values include:"FALSE_POSITIVE"
"BENIGN_POSITIVE"
"TRUE_POSITIVE"
"UNKNOWN"
verificationStateDescription
— (String
)The description of the verification state of the violation (detect alarm).
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
registerCACertificate(params = {}, callback) ⇒ AWS.Request
Registers a CA certificate with Amazon Web Services IoT Core. There is no limit to the number of CA certificates you can register in your Amazon Web Services account. You can register up to 10 CA certificates with the same
CA subject field
per Amazon Web Services account.Requires permission to access the RegisterCACertificate action.
Service Reference:
Examples:
Calling the registerCACertificate operation
var params = { caCertificate: 'STRING_VALUE', /* required */ allowAutoRegistration: true || false, certificateMode: DEFAULT | SNI_ONLY, registrationConfig: { roleArn: 'STRING_VALUE', templateBody: 'STRING_VALUE', templateName: 'STRING_VALUE' }, setAsActive: true || false, tags: [ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ], verificationCertificate: 'STRING_VALUE' }; iot.registerCACertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
caCertificate
— (String
)The CA certificate.
verificationCertificate
— (String
)The private key verification certificate. If
certificateMode
isSNI_ONLY
, theverificationCertificate
field must be empty. IfcertificateMode
isDEFAULT
or not provided, theverificationCertificate
field must not be empty.setAsActive
— (Boolean
)A boolean value that specifies if the CA certificate is set to active.
Valid values:
ACTIVE | INACTIVE
allowAutoRegistration
— (Boolean
)Allows this CA certificate to be used for auto registration of device certificates.
registrationConfig
— (map
)Information about the registration configuration.
templateBody
— (String
)The template body.
roleArn
— (String
)The ARN of the role.
templateName
— (String
)The name of the provisioning template.
tags
— (Array<map>
)Metadata which can be used to manage the CA certificate.
Note: For URI Request parameters use format: ...key1=value1&key2=value2... For the CLI command-line parameter use format: &&tags "key1=value1&key2=value2..." For the cli-input-json file use format: "tags": "key1=value1&key2=value2..."Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
certificateMode
— (String
)Describes the certificate mode in which the Certificate Authority (CA) will be registered. If the
Possible values include:verificationCertificate
field is not provided, setcertificateMode
to beSNI_ONLY
. If theverificationCertificate
field is provided, setcertificateMode
to beDEFAULT
. WhencertificateMode
is not provided, it defaults toDEFAULT
. All the device certificates that are registered using this CA will be registered in the same certificate mode as the CA. For more information about certificate mode for device certificates, see certificate mode."DEFAULT"
"SNI_ONLY"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateArn
— (String
)The CA certificate ARN.
certificateId
— (String
)The CA certificate identifier.
-
(AWS.Response)
—
Returns:
registerCertificate(params = {}, callback) ⇒ AWS.Request
Registers a device certificate with IoT in the same certificate mode as the signing CA. If you have more than one CA certificate that has the same subject field, you must specify the CA certificate that was used to sign the device certificate being registered.
Requires permission to access the RegisterCertificate action.
Service Reference:
Examples:
Calling the registerCertificate operation
var params = { certificatePem: 'STRING_VALUE', /* required */ caCertificatePem: 'STRING_VALUE', setAsActive: true || false, status: ACTIVE | INACTIVE | REVOKED | PENDING_TRANSFER | REGISTER_INACTIVE | PENDING_ACTIVATION }; iot.registerCertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificatePem
— (String
)The certificate data, in PEM format.
caCertificatePem
— (String
)The CA certificate used to sign the device certificate being registered.
setAsActive
— (Boolean
)A boolean value that specifies if the certificate is set to active.
Valid values:
ACTIVE | INACTIVE
status
— (String
)The status of the register certificate request. Valid values that you can use include
Possible values include:ACTIVE
,INACTIVE
, andREVOKED
."ACTIVE"
"INACTIVE"
"REVOKED"
"PENDING_TRANSFER"
"REGISTER_INACTIVE"
"PENDING_ACTIVATION"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateArn
— (String
)The certificate ARN.
certificateId
— (String
)The certificate identifier.
-
(AWS.Response)
—
Returns:
registerCertificateWithoutCA(params = {}, callback) ⇒ AWS.Request
Register a certificate that does not have a certificate authority (CA). For supported certificates, consult Certificate signing algorithms supported by IoT.
Service Reference:
Examples:
Calling the registerCertificateWithoutCA operation
var params = { certificatePem: 'STRING_VALUE', /* required */ status: ACTIVE | INACTIVE | REVOKED | PENDING_TRANSFER | REGISTER_INACTIVE | PENDING_ACTIVATION }; iot.registerCertificateWithoutCA(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificatePem
— (String
)The certificate data, in PEM format.
status
— (String
)The status of the register certificate request.
Possible values include:"ACTIVE"
"INACTIVE"
"REVOKED"
"PENDING_TRANSFER"
"REGISTER_INACTIVE"
"PENDING_ACTIVATION"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateArn
— (String
)The Amazon Resource Name (ARN) of the registered certificate.
certificateId
— (String
)The ID of the registered certificate. (The last part of the certificate ARN contains the certificate ID.
-
(AWS.Response)
—
Returns:
registerThing(params = {}, callback) ⇒ AWS.Request
Provisions a thing in the device registry. RegisterThing calls other IoT control plane APIs. These calls might exceed your account level IoT Throttling Limits and cause throttle errors. Please contact Amazon Web Services Customer Support to raise your throttling limits if necessary.
Requires permission to access the RegisterThing action.
Service Reference:
Examples:
Calling the registerThing operation
var params = { templateBody: 'STRING_VALUE', /* required */ parameters: { '<Parameter>': 'STRING_VALUE', /* '<Parameter>': ... */ } }; iot.registerThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateBody
— (String
)The provisioning template. See Provisioning Devices That Have Device Certificates for more information.
parameters
— (map<String>
)The parameters for provisioning a thing. See Provisioning Templates for more information.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificatePem
— (String
)The certificate data, in PEM format.
resourceArns
— (map<String>
)ARNs for the generated resources.
-
(AWS.Response)
—
Returns:
rejectCertificateTransfer(params = {}, callback) ⇒ AWS.Request
Rejects a pending certificate transfer. After IoT rejects a certificate transfer, the certificate status changes from PENDING_TRANSFER to INACTIVE.
To check for pending certificate transfers, call ListCertificates to enumerate your certificates.
This operation can only be called by the transfer destination. After it is called, the certificate will be returned to the source's account in the INACTIVE state.
Requires permission to access the RejectCertificateTransfer action.
Service Reference:
Examples:
Calling the rejectCertificateTransfer operation
var params = { certificateId: 'STRING_VALUE', /* required */ rejectReason: 'STRING_VALUE' }; iot.rejectCertificateTransfer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
rejectReason
— (String
)The reason the certificate transfer was rejected.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
removeThingFromBillingGroup(params = {}, callback) ⇒ AWS.Request
Removes the given thing from the billing group.
Requires permission to access the RemoveThingFromBillingGroup action.
Note: This call is asynchronous. It might take several seconds for the detachment to propagate.Service Reference:
Examples:
Calling the removeThingFromBillingGroup operation
var params = { billingGroupArn: 'STRING_VALUE', billingGroupName: 'STRING_VALUE', thingArn: 'STRING_VALUE', thingName: 'STRING_VALUE' }; iot.removeThingFromBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name of the billing group.
billingGroupArn
— (String
)The ARN of the billing group.
thingName
— (String
)The name of the thing to be removed from the billing group.
thingArn
— (String
)The ARN of the thing to be removed from the billing group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
removeThingFromThingGroup(params = {}, callback) ⇒ AWS.Request
Remove the specified thing from the specified group.
You must specify either a
thingGroupArn
or athingGroupName
to identify the thing group and either athingArn
or athingName
to identify the thing to remove from the thing group.Requires permission to access the RemoveThingFromThingGroup action.
Service Reference:
Examples:
Calling the removeThingFromThingGroup operation
var params = { thingArn: 'STRING_VALUE', thingGroupArn: 'STRING_VALUE', thingGroupName: 'STRING_VALUE', thingName: 'STRING_VALUE' }; iot.removeThingFromThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The group name.
thingGroupArn
— (String
)The group ARN.
thingName
— (String
)The name of the thing to remove from the group.
thingArn
— (String
)The ARN of the thing to remove from the group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
replaceTopicRule(params = {}, callback) ⇒ AWS.Request
Replaces the rule. You must specify all parameters for the new rule. Creating rules is an administrator-level action. Any user who has permission to create rules will be able to access data processed by the rule.
Requires permission to access the ReplaceTopicRule action.
Service Reference:
Examples:
Calling the replaceTopicRule operation
var params = { ruleName: 'STRING_VALUE', /* required */ topicRulePayload: { /* required */ actions: [ /* required */ { cloudwatchAlarm: { alarmName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ stateReason: 'STRING_VALUE', /* required */ stateValue: 'STRING_VALUE' /* required */ }, cloudwatchLogs: { logGroupName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false }, cloudwatchMetric: { metricName: 'STRING_VALUE', /* required */ metricNamespace: 'STRING_VALUE', /* required */ metricUnit: 'STRING_VALUE', /* required */ metricValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ metricTimestamp: 'STRING_VALUE' }, dynamoDB: { hashKeyField: 'STRING_VALUE', /* required */ hashKeyValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ hashKeyType: STRING | NUMBER, operation: 'STRING_VALUE', payloadField: 'STRING_VALUE', rangeKeyField: 'STRING_VALUE', rangeKeyType: STRING | NUMBER, rangeKeyValue: 'STRING_VALUE' }, dynamoDBv2: { putItem: { /* required */ tableName: 'STRING_VALUE' /* required */ }, roleArn: 'STRING_VALUE' /* required */ }, elasticsearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, firehose: { deliveryStreamName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, separator: 'STRING_VALUE' }, http: { url: 'STRING_VALUE', /* required */ auth: { sigv4: { roleArn: 'STRING_VALUE', /* required */ serviceName: 'STRING_VALUE', /* required */ signingRegion: 'STRING_VALUE' /* required */ } }, confirmationUrl: 'STRING_VALUE', headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, iotAnalytics: { batchMode: true || false, channelArn: 'STRING_VALUE', channelName: 'STRING_VALUE', roleArn: 'STRING_VALUE' }, iotEvents: { inputName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, messageId: 'STRING_VALUE' }, iotSiteWise: { putAssetPropertyValueEntries: [ /* required */ { propertyValues: [ /* required */ { timestamp: { /* required */ timeInSeconds: 'STRING_VALUE', /* required */ offsetInNanos: 'STRING_VALUE' }, value: { /* required */ booleanValue: 'STRING_VALUE', doubleValue: 'STRING_VALUE', integerValue: 'STRING_VALUE', stringValue: 'STRING_VALUE' }, quality: 'STRING_VALUE' }, /* more items */ ], assetId: 'STRING_VALUE', entryId: 'STRING_VALUE', propertyAlias: 'STRING_VALUE', propertyId: 'STRING_VALUE' }, /* more items */ ], roleArn: 'STRING_VALUE' /* required */ }, kafka: { clientProperties: { /* required */ '<String>': 'STRING_VALUE', /* '<String>': ... */ }, destinationArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], key: 'STRING_VALUE', partition: 'STRING_VALUE' }, kinesis: { roleArn: 'STRING_VALUE', /* required */ streamName: 'STRING_VALUE', /* required */ partitionKey: 'STRING_VALUE' }, lambda: { functionArn: 'STRING_VALUE' /* required */ }, location: { deviceId: 'STRING_VALUE', /* required */ latitude: 'STRING_VALUE', /* required */ longitude: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ trackerName: 'STRING_VALUE', /* required */ timestamp: { value: 'STRING_VALUE', /* required */ unit: 'STRING_VALUE' } }, openSearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, republish: { roleArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: { contentType: 'STRING_VALUE', correlationData: 'STRING_VALUE', messageExpiry: 'STRING_VALUE', payloadFormatIndicator: 'STRING_VALUE', responseTopic: 'STRING_VALUE', userProperties: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, qos: 'NUMBER_VALUE' }, s3: { bucketName: 'STRING_VALUE', /* required */ key: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ cannedAcl: private | public-read | public-read-write | aws-exec-read | authenticated-read | bucket-owner-read | bucket-owner-full-control | log-delivery-write }, salesforce: { token: 'STRING_VALUE', /* required */ url: 'STRING_VALUE' /* required */ }, sns: { roleArn: 'STRING_VALUE', /* required */ targetArn: 'STRING_VALUE', /* required */ messageFormat: RAW | JSON }, sqs: { queueUrl: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ useBase64: true || false }, stepFunctions: { roleArn: 'STRING_VALUE', /* required */ stateMachineName: 'STRING_VALUE', /* required */ executionNamePrefix: 'STRING_VALUE' }, timestream: { databaseName: 'STRING_VALUE', /* required */ dimensions: [ /* required */ { name: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ timestamp: { unit: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ } } }, /* more items */ ], sql: 'STRING_VALUE', /* required */ awsIotSqlVersion: 'STRING_VALUE', description: 'STRING_VALUE', errorAction: { cloudwatchAlarm: { alarmName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ stateReason: 'STRING_VALUE', /* required */ stateValue: 'STRING_VALUE' /* required */ }, cloudwatchLogs: { logGroupName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false }, cloudwatchMetric: { metricName: 'STRING_VALUE', /* required */ metricNamespace: 'STRING_VALUE', /* required */ metricUnit: 'STRING_VALUE', /* required */ metricValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ metricTimestamp: 'STRING_VALUE' }, dynamoDB: { hashKeyField: 'STRING_VALUE', /* required */ hashKeyValue: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ hashKeyType: STRING | NUMBER, operation: 'STRING_VALUE', payloadField: 'STRING_VALUE', rangeKeyField: 'STRING_VALUE', rangeKeyType: STRING | NUMBER, rangeKeyValue: 'STRING_VALUE' }, dynamoDBv2: { putItem: { /* required */ tableName: 'STRING_VALUE' /* required */ }, roleArn: 'STRING_VALUE' /* required */ }, elasticsearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, firehose: { deliveryStreamName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, separator: 'STRING_VALUE' }, http: { url: 'STRING_VALUE', /* required */ auth: { sigv4: { roleArn: 'STRING_VALUE', /* required */ serviceName: 'STRING_VALUE', /* required */ signingRegion: 'STRING_VALUE' /* required */ } }, confirmationUrl: 'STRING_VALUE', headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, iotAnalytics: { batchMode: true || false, channelArn: 'STRING_VALUE', channelName: 'STRING_VALUE', roleArn: 'STRING_VALUE' }, iotEvents: { inputName: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ batchMode: true || false, messageId: 'STRING_VALUE' }, iotSiteWise: { putAssetPropertyValueEntries: [ /* required */ { propertyValues: [ /* required */ { timestamp: { /* required */ timeInSeconds: 'STRING_VALUE', /* required */ offsetInNanos: 'STRING_VALUE' }, value: { /* required */ booleanValue: 'STRING_VALUE', doubleValue: 'STRING_VALUE', integerValue: 'STRING_VALUE', stringValue: 'STRING_VALUE' }, quality: 'STRING_VALUE' }, /* more items */ ], assetId: 'STRING_VALUE', entryId: 'STRING_VALUE', propertyAlias: 'STRING_VALUE', propertyId: 'STRING_VALUE' }, /* more items */ ], roleArn: 'STRING_VALUE' /* required */ }, kafka: { clientProperties: { /* required */ '<String>': 'STRING_VALUE', /* '<String>': ... */ }, destinationArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], key: 'STRING_VALUE', partition: 'STRING_VALUE' }, kinesis: { roleArn: 'STRING_VALUE', /* required */ streamName: 'STRING_VALUE', /* required */ partitionKey: 'STRING_VALUE' }, lambda: { functionArn: 'STRING_VALUE' /* required */ }, location: { deviceId: 'STRING_VALUE', /* required */ latitude: 'STRING_VALUE', /* required */ longitude: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ trackerName: 'STRING_VALUE', /* required */ timestamp: { value: 'STRING_VALUE', /* required */ unit: 'STRING_VALUE' } }, openSearch: { endpoint: 'STRING_VALUE', /* required */ id: 'STRING_VALUE', /* required */ index: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ type: 'STRING_VALUE' /* required */ }, republish: { roleArn: 'STRING_VALUE', /* required */ topic: 'STRING_VALUE', /* required */ headers: { contentType: 'STRING_VALUE', correlationData: 'STRING_VALUE', messageExpiry: 'STRING_VALUE', payloadFormatIndicator: 'STRING_VALUE', responseTopic: 'STRING_VALUE', userProperties: [ { key: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ] }, qos: 'NUMBER_VALUE' }, s3: { bucketName: 'STRING_VALUE', /* required */ key: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ cannedAcl: private | public-read | public-read-write | aws-exec-read | authenticated-read | bucket-owner-read | bucket-owner-full-control | log-delivery-write }, salesforce: { token: 'STRING_VALUE', /* required */ url: 'STRING_VALUE' /* required */ }, sns: { roleArn: 'STRING_VALUE', /* required */ targetArn: 'STRING_VALUE', /* required */ messageFormat: RAW | JSON }, sqs: { queueUrl: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ useBase64: true || false }, stepFunctions: { roleArn: 'STRING_VALUE', /* required */ stateMachineName: 'STRING_VALUE', /* required */ executionNamePrefix: 'STRING_VALUE' }, timestream: { databaseName: 'STRING_VALUE', /* required */ dimensions: [ /* required */ { name: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ }, /* more items */ ], roleArn: 'STRING_VALUE', /* required */ tableName: 'STRING_VALUE', /* required */ timestamp: { unit: 'STRING_VALUE', /* required */ value: 'STRING_VALUE' /* required */ } } }, ruleDisabled: true || false } }; iot.replaceTopicRule(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
ruleName
— (String
)The name of the rule.
topicRulePayload
— (map
)The rule payload.
sql
— required — (String
)The SQL statement used to query the topic. For more information, see IoT SQL Reference in the IoT Developer Guide.
description
— (String
)The description of the rule.
actions
— required — (Array<map>
)The actions associated with the rule.
dynamoDB
— (map
)Write to a DynamoDB table.
tableName
— required — (String
)The name of the DynamoDB table.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
operation
— (String
)The type of operation to be performed. This follows the substitution template, so it can be
${operation}
, but the substitution must result in one of the following:INSERT
,UPDATE
, orDELETE
.hashKeyField
— required — (String
)The hash key name.
hashKeyValue
— required — (String
)The hash key value.
hashKeyType
— (String
)The hash key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
rangeKeyField
— (String
)The range key name.
rangeKeyValue
— (String
)The range key value.
rangeKeyType
— (String
)The range key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
payloadField
— (String
)The action payload. This name can be customized.
dynamoDBv2
— (map
)Write to a DynamoDB table. This is a new version of the DynamoDB action. It allows you to write each attribute in an MQTT message payload into a separate DynamoDB column.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
putItem
— required — (map
)Specifies the DynamoDB table to which the message data will be written. For example:
{ "dynamoDBv2": { "roleArn": "aws:iam:12341251:my-role" "putItem": { "tableName": "my-table" } } }
Each attribute in the message payload will be written to a separate column in the DynamoDB database.
tableName
— required — (String
)The table where the message data will be written.
lambda
— (map
)Invoke a Lambda function.
functionArn
— required — (String
)The ARN of the Lambda function.
sns
— (map
)Publish to an Amazon SNS topic.
targetArn
— required — (String
)The ARN of the SNS topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
messageFormat
— (String
)(Optional) The message format of the message to publish. Accepted values are "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this setting to determine if the payload should be parsed and relevant platform-specific bits of the payload should be extracted. To read more about SNS message formats, see https://docs.aws.amazon.com/sns/latest/dg/json-formats.html refer to their official documentation.
Possible values include:"RAW"
"JSON"
sqs
— (map
)Publish to an Amazon SQS queue.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
queueUrl
— required — (String
)The URL of the Amazon SQS queue.
useBase64
— (Boolean
)Specifies whether to use Base64 encoding.
kinesis
— (map
)Write data to an Amazon Kinesis stream.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the Amazon Kinesis stream.
streamName
— required — (String
)The name of the Amazon Kinesis stream.
partitionKey
— (String
)The partition key.
republish
— (map
)Publish to another MQTT topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
topic
— required — (String
)The name of the MQTT topic.
qos
— (Integer
)The Quality of Service (QoS) level to use when republishing messages. The default value is 0.
headers
— (map
)MQTT Version 5.0 headers information. For more information, see MQTT from the Amazon Web Services IoT Core Developer Guide.
payloadFormatIndicator
— (String
)An
Enum
string value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTES
andUTF8_DATA
.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates.
contentType
— (String
)A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type from the MQTT Version 5.0 specification.
Supports substitution templates.
responseTopic
— (String
)A UTF-8 encoded string that's used as the topic name for a response message. The response topic is used to describe the topic which the receiver should publish to as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic from the MQTT Version 5.0 specification.
Supports substitution templates.
correlationData
— (String
)The base64-encoded binary data used by the sender of the request message to identify which request the response message is for when it's received.
For more information, see Correlation Data from the MQTT Version 5.0 specification.
Note: This binary data must be based64-encoded.Supports substitution templates.
messageExpiry
— (String
)A user-defined integer value that will persist a message at the message broker for a specified amount of time to ensure that the message will expire if it's no longer relevant to the subscriber. The value of
messageExpiry
represents the number of seconds before it expires. For more information about the limits ofmessageExpiry
, see Amazon Web Services IoT Core message broker and protocol limits and quotas from the Amazon Web Services Reference Guide.Supports substitution templates.
userProperties
— (Array<map>
)An array of key-value pairs that you define in the MQTT5 header.
key
— required — (String
)A key to be specified in
UserProperty
.value
— required — (String
)A value to be specified in
UserProperty
.
s3
— (map
)Write to an Amazon S3 bucket.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
bucketName
— required — (String
)The Amazon S3 bucket.
key
— required — (String
)The object key. For more information, see Actions, resources, and condition keys for Amazon S3.
cannedAcl
— (String
)The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs.
Possible values include:"private"
"public-read"
"public-read-write"
"aws-exec-read"
"authenticated-read"
"bucket-owner-read"
"bucket-owner-full-control"
"log-delivery-write"
firehose
— (map
)Write to an Amazon Kinesis Firehose stream.
roleArn
— required — (String
)The IAM role that grants access to the Amazon Kinesis Firehose stream.
deliveryStreamName
— required — (String
)The delivery stream name.
separator
— (String
)A character separator that will be used to separate records written to the Firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows newline), ',' (comma).
batchMode
— (Boolean
)Whether to deliver the Kinesis Data Firehose stream as a batch by using
PutRecordBatch
. The default value isfalse
.When
batchMode
istrue
and the rule's SQL statement evaluates to an Array, each Array element forms one record in thePutRecordBatch
request. The resulting array can't have more than 500 records.
cloudwatchMetric
— (map
)Capture a CloudWatch metric.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch metric.
metricNamespace
— required — (String
)The CloudWatch metric namespace name.
metricName
— required — (String
)The CloudWatch metric name.
metricValue
— required — (String
)The CloudWatch metric value.
metricUnit
— required — (String
)The metric unit supported by CloudWatch.
metricTimestamp
— (String
)An optional Unix timestamp.
cloudwatchAlarm
— (map
)Change the state of a CloudWatch alarm.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch alarm.
alarmName
— required — (String
)The CloudWatch alarm name.
stateReason
— required — (String
)The reason for the alarm change.
stateValue
— required — (String
)The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
cloudwatchLogs
— (map
)Send data to CloudWatch Logs.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch log.
logGroupName
— required — (String
)The CloudWatch log group to which the action sends data.
batchMode
— (Boolean
)Indicates whether batches of log records will be extracted and uploaded into CloudWatch. Values include
true
orfalse
(default).
elasticsearch
— (map
)Write data to an Amazon OpenSearch Service domain.
Note: TheElasticsearch
action can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearch
rule action instead. For more information, see OpenSearchAction.roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
salesforce
— (map
)Send a message to a Salesforce IoT Cloud Input Stream.
token
— required — (String
)The token used to authenticate access to the Salesforce IoT Cloud Input Stream. The token is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
url
— required — (String
)The URL exposed by the Salesforce IoT Cloud Input Stream. The URL is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
iotAnalytics
— (map
)Sends message data to an IoT Analytics channel.
channelArn
— (String
)(deprecated) The ARN of the IoT Analytics channel to which message data will be sent.
channelName
— (String
)The name of the IoT Analytics channel to which message data will be sent.
batchMode
— (Boolean
)Whether to process the action as a batch. The default value is
false
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed byBatchPutMessage
to the IoT Analytics channel. The resulting array can't have more than 100 messages.roleArn
— (String
)The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
iotEvents
— (map
)Sends an input to an IoT Events detector.
inputName
— required — (String
)The name of the IoT Events input.
messageId
— (String
)The ID of the message. The default
messageId
is a new UUID value.When
batchMode
istrue
, you can't specify amessageId
--a new UUID value will be assigned.Assign a value to this property to ensure that only one input (message) with a given
messageId
will be processed by an IoT Events detector.batchMode
— (Boolean
)Whether to process the event actions as a batch. The default value is
false
.When
batchMode
istrue
, you can't specify amessageId
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when it's sent to IoT Events by callingBatchPutMessage
. The resulting array can't have more than 10 messages.roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an input to an IoT Events detector. ("Action":"iotevents:BatchPutMessage").
iotSiteWise
— (map
)Sends data from the MQTT message that triggered the rule to IoT SiteWise asset properties.
putAssetPropertyValueEntries
— required — (Array<map>
)A list of asset property value entries.
entryId
— (String
)Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
assetId
— (String
)The ID of the IoT SiteWise asset. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyId
— (String
)The ID of the asset's property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyAlias
— (String
)The name of the property alias associated with your asset property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyValues
— required — (Array<map>
)A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
value
— required — (map
)The value of the asset property.
stringValue
— (String
)Optional. The string value of the value entry. Accepts substitution templates.
integerValue
— (String
)Optional. A string that contains the integer value of the value entry. Accepts substitution templates.
doubleValue
— (String
)Optional. A string that contains the double value of the value entry. Accepts substitution templates.
booleanValue
— (String
)Optional. A string that contains the boolean value (
true
orfalse
) of the value entry. Accepts substitution templates.
timestamp
— required — (map
)The asset property value timestamp.
timeInSeconds
— required — (String
)A string that contains the time in seconds since epoch. Accepts substitution templates.
offsetInNanos
— (String
)Optional. A string that contains the nanosecond time offset. Accepts substitution templates.
quality
— (String
)Optional. A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD
,BAD
, orUNCERTAIN
.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an asset property value to IoT SiteWise. (
"Action": "iotsitewise:BatchPutAssetPropertyValue"
). The trust policy can restrict access to specific asset hierarchy paths.
stepFunctions
— (map
)Starts execution of a Step Functions state machine.
executionNamePrefix
— (String
)(Optional) A name will be given to the state machine execution consisting of this prefix followed by a UUID. Step Functions automatically creates a unique name for each state machine execution if one is not provided.
stateMachineName
— required — (String
)The name of the Step Functions state machine whose execution will be started.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to start execution of a state machine ("Action":"states:StartExecution").
timestream
— (map
)The Timestream rule action writes attributes (measures) from an MQTT message into an Amazon Timestream table. For more information, see the Timestream topic rule action documentation.
roleArn
— required — (String
)The ARN of the role that grants permission to write to the Amazon Timestream database table.
databaseName
— required — (String
)The name of an Amazon Timestream database.
tableName
— required — (String
)The name of the database table into which to write the measure records.
dimensions
— required — (Array<map>
)Metadata attributes of the time series that are written in each measure record.
name
— required — (String
)The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.
Dimensions cannot be named:
measure_name
,measure_value
, ortime
. These names are reserved. Dimension names cannot start withts_
ormeasure_value
and they cannot contain the colon (:
) character.value
— required — (String
)The value to write in this column of the database record.
timestamp
— (map
)Specifies an application-defined value to replace the default value assigned to the Timestream record's timestamp in the
time
column.You can use this property to specify the value and the precision of the Timestream record's timestamp. You can specify a value from the message payload or a value computed by a substitution template.
If omitted, the topic rule action assigns the timestamp, in milliseconds, at the time it processed the rule.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— required — (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
http
— (map
)Send data to an HTTPS endpoint.
url
— required — (String
)The endpoint URL. If substitution templates are used in the URL, you must also specify a
confirmationUrl
. If this is a new destination, a newTopicRuleDestination
is created if possible.confirmationUrl
— (String
)The URL to which IoT sends a confirmation message. The value of the confirmation URL must be a prefix of the endpoint URL. If you do not specify a confirmation URL IoT uses the endpoint URL as the confirmation URL. If you use substitution templates in the confirmationUrl, you must create and enable topic rule destinations that match each possible value of the substitution template before traffic is allowed to your endpoint URL.
headers
— (Array<map>
)The HTTP headers to send with the message data.
key
— required — (String
)The HTTP header key.
value
— required — (String
)The HTTP header value. Substitution templates are supported.
auth
— (map
)The authentication method to use when sending data to an HTTPS endpoint.
sigv4
— (map
)Use Sig V4 authorization. For more information, see Signature Version 4 Signing Process.
signingRegion
— required — (String
)The signing region.
serviceName
— required — (String
)The service name to use while signing with Sig V4.
roleArn
— required — (String
)The ARN of the signing role.
kafka
— (map
)Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
destinationArn
— required — (String
)The ARN of Kafka action's VPC
TopicRuleDestination
.topic
— required — (String
)The Kafka topic for messages to be sent to the Kafka broker.
key
— (String
)The Kafka message key.
partition
— (String
)The Kafka message partition.
clientProperties
— required — (map<String>
)Properties of the Apache Kafka producer client.
headers
— (Array<map>
)The list of Kafka headers that you specify.
key
— required — (String
)The key of the Kafka header.
value
— required — (String
)The value of the Kafka header.
openSearch
— (map
)Write data to an Amazon OpenSearch Service domain.
roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The OpenSearch index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
location
— (map
)The Amazon Location Service rule action sends device location updates from an MQTT message to an Amazon Location tracker resource.
roleArn
— required — (String
)The IAM role that grants permission to write to the Amazon Location resource.
trackerName
— required — (String
)The name of the tracker resource in Amazon Location in which the location is updated.
deviceId
— required — (String
)The unique ID of the device providing the location data.
timestamp
— (map
)The time that the location data was sampled. The default value is the time the MQTT message was processed.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
latitude
— required — (String
)A string that evaluates to a double value that represents the latitude of the device's location.
longitude
— required — (String
)A string that evaluates to a double value that represents the longitude of the device's location.
ruleDisabled
— (Boolean
)Specifies whether the rule is disabled.
awsIotSqlVersion
— (String
)The version of the SQL rules engine to use when evaluating the rule.
errorAction
— (map
)The action to take when an error occurs.
dynamoDB
— (map
)Write to a DynamoDB table.
tableName
— required — (String
)The name of the DynamoDB table.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
operation
— (String
)The type of operation to be performed. This follows the substitution template, so it can be
${operation}
, but the substitution must result in one of the following:INSERT
,UPDATE
, orDELETE
.hashKeyField
— required — (String
)The hash key name.
hashKeyValue
— required — (String
)The hash key value.
hashKeyType
— (String
)The hash key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
rangeKeyField
— (String
)The range key name.
rangeKeyValue
— (String
)The range key value.
rangeKeyType
— (String
)The range key type. Valid values are "STRING" or "NUMBER"
Possible values include:"STRING"
"NUMBER"
payloadField
— (String
)The action payload. This name can be customized.
dynamoDBv2
— (map
)Write to a DynamoDB table. This is a new version of the DynamoDB action. It allows you to write each attribute in an MQTT message payload into a separate DynamoDB column.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the DynamoDB table.
putItem
— required — (map
)Specifies the DynamoDB table to which the message data will be written. For example:
{ "dynamoDBv2": { "roleArn": "aws:iam:12341251:my-role" "putItem": { "tableName": "my-table" } } }
Each attribute in the message payload will be written to a separate column in the DynamoDB database.
tableName
— required — (String
)The table where the message data will be written.
lambda
— (map
)Invoke a Lambda function.
functionArn
— required — (String
)The ARN of the Lambda function.
sns
— (map
)Publish to an Amazon SNS topic.
targetArn
— required — (String
)The ARN of the SNS topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
messageFormat
— (String
)(Optional) The message format of the message to publish. Accepted values are "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this setting to determine if the payload should be parsed and relevant platform-specific bits of the payload should be extracted. To read more about SNS message formats, see https://docs.aws.amazon.com/sns/latest/dg/json-formats.html refer to their official documentation.
Possible values include:"RAW"
"JSON"
sqs
— (map
)Publish to an Amazon SQS queue.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
queueUrl
— required — (String
)The URL of the Amazon SQS queue.
useBase64
— (Boolean
)Specifies whether to use Base64 encoding.
kinesis
— (map
)Write data to an Amazon Kinesis stream.
roleArn
— required — (String
)The ARN of the IAM role that grants access to the Amazon Kinesis stream.
streamName
— required — (String
)The name of the Amazon Kinesis stream.
partitionKey
— (String
)The partition key.
republish
— (map
)Publish to another MQTT topic.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
topic
— required — (String
)The name of the MQTT topic.
qos
— (Integer
)The Quality of Service (QoS) level to use when republishing messages. The default value is 0.
headers
— (map
)MQTT Version 5.0 headers information. For more information, see MQTT from the Amazon Web Services IoT Core Developer Guide.
payloadFormatIndicator
— (String
)An
Enum
string value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTES
andUTF8_DATA
.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates.
contentType
— (String
)A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type from the MQTT Version 5.0 specification.
Supports substitution templates.
responseTopic
— (String
)A UTF-8 encoded string that's used as the topic name for a response message. The response topic is used to describe the topic which the receiver should publish to as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic from the MQTT Version 5.0 specification.
Supports substitution templates.
correlationData
— (String
)The base64-encoded binary data used by the sender of the request message to identify which request the response message is for when it's received.
For more information, see Correlation Data from the MQTT Version 5.0 specification.
Note: This binary data must be based64-encoded.Supports substitution templates.
messageExpiry
— (String
)A user-defined integer value that will persist a message at the message broker for a specified amount of time to ensure that the message will expire if it's no longer relevant to the subscriber. The value of
messageExpiry
represents the number of seconds before it expires. For more information about the limits ofmessageExpiry
, see Amazon Web Services IoT Core message broker and protocol limits and quotas from the Amazon Web Services Reference Guide.Supports substitution templates.
userProperties
— (Array<map>
)An array of key-value pairs that you define in the MQTT5 header.
key
— required — (String
)A key to be specified in
UserProperty
.value
— required — (String
)A value to be specified in
UserProperty
.
s3
— (map
)Write to an Amazon S3 bucket.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
bucketName
— required — (String
)The Amazon S3 bucket.
key
— required — (String
)The object key. For more information, see Actions, resources, and condition keys for Amazon S3.
cannedAcl
— (String
)The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs.
Possible values include:"private"
"public-read"
"public-read-write"
"aws-exec-read"
"authenticated-read"
"bucket-owner-read"
"bucket-owner-full-control"
"log-delivery-write"
firehose
— (map
)Write to an Amazon Kinesis Firehose stream.
roleArn
— required — (String
)The IAM role that grants access to the Amazon Kinesis Firehose stream.
deliveryStreamName
— required — (String
)The delivery stream name.
separator
— (String
)A character separator that will be used to separate records written to the Firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows newline), ',' (comma).
batchMode
— (Boolean
)Whether to deliver the Kinesis Data Firehose stream as a batch by using
PutRecordBatch
. The default value isfalse
.When
batchMode
istrue
and the rule's SQL statement evaluates to an Array, each Array element forms one record in thePutRecordBatch
request. The resulting array can't have more than 500 records.
cloudwatchMetric
— (map
)Capture a CloudWatch metric.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch metric.
metricNamespace
— required — (String
)The CloudWatch metric namespace name.
metricName
— required — (String
)The CloudWatch metric name.
metricValue
— required — (String
)The CloudWatch metric value.
metricUnit
— required — (String
)The metric unit supported by CloudWatch.
metricTimestamp
— (String
)An optional Unix timestamp.
cloudwatchAlarm
— (map
)Change the state of a CloudWatch alarm.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch alarm.
alarmName
— required — (String
)The CloudWatch alarm name.
stateReason
— required — (String
)The reason for the alarm change.
stateValue
— required — (String
)The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
cloudwatchLogs
— (map
)Send data to CloudWatch Logs.
roleArn
— required — (String
)The IAM role that allows access to the CloudWatch log.
logGroupName
— required — (String
)The CloudWatch log group to which the action sends data.
batchMode
— (Boolean
)Indicates whether batches of log records will be extracted and uploaded into CloudWatch. Values include
true
orfalse
(default).
elasticsearch
— (map
)Write data to an Amazon OpenSearch Service domain.
Note: TheElasticsearch
action can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearch
rule action instead. For more information, see OpenSearchAction.roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
salesforce
— (map
)Send a message to a Salesforce IoT Cloud Input Stream.
token
— required — (String
)The token used to authenticate access to the Salesforce IoT Cloud Input Stream. The token is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
url
— required — (String
)The URL exposed by the Salesforce IoT Cloud Input Stream. The URL is available from the Salesforce IoT Cloud platform after creation of the Input Stream.
iotAnalytics
— (map
)Sends message data to an IoT Analytics channel.
channelArn
— (String
)(deprecated) The ARN of the IoT Analytics channel to which message data will be sent.
channelName
— (String
)The name of the IoT Analytics channel to which message data will be sent.
batchMode
— (Boolean
)Whether to process the action as a batch. The default value is
false
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed byBatchPutMessage
to the IoT Analytics channel. The resulting array can't have more than 100 messages.roleArn
— (String
)The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
iotEvents
— (map
)Sends an input to an IoT Events detector.
inputName
— required — (String
)The name of the IoT Events input.
messageId
— (String
)The ID of the message. The default
messageId
is a new UUID value.When
batchMode
istrue
, you can't specify amessageId
--a new UUID value will be assigned.Assign a value to this property to ensure that only one input (message) with a given
messageId
will be processed by an IoT Events detector.batchMode
— (Boolean
)Whether to process the event actions as a batch. The default value is
false
.When
batchMode
istrue
, you can't specify amessageId
.When
batchMode
istrue
and the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when it's sent to IoT Events by callingBatchPutMessage
. The resulting array can't have more than 10 messages.roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an input to an IoT Events detector. ("Action":"iotevents:BatchPutMessage").
iotSiteWise
— (map
)Sends data from the MQTT message that triggered the rule to IoT SiteWise asset properties.
putAssetPropertyValueEntries
— required — (Array<map>
)A list of asset property value entries.
entryId
— (String
)Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
assetId
— (String
)The ID of the IoT SiteWise asset. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyId
— (String
)The ID of the asset's property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyAlias
— (String
)The name of the property alias associated with your asset property. You must specify either a
propertyAlias
or both analiasId
and apropertyId
. Accepts substitution templates.propertyValues
— required — (Array<map>
)A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
value
— required — (map
)The value of the asset property.
stringValue
— (String
)Optional. The string value of the value entry. Accepts substitution templates.
integerValue
— (String
)Optional. A string that contains the integer value of the value entry. Accepts substitution templates.
doubleValue
— (String
)Optional. A string that contains the double value of the value entry. Accepts substitution templates.
booleanValue
— (String
)Optional. A string that contains the boolean value (
true
orfalse
) of the value entry. Accepts substitution templates.
timestamp
— required — (map
)The asset property value timestamp.
timeInSeconds
— required — (String
)A string that contains the time in seconds since epoch. Accepts substitution templates.
offsetInNanos
— (String
)Optional. A string that contains the nanosecond time offset. Accepts substitution templates.
quality
— (String
)Optional. A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD
,BAD
, orUNCERTAIN
.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to send an asset property value to IoT SiteWise. (
"Action": "iotsitewise:BatchPutAssetPropertyValue"
). The trust policy can restrict access to specific asset hierarchy paths.
stepFunctions
— (map
)Starts execution of a Step Functions state machine.
executionNamePrefix
— (String
)(Optional) A name will be given to the state machine execution consisting of this prefix followed by a UUID. Step Functions automatically creates a unique name for each state machine execution if one is not provided.
stateMachineName
— required — (String
)The name of the Step Functions state machine whose execution will be started.
roleArn
— required — (String
)The ARN of the role that grants IoT permission to start execution of a state machine ("Action":"states:StartExecution").
timestream
— (map
)The Timestream rule action writes attributes (measures) from an MQTT message into an Amazon Timestream table. For more information, see the Timestream topic rule action documentation.
roleArn
— required — (String
)The ARN of the role that grants permission to write to the Amazon Timestream database table.
databaseName
— required — (String
)The name of an Amazon Timestream database.
tableName
— required — (String
)The name of the database table into which to write the measure records.
dimensions
— required — (Array<map>
)Metadata attributes of the time series that are written in each measure record.
name
— required — (String
)The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.
Dimensions cannot be named:
measure_name
,measure_value
, ortime
. These names are reserved. Dimension names cannot start withts_
ormeasure_value
and they cannot contain the colon (:
) character.value
— required — (String
)The value to write in this column of the database record.
timestamp
— (map
)Specifies an application-defined value to replace the default value assigned to the Timestream record's timestamp in the
time
column.You can use this property to specify the value and the precision of the Timestream record's timestamp. You can specify a value from the message payload or a value computed by a substitution template.
If omitted, the topic rule action assigns the timestamp, in milliseconds, at the time it processed the rule.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— required — (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
http
— (map
)Send data to an HTTPS endpoint.
url
— required — (String
)The endpoint URL. If substitution templates are used in the URL, you must also specify a
confirmationUrl
. If this is a new destination, a newTopicRuleDestination
is created if possible.confirmationUrl
— (String
)The URL to which IoT sends a confirmation message. The value of the confirmation URL must be a prefix of the endpoint URL. If you do not specify a confirmation URL IoT uses the endpoint URL as the confirmation URL. If you use substitution templates in the confirmationUrl, you must create and enable topic rule destinations that match each possible value of the substitution template before traffic is allowed to your endpoint URL.
headers
— (Array<map>
)The HTTP headers to send with the message data.
key
— required — (String
)The HTTP header key.
value
— required — (String
)The HTTP header value. Substitution templates are supported.
auth
— (map
)The authentication method to use when sending data to an HTTPS endpoint.
sigv4
— (map
)Use Sig V4 authorization. For more information, see Signature Version 4 Signing Process.
signingRegion
— required — (String
)The signing region.
serviceName
— required — (String
)The service name to use while signing with Sig V4.
roleArn
— required — (String
)The ARN of the signing role.
kafka
— (map
)Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
destinationArn
— required — (String
)The ARN of Kafka action's VPC
TopicRuleDestination
.topic
— required — (String
)The Kafka topic for messages to be sent to the Kafka broker.
key
— (String
)The Kafka message key.
partition
— (String
)The Kafka message partition.
clientProperties
— required — (map<String>
)Properties of the Apache Kafka producer client.
headers
— (Array<map>
)The list of Kafka headers that you specify.
key
— required — (String
)The key of the Kafka header.
value
— required — (String
)The value of the Kafka header.
openSearch
— (map
)Write data to an Amazon OpenSearch Service domain.
roleArn
— required — (String
)The IAM role ARN that has access to OpenSearch.
endpoint
— required — (String
)The endpoint of your OpenSearch domain.
index
— required — (String
)The OpenSearch index where you want to store your data.
type
— required — (String
)The type of document you are storing.
id
— required — (String
)The unique identifier for the document you are storing.
location
— (map
)The Amazon Location Service rule action sends device location updates from an MQTT message to an Amazon Location tracker resource.
roleArn
— required — (String
)The IAM role that grants permission to write to the Amazon Location resource.
trackerName
— required — (String
)The name of the tracker resource in Amazon Location in which the location is updated.
deviceId
— required — (String
)The unique ID of the device providing the location data.
timestamp
— (map
)The time that the location data was sampled. The default value is the time the MQTT message was processed.
value
— required — (String
)An expression that returns a long epoch time value.
unit
— (String
)The precision of the timestamp value that results from the expression described in
value
.Valid values:
SECONDS
|MILLISECONDS
|MICROSECONDS
|NANOSECONDS
. The default isMILLISECONDS
.
latitude
— required — (String
)A string that evaluates to a double value that represents the latitude of the device's location.
longitude
— required — (String
)A string that evaluates to a double value that represents the longitude of the device's location.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
searchIndex(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the searchIndex operation
var params = { queryString: 'STRING_VALUE', /* required */ indexName: 'STRING_VALUE', maxResults: 'NUMBER_VALUE', nextToken: 'STRING_VALUE', queryVersion: 'STRING_VALUE' }; iot.searchIndex(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
indexName
— (String
)The search index name.
queryString
— (String
)The search query string. For more information about the search query syntax, see Query syntax.
nextToken
— (String
)The token used to get the next set of results, or
null
if there are no additional results.maxResults
— (Integer
)The maximum number of results to return per page at one time. This maximum number cannot exceed 100. The response might contain fewer results but will never contain more. You can use
nextToken
to retrieve the next set of results untilnextToken
returnsNULL
.queryVersion
— (String
)The query version.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:nextToken
— (String
)The token used to get the next set of results, or
null
if there are no additional results.things
— (Array<map>
)The things that match the search query.
thingName
— (String
)The thing name.
thingId
— (String
)The thing ID.
thingTypeName
— (String
)The thing type name.
thingGroupNames
— (Array<String>
)Thing group names.
attributes
— (map<String>
)The attributes.
shadow
— (String
)The unnamed shadow and named shadow.
For more information about shadows, see IoT Device Shadow service.
deviceDefender
— (String
)Contains Device Defender data.
For more information about Device Defender, see Device Defender.
connectivity
— (map
)Indicates whether the thing is connected to the Amazon Web Services IoT Core service.
connected
— (Boolean
)True if the thing is connected to the Amazon Web Services IoT Core service; false if it is not connected.
timestamp
— (Integer
)The epoch time (in milliseconds) when the thing last connected or disconnected. If the thing has been disconnected for approximately an hour, the time value might be missing.
disconnectReason
— (String
)The reason why the client is disconnected. If the thing has been disconnected for approximately an hour, the
disconnectReason
value might be missing.
thingGroups
— (Array<map>
)The thing groups that match the search query.
thingGroupName
— (String
)The thing group name.
thingGroupId
— (String
)The thing group ID.
thingGroupDescription
— (String
)The thing group description.
attributes
— (map<String>
)The thing group attributes.
parentGroupNames
— (Array<String>
)Parent group names.
-
(AWS.Response)
—
Returns:
setDefaultAuthorizer(params = {}, callback) ⇒ AWS.Request
Sets the default authorizer. This will be used if a websocket connection is made without specifying an authorizer.
Requires permission to access the SetDefaultAuthorizer action.
Service Reference:
Examples:
Calling the setDefaultAuthorizer operation
var params = { authorizerName: 'STRING_VALUE' /* required */ }; iot.setDefaultAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
authorizerName
— (String
)The authorizer name.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authorizerName
— (String
)The authorizer name.
authorizerArn
— (String
)The authorizer ARN.
-
(AWS.Response)
—
Returns:
setDefaultPolicyVersion(params = {}, callback) ⇒ AWS.Request
Sets the specified version of the specified policy as the policy's default (operative) version. This action affects all certificates to which the policy is attached. To list the principals the policy is attached to, use the ListPrincipalPolicies action.
Requires permission to access the SetDefaultPolicyVersion action.
Service Reference:
Examples:
Calling the setDefaultPolicyVersion operation
var params = { policyName: 'STRING_VALUE', /* required */ policyVersionId: 'STRING_VALUE' /* required */ }; iot.setDefaultPolicyVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
policyName
— (String
)The policy name.
policyVersionId
— (String
)The policy version ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
setLoggingOptions(params = {}, callback) ⇒ AWS.Request
Sets the logging options.
NOTE: use of this command is not recommended. Use
SetV2LoggingOptions
instead.Requires permission to access the SetLoggingOptions action.
Service Reference:
Examples:
Calling the setLoggingOptions operation
var params = { loggingOptionsPayload: { /* required */ roleArn: 'STRING_VALUE', /* required */ logLevel: DEBUG | INFO | ERROR | WARN | DISABLED } }; iot.setLoggingOptions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
loggingOptionsPayload
— (map
)The logging options payload.
roleArn
— required — (String
)The ARN of the IAM role that grants access.
logLevel
— (String
)The log level.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
setV2LoggingLevel(params = {}, callback) ⇒ AWS.Request
Sets the logging level.
Requires permission to access the SetV2LoggingLevel action.
Service Reference:
Examples:
Calling the setV2LoggingLevel operation
var params = { logLevel: DEBUG | INFO | ERROR | WARN | DISABLED, /* required */ logTarget: { /* required */ targetType: DEFAULT | THING_GROUP | CLIENT_ID | SOURCE_IP | PRINCIPAL_ID, /* required */ targetName: 'STRING_VALUE' } }; iot.setV2LoggingLevel(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
logTarget
— (map
)The log target.
targetType
— required — (String
)The target type.
Possible values include:"DEFAULT"
"THING_GROUP"
"CLIENT_ID"
"SOURCE_IP"
"PRINCIPAL_ID"
targetName
— (String
)The target name.
logLevel
— (String
)The log level.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
setV2LoggingOptions(params = {}, callback) ⇒ AWS.Request
Sets the logging options for the V2 logging service.
Requires permission to access the SetV2LoggingOptions action.
Service Reference:
Examples:
Calling the setV2LoggingOptions operation
var params = { defaultLogLevel: DEBUG | INFO | ERROR | WARN | DISABLED, disableAllLogs: true || false, roleArn: 'STRING_VALUE' }; iot.setV2LoggingOptions(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
roleArn
— (String
)The ARN of the role that allows IoT to write to Cloudwatch logs.
defaultLogLevel
— (String
)The default logging level.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
disableAllLogs
— (Boolean
)If true all logs are disabled. The default is false.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
startAuditMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Starts a task that applies a set of mitigation actions to the specified target.
Requires permission to access the StartAuditMitigationActionsTask action.
Service Reference:
Examples:
Calling the startAuditMitigationActionsTask operation
var params = { auditCheckToActionsMapping: { /* required */ '<AuditCheckName>': [ 'STRING_VALUE', /* more items */ ], /* '<AuditCheckName>': ... */ }, clientRequestToken: 'STRING_VALUE', /* required */ target: { /* required */ auditCheckToReasonCodeFilter: { '<AuditCheckName>': [ 'STRING_VALUE', /* more items */ ], /* '<AuditCheckName>': ... */ }, auditTaskId: 'STRING_VALUE', findingIds: [ 'STRING_VALUE', /* more items */ ] }, taskId: 'STRING_VALUE' /* required */ }; iot.startAuditMitigationActionsTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)A unique identifier for the task. You can use this identifier to check the status of the task or to cancel it.
target
— (map
)Specifies the audit findings to which the mitigation actions are applied. You can apply them to a type of audit check, to all findings from an audit, or to a specific set of findings.
auditTaskId
— (String
)If the task will apply a mitigation action to findings from a specific audit, this value uniquely identifies the audit.
findingIds
— (Array<String>
)If the task will apply a mitigation action to one or more listed findings, this value uniquely identifies those findings.
auditCheckToReasonCodeFilter
— (map<Array<String>>
)Specifies a filter in the form of an audit check and set of reason codes that identify the findings from the audit to which the audit mitigation actions task apply.
auditCheckToActionsMapping
— (map<Array<String>>
)For an audit check, specifies which mitigation actions to apply. Those actions must be defined in your Amazon Web Services accounts.
clientRequestToken
— (String
)Each audit mitigation task must have a unique client request token. If you try to start a new task with the same token as a task that already exists, an exception occurs. If you omit this value, a unique client request token is generated automatically.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskId
— (String
)The unique identifier for the audit mitigation task. This matches the
taskId
that you specified in the request.
-
(AWS.Response)
—
Returns:
startDetectMitigationActionsTask(params = {}, callback) ⇒ AWS.Request
Starts a Device Defender ML Detect mitigation actions task.
Requires permission to access the StartDetectMitigationActionsTask action.
Service Reference:
Examples:
Calling the startDetectMitigationActionsTask operation
var params = { actions: [ /* required */ 'STRING_VALUE', /* more items */ ], clientRequestToken: 'STRING_VALUE', /* required */ target: { /* required */ behaviorName: 'STRING_VALUE', securityProfileName: 'STRING_VALUE', violationIds: [ 'STRING_VALUE', /* more items */ ] }, taskId: 'STRING_VALUE', /* required */ includeOnlyActiveViolations: true || false, includeSuppressedAlerts: true || false, violationEventOccurrenceRange: { endTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */ startTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789 /* required */ } }; iot.startDetectMitigationActionsTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The unique identifier of the task.
target
— (map
)Specifies the ML Detect findings to which the mitigation actions are applied.
violationIds
— (Array<String>
)The unique identifiers of the violations.
securityProfileName
— (String
)The name of the security profile.
behaviorName
— (String
)The name of the behavior.
actions
— (Array<String>
)The actions to be performed when a device has unexpected behavior.
violationEventOccurrenceRange
— (map
)Specifies the time period of which violation events occurred between.
startTime
— required — (Date
)The start date and time of a time period in which violation events occurred.
endTime
— required — (Date
)The end date and time of a time period in which violation events occurred.
includeOnlyActiveViolations
— (Boolean
)Specifies to list only active violations.
includeSuppressedAlerts
— (Boolean
)Specifies to include suppressed alerts.
clientRequestToken
— (String
)Each mitigation action task must have a unique client request token. If you try to create a new task with the same token as a task that already exists, an exception occurs. If you omit this value, Amazon Web Services SDKs will automatically generate a unique client request.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskId
— (String
)The unique identifier of the task.
-
(AWS.Response)
—
Returns:
startOnDemandAuditTask(params = {}, callback) ⇒ AWS.Request
Starts an on-demand Device Defender audit.
Requires permission to access the StartOnDemandAuditTask action.
Service Reference:
Examples:
Calling the startOnDemandAuditTask operation
var params = { targetCheckNames: [ /* required */ 'STRING_VALUE', /* more items */ ] }; iot.startOnDemandAuditTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
targetCheckNames
— (Array<String>
)Which checks are performed during the audit. The checks you specify must be enabled for your account or an exception occurs. Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled orUpdateAccountAuditConfiguration
to select which checks are enabled.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskId
— (String
)The ID of the on-demand audit you started.
-
(AWS.Response)
—
Returns:
startThingRegistrationTask(params = {}, callback) ⇒ AWS.Request
Creates a bulk thing provisioning task.
Requires permission to access the StartThingRegistrationTask action.
Service Reference:
Examples:
Calling the startThingRegistrationTask operation
var params = { inputFileBucket: 'STRING_VALUE', /* required */ inputFileKey: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE', /* required */ templateBody: 'STRING_VALUE' /* required */ }; iot.startThingRegistrationTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateBody
— (String
)The provisioning template.
inputFileBucket
— (String
)The S3 bucket that contains the input file.
inputFileKey
— (String
)The name of input file within the S3 bucket. This file contains a newline delimited JSON file. Each line contains the parameter values to provision one device (thing).
roleArn
— (String
)The IAM role ARN that grants permission the input file.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:taskId
— (String
)The bulk thing provisioning task ID.
-
(AWS.Response)
—
Returns:
stopThingRegistrationTask(params = {}, callback) ⇒ AWS.Request
Cancels a bulk thing provisioning task.
Requires permission to access the StopThingRegistrationTask action.
Service Reference:
Examples:
Calling the stopThingRegistrationTask operation
var params = { taskId: 'STRING_VALUE' /* required */ }; iot.stopThingRegistrationTask(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
taskId
— (String
)The bulk thing provisioning task ID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
tagResource(params = {}, callback) ⇒ AWS.Request
Adds to or modifies the tags of the given resource. Tags are metadata which can be used to manage a resource.
Requires permission to access the TagResource action.
Service Reference:
Examples:
Calling the tagResource operation
var params = { resourceArn: 'STRING_VALUE', /* required */ tags: [ /* required */ { Key: 'STRING_VALUE', /* required */ Value: 'STRING_VALUE' }, /* more items */ ] }; iot.tagResource(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
resourceArn
— (String
)The ARN of the resource.
tags
— (Array<map>
)The new or modified tags for the resource.
Key
— required — (String
)The tag's key.
Value
— (String
)The tag's value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
testAuthorization(params = {}, callback) ⇒ AWS.Request
Tests if a specified principal is authorized to perform an IoT action on a specified resource. Use this to test and debug the authorization behavior of devices that connect to the IoT device gateway.
Requires permission to access the TestAuthorization action.
Service Reference:
Examples:
Calling the testAuthorization operation
var params = { authInfos: [ /* required */ { resources: [ /* required */ 'STRING_VALUE', /* more items */ ], actionType: PUBLISH | SUBSCRIBE | RECEIVE | CONNECT }, /* more items */ ], clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', policyNamesToAdd: [ 'STRING_VALUE', /* more items */ ], policyNamesToSkip: [ 'STRING_VALUE', /* more items */ ], principal: 'STRING_VALUE' }; iot.testAuthorization(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
principal
— (String
)The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
cognitoIdentityPoolId
— (String
)The Cognito identity pool ID.
authInfos
— (Array<map>
)A list of authorization info objects. Simulating authorization will create a response for each
authInfo
object in the list.actionType
— (String
)The type of action for which the principal is being authorized.
Possible values include:"PUBLISH"
"SUBSCRIBE"
"RECEIVE"
"CONNECT"
resources
— required — (Array<String>
)The resources for which the principal is being authorized to perform the specified action.
clientId
— (String
)The MQTT client ID.
policyNamesToAdd
— (Array<String>
)When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
policyNamesToSkip
— (Array<String>
)When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authResults
— (Array<map>
)The authentication results.
authInfo
— (map
)Authorization information.
actionType
— (String
)The type of action for which the principal is being authorized.
Possible values include:"PUBLISH"
"SUBSCRIBE"
"RECEIVE"
"CONNECT"
resources
— required — (Array<String>
)The resources for which the principal is being authorized to perform the specified action.
allowed
— (map
)The policies and statements that allowed the specified action.
policies
— (Array<map>
)A list of policies that allowed the authentication.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
denied
— (map
)The policies and statements that denied the specified action.
implicitDeny
— (map
)Information that implicitly denies the authorization. When a policy doesn't explicitly deny or allow an action on a resource it is considered an implicit deny.
policies
— (Array<map>
)Policies that don't contain a matching allow or deny statement for the specified action on the specified resource.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
explicitDeny
— (map
)Information that explicitly denies the authorization.
policies
— (Array<map>
)The policies that denied the authorization.
policyName
— (String
)The policy name.
policyArn
— (String
)The policy ARN.
authDecision
— (String
)The final authorization decision of this scenario. Multiple statements are taken into account when determining the authorization decision. An explicit deny statement can override multiple allow statements.
Possible values include:"ALLOWED"
"EXPLICIT_DENY"
"IMPLICIT_DENY"
missingContextValues
— (Array<String>
)Contains any missing context values found while evaluating policy.
-
(AWS.Response)
—
Returns:
testInvokeAuthorizer(params = {}, callback) ⇒ AWS.Request
Tests a custom authorization behavior by invoking a specified custom authorizer. Use this to test and debug the custom authorization behavior of devices that connect to the IoT device gateway.
Requires permission to access the TestInvokeAuthorizer action.
Service Reference:
Examples:
Calling the testInvokeAuthorizer operation
var params = { authorizerName: 'STRING_VALUE', /* required */ httpContext: { headers: { '<HttpHeaderName>': 'STRING_VALUE', /* '<HttpHeaderName>': ... */ }, queryString: 'STRING_VALUE' }, mqttContext: { clientId: 'STRING_VALUE', password: Buffer.from('...') || 'STRING_VALUE' /* Strings will be Base-64 encoded on your behalf */, username: 'STRING_VALUE' }, tlsContext: { serverName: 'STRING_VALUE' }, token: 'STRING_VALUE', tokenSignature: 'STRING_VALUE' }; iot.testInvokeAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
authorizerName
— (String
)The custom authorizer name.
token
— (String
)The token returned by your custom authentication service.
tokenSignature
— (String
)The signature made with the token and your custom authentication service's private key. This value must be Base-64-encoded.
httpContext
— (map
)Specifies a test HTTP authorization request.
headers
— (map<String>
)The header keys and values in an HTTP authorization request.
queryString
— (String
)The query string keys and values in an HTTP authorization request.
mqttContext
— (map
)Specifies a test MQTT authorization request.
username
— (String
)The value of the
username
key in an MQTT authorization request.password
— (Buffer, Typed Array, Blob, String
)The value of the
password
key in an MQTT authorization request.clientId
— (String
)The value of the
clientId
key in an MQTT authorization request.
tlsContext
— (map
)Specifies a test TLS authorization request.
serverName
— (String
)The value of the
serverName
key in a TLS authorization request.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:isAuthenticated
— (Boolean
)True if the token is authenticated, otherwise false.
principalId
— (String
)The principal ID.
policyDocuments
— (Array<String>
)IAM policy documents.
refreshAfterInSeconds
— (Integer
)The number of seconds after which the temporary credentials are refreshed.
disconnectAfterInSeconds
— (Integer
)The number of seconds after which the connection is terminated.
-
(AWS.Response)
—
Returns:
transferCertificate(params = {}, callback) ⇒ AWS.Request
Transfers the specified certificate to the specified Amazon Web Services account.
Requires permission to access the TransferCertificate action.
You can cancel the transfer until it is acknowledged by the recipient.
No notification is sent to the transfer destination's account. It is up to the caller to notify the transfer target.
The certificate being transferred must not be in the ACTIVE state. You can use the UpdateCertificate action to deactivate it.
The certificate must not have any policies attached to it. You can use the DetachPolicy action to detach them.
Service Reference:
Examples:
Calling the transferCertificate operation
var params = { certificateId: 'STRING_VALUE', /* required */ targetAwsAccount: 'STRING_VALUE', /* required */ transferMessage: 'STRING_VALUE' }; iot.transferCertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
targetAwsAccount
— (String
)The Amazon Web Services account.
transferMessage
— (String
)The transfer message.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:transferredCertificateArn
— (String
)The ARN of the certificate.
-
(AWS.Response)
—
Returns:
untagResource(params = {}, callback) ⇒ AWS.Request
Removes the given tags (metadata) from the resource.
Requires permission to access the UntagResource action.
Service Reference:
Examples:
Calling the untagResource operation
var params = { resourceArn: 'STRING_VALUE', /* required */ tagKeys: [ /* required */ 'STRING_VALUE', /* more items */ ] }; iot.untagResource(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
resourceArn
— (String
)The ARN of the resource.
tagKeys
— (Array<String>
)A list of the keys of the tags to be removed from the resource.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateAccountAuditConfiguration(params = {}, callback) ⇒ AWS.Request
Configures or reconfigures the Device Defender audit settings for this account. Settings include how audit notifications are sent and which audit checks are enabled or disabled.
Requires permission to access the UpdateAccountAuditConfiguration action.
Service Reference:
Examples:
Calling the updateAccountAuditConfiguration operation
var params = { auditCheckConfigurations: { '<AuditCheckName>': { enabled: true || false }, /* '<AuditCheckName>': ... */ }, auditNotificationTargetConfigurations: { '<AuditNotificationType>': { enabled: true || false, roleArn: 'STRING_VALUE', targetArn: 'STRING_VALUE' }, /* '<AuditNotificationType>': ... */ }, roleArn: 'STRING_VALUE' }; iot.updateAccountAuditConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
roleArn
— (String
)The Amazon Resource Name (ARN) of the role that grants permission to IoT to access information about your devices, policies, certificates, and other items as required when performing an audit.
auditNotificationTargetConfigurations
— (map<map>
)Information about the targets to which audit notifications are sent.
targetArn
— (String
)The ARN of the target (SNS topic) to which audit notifications are sent.
roleArn
— (String
)The ARN of the role that grants permission to send notifications to the target.
enabled
— (Boolean
)True if notifications to the target are enabled.
auditCheckConfigurations
— (map<map>
)Specifies which audit checks are enabled and disabled for this account. Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are currently enabled.Some data collection might start immediately when certain checks are enabled. When a check is disabled, any data collected so far in relation to the check is deleted.
You cannot disable a check if it's used by any scheduled audit. You must first delete the check from the scheduled audit or delete the scheduled audit itself.
On the first call to
UpdateAccountAuditConfiguration
, this parameter is required and must specify at least one enabled check.enabled
— (Boolean
)True if this audit check is enabled for this account.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateAuditSuppression(params = {}, callback) ⇒ AWS.Request
Updates a Device Defender audit suppression.
Service Reference:
Examples:
Calling the updateAuditSuppression operation
var params = { checkName: 'STRING_VALUE', /* required */ resourceIdentifier: { /* required */ account: 'STRING_VALUE', caCertificateId: 'STRING_VALUE', clientId: 'STRING_VALUE', cognitoIdentityPoolId: 'STRING_VALUE', deviceCertificateArn: 'STRING_VALUE', deviceCertificateId: 'STRING_VALUE', iamRoleArn: 'STRING_VALUE', issuerCertificateIdentifier: { issuerCertificateSerialNumber: 'STRING_VALUE', issuerCertificateSubject: 'STRING_VALUE', issuerId: 'STRING_VALUE' }, policyVersionIdentifier: { policyName: 'STRING_VALUE', policyVersionId: 'STRING_VALUE' }, roleAliasArn: 'STRING_VALUE' }, description: 'STRING_VALUE', expirationDate: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, suppressIndefinitely: true || false }; iot.updateAuditSuppression(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
checkName
— (String
)An audit check name. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)resourceIdentifier
— (map
)Information that identifies the noncompliant resource.
deviceCertificateId
— (String
)The ID of the certificate attached to the resource.
caCertificateId
— (String
)The ID of the CA certificate used to authorize the certificate.
cognitoIdentityPoolId
— (String
)The ID of the Amazon Cognito identity pool.
clientId
— (String
)The client ID.
policyVersionIdentifier
— (map
)The version of the policy associated with the resource.
policyName
— (String
)The name of the policy.
policyVersionId
— (String
)The ID of the version of the policy associated with the resource.
account
— (String
)The account with which the resource is associated.
iamRoleArn
— (String
)The ARN of the IAM role that has overly permissive actions.
roleAliasArn
— (String
)The ARN of the role alias that has overly permissive actions.
issuerCertificateIdentifier
— (map
)The issuer certificate identifier.
issuerCertificateSubject
— (String
)The subject of the issuer certificate.
issuerId
— (String
)The issuer ID.
issuerCertificateSerialNumber
— (String
)The issuer certificate serial number.
deviceCertificateArn
— (String
)The ARN of the identified device certificate.
expirationDate
— (Date
)The expiration date (epoch timestamp in seconds) that you want the suppression to adhere to.
suppressIndefinitely
— (Boolean
)Indicates whether a suppression should exist indefinitely or not.
description
— (String
)The description of the audit suppression.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateAuthorizer(params = {}, callback) ⇒ AWS.Request
Updates an authorizer.
Requires permission to access the UpdateAuthorizer action.
Service Reference:
Examples:
Calling the updateAuthorizer operation
var params = { authorizerName: 'STRING_VALUE', /* required */ authorizerFunctionArn: 'STRING_VALUE', enableCachingForHttp: true || false, status: ACTIVE | INACTIVE, tokenKeyName: 'STRING_VALUE', tokenSigningPublicKeys: { '<KeyName>': 'STRING_VALUE', /* '<KeyName>': ... */ } }; iot.updateAuthorizer(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
authorizerName
— (String
)The authorizer name.
authorizerFunctionArn
— (String
)The ARN of the authorizer's Lambda function.
tokenKeyName
— (String
)The key used to extract the token from the HTTP headers.
tokenSigningPublicKeys
— (map<String>
)The public keys used to verify the token signature.
status
— (String
)The status of the update authorizer request.
Possible values include:"ACTIVE"
"INACTIVE"
enableCachingForHttp
— (Boolean
)When
true
, the result from the authorizer’s Lambda function is cached for the time specified inrefreshAfterInSeconds
. The cached result is used while the device reuses the same HTTP connection.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:authorizerName
— (String
)The authorizer name.
authorizerArn
— (String
)The authorizer ARN.
-
(AWS.Response)
—
Returns:
updateBillingGroup(params = {}, callback) ⇒ AWS.Request
Updates information about the billing group.
Requires permission to access the UpdateBillingGroup action.
Service Reference:
Examples:
Calling the updateBillingGroup operation
var params = { billingGroupName: 'STRING_VALUE', /* required */ billingGroupProperties: { /* required */ billingGroupDescription: 'STRING_VALUE' }, expectedVersion: 'NUMBER_VALUE' }; iot.updateBillingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
billingGroupName
— (String
)The name of the billing group.
billingGroupProperties
— (map
)The properties of the billing group.
billingGroupDescription
— (String
)The description of the billing group.
expectedVersion
— (Integer
)The expected version of the billing group. If the version of the billing group does not match the expected version specified in the request, the
UpdateBillingGroup
request is rejected with aVersionConflictException
.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:version
— (Integer
)The latest version of the billing group.
-
(AWS.Response)
—
Returns:
updateCACertificate(params = {}, callback) ⇒ AWS.Request
Updates a registered CA certificate.
Requires permission to access the UpdateCACertificate action.
Service Reference:
Examples:
Calling the updateCACertificate operation
var params = { certificateId: 'STRING_VALUE', /* required */ newAutoRegistrationStatus: ENABLE | DISABLE, newStatus: ACTIVE | INACTIVE, registrationConfig: { roleArn: 'STRING_VALUE', templateBody: 'STRING_VALUE', templateName: 'STRING_VALUE' }, removeAutoRegistration: true || false }; iot.updateCACertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The CA certificate identifier.
newStatus
— (String
)The updated status of the CA certificate.
Note: The status value REGISTER_INACTIVE is deprecated and should not be used.
Possible values include:"ACTIVE"
"INACTIVE"
newAutoRegistrationStatus
— (String
)The new value for the auto registration status. Valid values are: "ENABLE" or "DISABLE".
Possible values include:"ENABLE"
"DISABLE"
registrationConfig
— (map
)Information about the registration configuration.
templateBody
— (String
)The template body.
roleArn
— (String
)The ARN of the role.
templateName
— (String
)The name of the provisioning template.
removeAutoRegistration
— (Boolean
)If true, removes auto registration.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateCertificate(params = {}, callback) ⇒ AWS.Request
Updates the status of the specified certificate. This operation is idempotent.
Requires permission to access the UpdateCertificate action.
Certificates must be in the ACTIVE state to authenticate devices that use a certificate to connect to IoT.
Within a few minutes of updating a certificate from the ACTIVE state to any other state, IoT disconnects all devices that used that certificate to connect. Devices cannot use a certificate that is not in the ACTIVE state to reconnect.
Service Reference:
Examples:
Calling the updateCertificate operation
var params = { certificateId: 'STRING_VALUE', /* required */ newStatus: ACTIVE | INACTIVE | REVOKED | PENDING_TRANSFER | REGISTER_INACTIVE | PENDING_ACTIVATION /* required */ }; iot.updateCertificate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateId
— (String
)The ID of the certificate. (The last part of the certificate ARN contains the certificate ID.)
newStatus
— (String
)The new status.
Note: Setting the status to PENDING_TRANSFER or PENDING_ACTIVATION will result in an exception being thrown. PENDING_TRANSFER and PENDING_ACTIVATION are statuses used internally by IoT. They are not intended for developer use.
Note: The status value REGISTER_INACTIVE is deprecated and should not be used.
Possible values include:"ACTIVE"
"INACTIVE"
"REVOKED"
"PENDING_TRANSFER"
"REGISTER_INACTIVE"
"PENDING_ACTIVATION"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateCertificateProvider(params = {}, callback) ⇒ AWS.Request
Updates a certificate provider.
Requires permission to access the UpdateCertificateProvider action.
Service Reference:
Examples:
Calling the updateCertificateProvider operation
var params = { certificateProviderName: 'STRING_VALUE', /* required */ accountDefaultForOperations: [ CreateCertificateFromCsr, /* more items */ ], lambdaFunctionArn: 'STRING_VALUE' }; iot.updateCertificateProvider(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
certificateProviderName
— (String
)The name of the certificate provider.
lambdaFunctionArn
— (String
)The Lambda function ARN that's associated with the certificate provider.
accountDefaultForOperations
— (Array<String>
)A list of the operations that the certificate provider will use to generate certificates. Valid value:
CreateCertificateFromCsr
.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:certificateProviderName
— (String
)The name of the certificate provider.
certificateProviderArn
— (String
)The ARN of the certificate provider.
-
(AWS.Response)
—
Returns:
updateCustomMetric(params = {}, callback) ⇒ AWS.Request
Updates a Device Defender detect custom metric.
Requires permission to access the UpdateCustomMetric action.
Service Reference:
Examples:
Calling the updateCustomMetric operation
var params = { displayName: 'STRING_VALUE', /* required */ metricName: 'STRING_VALUE' /* required */ }; iot.updateCustomMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the custom metric. Cannot be updated.
displayName
— (String
)Field represents a friendly name in the console for the custom metric, it doesn't have to be unique. Don't use this name as the metric identifier in the device metric report. Can be updated.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:metricName
— (String
)The name of the custom metric.
metricArn
— (String
)The Amazon Resource Number (ARN) of the custom metric.
metricType
— (String
)The type of the custom metric.
The type
number
only takes a single metric value as an input, but while submitting the metrics value in the DeviceMetrics report, it must be passed as an array with a single value."string-list"
"ip-address-list"
"number-list"
"number"
displayName
— (String
)A friendly name in the console for the custom metric
creationDate
— (Date
)The creation date of the custom metric in milliseconds since epoch.
lastModifiedDate
— (Date
)The time the custom metric was last modified in milliseconds since epoch.
-
(AWS.Response)
—
Returns:
updateDimension(params = {}, callback) ⇒ AWS.Request
Updates the definition for a dimension. You cannot change the type of a dimension after it is created (you can delete it and recreate it).
Requires permission to access the UpdateDimension action.
Service Reference:
Examples:
Calling the updateDimension operation
var params = { name: 'STRING_VALUE', /* required */ stringValues: [ /* required */ 'STRING_VALUE', /* more items */ ] }; iot.updateDimension(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
name
— (String
)A unique identifier for the dimension. Choose something that describes the type and value to make it easy to remember what it does.
stringValues
— (Array<String>
)Specifies the value or list of values for the dimension. For
TOPIC_FILTER
dimensions, this is a pattern used to match the MQTT topic (for example, "admin/#").
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:name
— (String
)A unique identifier for the dimension.
arn
— (String
)The Amazon Resource Name (ARN)of the created dimension.
type
— (String
)The type of the dimension.
Possible values include:"TOPIC_FILTER"
stringValues
— (Array<String>
)The value or list of values used to scope the dimension. For example, for topic filters, this is the pattern used to match the MQTT topic name.
creationDate
— (Date
)The date and time, in milliseconds since epoch, when the dimension was initially created.
lastModifiedDate
— (Date
)The date and time, in milliseconds since epoch, when the dimension was most recently updated.
-
(AWS.Response)
—
Returns:
updateDomainConfiguration(params = {}, callback) ⇒ AWS.Request
Updates values stored in the domain configuration. Domain configurations for default endpoints can't be updated.
Requires permission to access the UpdateDomainConfiguration action.
Service Reference:
Examples:
Calling the updateDomainConfiguration operation
var params = { domainConfigurationName: 'STRING_VALUE', /* required */ authorizerConfig: { allowAuthorizerOverride: true || false, defaultAuthorizerName: 'STRING_VALUE' }, domainConfigurationStatus: ENABLED | DISABLED, removeAuthorizerConfig: true || false, serverCertificateConfig: { enableOCSPCheck: true || false }, tlsConfig: { securityPolicy: 'STRING_VALUE' } }; iot.updateDomainConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
domainConfigurationName
— (String
)The name of the domain configuration to be updated.
authorizerConfig
— (map
)An object that specifies the authorization service for a domain.
defaultAuthorizerName
— (String
)The name of the authorization service for a domain configuration.
allowAuthorizerOverride
— (Boolean
)A Boolean that specifies whether the domain configuration's authorization service can be overridden.
domainConfigurationStatus
— (String
)The status to which the domain configuration should be updated.
Possible values include:"ENABLED"
"DISABLED"
removeAuthorizerConfig
— (Boolean
)Removes the authorization configuration from a domain.
tlsConfig
— (map
)An object that specifies the TLS configuration for a domain.
securityPolicy
— (String
)The security policy for a domain configuration. For more information, see Security policies in the Amazon Web Services IoT Core developer guide.
serverCertificateConfig
— (map
)The server certificate configuration.
enableOCSPCheck
— (Boolean
)A Boolean value that indicates whether Online Certificate Status Protocol (OCSP) server certificate check is enabled or not.
For more information, see Configuring OCSP server-certificate stapling in domain configuration from Amazon Web Services IoT Core Developer Guide.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:domainConfigurationName
— (String
)The name of the domain configuration that was updated.
domainConfigurationArn
— (String
)The ARN of the domain configuration that was updated.
-
(AWS.Response)
—
Returns:
updateDynamicThingGroup(params = {}, callback) ⇒ AWS.Request
Updates a dynamic thing group.
Requires permission to access the UpdateDynamicThingGroup action.
Service Reference:
Examples:
Calling the updateDynamicThingGroup operation
var params = { thingGroupName: 'STRING_VALUE', /* required */ thingGroupProperties: { /* required */ attributePayload: { attributes: { '<AttributeName>': 'STRING_VALUE', /* '<AttributeName>': ... */ }, merge: true || false }, thingGroupDescription: 'STRING_VALUE' }, expectedVersion: 'NUMBER_VALUE', indexName: 'STRING_VALUE', queryString: 'STRING_VALUE', queryVersion: 'STRING_VALUE' }; iot.updateDynamicThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The name of the dynamic thing group to update.
thingGroupProperties
— (map
)The dynamic thing group properties to update.
thingGroupDescription
— (String
)The thing group description.
attributePayload
— (map
)The thing group attributes in JSON format.
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
expectedVersion
— (Integer
)The expected version of the dynamic thing group to update.
indexName
— (String
)The dynamic thing group index to update.
Note: Currently one index is supported:AWS_Things
.queryString
— (String
)The dynamic thing group search query string to update.
queryVersion
— (String
)The dynamic thing group query version to update.
Note: Currently one query version is supported: "2017-09-30". If not specified, the query version defaults to this value.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:version
— (Integer
)The dynamic thing group version.
-
(AWS.Response)
—
Returns:
updateEventConfigurations(params = {}, callback) ⇒ AWS.Request
Updates the event configurations.
Requires permission to access the UpdateEventConfigurations action.
Service Reference:
Examples:
Calling the updateEventConfigurations operation
var params = { eventConfigurations: { '<EventType>': { Enabled: true || false }, /* '<EventType>': ... */ } }; iot.updateEventConfigurations(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
eventConfigurations
— (map<map>
)The new event configuration values.
Enabled
— (Boolean
)True to enable the configuration.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateFleetMetric(params = {}, callback) ⇒ AWS.Request
Updates the data for a fleet metric.
Requires permission to access the UpdateFleetMetric action.
Service Reference:
Examples:
Calling the updateFleetMetric operation
var params = { indexName: 'STRING_VALUE', /* required */ metricName: 'STRING_VALUE', /* required */ aggregationField: 'STRING_VALUE', aggregationType: { name: Statistics | Percentiles | Cardinality, /* required */ values: [ 'STRING_VALUE', /* more items */ ] }, description: 'STRING_VALUE', expectedVersion: 'NUMBER_VALUE', period: 'NUMBER_VALUE', queryString: 'STRING_VALUE', queryVersion: 'STRING_VALUE', unit: Seconds | Microseconds | Milliseconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None }; iot.updateFleetMetric(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
metricName
— (String
)The name of the fleet metric to update.
queryString
— (String
)The search query string.
aggregationType
— (map
)The type of the aggregation query.
name
— required — (String
)The name of the aggregation type.
Possible values include:"Statistics"
"Percentiles"
"Cardinality"
values
— (Array<String>
)A list of the values of aggregation types.
period
— (Integer
)The time in seconds between fleet metric emissions. Range [60(1 min), 86400(1 day)] and must be multiple of 60.
aggregationField
— (String
)The field to aggregate.
description
— (String
)The description of the fleet metric.
queryVersion
— (String
)The version of the query.
indexName
— (String
)The name of the index to search.
unit
— (String
)Used to support unit transformation such as milliseconds to seconds. The unit must be supported by CW metric.
Possible values include:"Seconds"
"Microseconds"
"Milliseconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
expectedVersion
— (Integer
)The expected version of the fleet metric record in the registry.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateIndexingConfiguration(params = {}, callback) ⇒ AWS.Request
Updates the search configuration.
Requires permission to access the UpdateIndexingConfiguration action.
Service Reference:
Examples:
Calling the updateIndexingConfiguration operation
var params = { thingGroupIndexingConfiguration: { thingGroupIndexingMode: OFF | ON, /* required */ customFields: [ { name: 'STRING_VALUE', type: Number | String | Boolean }, /* more items */ ], managedFields: [ { name: 'STRING_VALUE', type: Number | String | Boolean }, /* more items */ ] }, thingIndexingConfiguration: { thingIndexingMode: OFF | REGISTRY | REGISTRY_AND_SHADOW, /* required */ customFields: [ { name: 'STRING_VALUE', type: Number | String | Boolean }, /* more items */ ], deviceDefenderIndexingMode: OFF | VIOLATIONS, filter: { geoLocations: [ { name: 'STRING_VALUE', order: LatLon | LonLat }, /* more items */ ], namedShadowNames: [ 'STRING_VALUE', /* more items */ ] }, managedFields: [ { name: 'STRING_VALUE', type: Number | String | Boolean }, /* more items */ ], namedShadowIndexingMode: OFF | ON, thingConnectivityIndexingMode: OFF | STATUS } }; iot.updateIndexingConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingIndexingConfiguration
— (map
)Thing indexing configuration.
thingIndexingMode
— required — (String
)Thing indexing mode. Valid values are:
-
REGISTRY – Your thing index contains registry data only.
-
REGISTRY_AND_SHADOW - Your thing index contains registry and shadow data.
-
OFF - Thing indexing is disabled.
"OFF"
"REGISTRY"
"REGISTRY_AND_SHADOW"
-
thingConnectivityIndexingMode
— (String
)Thing connectivity indexing mode. Valid values are:
-
STATUS – Your thing index contains connectivity status. To enable thing connectivity indexing, thingIndexMode must not be set to OFF.
-
OFF - Thing connectivity status indexing is disabled.
"OFF"
"STATUS"
-
deviceDefenderIndexingMode
— (String
)Device Defender indexing mode. Valid values are:
-
VIOLATIONS – Your thing index contains Device Defender violations. To enable Device Defender indexing, deviceDefenderIndexingMode must not be set to OFF.
-
OFF - Device Defender indexing is disabled.
For more information about Device Defender violations, see Device Defender Detect.
Possible values include:"OFF"
"VIOLATIONS"
-
namedShadowIndexingMode
— (String
)Named shadow indexing mode. Valid values are:
-
ON – Your thing index contains named shadow. To enable thing named shadow indexing, namedShadowIndexingMode must not be set to OFF.
-
OFF - Named shadow indexing is disabled.
For more information about Shadows, see IoT Device Shadow service.
Possible values include:"OFF"
"ON"
-
managedFields
— (Array<map>
)Contains fields that are indexed and whose types are already known by the Fleet Indexing service. This is an optional field. For more information, see Managed fields in the Amazon Web Services IoT Core Developer Guide.
Note: You can't modify managed fields by updating fleet indexing configuration.name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
customFields
— (Array<map>
)Contains custom field names and their data type.
name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
filter
— (map
)Provides additional selections for named shadows and geolocation data.
To add named shadows to your fleet indexing configuration, set
namedShadowIndexingMode
to be ON and specify your shadow names innamedShadowNames
filter.To add geolocation data to your fleet indexing configuration:
-
If you store geolocation data in a class/unnamed shadow, set
thingIndexingMode
to beREGISTRY_AND_SHADOW
and specify your geolocation data ingeoLocations
filter. -
If you store geolocation data in a named shadow, set
namedShadowIndexingMode
to beON
, add the shadow name innamedShadowNames
filter, and specify your geolocation data ingeoLocations
filter. For more information, see Managing fleet indexing.
namedShadowNames
— (Array<String>
)The shadow names that you select to index. The default maximum number of shadow names for indexing is 10. To increase the limit, see Amazon Web Services IoT Device Management Quotas in the Amazon Web Services General Reference.
geoLocations
— (Array<map>
)The list of geolocation targets that you select to index. The default maximum number of geolocation targets for indexing is
1
. To increase the limit, see Amazon Web Services IoT Device Management Quotas in the Amazon Web Services General Reference.name
— (String
)The
name
of the geolocation target field. If the target field is part of a named shadow, you must select the named shadow using thenamedShadow
filter.order
— (String
)The
Possible values include:order
of the geolocation target field. This field is optional. The default value isLatLon
."LatLon"
"LonLat"
-
thingGroupIndexingConfiguration
— (map
)Thing group indexing configuration.
thingGroupIndexingMode
— required — (String
)Thing group indexing mode.
Possible values include:"OFF"
"ON"
managedFields
— (Array<map>
)Contains fields that are indexed and whose types are already known by the Fleet Indexing service. This is an optional field. For more information, see Managed fields in the Amazon Web Services IoT Core Developer Guide.
Note: You can't modify managed fields by updating fleet indexing configuration.name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
customFields
— (Array<map>
)A list of thing group fields to index. This list cannot contain any managed fields. Use the GetIndexingConfiguration API to get a list of managed fields.
Contains custom field names and their data type.
name
— (String
)The name of the field.
type
— (String
)The data type of the field.
Possible values include:"Number"
"String"
"Boolean"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateJob(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the updateJob operation
var params = { jobId: 'STRING_VALUE', /* required */ abortConfig: { criteriaList: [ /* required */ { action: CANCEL, /* required */ failureType: FAILED | REJECTED | TIMED_OUT | ALL, /* required */ minNumberOfExecutedThings: 'NUMBER_VALUE', /* required */ thresholdPercentage: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, description: 'STRING_VALUE', jobExecutionsRetryConfig: { criteriaList: [ /* required */ { failureType: FAILED | TIMED_OUT | ALL, /* required */ numberOfRetries: 'NUMBER_VALUE' /* required */ }, /* more items */ ] }, jobExecutionsRolloutConfig: { exponentialRate: { baseRatePerMinute: 'NUMBER_VALUE', /* required */ incrementFactor: 'NUMBER_VALUE', /* required */ rateIncreaseCriteria: { /* required */ numberOfNotifiedThings: 'NUMBER_VALUE', numberOfSucceededThings: 'NUMBER_VALUE' } }, maximumPerMinute: 'NUMBER_VALUE' }, namespaceId: 'STRING_VALUE', presignedUrlConfig: { expiresInSec: 'NUMBER_VALUE', roleArn: 'STRING_VALUE' }, timeoutConfig: { inProgressTimeoutInMinutes: 'NUMBER_VALUE' } }; iot.updateJob(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
jobId
— (String
)The ID of the job to be updated.
description
— (String
)A short text description of the job.
presignedUrlConfig
— (map
)Configuration information for pre-signed S3 URLs.
roleArn
— (String
)The ARN of an IAM role that grants permission to download files from the S3 bucket where the job data/updates are stored. The role must also grant permission for IoT to download the files.
For information about addressing the confused deputy problem, see cross-service confused deputy prevention in the Amazon Web Services IoT Core developer guide.
expiresInSec
— (Integer
)How long (in seconds) pre-signed URLs are valid. Valid values are 60 - 3600, the default value is 3600 seconds. Pre-signed URLs are generated when Jobs receives an MQTT request for the job document.
jobExecutionsRolloutConfig
— (map
)Allows you to create a staged rollout of the job.
maximumPerMinute
— (Integer
)The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
exponentialRate
— (map
)The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
baseRatePerMinute
— required — (Integer
)The minimum number of things that will be notified of a pending job, per minute at the start of job rollout. This parameter allows you to define the initial rate of rollout.
incrementFactor
— required — (Float
)The exponential factor to increase the rate of rollout for a job.
Amazon Web Services IoT Core supports up to one digit after the decimal (for example, 1.5, but not 1.55).
rateIncreaseCriteria
— required — (map
)The criteria to initiate the increase in rate of rollout for a job.
numberOfNotifiedThings
— (Integer
)The threshold for number of notified things that will initiate the increase in rate of rollout.
numberOfSucceededThings
— (Integer
)The threshold for number of succeeded things that will initiate the increase in rate of rollout.
abortConfig
— (map
)Allows you to create criteria to abort a job.
criteriaList
— required — (Array<map>
)The list of criteria that determine when and how to abort the job.
failureType
— required — (String
)The type of job execution failures that can initiate a job abort.
Possible values include:"FAILED"
"REJECTED"
"TIMED_OUT"
"ALL"
action
— required — (String
)The type of job action to take to initiate the job abort.
Possible values include:"CANCEL"
thresholdPercentage
— required — (Float
)The minimum percentage of job execution failures that must occur to initiate the job abort.
Amazon Web Services IoT Core supports up to two digits after the decimal (for example, 10.9 and 10.99, but not 10.999).
minNumberOfExecutedThings
— required — (Integer
)The minimum number of things which must receive job execution notifications before the job can be aborted.
timeoutConfig
— (map
)Specifies the amount of time each device has to finish its execution of the job. The timer is started when the job execution status is set to
IN_PROGRESS
. If the job execution status is not set to another terminal state before the time expires, it will be automatically set toTIMED_OUT
.inProgressTimeoutInMinutes
— (Integer
)Specifies the amount of time, in minutes, this device has to finish execution of this job. The timeout interval can be anywhere between 1 minute and 7 days (1 to 10080 minutes). The in progress timer can't be updated and will apply to all job executions for the job. Whenever a job execution remains in the IN_PROGRESS status for longer than this interval, the job execution will fail and switch to the terminal
TIMED_OUT
status.
namespaceId
— (String
)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: ThenamespaceId
feature is only supported by IoT Greengrass at this time. For more information, see Setting up IoT Greengrass core devices.jobExecutionsRetryConfig
— (map
)Allows you to create the criteria to retry a job.
criteriaList
— required — (Array<map>
)The list of criteria that determines how many retries are allowed for each failure type for a job.
failureType
— required — (String
)The type of job execution failures that can initiate a job retry.
Possible values include:"FAILED"
"TIMED_OUT"
"ALL"
numberOfRetries
— required — (Integer
)The number of retries allowed for a failure type for the job.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateMitigationAction(params = {}, callback) ⇒ AWS.Request
Updates the definition for the specified mitigation action.
Requires permission to access the UpdateMitigationAction action.
Service Reference:
Examples:
Calling the updateMitigationAction operation
var params = { actionName: 'STRING_VALUE', /* required */ actionParams: { addThingsToThingGroupParams: { thingGroupNames: [ /* required */ 'STRING_VALUE', /* more items */ ], overrideDynamicGroups: true || false }, enableIoTLoggingParams: { logLevel: DEBUG | INFO | ERROR | WARN | DISABLED, /* required */ roleArnForLogging: 'STRING_VALUE' /* required */ }, publishFindingToSnsParams: { topicArn: 'STRING_VALUE' /* required */ }, replaceDefaultPolicyVersionParams: { templateName: BLANK_POLICY /* required */ }, updateCACertificateParams: { action: DEACTIVATE /* required */ }, updateDeviceCertificateParams: { action: DEACTIVATE /* required */ } }, roleArn: 'STRING_VALUE' }; iot.updateMitigationAction(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
actionName
— (String
)The friendly name for the mitigation action. You cannot change the name by using
UpdateMitigationAction
. Instead, you must delete and recreate the mitigation action with the new name.roleArn
— (String
)The ARN of the IAM role that is used to apply the mitigation action.
actionParams
— (map
)Defines the type of action and the parameters for that action.
updateDeviceCertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the device certificate to inactive.
action
— required — (String
)The action that you want to apply to the device certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
updateCACertificateParams
— (map
)Parameters to define a mitigation action that changes the state of the CA certificate to inactive.
action
— required — (String
)The action that you want to apply to the CA certificate. The only supported value is
Possible values include:DEACTIVATE
."DEACTIVATE"
addThingsToThingGroupParams
— (map
)Parameters to define a mitigation action that moves devices associated with a certificate to one or more specified thing groups, typically for quarantine.
thingGroupNames
— required — (Array<String>
)The list of groups to which you want to add the things that triggered the mitigation action. You can add a thing to a maximum of 10 groups, but you can't add a thing to more than one group in the same hierarchy.
overrideDynamicGroups
— (Boolean
)Specifies if this mitigation action can move the things that triggered the mitigation action even if they are part of one or more dynamic thing groups.
replaceDefaultPolicyVersionParams
— (map
)Parameters to define a mitigation action that adds a blank policy to restrict permissions.
templateName
— required — (String
)The name of the template to be applied. The only supported value is
Possible values include:BLANK_POLICY
."BLANK_POLICY"
enableIoTLoggingParams
— (map
)Parameters to define a mitigation action that enables Amazon Web Services IoT Core logging at a specified level of detail.
roleArnForLogging
— required — (String
)The Amazon Resource Name (ARN) of the IAM role used for logging.
logLevel
— required — (String
)Specifies the type of information to be logged.
Possible values include:"DEBUG"
"INFO"
"ERROR"
"WARN"
"DISABLED"
publishFindingToSnsParams
— (map
)Parameters to define a mitigation action that publishes findings to Amazon Simple Notification Service (Amazon SNS. You can implement your own custom actions in response to the Amazon SNS messages.
topicArn
— required — (String
)The ARN of the topic to which you want to publish the findings.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:actionArn
— (String
)The ARN for the new mitigation action.
actionId
— (String
)A unique identifier for the mitigation action.
-
(AWS.Response)
—
Returns:
updatePackage(params = {}, callback) ⇒ AWS.Request
Updates the supported fields for a specific software package.
Requires permission to access the UpdatePackage and GetIndexingConfiguration actions.
Service Reference:
Examples:
Calling the updatePackage operation
var params = { packageName: 'STRING_VALUE', /* required */ clientToken: 'STRING_VALUE', defaultVersionName: 'STRING_VALUE', description: 'STRING_VALUE', unsetDefaultVersion: true || false }; iot.updatePackage(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the target software package.
description
— (String
)The package description.
defaultVersionName
— (String
)The name of the default package version.
Note: You cannot name a
defaultVersion
and setunsetDefaultVersion
equal totrue
at the same time.unsetDefaultVersion
— (Boolean
)Indicates whether you want to remove the named default package version from the software package. Set as
true
to remove the default package version.Note: You cannot name a
defaultVersion
and setunsetDefaultVersion
equal totrue
at the same time.clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updatePackageConfiguration(params = {}, callback) ⇒ AWS.Request
Updates the software package configuration.
Requires permission to access the UpdatePackageConfiguration and iam:PassRole actions.
Service Reference:
Examples:
Calling the updatePackageConfiguration operation
var params = { clientToken: 'STRING_VALUE', versionUpdateByJobsConfig: { enabled: true || false, roleArn: 'STRING_VALUE' } }; iot.updatePackageConfiguration(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
versionUpdateByJobsConfig
— (map
)Configuration to manage job's package version reporting. This updates the thing's reserved named shadow that the job targets.
enabled
— (Boolean
)Indicates whether the Job is enabled or not.
roleArn
— (String
)The Amazon Resource Name (ARN) of the role that grants permission to the IoT jobs service to update the reserved named shadow when the job successfully completes.
clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updatePackageVersion(params = {}, callback) ⇒ AWS.Request
Updates the supported fields for a specific package version.
Requires permission to access the UpdatePackageVersion and GetIndexingConfiguration actions.
Service Reference:
Examples:
Calling the updatePackageVersion operation
var params = { packageName: 'STRING_VALUE', /* required */ versionName: 'STRING_VALUE', /* required */ action: PUBLISH | DEPRECATE, attributes: { '<ResourceAttributeKey>': 'STRING_VALUE', /* '<ResourceAttributeKey>': ... */ }, clientToken: 'STRING_VALUE', description: 'STRING_VALUE' }; iot.updatePackageVersion(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
packageName
— (String
)The name of the associated software package.
versionName
— (String
)The name of the target package version.
description
— (String
)The package version description.
attributes
— (map<String>
)Metadata that can be used to define a package version’s configuration. For example, the Amazon S3 file location, configuration options that are being sent to the device or fleet.
Note: Attributes can be updated only when the package version is in a draft state.
The combined size of all the attributes on a package version is limited to 3KB.
action
— (String
)The status that the package version should be assigned. For more information, see Package version lifecycle.
Possible values include:"PUBLISH"
"DEPRECATE"
clientToken
— (String
)A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.
If a token is not provided, the SDK will use a version 4 UUID.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateProvisioningTemplate(params = {}, callback) ⇒ AWS.Request
Updates a provisioning template.
Requires permission to access the UpdateProvisioningTemplate action.
Service Reference:
Examples:
Calling the updateProvisioningTemplate operation
var params = { templateName: 'STRING_VALUE', /* required */ defaultVersionId: 'NUMBER_VALUE', description: 'STRING_VALUE', enabled: true || false, preProvisioningHook: { targetArn: 'STRING_VALUE', /* required */ payloadVersion: 'STRING_VALUE' }, provisioningRoleArn: 'STRING_VALUE', removePreProvisioningHook: true || false }; iot.updateProvisioningTemplate(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
templateName
— (String
)The name of the provisioning template.
description
— (String
)The description of the provisioning template.
enabled
— (Boolean
)True to enable the provisioning template, otherwise false.
defaultVersionId
— (Integer
)The ID of the default provisioning template version.
provisioningRoleArn
— (String
)The ARN of the role associated with the provisioning template. This IoT role grants permission to provision a device.
preProvisioningHook
— (map
)Updates the pre-provisioning hook template. Only supports template of type
FLEET_PROVISIONING
. For more information about provisioning template types, see type.payloadVersion
— (String
)The payload that was sent to the target function.
Note: Only Lambda functions are currently supported.
targetArn
— required — (String
)The ARN of the target function.
Note: Only Lambda functions are currently supported.
removePreProvisioningHook
— (Boolean
)Removes pre-provisioning hook template.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateRoleAlias(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the updateRoleAlias operation
var params = { roleAlias: 'STRING_VALUE', /* required */ credentialDurationSeconds: 'NUMBER_VALUE', roleArn: 'STRING_VALUE' }; iot.updateRoleAlias(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
roleAlias
— (String
)The role alias to update.
roleArn
— (String
)The role ARN.
credentialDurationSeconds
— (Integer
)The number of seconds the credential will be valid.
This value must be less than or equal to the maximum session duration of the IAM role that the role alias references.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:roleAlias
— (String
)The role alias.
roleAliasArn
— (String
)The role alias ARN.
-
(AWS.Response)
—
Returns:
updateScheduledAudit(params = {}, callback) ⇒ AWS.Request
Updates a scheduled audit, including which checks are performed and how often the audit takes place.
Requires permission to access the UpdateScheduledAudit action.
Service Reference:
Examples:
Calling the updateScheduledAudit operation
var params = { scheduledAuditName: 'STRING_VALUE', /* required */ dayOfMonth: 'STRING_VALUE', dayOfWeek: SUN | MON | TUE | WED | THU | FRI | SAT, frequency: DAILY | WEEKLY | BIWEEKLY | MONTHLY, targetCheckNames: [ 'STRING_VALUE', /* more items */ ] }; iot.updateScheduledAudit(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
frequency
— (String
)How often the scheduled audit takes place, either
Possible values include:DAILY
,WEEKLY
,BIWEEKLY
, orMONTHLY
. The start time of each audit is determined by the system."DAILY"
"WEEKLY"
"BIWEEKLY"
"MONTHLY"
dayOfMonth
— (String
)The day of the month on which the scheduled audit takes place. This can be
1
through31
orLAST
. This field is required if thefrequency
parameter is set toMONTHLY
. If days 29-31 are specified, and the month does not have that many days, the audit takes place on the "LAST" day of the month.dayOfWeek
— (String
)The day of the week on which the scheduled audit takes place. This can be one of
Possible values include:SUN
,MON
,TUE
,WED
,THU
,FRI
, orSAT
. This field is required if the "frequency" parameter is set toWEEKLY
orBIWEEKLY
."SUN"
"MON"
"TUE"
"WED"
"THU"
"FRI"
"SAT"
targetCheckNames
— (Array<String>
)Which checks are performed during the scheduled audit. Checks must be enabled for your account. (Use
DescribeAccountAuditConfiguration
to see the list of all checks, including those that are enabled or useUpdateAccountAuditConfiguration
to select which checks are enabled.)scheduledAuditName
— (String
)The name of the scheduled audit. (Max. 128 chars)
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:scheduledAuditArn
— (String
)The ARN of the scheduled audit.
-
(AWS.Response)
—
Returns:
updateSecurityProfile(params = {}, callback) ⇒ AWS.Request
Updates a Device Defender security profile.
Requires permission to access the UpdateSecurityProfile action.
Service Reference:
Examples:
Calling the updateSecurityProfile operation
var params = { securityProfileName: 'STRING_VALUE', /* required */ additionalMetricsToRetain: [ 'STRING_VALUE', /* more items */ ], additionalMetricsToRetainV2: [ { metric: 'STRING_VALUE', /* required */ exportMetric: true || false, metricDimension: { dimensionName: 'STRING_VALUE', /* required */ operator: IN | NOT_IN } }, /* more items */ ], alertTargets: { '<AlertTargetType>': { alertTargetArn: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE' /* required */ }, /* '<AlertTargetType>': ... */ }, behaviors: [ { name: 'STRING_VALUE', /* required */ criteria: { comparisonOperator: less-than | less-than-equals | greater-than | greater-than-equals | in-cidr-set | not-in-cidr-set | in-port-set | not-in-port-set | in-set | not-in-set, consecutiveDatapointsToAlarm: 'NUMBER_VALUE', consecutiveDatapointsToClear: 'NUMBER_VALUE', durationSeconds: 'NUMBER_VALUE', mlDetectionConfig: { confidenceLevel: LOW | MEDIUM | HIGH /* required */ }, statisticalThreshold: { statistic: 'STRING_VALUE' }, value: { cidrs: [ 'STRING_VALUE', /* more items */ ], count: 'NUMBER_VALUE', number: 'NUMBER_VALUE', numbers: [ 'NUMBER_VALUE', /* more items */ ], ports: [ 'NUMBER_VALUE', /* more items */ ], strings: [ 'STRING_VALUE', /* more items */ ] } }, exportMetric: true || false, metric: 'STRING_VALUE', metricDimension: { dimensionName: 'STRING_VALUE', /* required */ operator: IN | NOT_IN }, suppressAlerts: true || false }, /* more items */ ], deleteAdditionalMetricsToRetain: true || false, deleteAlertTargets: true || false, deleteBehaviors: true || false, deleteMetricsExportConfig: true || false, expectedVersion: 'NUMBER_VALUE', metricsExportConfig: { mqttTopic: 'STRING_VALUE', /* required */ roleArn: 'STRING_VALUE' /* required */ }, securityProfileDescription: 'STRING_VALUE' }; iot.updateSecurityProfile(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
securityProfileName
— (String
)The name of the security profile you want to update.
securityProfileDescription
— (String
)A description of the security profile.
behaviors
— (Array<map>
)Specifies the behaviors that, when violated by a device (thing), cause an alert.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
alertTargets
— (map<map>
)Where the alerts are sent. (Alerts are always sent to the console.)
alertTargetArn
— required — (String
)The Amazon Resource Name (ARN) of the notification target to which alerts are sent.
roleArn
— required — (String
)The ARN of the role that grants permission to send alerts to the notification target.
additionalMetricsToRetain
— (Array<String>
)Please use UpdateSecurityProfileRequest$additionalMetricsToRetainV2 instead.
A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's
behaviors
, but it is also retained for any metric specified here. Can be used with custom metrics; cannot be used with dimensions.additionalMetricsToRetainV2
— (Array<map>
)A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's behaviors, but it is also retained for any metric specified here. Can be used with custom metrics; cannot be used with dimensions.
metric
— required — (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension of a metric. This can't be used with custom metrics.
dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
exportMetric
— (Boolean
)The value indicates exporting metrics related to the
MetricToRetain
when it's true.
deleteBehaviors
— (Boolean
)If true, delete all
behaviors
defined for this security profile. If anybehaviors
are defined in the current invocation, an exception occurs.deleteAlertTargets
— (Boolean
)If true, delete all
alertTargets
defined for this security profile. If anyalertTargets
are defined in the current invocation, an exception occurs.deleteAdditionalMetricsToRetain
— (Boolean
)If true, delete all
additionalMetricsToRetain
defined for this security profile. If anyadditionalMetricsToRetain
are defined in the current invocation, an exception occurs.expectedVersion
— (Integer
)The expected version of the security profile. A new version is generated whenever the security profile is updated. If you specify a value that is different from the actual version, a
VersionConflictException
is thrown.metricsExportConfig
— (map
)Specifies the MQTT topic and role ARN required for metric export.
mqttTopic
— required — (String
)The MQTT topic that Device Defender Detect should publish messages to for metrics export.
roleArn
— required — (String
)This role ARN has permission to publish MQTT messages, after which Device Defender Detect can assume the role and publish messages on your behalf.
deleteMetricsExportConfig
— (Boolean
)Set the value as true to delete metrics export related configurations.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:securityProfileName
— (String
)The name of the security profile that was updated.
securityProfileArn
— (String
)The ARN of the security profile that was updated.
securityProfileDescription
— (String
)The description of the security profile.
behaviors
— (Array<map>
)Specifies the behaviors that, when violated by a device (thing), cause an alert.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
alertTargets
— (map<map>
)Where the alerts are sent. (Alerts are always sent to the console.)
alertTargetArn
— required — (String
)The Amazon Resource Name (ARN) of the notification target to which alerts are sent.
roleArn
— required — (String
)The ARN of the role that grants permission to send alerts to the notification target.
additionalMetricsToRetain
— (Array<String>
)Please use UpdateSecurityProfileResponse$additionalMetricsToRetainV2 instead.
A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the security profile's
behaviors
, but it is also retained for any metric specified here.additionalMetricsToRetainV2
— (Array<map>
)A list of metrics whose data is retained (stored). By default, data is retained for any metric used in the profile's behaviors, but it is also retained for any metric specified here. Can be used with custom metrics; cannot be used with dimensions.
metric
— required — (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension of a metric. This can't be used with custom metrics.
dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
exportMetric
— (Boolean
)The value indicates exporting metrics related to the
MetricToRetain
when it's true.
version
— (Integer
)The updated version of the security profile.
creationDate
— (Date
)The time the security profile was created.
lastModifiedDate
— (Date
)The time the security profile was last modified.
metricsExportConfig
— (map
)Specifies the MQTT topic and role ARN required for metric export.
mqttTopic
— required — (String
)The MQTT topic that Device Defender Detect should publish messages to for metrics export.
roleArn
— required — (String
)This role ARN has permission to publish MQTT messages, after which Device Defender Detect can assume the role and publish messages on your behalf.
-
(AWS.Response)
—
Returns:
updateStream(params = {}, callback) ⇒ AWS.Request
Updates an existing stream. The stream version will be incremented by one.
Requires permission to access the UpdateStream action.
Service Reference:
Examples:
Calling the updateStream operation
var params = { streamId: 'STRING_VALUE', /* required */ description: 'STRING_VALUE', files: [ { fileId: 'NUMBER_VALUE', s3Location: { bucket: 'STRING_VALUE', key: 'STRING_VALUE', version: 'STRING_VALUE' } }, /* more items */ ], roleArn: 'STRING_VALUE' }; iot.updateStream(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
streamId
— (String
)The stream ID.
description
— (String
)The description of the stream.
files
— (Array<map>
)The files associated with the stream.
fileId
— (Integer
)The file ID.
s3Location
— (map
)The location of the file in S3.
bucket
— (String
)The S3 bucket.
key
— (String
)The S3 key.
version
— (String
)The S3 bucket version.
roleArn
— (String
)An IAM role that allows the IoT service principal assumes to access your S3 files.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:streamId
— (String
)The stream ID.
streamArn
— (String
)The stream ARN.
description
— (String
)A description of the stream.
streamVersion
— (Integer
)The stream version.
-
(AWS.Response)
—
Returns:
updateThing(params = {}, callback) ⇒ AWS.Request
Updates the data for a thing.
Requires permission to access the UpdateThing action.
Service Reference:
Examples:
Calling the updateThing operation
var params = { thingName: 'STRING_VALUE', /* required */ attributePayload: { attributes: { '<AttributeName>': 'STRING_VALUE', /* '<AttributeName>': ... */ }, merge: true || false }, expectedVersion: 'NUMBER_VALUE', removeThingType: true || false, thingTypeName: 'STRING_VALUE' }; iot.updateThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)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.
thingTypeName
— (String
)The name of the thing type.
attributePayload
— (map
)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.
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
expectedVersion
— (Integer
)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 aVersionConflictException
.removeThingType
— (Boolean
)Remove a thing type association. If true, the association is removed.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateThingGroup(params = {}, callback) ⇒ AWS.Request
Examples:
Calling the updateThingGroup operation
var params = { thingGroupName: 'STRING_VALUE', /* required */ thingGroupProperties: { /* required */ attributePayload: { attributes: { '<AttributeName>': 'STRING_VALUE', /* '<AttributeName>': ... */ }, merge: true || false }, thingGroupDescription: 'STRING_VALUE' }, expectedVersion: 'NUMBER_VALUE' }; iot.updateThingGroup(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingGroupName
— (String
)The thing group to update.
thingGroupProperties
— (map
)The thing group properties.
thingGroupDescription
— (String
)The thing group description.
attributePayload
— (map
)The thing group attributes in JSON format.
attributes
— (map<String>
)A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
merge
— (Boolean
)Specifies whether the list of attributes provided in the
AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.To remove an attribute, call
UpdateThing
with an empty attribute value.Note: Themerge
attribute is only valid when callingUpdateThing
orUpdateThingGroup
.
expectedVersion
— (Integer
)The expected version of the thing group. If this does not match the version of the thing group being updated, the update will fail.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:version
— (Integer
)The version of the updated thing group.
-
(AWS.Response)
—
Returns:
updateThingGroupsForThing(params = {}, callback) ⇒ AWS.Request
Updates the groups to which the thing belongs.
Requires permission to access the UpdateThingGroupsForThing action.
Service Reference:
Examples:
Calling the updateThingGroupsForThing operation
var params = { overrideDynamicGroups: true || false, thingGroupsToAdd: [ 'STRING_VALUE', /* more items */ ], thingGroupsToRemove: [ 'STRING_VALUE', /* more items */ ], thingName: 'STRING_VALUE' }; iot.updateThingGroupsForThing(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
thingName
— (String
)The thing whose group memberships will be updated.
thingGroupsToAdd
— (Array<String>
)The groups to which the thing will be added.
thingGroupsToRemove
— (Array<String>
)The groups from which the thing will be removed.
overrideDynamicGroups
— (Boolean
)Override dynamic thing groups with static thing groups when 10-group limit is reached. If a thing belongs to 10 thing groups, and one or more of those groups are dynamic thing groups, adding a thing to a static group removes the thing from the last dynamic group.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateTopicRuleDestination(params = {}, callback) ⇒ AWS.Request
Updates a topic rule destination. You use this to change the status, endpoint URL, or confirmation URL of the destination.
Requires permission to access the UpdateTopicRuleDestination action.
Service Reference:
Examples:
Calling the updateTopicRuleDestination operation
var params = { arn: 'STRING_VALUE', /* required */ status: ENABLED | IN_PROGRESS | DISABLED | ERROR | DELETING /* required */ }; iot.updateTopicRuleDestination(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
arn
— (String
)The ARN of the topic rule destination.
status
— (String
)The status of the topic rule destination. Valid values are:
- IN_PROGRESS
-
A topic rule destination was created but has not been confirmed. You can set
status
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint. - ENABLED
-
Confirmation was completed, and traffic to this destination is allowed. You can set
status
toDISABLED
by callingUpdateTopicRuleDestination
. - DISABLED
-
Confirmation was completed, and traffic to this destination is not allowed. You can set
status
toENABLED
by callingUpdateTopicRuleDestination
. - ERROR
-
Confirmation could not be completed, for example if the confirmation timed out. You can call
GetTopicRuleDestination
for details about the error. You can setstatus
toIN_PROGRESS
by callingUpdateTopicRuleDestination
. CallingUpdateTopicRuleDestination
causes a new confirmation challenge to be sent to your confirmation endpoint.
"ENABLED"
"IN_PROGRESS"
"DISABLED"
"ERROR"
"DELETING"
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
validateSecurityProfileBehaviors(params = {}, callback) ⇒ AWS.Request
Validates a Device Defender security profile behaviors specification.
Requires permission to access the ValidateSecurityProfileBehaviors action.
Service Reference:
Examples:
Calling the validateSecurityProfileBehaviors operation
var params = { behaviors: [ /* required */ { name: 'STRING_VALUE', /* required */ criteria: { comparisonOperator: less-than | less-than-equals | greater-than | greater-than-equals | in-cidr-set | not-in-cidr-set | in-port-set | not-in-port-set | in-set | not-in-set, consecutiveDatapointsToAlarm: 'NUMBER_VALUE', consecutiveDatapointsToClear: 'NUMBER_VALUE', durationSeconds: 'NUMBER_VALUE', mlDetectionConfig: { confidenceLevel: LOW | MEDIUM | HIGH /* required */ }, statisticalThreshold: { statistic: 'STRING_VALUE' }, value: { cidrs: [ 'STRING_VALUE', /* more items */ ], count: 'NUMBER_VALUE', number: 'NUMBER_VALUE', numbers: [ 'NUMBER_VALUE', /* more items */ ], ports: [ 'NUMBER_VALUE', /* more items */ ], strings: [ 'STRING_VALUE', /* more items */ ] } }, exportMetric: true || false, metric: 'STRING_VALUE', metricDimension: { dimensionName: 'STRING_VALUE', /* required */ operator: IN | NOT_IN }, suppressAlerts: true || false }, /* more items */ ] }; iot.validateSecurityProfileBehaviors(params, function(err, data) { if (err) console.log(err, err.stack); // an error occurred else console.log(data); // successful response });
Parameters:
-
params
(Object)
(defaults to: {})
—
behaviors
— (Array<map>
)Specifies the behaviors that, when violated by a device (thing), cause an alert.
name
— required — (String
)The name you've given to the behavior.
metric
— (String
)What is measured by the behavior.
metricDimension
— (map
)The dimension for a metric in your behavior. For example, using a
TOPIC_FILTER
dimension, you can narrow down the scope of the metric to only MQTT topics where the name matches the pattern specified in the dimension. This can't be used with custom metrics.dimensionName
— required — (String
)A unique identifier for the dimension.
operator
— (String
)Defines how the
Possible values include:dimensionValues
of a dimension are interpreted. For example, for dimension type TOPIC_FILTER, theIN
operator, a message will be counted only if its topic matches one of the topic filters. WithNOT_IN
operator, a message will be counted only if it doesn't match any of the topic filters. The operator is optional: if it's not provided (isnull
), it will be interpreted asIN
."IN"
"NOT_IN"
criteria
— (map
)The criteria that determine if a device is behaving normally in regard to the
metric
.Note: In the IoT console, you can choose to be sent an alert through Amazon SNS when IoT Device Defender detects that a device is behaving anomalously.comparisonOperator
— (String
)The operator that relates the thing measured (
metric
) to the criteria (containing avalue
orstatisticalThreshold
). Valid operators include:-
string-list
:in-set
andnot-in-set
-
number-list
:in-set
andnot-in-set
-
ip-address-list
:in-cidr-set
andnot-in-cidr-set
-
number
:less-than
,less-than-equals
,greater-than
, andgreater-than-equals
"less-than"
"less-than-equals"
"greater-than"
"greater-than-equals"
"in-cidr-set"
"not-in-cidr-set"
"in-port-set"
"not-in-port-set"
"in-set"
"not-in-set"
-
value
— (map
)The value to be compared with the
metric
.count
— (Integer
)If the
comparisonOperator
calls for a numeric value, use this to specify that numeric value to be compared with themetric
.cidrs
— (Array<String>
)If the
comparisonOperator
calls for a set of CIDRs, use this to specify that set to be compared with themetric
.ports
— (Array<Integer>
)If the
comparisonOperator
calls for a set of ports, use this to specify that set to be compared with themetric
.number
— (Float
)The numeral value of a metric.
numbers
— (Array<Float>
)The numeral values of a metric.
strings
— (Array<String>
)The string values of a metric.
durationSeconds
— (Integer
)Use this to specify the time duration over which the behavior is evaluated, for those criteria that have a time dimension (for example,
NUM_MESSAGES_SENT
). For astatisticalThreshhold
metric comparison, measurements from all devices are accumulated over this time duration before being used to calculate percentiles, and later, measurements from an individual device are also accumulated over this time duration before being given a percentile rank. Cannot be used with list-based metric datatypes.consecutiveDatapointsToAlarm
— (Integer
)If a device is in violation of the behavior for the specified number of consecutive datapoints, an alarm occurs. If not specified, the default is 1.
consecutiveDatapointsToClear
— (Integer
)If an alarm has occurred and the offending device is no longer in violation of the behavior for the specified number of consecutive datapoints, the alarm is cleared. If not specified, the default is 1.
statisticalThreshold
— (map
)A statistical ranking (percentile)that indicates a threshold value by which a behavior is determined to be in compliance or in violation of the behavior.
statistic
— (String
)The percentile that resolves to a threshold value by which compliance with a behavior is determined. Metrics are collected over the specified period (
durationSeconds
) from all reporting devices in your account and statistical ranks are calculated. Then, the measurements from a device are collected over the same period. If the accumulated measurements from the device fall above or below (comparisonOperator
) the value associated with the percentile specified, then the device is considered to be in compliance with the behavior, otherwise a violation occurs.
mlDetectionConfig
— (map
)The configuration of an ML Detect
confidenceLevel
— required — (String
)The sensitivity of anomalous behavior evaluation. Can be
Possible values include:Low
,Medium
, orHigh
."LOW"
"MEDIUM"
"HIGH"
suppressAlerts
— (Boolean
)Suppresses alerts.
exportMetric
— (Boolean
)Value indicates exporting metrics related to the behavior when it is true.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:valid
— (Boolean
)True if the behaviors were valid.
validationErrors
— (Array<map>
)The list of any errors found in the behaviors.
errorMessage
— (String
)The description of an error found in the behaviors.
-
(AWS.Response)
—
Returns:
Generated on Fri Sep 6 18:22:31 2024 by yard 0.9.36 (ruby-2.5.1).