CfnTopicRulePropsMixin
- class aws_cdk.mixins_preview.aws_iot.mixins.CfnTopicRulePropsMixin(props, *, strategy=None)
Bases:
MixinUse the
AWS::IoT::TopicRuleresource to declare an AWS IoT rule.For information about working with AWS IoT rules, see Rules for AWS IoT in the AWS IoT Developer Guide .
- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iot-topicrule.html
- CloudformationResource:
AWS::IoT::TopicRule
- Mixin:
true
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview import mixins from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins cfn_topic_rule_props_mixin = iot_mixins.CfnTopicRulePropsMixin(iot_mixins.CfnTopicRuleMixinProps( rule_name="ruleName", tags=[CfnTag( key="key", value="value" )], topic_rule_payload=iot_mixins.CfnTopicRulePropsMixin.TopicRulePayloadProperty( actions=[iot_mixins.CfnTopicRulePropsMixin.ActionProperty( cloudwatch_alarm=iot_mixins.CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty( alarm_name="alarmName", role_arn="roleArn", state_reason="stateReason", state_value="stateValue" ), cloudwatch_logs=iot_mixins.CfnTopicRulePropsMixin.CloudwatchLogsActionProperty( batch_mode=False, log_group_name="logGroupName", role_arn="roleArn" ), cloudwatch_metric=iot_mixins.CfnTopicRulePropsMixin.CloudwatchMetricActionProperty( metric_name="metricName", metric_namespace="metricNamespace", metric_timestamp="metricTimestamp", metric_unit="metricUnit", metric_value="metricValue", role_arn="roleArn" ), dynamo_db=iot_mixins.CfnTopicRulePropsMixin.DynamoDBActionProperty( hash_key_field="hashKeyField", hash_key_type="hashKeyType", hash_key_value="hashKeyValue", payload_field="payloadField", range_key_field="rangeKeyField", range_key_type="rangeKeyType", range_key_value="rangeKeyValue", role_arn="roleArn", table_name="tableName" ), dynamo_dBv2=iot_mixins.CfnTopicRulePropsMixin.DynamoDBv2ActionProperty( put_item=iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" ), role_arn="roleArn" ), elasticsearch=iot_mixins.CfnTopicRulePropsMixin.ElasticsearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), firehose=iot_mixins.CfnTopicRulePropsMixin.FirehoseActionProperty( batch_mode=False, delivery_stream_name="deliveryStreamName", role_arn="roleArn", separator="separator" ), http=iot_mixins.CfnTopicRulePropsMixin.HttpActionProperty( auth=iot_mixins.CfnTopicRulePropsMixin.HttpAuthorizationProperty( sigv4=iot_mixins.CfnTopicRulePropsMixin.SigV4AuthorizationProperty( role_arn="roleArn", service_name="serviceName", signing_region="signingRegion" ) ), confirmation_url="confirmationUrl", headers=[iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )], url="url" ), iot_analytics=iot_mixins.CfnTopicRulePropsMixin.IotAnalyticsActionProperty( batch_mode=False, channel_name="channelName", role_arn="roleArn" ), iot_events=iot_mixins.CfnTopicRulePropsMixin.IotEventsActionProperty( batch_mode=False, input_name="inputName", message_id="messageId", role_arn="roleArn" ), iot_site_wise=iot_mixins.CfnTopicRulePropsMixin.IotSiteWiseActionProperty( put_asset_property_value_entries=[iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )], role_arn="roleArn" ), kafka=iot_mixins.CfnTopicRulePropsMixin.KafkaActionProperty( client_properties={ "client_properties_key": "clientProperties" }, destination_arn="destinationArn", headers=[iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )], key="key", partition="partition", topic="topic" ), kinesis=iot_mixins.CfnTopicRulePropsMixin.KinesisActionProperty( partition_key="partitionKey", role_arn="roleArn", stream_name="streamName" ), lambda_=iot_mixins.CfnTopicRulePropsMixin.LambdaActionProperty( function_arn="functionArn" ), location=iot_mixins.CfnTopicRulePropsMixin.LocationActionProperty( device_id="deviceId", latitude="latitude", longitude="longitude", role_arn="roleArn", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" ), tracker_name="trackerName" ), open_search=iot_mixins.CfnTopicRulePropsMixin.OpenSearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), republish=iot_mixins.CfnTopicRulePropsMixin.RepublishActionProperty( headers=iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] ), qos=123, role_arn="roleArn", topic="topic" ), s3=iot_mixins.CfnTopicRulePropsMixin.S3ActionProperty( bucket_name="bucketName", canned_acl="cannedAcl", key="key", role_arn="roleArn" ), sns=iot_mixins.CfnTopicRulePropsMixin.SnsActionProperty( message_format="messageFormat", role_arn="roleArn", target_arn="targetArn" ), sqs=iot_mixins.CfnTopicRulePropsMixin.SqsActionProperty( queue_url="queueUrl", role_arn="roleArn", use_base64=False ), step_functions=iot_mixins.CfnTopicRulePropsMixin.StepFunctionsActionProperty( execution_name_prefix="executionNamePrefix", role_arn="roleArn", state_machine_name="stateMachineName" ), timestream=iot_mixins.CfnTopicRulePropsMixin.TimestreamActionProperty( database_name="databaseName", dimensions=[iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )], role_arn="roleArn", table_name="tableName", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" ) ) )], aws_iot_sql_version="awsIotSqlVersion", description="description", error_action=iot_mixins.CfnTopicRulePropsMixin.ActionProperty( cloudwatch_alarm=iot_mixins.CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty( alarm_name="alarmName", role_arn="roleArn", state_reason="stateReason", state_value="stateValue" ), cloudwatch_logs=iot_mixins.CfnTopicRulePropsMixin.CloudwatchLogsActionProperty( batch_mode=False, log_group_name="logGroupName", role_arn="roleArn" ), cloudwatch_metric=iot_mixins.CfnTopicRulePropsMixin.CloudwatchMetricActionProperty( metric_name="metricName", metric_namespace="metricNamespace", metric_timestamp="metricTimestamp", metric_unit="metricUnit", metric_value="metricValue", role_arn="roleArn" ), dynamo_db=iot_mixins.CfnTopicRulePropsMixin.DynamoDBActionProperty( hash_key_field="hashKeyField", hash_key_type="hashKeyType", hash_key_value="hashKeyValue", payload_field="payloadField", range_key_field="rangeKeyField", range_key_type="rangeKeyType", range_key_value="rangeKeyValue", role_arn="roleArn", table_name="tableName" ), dynamo_dBv2=iot_mixins.CfnTopicRulePropsMixin.DynamoDBv2ActionProperty( put_item=iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" ), role_arn="roleArn" ), elasticsearch=iot_mixins.CfnTopicRulePropsMixin.ElasticsearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), firehose=iot_mixins.CfnTopicRulePropsMixin.FirehoseActionProperty( batch_mode=False, delivery_stream_name="deliveryStreamName", role_arn="roleArn", separator="separator" ), http=iot_mixins.CfnTopicRulePropsMixin.HttpActionProperty( auth=iot_mixins.CfnTopicRulePropsMixin.HttpAuthorizationProperty( sigv4=iot_mixins.CfnTopicRulePropsMixin.SigV4AuthorizationProperty( role_arn="roleArn", service_name="serviceName", signing_region="signingRegion" ) ), confirmation_url="confirmationUrl", headers=[iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )], url="url" ), iot_analytics=iot_mixins.CfnTopicRulePropsMixin.IotAnalyticsActionProperty( batch_mode=False, channel_name="channelName", role_arn="roleArn" ), iot_events=iot_mixins.CfnTopicRulePropsMixin.IotEventsActionProperty( batch_mode=False, input_name="inputName", message_id="messageId", role_arn="roleArn" ), iot_site_wise=iot_mixins.CfnTopicRulePropsMixin.IotSiteWiseActionProperty( put_asset_property_value_entries=[iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )], role_arn="roleArn" ), kafka=iot_mixins.CfnTopicRulePropsMixin.KafkaActionProperty( client_properties={ "client_properties_key": "clientProperties" }, destination_arn="destinationArn", headers=[iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )], key="key", partition="partition", topic="topic" ), kinesis=iot_mixins.CfnTopicRulePropsMixin.KinesisActionProperty( partition_key="partitionKey", role_arn="roleArn", stream_name="streamName" ), lambda_=iot_mixins.CfnTopicRulePropsMixin.LambdaActionProperty( function_arn="functionArn" ), location=iot_mixins.CfnTopicRulePropsMixin.LocationActionProperty( device_id="deviceId", latitude="latitude", longitude="longitude", role_arn="roleArn", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" ), tracker_name="trackerName" ), open_search=iot_mixins.CfnTopicRulePropsMixin.OpenSearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), republish=iot_mixins.CfnTopicRulePropsMixin.RepublishActionProperty( headers=iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] ), qos=123, role_arn="roleArn", topic="topic" ), s3=iot_mixins.CfnTopicRulePropsMixin.S3ActionProperty( bucket_name="bucketName", canned_acl="cannedAcl", key="key", role_arn="roleArn" ), sns=iot_mixins.CfnTopicRulePropsMixin.SnsActionProperty( message_format="messageFormat", role_arn="roleArn", target_arn="targetArn" ), sqs=iot_mixins.CfnTopicRulePropsMixin.SqsActionProperty( queue_url="queueUrl", role_arn="roleArn", use_base64=False ), step_functions=iot_mixins.CfnTopicRulePropsMixin.StepFunctionsActionProperty( execution_name_prefix="executionNamePrefix", role_arn="roleArn", state_machine_name="stateMachineName" ), timestream=iot_mixins.CfnTopicRulePropsMixin.TimestreamActionProperty( database_name="databaseName", dimensions=[iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )], role_arn="roleArn", table_name="tableName", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" ) ) ), rule_disabled=False, sql="sql" ) ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::IoT::TopicRule.- Parameters:
props (
Union[CfnTopicRuleMixinProps,Dict[str,Any]]) – L1 properties to apply.strategy (
Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE
Methods
- apply_to(construct)
Apply the mixin properties to the construct.
- Parameters:
construct (
IConstruct)- Return type:
- supports(construct)
Check if this mixin supports the given construct.
- Parameters:
construct (
IConstruct)- Return type:
bool
Attributes
- CFN_PROPERTY_KEYS = ['ruleName', 'tags', 'topicRulePayload']
Static Methods
- classmethod is_mixin(x)
(experimental) Checks if
xis a Mixin.- Parameters:
x (
Any) – Any object.- Return type:
bool- Returns:
true if
xis an object created from a class which extendsMixin.- Stability:
experimental
ActionProperty
- class CfnTopicRulePropsMixin.ActionProperty(*, cloudwatch_alarm=None, cloudwatch_logs=None, cloudwatch_metric=None, dynamo_db=None, dynamo_d_bv2=None, elasticsearch=None, firehose=None, http=None, iot_analytics=None, iot_events=None, iot_site_wise=None, kafka=None, kinesis=None, lambda_=None, location=None, open_search=None, republish=None, s3=None, sns=None, sqs=None, step_functions=None, timestream=None)
Bases:
objectDescribes the actions associated with a rule.
- Parameters:
cloudwatch_alarm (
Union[IResolvable,CloudwatchAlarmActionProperty,Dict[str,Any],None]) – Change the state of a CloudWatch alarm.cloudwatch_logs (
Union[IResolvable,CloudwatchLogsActionProperty,Dict[str,Any],None]) – Sends data to CloudWatch.cloudwatch_metric (
Union[IResolvable,CloudwatchMetricActionProperty,Dict[str,Any],None]) – Capture a CloudWatch metric.dynamo_db (
Union[IResolvable,DynamoDBActionProperty,Dict[str,Any],None]) – Write to a DynamoDB table.dynamo_d_bv2 (
Union[IResolvable,DynamoDBv2ActionProperty,Dict[str,Any],None]) – 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.elasticsearch (
Union[IResolvable,ElasticsearchActionProperty,Dict[str,Any],None]) – Write data to an Amazon OpenSearch Service domain. .. epigraph:: TheElasticsearchaction can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearchrule action instead. For more information, see OpenSearchAction .firehose (
Union[IResolvable,FirehoseActionProperty,Dict[str,Any],None]) – Write to an Amazon Kinesis Firehose stream.http (
Union[IResolvable,HttpActionProperty,Dict[str,Any],None]) – Send data to an HTTPS endpoint.iot_analytics (
Union[IResolvable,IotAnalyticsActionProperty,Dict[str,Any],None]) – Sends message data to an AWS IoT Analytics channel.iot_events (
Union[IResolvable,IotEventsActionProperty,Dict[str,Any],None]) – Sends an input to an AWS IoT Events detector.iot_site_wise (
Union[IResolvable,IotSiteWiseActionProperty,Dict[str,Any],None]) – Sends data from the MQTT message that triggered the rule to AWS IoT SiteWise asset properties.kafka (
Union[IResolvable,KafkaActionProperty,Dict[str,Any],None]) – Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.kinesis (
Union[IResolvable,KinesisActionProperty,Dict[str,Any],None]) – Write data to an Amazon Kinesis stream.lambda – Invoke a Lambda function.
location (
Union[IResolvable,LocationActionProperty,Dict[str,Any],None]) – Sends device location data to Amazon Location Service .open_search (
Union[IResolvable,OpenSearchActionProperty,Dict[str,Any],None]) – Write data to an Amazon OpenSearch Service domain.republish (
Union[IResolvable,RepublishActionProperty,Dict[str,Any],None]) – Publish to another MQTT topic.s3 (
Union[IResolvable,S3ActionProperty,Dict[str,Any],None]) – Write to an Amazon S3 bucket.sns (
Union[IResolvable,SnsActionProperty,Dict[str,Any],None]) – Publish to an Amazon SNS topic.sqs (
Union[IResolvable,SqsActionProperty,Dict[str,Any],None]) – Publish to an Amazon SQS queue.step_functions (
Union[IResolvable,StepFunctionsActionProperty,Dict[str,Any],None]) – Starts execution of a Step Functions state machine.timestream (
Union[IResolvable,TimestreamActionProperty,Dict[str,Any],None]) – Writes attributes from an MQTT message.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins action_property = iot_mixins.CfnTopicRulePropsMixin.ActionProperty( cloudwatch_alarm=iot_mixins.CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty( alarm_name="alarmName", role_arn="roleArn", state_reason="stateReason", state_value="stateValue" ), cloudwatch_logs=iot_mixins.CfnTopicRulePropsMixin.CloudwatchLogsActionProperty( batch_mode=False, log_group_name="logGroupName", role_arn="roleArn" ), cloudwatch_metric=iot_mixins.CfnTopicRulePropsMixin.CloudwatchMetricActionProperty( metric_name="metricName", metric_namespace="metricNamespace", metric_timestamp="metricTimestamp", metric_unit="metricUnit", metric_value="metricValue", role_arn="roleArn" ), dynamo_db=iot_mixins.CfnTopicRulePropsMixin.DynamoDBActionProperty( hash_key_field="hashKeyField", hash_key_type="hashKeyType", hash_key_value="hashKeyValue", payload_field="payloadField", range_key_field="rangeKeyField", range_key_type="rangeKeyType", range_key_value="rangeKeyValue", role_arn="roleArn", table_name="tableName" ), dynamo_dBv2=iot_mixins.CfnTopicRulePropsMixin.DynamoDBv2ActionProperty( put_item=iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" ), role_arn="roleArn" ), elasticsearch=iot_mixins.CfnTopicRulePropsMixin.ElasticsearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), firehose=iot_mixins.CfnTopicRulePropsMixin.FirehoseActionProperty( batch_mode=False, delivery_stream_name="deliveryStreamName", role_arn="roleArn", separator="separator" ), http=iot_mixins.CfnTopicRulePropsMixin.HttpActionProperty( auth=iot_mixins.CfnTopicRulePropsMixin.HttpAuthorizationProperty( sigv4=iot_mixins.CfnTopicRulePropsMixin.SigV4AuthorizationProperty( role_arn="roleArn", service_name="serviceName", signing_region="signingRegion" ) ), confirmation_url="confirmationUrl", headers=[iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )], url="url" ), iot_analytics=iot_mixins.CfnTopicRulePropsMixin.IotAnalyticsActionProperty( batch_mode=False, channel_name="channelName", role_arn="roleArn" ), iot_events=iot_mixins.CfnTopicRulePropsMixin.IotEventsActionProperty( batch_mode=False, input_name="inputName", message_id="messageId", role_arn="roleArn" ), iot_site_wise=iot_mixins.CfnTopicRulePropsMixin.IotSiteWiseActionProperty( put_asset_property_value_entries=[iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )], role_arn="roleArn" ), kafka=iot_mixins.CfnTopicRulePropsMixin.KafkaActionProperty( client_properties={ "client_properties_key": "clientProperties" }, destination_arn="destinationArn", headers=[iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )], key="key", partition="partition", topic="topic" ), kinesis=iot_mixins.CfnTopicRulePropsMixin.KinesisActionProperty( partition_key="partitionKey", role_arn="roleArn", stream_name="streamName" ), lambda_=iot_mixins.CfnTopicRulePropsMixin.LambdaActionProperty( function_arn="functionArn" ), location=iot_mixins.CfnTopicRulePropsMixin.LocationActionProperty( device_id="deviceId", latitude="latitude", longitude="longitude", role_arn="roleArn", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" ), tracker_name="trackerName" ), open_search=iot_mixins.CfnTopicRulePropsMixin.OpenSearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), republish=iot_mixins.CfnTopicRulePropsMixin.RepublishActionProperty( headers=iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] ), qos=123, role_arn="roleArn", topic="topic" ), s3=iot_mixins.CfnTopicRulePropsMixin.S3ActionProperty( bucket_name="bucketName", canned_acl="cannedAcl", key="key", role_arn="roleArn" ), sns=iot_mixins.CfnTopicRulePropsMixin.SnsActionProperty( message_format="messageFormat", role_arn="roleArn", target_arn="targetArn" ), sqs=iot_mixins.CfnTopicRulePropsMixin.SqsActionProperty( queue_url="queueUrl", role_arn="roleArn", use_base64=False ), step_functions=iot_mixins.CfnTopicRulePropsMixin.StepFunctionsActionProperty( execution_name_prefix="executionNamePrefix", role_arn="roleArn", state_machine_name="stateMachineName" ), timestream=iot_mixins.CfnTopicRulePropsMixin.TimestreamActionProperty( database_name="databaseName", dimensions=[iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )], role_arn="roleArn", table_name="tableName", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" ) ) )
Attributes
- cloudwatch_alarm
Change the state of a CloudWatch alarm.
- cloudwatch_logs
Sends data to CloudWatch.
- cloudwatch_metric
Capture a CloudWatch metric.
- dynamo_d_bv2
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.
- dynamo_db
Write to a DynamoDB table.
- elasticsearch
Write data to an Amazon OpenSearch Service domain.
The
Elasticsearchaction can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearchrule action instead. For more information, see OpenSearchAction .
- firehose
Write to an Amazon Kinesis Firehose stream.
- http
Send data to an HTTPS endpoint.
- iot_analytics
Sends message data to an AWS IoT Analytics channel.
- iot_events
Sends an input to an AWS IoT Events detector.
- iot_site_wise
Sends data from the MQTT message that triggered the rule to AWS IoT SiteWise asset properties.
- kafka
Send messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
- kinesis
Write data to an Amazon Kinesis stream.
- lambda_
Invoke a Lambda function.
- location
Sends device location data to Amazon Location Service .
- open_search
Write data to an Amazon OpenSearch Service domain.
- republish
Publish to another MQTT topic.
- s3
Write to an Amazon S3 bucket.
- sns
Publish to an Amazon SNS topic.
- sqs
Publish to an Amazon SQS queue.
- step_functions
Starts execution of a Step Functions state machine.
- timestream
Writes attributes from an MQTT message.
AssetPropertyTimestampProperty
- class CfnTopicRulePropsMixin.AssetPropertyTimestampProperty(*, offset_in_nanos=None, time_in_seconds=None)
Bases:
objectAn asset property timestamp entry containing the following information.
- Parameters:
offset_in_nanos (
Optional[str]) – Optional. A string that contains the nanosecond time offset. Accepts substitution templates.time_in_seconds (
Optional[str]) – A string that contains the time in seconds since epoch. Accepts substitution templates.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins asset_property_timestamp_property = iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" )
Attributes
- offset_in_nanos
Optional.
A string that contains the nanosecond time offset. Accepts substitution templates.
- time_in_seconds
A string that contains the time in seconds since epoch.
Accepts substitution templates.
AssetPropertyValueProperty
- class CfnTopicRulePropsMixin.AssetPropertyValueProperty(*, quality=None, timestamp=None, value=None)
Bases:
objectAn asset property value entry containing the following information.
- Parameters:
quality (
Optional[str]) – Optional. A string that describes the quality of the value. Accepts substitution templates. Must beGOOD,BAD, orUNCERTAIN.timestamp (
Union[IResolvable,AssetPropertyTimestampProperty,Dict[str,Any],None]) – The asset property value timestamp.value (
Union[IResolvable,AssetPropertyVariantProperty,Dict[str,Any],None]) – The value of the asset property.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins asset_property_value_property = iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )
Attributes
- quality
Optional.
A string that describes the quality of the value. Accepts substitution templates. Must be
GOOD,BAD, orUNCERTAIN.
- timestamp
The asset property value timestamp.
- value
The value of the asset property.
AssetPropertyVariantProperty
- class CfnTopicRulePropsMixin.AssetPropertyVariantProperty(*, boolean_value=None, double_value=None, integer_value=None, string_value=None)
Bases:
objectContains an asset property value (of a single type).
- Parameters:
boolean_value (
Optional[str]) – Optional. A string that contains the boolean value (trueorfalse) of the value entry. Accepts substitution templates.double_value (
Optional[str]) – Optional. A string that contains the double value of the value entry. Accepts substitution templates.integer_value (
Optional[str]) – Optional. A string that contains the integer value of the value entry. Accepts substitution templates.string_value (
Optional[str]) – Optional. The string value of the value entry. Accepts substitution templates.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins asset_property_variant_property = iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" )
Attributes
- boolean_value
Optional.
A string that contains the boolean value (
trueorfalse) of the value entry. Accepts substitution templates.
- double_value
Optional.
A string that contains the double value of the value entry. Accepts substitution templates.
- integer_value
Optional.
A string that contains the integer value of the value entry. Accepts substitution templates.
- string_value
Optional.
The string value of the value entry. Accepts substitution templates.
CloudwatchAlarmActionProperty
- class CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty(*, alarm_name=None, role_arn=None, state_reason=None, state_value=None)
Bases:
objectDescribes an action that updates a CloudWatch alarm.
- Parameters:
alarm_name (
Optional[str]) – The CloudWatch alarm name.role_arn (
Optional[str]) – The IAM role that allows access to the CloudWatch alarm.state_reason (
Optional[str]) – The reason for the alarm change.state_value (
Optional[str]) – The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins cloudwatch_alarm_action_property = iot_mixins.CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty( alarm_name="alarmName", role_arn="roleArn", state_reason="stateReason", state_value="stateValue" )
Attributes
- alarm_name
The CloudWatch alarm name.
- role_arn
The IAM role that allows access to the CloudWatch alarm.
- state_reason
The reason for the alarm change.
- state_value
The value of the alarm state.
Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
CloudwatchLogsActionProperty
- class CfnTopicRulePropsMixin.CloudwatchLogsActionProperty(*, batch_mode=None, log_group_name=None, role_arn=None)
Bases:
objectDescribes an action that updates a CloudWatch log.
- Parameters:
batch_mode (
Union[bool,IResolvable,None]) – Indicates whether batches of log records will be extracted and uploaded into CloudWatch.log_group_name (
Optional[str]) – The CloudWatch log name.role_arn (
Optional[str]) – The IAM role that allows access to the CloudWatch log.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins cloudwatch_logs_action_property = iot_mixins.CfnTopicRulePropsMixin.CloudwatchLogsActionProperty( batch_mode=False, log_group_name="logGroupName", role_arn="roleArn" )
Attributes
- batch_mode
Indicates whether batches of log records will be extracted and uploaded into CloudWatch.
- log_group_name
The CloudWatch log name.
- role_arn
The IAM role that allows access to the CloudWatch log.
CloudwatchMetricActionProperty
- class CfnTopicRulePropsMixin.CloudwatchMetricActionProperty(*, metric_name=None, metric_namespace=None, metric_timestamp=None, metric_unit=None, metric_value=None, role_arn=None)
Bases:
objectDescribes an action that captures a CloudWatch metric.
- Parameters:
metric_name (
Optional[str]) – The CloudWatch metric name.metric_namespace (
Optional[str]) – The CloudWatch metric namespace name.metric_timestamp (
Optional[str]) – An optional Unix timestamp .metric_unit (
Optional[str]) – The metric unit supported by CloudWatch.metric_value (
Optional[str]) – The CloudWatch metric value.role_arn (
Optional[str]) – The IAM role that allows access to the CloudWatch metric.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins cloudwatch_metric_action_property = iot_mixins.CfnTopicRulePropsMixin.CloudwatchMetricActionProperty( metric_name="metricName", metric_namespace="metricNamespace", metric_timestamp="metricTimestamp", metric_unit="metricUnit", metric_value="metricValue", role_arn="roleArn" )
Attributes
- metric_name
The CloudWatch metric name.
- metric_namespace
The CloudWatch metric namespace name.
- metric_timestamp
An optional Unix timestamp .
- metric_unit
The metric unit supported by CloudWatch.
- metric_value
The CloudWatch metric value.
- role_arn
The IAM role that allows access to the CloudWatch metric.
DynamoDBActionProperty
- class CfnTopicRulePropsMixin.DynamoDBActionProperty(*, hash_key_field=None, hash_key_type=None, hash_key_value=None, payload_field=None, range_key_field=None, range_key_type=None, range_key_value=None, role_arn=None, table_name=None)
Bases:
objectDescribes an action to write to a DynamoDB table.
The
tableName,hashKeyField, andrangeKeyFieldvalues must match the values used when you created the table.The
hashKeyValueandrangeKeyvaluefields use a substitution template syntax. These templates provide data at runtime. The syntax is as follows: ${ sql-expression }.You can specify any valid expression in a WHERE or SELECT clause, including JSON properties, comparisons, calculations, and functions. For example, the following field uses the third level of the topic:
"hashKeyValue": "${topic(3)}"The following field uses the timestamp:
"rangeKeyValue": "${timestamp()}"For more information, see DynamoDBv2 Action in the AWS IoT Developer Guide .
- Parameters:
hash_key_field (
Optional[str]) – The hash key name.hash_key_type (
Optional[str]) – The hash key type. Valid values are “STRING” or “NUMBER”hash_key_value (
Optional[str]) – The hash key value.payload_field (
Optional[str]) – The action payload. This name can be customized.range_key_field (
Optional[str]) – The range key name.range_key_type (
Optional[str]) – The range key type. Valid values are “STRING” or “NUMBER”range_key_value (
Optional[str]) – The range key value.role_arn (
Optional[str]) – The ARN of the IAM role that grants access to the DynamoDB table.table_name (
Optional[str]) – The name of the DynamoDB table.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins dynamo_dBAction_property = iot_mixins.CfnTopicRulePropsMixin.DynamoDBActionProperty( hash_key_field="hashKeyField", hash_key_type="hashKeyType", hash_key_value="hashKeyValue", payload_field="payloadField", range_key_field="rangeKeyField", range_key_type="rangeKeyType", range_key_value="rangeKeyValue", role_arn="roleArn", table_name="tableName" )
Attributes
- hash_key_field
The hash key name.
- hash_key_type
The hash key type.
Valid values are “STRING” or “NUMBER”
- hash_key_value
The hash key value.
- payload_field
The action payload.
This name can be customized.
- range_key_field
The range key name.
- range_key_type
The range key type.
Valid values are “STRING” or “NUMBER”
- range_key_value
The range key value.
- role_arn
The ARN of the IAM role that grants access to the DynamoDB table.
- table_name
The name of the DynamoDB table.
DynamoDBv2ActionProperty
- class CfnTopicRulePropsMixin.DynamoDBv2ActionProperty(*, put_item=None, role_arn=None)
Bases:
objectDescribes an action to write to a DynamoDB table.
This DynamoDB action writes each attribute in the message payload into it’s own column in the DynamoDB table.
- Parameters:
put_item (
Union[IResolvable,PutItemInputProperty,Dict[str,Any],None]) – 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.role_arn (
Optional[str]) – The ARN of the IAM role that grants access to the DynamoDB table.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins dynamo_dBv2_action_property = iot_mixins.CfnTopicRulePropsMixin.DynamoDBv2ActionProperty( put_item=iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" ), role_arn="roleArn" )
Attributes
- put_item
.
{ "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.
- See:
- Type:
Specifies the DynamoDB table to which the message data will be written. For example
- role_arn
The ARN of the IAM role that grants access to the DynamoDB table.
ElasticsearchActionProperty
- class CfnTopicRulePropsMixin.ElasticsearchActionProperty(*, endpoint=None, id=None, index=None, role_arn=None, type=None)
Bases:
objectDescribes an action that writes data to an Amazon OpenSearch Service domain.
The
Elasticsearchaction can only be used by existing rule actions. To create a new rule action or to update an existing rule action, use theOpenSearchrule action instead. For more information, see OpenSearchAction .- Parameters:
endpoint (
Optional[str]) – The endpoint of your OpenSearch domain.id (
Optional[str]) – The unique identifier for the document you are storing.index (
Optional[str]) – The index where you want to store your data.role_arn (
Optional[str]) – The IAM role ARN that has access to OpenSearch.type (
Optional[str]) – The type of document you are storing.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins elasticsearch_action_property = iot_mixins.CfnTopicRulePropsMixin.ElasticsearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" )
Attributes
- endpoint
The endpoint of your OpenSearch domain.
- id
The unique identifier for the document you are storing.
- index
The index where you want to store your data.
- role_arn
The IAM role ARN that has access to OpenSearch.
- type
The type of document you are storing.
FirehoseActionProperty
- class CfnTopicRulePropsMixin.FirehoseActionProperty(*, batch_mode=None, delivery_stream_name=None, role_arn=None, separator=None)
Bases:
objectDescribes an action that writes data to an Amazon Kinesis Firehose stream.
- Parameters:
batch_mode (
Union[bool,IResolvable,None]) – Whether to deliver the Kinesis Data Firehose stream as a batch by using`PutRecordBatch<https://docs.aws.amazon.com/firehose/latest/APIReference/API_PutRecordBatch.html>`_ . The default value isfalse. WhenbatchModeistrueand the rule’s SQL statement evaluates to an Array, each Array element forms one record in the`PutRecordBatch<https://docs.aws.amazon.com/firehose/latest/APIReference/API_PutRecordBatch.html>`_ request. The resulting array can’t have more than 500 records.delivery_stream_name (
Optional[str]) – The delivery stream name.role_arn (
Optional[str]) – The IAM role that grants access to the Amazon Kinesis Firehose stream.separator (
Optional[str]) – A character separator that will be used to separate records written to the Firehose stream. Valid values are: ‘n’ (newline), ‘t’ (tab), ‘rn’ (Windows newline), ‘,’ (comma).
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins firehose_action_property = iot_mixins.CfnTopicRulePropsMixin.FirehoseActionProperty( batch_mode=False, delivery_stream_name="deliveryStreamName", role_arn="roleArn", separator="separator" )
Attributes
- batch_mode
//docs.aws.amazon.com/firehose/latest/APIReference/API_PutRecordBatch.html>`_ . The default value is
false.When
batchModeistrueand the rule’s SQL statement evaluates to an Array, each Array element forms one record in the`PutRecordBatch<https://docs.aws.amazon.com/firehose/latest/APIReference/API_PutRecordBatch.html>`_ request. The resulting array can’t have more than 500 records.- See:
- Type:
Whether to deliver the Kinesis Data Firehose stream as a batch by using
`PutRecordBatch<https
- delivery_stream_name
The delivery stream name.
- role_arn
The IAM role that grants access to the Amazon Kinesis Firehose stream.
- separator
A character separator that will be used to separate records written to the Firehose stream.
Valid values are: ‘n’ (newline), ‘t’ (tab), ‘rn’ (Windows newline), ‘,’ (comma).
HttpActionHeaderProperty
- class CfnTopicRulePropsMixin.HttpActionHeaderProperty(*, key=None, value=None)
Bases:
objectThe HTTP action header.
- Parameters:
key (
Optional[str]) – The HTTP header key.value (
Optional[str]) – The HTTP header value. Substitution templates are supported.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins http_action_header_property = iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )
Attributes
- key
The HTTP header key.
- value
The HTTP header value.
Substitution templates are supported.
HttpActionProperty
- class CfnTopicRulePropsMixin.HttpActionProperty(*, auth=None, confirmation_url=None, headers=None, url=None)
Bases:
objectSend data to an HTTPS endpoint.
- Parameters:
auth (
Union[IResolvable,HttpAuthorizationProperty,Dict[str,Any],None]) – The authentication method to use when sending data to an HTTPS endpoint.confirmation_url (
Optional[str]) – The URL to which AWS 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 AWS 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 (
Union[IResolvable,Sequence[Union[IResolvable,HttpActionHeaderProperty,Dict[str,Any]]],None]) – The HTTP headers to send with the message data.url (
Optional[str]) – The endpoint URL. If substitution templates are used in the URL, you must also specify aconfirmationUrl. If this is a new destination, a newTopicRuleDestinationis created if possible.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins http_action_property = iot_mixins.CfnTopicRulePropsMixin.HttpActionProperty( auth=iot_mixins.CfnTopicRulePropsMixin.HttpAuthorizationProperty( sigv4=iot_mixins.CfnTopicRulePropsMixin.SigV4AuthorizationProperty( role_arn="roleArn", service_name="serviceName", signing_region="signingRegion" ) ), confirmation_url="confirmationUrl", headers=[iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )], url="url" )
Attributes
- auth
The authentication method to use when sending data to an HTTPS endpoint.
- confirmation_url
The URL to which AWS 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 AWS 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
The HTTP headers to send with the message data.
- url
The endpoint URL.
If substitution templates are used in the URL, you must also specify a
confirmationUrl. If this is a new destination, a newTopicRuleDestinationis created if possible.
IotAnalyticsActionProperty
- class CfnTopicRulePropsMixin.IotAnalyticsActionProperty(*, batch_mode=None, channel_name=None, role_arn=None)
Bases:
objectSends message data to an AWS IoT Analytics channel.
- Parameters:
batch_mode (
Union[bool,IResolvable,None]) – Whether to process the action as a batch. The default value isfalse. WhenbatchModeistrueand the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed by`BatchPutMessage<https://docs.aws.amazon.com/iotanalytics/latest/APIReference/API_BatchPutMessage.html>`_ The resulting array can’t have more than 100 messages.channel_name (
Optional[str]) – The name of the IoT Analytics channel to which message data will be sent.role_arn (
Optional[str]) – The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics:BatchPutMessage).
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins iot_analytics_action_property = iot_mixins.CfnTopicRulePropsMixin.IotAnalyticsActionProperty( batch_mode=False, channel_name="channelName", role_arn="roleArn" )
Attributes
- batch_mode
Whether to process the action as a batch. The default value is
false.When
batchModeistrueand the rule SQL statement evaluates to an Array, each Array element is delivered as a separate message when passed by`BatchPutMessage<https://docs.aws.amazon.com/iotanalytics/latest/APIReference/API_BatchPutMessage.html>`_ The resulting array can’t have more than 100 messages.
- channel_name
The name of the IoT Analytics channel to which message data will be sent.
- role_arn
BatchPutMessage).
- See:
- Type:
The ARN of the role which has a policy that grants IoT Analytics permission to send message data via IoT Analytics (iotanalytics
IotEventsActionProperty
- class CfnTopicRulePropsMixin.IotEventsActionProperty(*, batch_mode=None, input_name=None, message_id=None, role_arn=None)
Bases:
objectSends an input to an AWS IoT Events detector.
- Parameters:
batch_mode (
Union[bool,IResolvable,None]) – Whether to process the event actions as a batch. The default value isfalse. WhenbatchModeistrue, you can’t specify amessageId. WhenbatchModeistrueand the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when Events by calling`BatchPutMessage<https://docs.aws.amazon.com/iotevents/latest/apireference/API_iotevents-data_BatchPutMessage.html>`_ . The resulting array can’t have more than 10 messages.input_name (
Optional[str]) – The name of the AWS IoT Events input.message_id (
Optional[str]) – The ID of the message. The defaultmessageIdis a new UUID value. WhenbatchModeistrue, 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 givenmessageIdwill be processed by an AWS IoT Events detector.role_arn (
Optional[str]) – The ARN of the role that grants AWS IoT permission to send an input to an AWS IoT Events detector. (“Action”:”iotevents:BatchPutMessage”).
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins iot_events_action_property = iot_mixins.CfnTopicRulePropsMixin.IotEventsActionProperty( batch_mode=False, input_name="inputName", message_id="messageId", role_arn="roleArn" )
Attributes
- batch_mode
Whether to process the event actions as a batch. The default value is
false.When
batchModeistrue, you can’t specify amessageId.When
batchModeistrueand the rule SQL statement evaluates to an Array, each Array element is treated as a separate message when Events by calling`BatchPutMessage<https://docs.aws.amazon.com/iotevents/latest/apireference/API_iotevents-data_BatchPutMessage.html>`_ . The resulting array can’t have more than 10 messages.
- input_name
The name of the AWS IoT Events input.
- message_id
The ID of the message. The default
messageIdis a new UUID value.When
batchModeistrue, 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
messageIdwill be processed by an AWS IoT Events detector.
- role_arn
The ARN of the role that grants AWS IoT permission to send an input to an AWS IoT Events detector.
(“Action”:”iotevents:BatchPutMessage”).
IotSiteWiseActionProperty
- class CfnTopicRulePropsMixin.IotSiteWiseActionProperty(*, put_asset_property_value_entries=None, role_arn=None)
Bases:
objectDescribes an action to send data from an MQTT message that triggered the rule to AWS IoT SiteWise asset properties.
- Parameters:
put_asset_property_value_entries (
Union[IResolvable,Sequence[Union[IResolvable,PutAssetPropertyValueEntryProperty,Dict[str,Any]]],None]) – A list of asset property value entries.role_arn (
Optional[str]) – The ARN of the role that grants AWS IoT permission to send an asset property value to AWS IoT SiteWise. ("Action": "iotsitewise:BatchPutAssetPropertyValue"). The trust policy can restrict access to specific asset hierarchy paths.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins iot_site_wise_action_property = iot_mixins.CfnTopicRulePropsMixin.IotSiteWiseActionProperty( put_asset_property_value_entries=[iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )], role_arn="roleArn" )
Attributes
- put_asset_property_value_entries
A list of asset property value entries.
- role_arn
The ARN of the role that grants AWS IoT permission to send an asset property value to AWS IoT SiteWise.
(
"Action": "iotsitewise:BatchPutAssetPropertyValue"). The trust policy can restrict access to specific asset hierarchy paths.
KafkaActionHeaderProperty
- class CfnTopicRulePropsMixin.KafkaActionHeaderProperty(*, key=None, value=None)
Bases:
objectSpecifies a Kafka header using key-value pairs when you create a Rule’s Kafka Action.
You can use these headers to route data from IoT clients to downstream Kafka clusters without modifying your message payload.
- Parameters:
key (
Optional[str]) – The key of the Kafka header.value (
Optional[str]) – The value of the Kafka header.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins kafka_action_header_property = iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )
Attributes
- key
The key of the Kafka header.
- value
The value of the Kafka header.
KafkaActionProperty
- class CfnTopicRulePropsMixin.KafkaActionProperty(*, client_properties=None, destination_arn=None, headers=None, key=None, partition=None, topic=None)
Bases:
objectSend messages to an Amazon Managed Streaming for Apache Kafka (Amazon MSK) or self-managed Apache Kafka cluster.
- Parameters:
client_properties (
Union[Mapping[str,str],IResolvable,None]) – Properties of the Apache Kafka producer client.destination_arn (
Optional[str]) – The ARN of Kafka action’s VPCTopicRuleDestination.headers (
Union[IResolvable,Sequence[Union[IResolvable,KafkaActionHeaderProperty,Dict[str,Any]]],None]) – The list of Kafka headers that you specify.key (
Optional[str]) – The Kafka message key.partition (
Optional[str]) – The Kafka message partition.topic (
Optional[str]) – The Kafka topic for messages to be sent to the Kafka broker.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins kafka_action_property = iot_mixins.CfnTopicRulePropsMixin.KafkaActionProperty( client_properties={ "client_properties_key": "clientProperties" }, destination_arn="destinationArn", headers=[iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )], key="key", partition="partition", topic="topic" )
Attributes
- client_properties
Properties of the Apache Kafka producer client.
- destination_arn
The ARN of Kafka action’s VPC
TopicRuleDestination.
- headers
The list of Kafka headers that you specify.
- key
The Kafka message key.
- partition
The Kafka message partition.
- topic
The Kafka topic for messages to be sent to the Kafka broker.
KinesisActionProperty
- class CfnTopicRulePropsMixin.KinesisActionProperty(*, partition_key=None, role_arn=None, stream_name=None)
Bases:
objectDescribes an action to write data to an Amazon Kinesis stream.
- Parameters:
partition_key (
Optional[str]) – The partition key.role_arn (
Optional[str]) – The ARN of the IAM role that grants access to the Amazon Kinesis stream.stream_name (
Optional[str]) – The name of the Amazon Kinesis stream.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins kinesis_action_property = iot_mixins.CfnTopicRulePropsMixin.KinesisActionProperty( partition_key="partitionKey", role_arn="roleArn", stream_name="streamName" )
Attributes
- partition_key
The partition key.
- role_arn
The ARN of the IAM role that grants access to the Amazon Kinesis stream.
- stream_name
The name of the Amazon Kinesis stream.
LambdaActionProperty
- class CfnTopicRulePropsMixin.LambdaActionProperty(*, function_arn=None)
Bases:
objectDescribes an action to invoke a Lambda function.
- Parameters:
function_arn (
Optional[str]) – The ARN of the Lambda function.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins lambda_action_property = iot_mixins.CfnTopicRulePropsMixin.LambdaActionProperty( function_arn="functionArn" )
Attributes
- function_arn
The ARN of the Lambda function.
LocationActionProperty
- class CfnTopicRulePropsMixin.LocationActionProperty(*, device_id=None, latitude=None, longitude=None, role_arn=None, timestamp=None, tracker_name=None)
Bases:
objectDescribes an action to send device location updates from an MQTT message to an Amazon Location tracker resource.
- Parameters:
device_id (
Optional[str]) – The unique ID of the device providing the location data.latitude (
Optional[str]) – A string that evaluates to a double value that represents the latitude of the device’s location.longitude (
Optional[str]) – A string that evaluates to a double value that represents the longitude of the device’s location.role_arn (
Optional[str]) – The IAM role that grants permission to write to the Amazon Location resource.timestamp (
Union[IResolvable,TimestampProperty,Dict[str,Any],None]) – The time that the location data was sampled. The default value is the time the MQTT message was processed.tracker_name (
Optional[str]) – The name of the tracker resource in Amazon Location in which the location is updated.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins location_action_property = iot_mixins.CfnTopicRulePropsMixin.LocationActionProperty( device_id="deviceId", latitude="latitude", longitude="longitude", role_arn="roleArn", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" ), tracker_name="trackerName" )
Attributes
- device_id
The unique ID of the device providing the location data.
- latitude
A string that evaluates to a double value that represents the latitude of the device’s location.
- longitude
A string that evaluates to a double value that represents the longitude of the device’s location.
- role_arn
The IAM role that grants permission to write to the Amazon Location resource.
- timestamp
The time that the location data was sampled.
The default value is the time the MQTT message was processed.
- tracker_name
The name of the tracker resource in Amazon Location in which the location is updated.
OpenSearchActionProperty
- class CfnTopicRulePropsMixin.OpenSearchActionProperty(*, endpoint=None, id=None, index=None, role_arn=None, type=None)
Bases:
objectDescribes an action that writes data to an Amazon OpenSearch Service domain.
- Parameters:
endpoint (
Optional[str]) – The endpoint of your OpenSearch domain.id (
Optional[str]) – The unique identifier for the document you are storing.index (
Optional[str]) – The OpenSearch index where you want to store your data.role_arn (
Optional[str]) – The IAM role ARN that has access to OpenSearch.type (
Optional[str]) – The type of document you are storing.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins open_search_action_property = iot_mixins.CfnTopicRulePropsMixin.OpenSearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" )
Attributes
- endpoint
The endpoint of your OpenSearch domain.
- id
The unique identifier for the document you are storing.
- index
The OpenSearch index where you want to store your data.
- role_arn
The IAM role ARN that has access to OpenSearch.
- type
The type of document you are storing.
PutAssetPropertyValueEntryProperty
- class CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty(*, asset_id=None, entry_id=None, property_alias=None, property_id=None, property_values=None)
Bases:
objectAn asset property value entry containing the following information.
- Parameters:
asset_id (
Optional[str]) – The ID of the AWS IoT SiteWise asset. You must specify either apropertyAliasor both analiasIdand apropertyId. Accepts substitution templates.entry_id (
Optional[str]) – 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.property_alias (
Optional[str]) – The name of the property alias associated with your asset property. You must specify either apropertyAliasor both analiasIdand apropertyId. Accepts substitution templates.property_id (
Optional[str]) – The ID of the asset’s property. You must specify either apropertyAliasor both analiasIdand apropertyId. Accepts substitution templates.property_values (
Union[IResolvable,Sequence[Union[IResolvable,AssetPropertyValueProperty,Dict[str,Any]]],None]) – A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins put_asset_property_value_entry_property = iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )
Attributes
- asset_id
The ID of the AWS IoT SiteWise asset.
You must specify either a
propertyAliasor both analiasIdand apropertyId. Accepts substitution templates.
- entry_id
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.
- property_alias
The name of the property alias associated with your asset property.
You must specify either a
propertyAliasor both analiasIdand apropertyId. Accepts substitution templates.
- property_id
The ID of the asset’s property.
You must specify either a
propertyAliasor both analiasIdand apropertyId. Accepts substitution templates.
- property_values
A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
PutItemInputProperty
- class CfnTopicRulePropsMixin.PutItemInputProperty(*, table_name=None)
Bases:
objectThe input for the DynamoActionVS action that specifies the DynamoDB table to which the message data will be written.
- Parameters:
table_name (
Optional[str]) – The table where the message data will be written.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins put_item_input_property = iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" )
Attributes
- table_name
The table where the message data will be written.
RepublishActionHeadersProperty
- class CfnTopicRulePropsMixin.RepublishActionHeadersProperty(*, content_type=None, correlation_data=None, message_expiry=None, payload_format_indicator=None, response_topic=None, user_properties=None)
Bases:
objectSpecifies MQTT Version 5.0 headers information. For more information, see MQTT in the IoT Core Developer Guide.
- Parameters:
content_type (
Optional[str]) – A UTF-8 encoded string that describes the content of the publishing message. For more information, see Content Type in the MQTT Version 5.0 specification. Supports substitution templates .correlation_data (
Optional[str]) –The base64-encoded binary data used by the sender of the request message to identify which request the response message is for. For more information, see Correlation Data in the MQTT Version 5.0 specification. Supports substitution templates . .. epigraph:: This binary data must be base64-encoded.
message_expiry (
Optional[str]) –A user-defined integer value that represents the message expiry interval at the broker. If the messages haven’t been sent to the subscribers within that interval, the message expires and is removed. The value of
messageExpiryrepresents the number of seconds before it expires. For more information about the limits ofmessageExpiry, see Message broker and protocol limits and quotas in the IoT Core Reference Guide. Supports substitution templates .payload_format_indicator (
Optional[str]) –An
Enumstring value that indicates whether the payload is formatted as UTF-8. Valid values areUNSPECIFIED_BYTESandUTF8_DATA. For more information, see Payload Format Indicator from the MQTT Version 5.0 specification. Supports substitution templates .response_topic (
Optional[str]) –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 to which the receiver should publish as part of the request-response flow. The topic must not contain wildcard characters. For more information, see Response Topic in the MQTT Version 5.0 specification. Supports substitution templates .
user_properties (
Union[IResolvable,Sequence[Union[IResolvable,UserPropertyProperty,Dict[str,Any]]],None]) – An array of key-value pairs that you define in the MQTT5 header.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins republish_action_headers_property = iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] )
Attributes
- content_type
A UTF-8 encoded string that describes the content of the publishing message.
For more information, see Content Type in the MQTT Version 5.0 specification.
Supports substitution templates .
- correlation_data
The base64-encoded binary data used by the sender of the request message to identify which request the response message is for.
For more information, see Correlation Data in the MQTT Version 5.0 specification.
Supports substitution templates . .. epigraph:
This binary data must be base64-encoded.
- message_expiry
A user-defined integer value that represents the message expiry interval at the broker.
If the messages haven’t been sent to the subscribers within that interval, the message expires and is removed. The value of
messageExpiryrepresents the number of seconds before it expires. For more information about the limits ofmessageExpiry, see Message broker and protocol limits and quotas in the IoT Core Reference Guide.Supports substitution templates .
- payload_format_indicator
An
Enumstring value that indicates whether the payload is formatted as UTF-8.Valid values are
UNSPECIFIED_BYTESandUTF8_DATA.For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.
Supports substitution templates .
- response_topic
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 to which the receiver should publish as part of the request-response flow. The topic must not contain wildcard characters.
For more information, see Response Topic in the MQTT Version 5.0 specification.
Supports substitution templates .
- user_properties
An array of key-value pairs that you define in the MQTT5 header.
RepublishActionProperty
- class CfnTopicRulePropsMixin.RepublishActionProperty(*, headers=None, qos=None, role_arn=None, topic=None)
Bases:
objectDescribes an action to republish to another topic.
- Parameters:
headers (
Union[IResolvable,RepublishActionHeadersProperty,Dict[str,Any],None]) –MQTT Version 5.0 headers information. For more information, see MQTT in the IoT Core Developer Guide.
qos (
Union[int,float,None]) – The Quality of Service (QoS) level to use when republishing messages. The default value is 0.role_arn (
Optional[str]) – The ARN of the IAM role that grants access.topic (
Optional[str]) – The name of the MQTT topic.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins republish_action_property = iot_mixins.CfnTopicRulePropsMixin.RepublishActionProperty( headers=iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] ), qos=123, role_arn="roleArn", topic="topic" )
Attributes
- headers
MQTT Version 5.0 headers information. For more information, see MQTT in the IoT Core Developer Guide.
- qos
The Quality of Service (QoS) level to use when republishing messages.
The default value is 0.
- role_arn
The ARN of the IAM role that grants access.
- topic
The name of the MQTT topic.
S3ActionProperty
- class CfnTopicRulePropsMixin.S3ActionProperty(*, bucket_name=None, canned_acl=None, key=None, role_arn=None)
Bases:
objectDescribes an action to write data to an Amazon S3 bucket.
- Parameters:
bucket_name (
Optional[str]) – The Amazon S3 bucket.canned_acl (
Optional[str]) – The Amazon S3 canned ACL that controls access to the object identified by the object key. For more information, see S3 canned ACLs .key (
Optional[str]) – The object key. For more information, see Actions, resources, and condition keys for Amazon S3 .role_arn (
Optional[str]) – The ARN of the IAM role that grants access.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins s3_action_property = iot_mixins.CfnTopicRulePropsMixin.S3ActionProperty( bucket_name="bucketName", canned_acl="cannedAcl", key="key", role_arn="roleArn" )
Attributes
- bucket_name
The Amazon S3 bucket.
- canned_acl
The Amazon S3 canned ACL that controls access to the object identified by the object key.
For more information, see S3 canned ACLs .
- key
The object key.
For more information, see Actions, resources, and condition keys for Amazon S3 .
- role_arn
The ARN of the IAM role that grants access.
SnsActionProperty
- class CfnTopicRulePropsMixin.SnsActionProperty(*, message_format=None, role_arn=None, target_arn=None)
Bases:
objectDescribes an action to publish to an Amazon SNS topic.
- Parameters:
message_format (
Optional[str]) – (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. For more information, see Amazon SNS Message and JSON Formats in the Amazon Simple Notification Service Developer Guide .role_arn (
Optional[str]) – The ARN of the IAM role that grants access.target_arn (
Optional[str]) – The ARN of the SNS topic.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins sns_action_property = iot_mixins.CfnTopicRulePropsMixin.SnsActionProperty( message_format="messageFormat", role_arn="roleArn", target_arn="targetArn" )
Attributes
- message_format
(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. For more information, see Amazon SNS Message and JSON Formats in the Amazon Simple Notification Service Developer Guide .
- role_arn
The ARN of the IAM role that grants access.
- target_arn
The ARN of the SNS topic.
SqsActionProperty
- class CfnTopicRulePropsMixin.SqsActionProperty(*, queue_url=None, role_arn=None, use_base64=None)
Bases:
objectDescribes an action to publish data to an Amazon SQS queue.
- Parameters:
queue_url (
Optional[str]) – The URL of the Amazon SQS queue.role_arn (
Optional[str]) – The ARN of the IAM role that grants access.use_base64 (
Union[bool,IResolvable,None]) – Specifies whether to use Base64 encoding.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins sqs_action_property = iot_mixins.CfnTopicRulePropsMixin.SqsActionProperty( queue_url="queueUrl", role_arn="roleArn", use_base64=False )
Attributes
- queue_url
The URL of the Amazon SQS queue.
- role_arn
The ARN of the IAM role that grants access.
- use_base64
Specifies whether to use Base64 encoding.
StepFunctionsActionProperty
- class CfnTopicRulePropsMixin.StepFunctionsActionProperty(*, execution_name_prefix=None, role_arn=None, state_machine_name=None)
Bases:
objectStarts execution of a Step Functions state machine.
- Parameters:
execution_name_prefix (
Optional[str]) – (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.role_arn (
Optional[str]) – The ARN of the role that grants IoT permission to start execution of a state machine (“Action”:”states:StartExecution”).state_machine_name (
Optional[str]) – The name of the Step Functions state machine whose execution will be started.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins step_functions_action_property = iot_mixins.CfnTopicRulePropsMixin.StepFunctionsActionProperty( execution_name_prefix="executionNamePrefix", role_arn="roleArn", state_machine_name="stateMachineName" )
Attributes
- execution_name_prefix
(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.
- role_arn
StartExecution”).
- See:
- Type:
The ARN of the role that grants IoT permission to start execution of a state machine (“Action”
- Type:
“states
- state_machine_name
The name of the Step Functions state machine whose execution will be started.
TimestampProperty
- class CfnTopicRulePropsMixin.TimestampProperty(*, unit=None, value=None)
Bases:
objectDescribes how to interpret an application-defined timestamp value from an MQTT message payload and the precision of that value.
- Parameters:
unit (
Optional[str]) – The precision of the timestamp value that results from the expression described invalue.value (
Optional[str]) – An expression that returns a long epoch time value.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins timestamp_property = iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" )
Attributes
- unit
The precision of the timestamp value that results from the expression described in
value.
- value
An expression that returns a long epoch time value.
TimestreamActionProperty
- class CfnTopicRulePropsMixin.TimestreamActionProperty(*, database_name=None, dimensions=None, role_arn=None, table_name=None, timestamp=None)
Bases:
objectDescribes an action that writes records into an Amazon Timestream table.
- Parameters:
database_name (
Optional[str]) – The name of an Amazon Timestream database that has the table to write records into.dimensions (
Union[IResolvable,Sequence[Union[IResolvable,TimestreamDimensionProperty,Dict[str,Any]]],None]) – Metadata attributes of the time series that are written in each measure record.role_arn (
Optional[str]) – The Amazon Resource Name (ARN) of the role that grants AWS IoT permission to write to the Timestream database table.table_name (
Optional[str]) – The table where the message data will be written.timestamp (
Union[IResolvable,TimestreamTimestampProperty,Dict[str,Any],None]) – The value to use for the entry’s timestamp. If blank, the time that the entry was processed is used.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins timestream_action_property = iot_mixins.CfnTopicRulePropsMixin.TimestreamActionProperty( database_name="databaseName", dimensions=[iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )], role_arn="roleArn", table_name="tableName", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" ) )
Attributes
- database_name
The name of an Amazon Timestream database that has the table to write records into.
- dimensions
Metadata attributes of the time series that are written in each measure record.
- role_arn
The Amazon Resource Name (ARN) of the role that grants AWS IoT permission to write to the Timestream database table.
- table_name
The table where the message data will be written.
- timestamp
The value to use for the entry’s timestamp.
If blank, the time that the entry was processed is used.
TimestreamDimensionProperty
- class CfnTopicRulePropsMixin.TimestreamDimensionProperty(*, name=None, value=None)
Bases:
objectMetadata attributes of the time series that are written in each measure record.
- Parameters:
name (
Optional[str]) – The metadata dimension name. This is the name of the column in the Amazon Timestream database table record.value (
Optional[str]) – The value to write in this column of the database record.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins timestream_dimension_property = iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )
Attributes
- name
The metadata dimension name.
This is the name of the column in the Amazon Timestream database table record.
- value
The value to write in this column of the database record.
TimestreamTimestampProperty
- class CfnTopicRulePropsMixin.TimestreamTimestampProperty(*, unit=None, value=None)
Bases:
objectThe value to use for the entry’s timestamp.
If blank, the time that the entry was processed is used.
- Parameters:
unit (
Optional[str]) – The precision of the timestamp value that results from the expression described invalue.value (
Optional[str]) – An expression that returns a long epoch time value.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins timestream_timestamp_property = iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" )
Attributes
- unit
The precision of the timestamp value that results from the expression described in
value.
- value
An expression that returns a long epoch time value.
TopicRulePayloadProperty
- class CfnTopicRulePropsMixin.TopicRulePayloadProperty(*, actions=None, aws_iot_sql_version=None, description=None, error_action=None, rule_disabled=None, sql=None)
Bases:
objectDescribes a rule.
- Parameters:
actions (
Union[IResolvable,Sequence[Union[IResolvable,ActionProperty,Dict[str,Any]]],None]) – The actions associated with the rule.aws_iot_sql_version (
Optional[str]) – The version of the SQL rules engine to use when evaluating the rule. The default value is 2015-10-08.description (
Optional[str]) – The description of the rule.error_action (
Union[IResolvable,ActionProperty,Dict[str,Any],None]) – The action to take when an error occurs.rule_disabled (
Union[bool,IResolvable,None]) – Specifies whether the rule is disabled.sql (
Optional[str]) – The SQL statement used to query the topic. For more information, see AWS IoT SQL Reference in the AWS IoT Developer Guide .
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins topic_rule_payload_property = iot_mixins.CfnTopicRulePropsMixin.TopicRulePayloadProperty( actions=[iot_mixins.CfnTopicRulePropsMixin.ActionProperty( cloudwatch_alarm=iot_mixins.CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty( alarm_name="alarmName", role_arn="roleArn", state_reason="stateReason", state_value="stateValue" ), cloudwatch_logs=iot_mixins.CfnTopicRulePropsMixin.CloudwatchLogsActionProperty( batch_mode=False, log_group_name="logGroupName", role_arn="roleArn" ), cloudwatch_metric=iot_mixins.CfnTopicRulePropsMixin.CloudwatchMetricActionProperty( metric_name="metricName", metric_namespace="metricNamespace", metric_timestamp="metricTimestamp", metric_unit="metricUnit", metric_value="metricValue", role_arn="roleArn" ), dynamo_db=iot_mixins.CfnTopicRulePropsMixin.DynamoDBActionProperty( hash_key_field="hashKeyField", hash_key_type="hashKeyType", hash_key_value="hashKeyValue", payload_field="payloadField", range_key_field="rangeKeyField", range_key_type="rangeKeyType", range_key_value="rangeKeyValue", role_arn="roleArn", table_name="tableName" ), dynamo_dBv2=iot_mixins.CfnTopicRulePropsMixin.DynamoDBv2ActionProperty( put_item=iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" ), role_arn="roleArn" ), elasticsearch=iot_mixins.CfnTopicRulePropsMixin.ElasticsearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), firehose=iot_mixins.CfnTopicRulePropsMixin.FirehoseActionProperty( batch_mode=False, delivery_stream_name="deliveryStreamName", role_arn="roleArn", separator="separator" ), http=iot_mixins.CfnTopicRulePropsMixin.HttpActionProperty( auth=iot_mixins.CfnTopicRulePropsMixin.HttpAuthorizationProperty( sigv4=iot_mixins.CfnTopicRulePropsMixin.SigV4AuthorizationProperty( role_arn="roleArn", service_name="serviceName", signing_region="signingRegion" ) ), confirmation_url="confirmationUrl", headers=[iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )], url="url" ), iot_analytics=iot_mixins.CfnTopicRulePropsMixin.IotAnalyticsActionProperty( batch_mode=False, channel_name="channelName", role_arn="roleArn" ), iot_events=iot_mixins.CfnTopicRulePropsMixin.IotEventsActionProperty( batch_mode=False, input_name="inputName", message_id="messageId", role_arn="roleArn" ), iot_site_wise=iot_mixins.CfnTopicRulePropsMixin.IotSiteWiseActionProperty( put_asset_property_value_entries=[iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )], role_arn="roleArn" ), kafka=iot_mixins.CfnTopicRulePropsMixin.KafkaActionProperty( client_properties={ "client_properties_key": "clientProperties" }, destination_arn="destinationArn", headers=[iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )], key="key", partition="partition", topic="topic" ), kinesis=iot_mixins.CfnTopicRulePropsMixin.KinesisActionProperty( partition_key="partitionKey", role_arn="roleArn", stream_name="streamName" ), lambda_=iot_mixins.CfnTopicRulePropsMixin.LambdaActionProperty( function_arn="functionArn" ), location=iot_mixins.CfnTopicRulePropsMixin.LocationActionProperty( device_id="deviceId", latitude="latitude", longitude="longitude", role_arn="roleArn", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" ), tracker_name="trackerName" ), open_search=iot_mixins.CfnTopicRulePropsMixin.OpenSearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), republish=iot_mixins.CfnTopicRulePropsMixin.RepublishActionProperty( headers=iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] ), qos=123, role_arn="roleArn", topic="topic" ), s3=iot_mixins.CfnTopicRulePropsMixin.S3ActionProperty( bucket_name="bucketName", canned_acl="cannedAcl", key="key", role_arn="roleArn" ), sns=iot_mixins.CfnTopicRulePropsMixin.SnsActionProperty( message_format="messageFormat", role_arn="roleArn", target_arn="targetArn" ), sqs=iot_mixins.CfnTopicRulePropsMixin.SqsActionProperty( queue_url="queueUrl", role_arn="roleArn", use_base64=False ), step_functions=iot_mixins.CfnTopicRulePropsMixin.StepFunctionsActionProperty( execution_name_prefix="executionNamePrefix", role_arn="roleArn", state_machine_name="stateMachineName" ), timestream=iot_mixins.CfnTopicRulePropsMixin.TimestreamActionProperty( database_name="databaseName", dimensions=[iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )], role_arn="roleArn", table_name="tableName", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" ) ) )], aws_iot_sql_version="awsIotSqlVersion", description="description", error_action=iot_mixins.CfnTopicRulePropsMixin.ActionProperty( cloudwatch_alarm=iot_mixins.CfnTopicRulePropsMixin.CloudwatchAlarmActionProperty( alarm_name="alarmName", role_arn="roleArn", state_reason="stateReason", state_value="stateValue" ), cloudwatch_logs=iot_mixins.CfnTopicRulePropsMixin.CloudwatchLogsActionProperty( batch_mode=False, log_group_name="logGroupName", role_arn="roleArn" ), cloudwatch_metric=iot_mixins.CfnTopicRulePropsMixin.CloudwatchMetricActionProperty( metric_name="metricName", metric_namespace="metricNamespace", metric_timestamp="metricTimestamp", metric_unit="metricUnit", metric_value="metricValue", role_arn="roleArn" ), dynamo_db=iot_mixins.CfnTopicRulePropsMixin.DynamoDBActionProperty( hash_key_field="hashKeyField", hash_key_type="hashKeyType", hash_key_value="hashKeyValue", payload_field="payloadField", range_key_field="rangeKeyField", range_key_type="rangeKeyType", range_key_value="rangeKeyValue", role_arn="roleArn", table_name="tableName" ), dynamo_dBv2=iot_mixins.CfnTopicRulePropsMixin.DynamoDBv2ActionProperty( put_item=iot_mixins.CfnTopicRulePropsMixin.PutItemInputProperty( table_name="tableName" ), role_arn="roleArn" ), elasticsearch=iot_mixins.CfnTopicRulePropsMixin.ElasticsearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), firehose=iot_mixins.CfnTopicRulePropsMixin.FirehoseActionProperty( batch_mode=False, delivery_stream_name="deliveryStreamName", role_arn="roleArn", separator="separator" ), http=iot_mixins.CfnTopicRulePropsMixin.HttpActionProperty( auth=iot_mixins.CfnTopicRulePropsMixin.HttpAuthorizationProperty( sigv4=iot_mixins.CfnTopicRulePropsMixin.SigV4AuthorizationProperty( role_arn="roleArn", service_name="serviceName", signing_region="signingRegion" ) ), confirmation_url="confirmationUrl", headers=[iot_mixins.CfnTopicRulePropsMixin.HttpActionHeaderProperty( key="key", value="value" )], url="url" ), iot_analytics=iot_mixins.CfnTopicRulePropsMixin.IotAnalyticsActionProperty( batch_mode=False, channel_name="channelName", role_arn="roleArn" ), iot_events=iot_mixins.CfnTopicRulePropsMixin.IotEventsActionProperty( batch_mode=False, input_name="inputName", message_id="messageId", role_arn="roleArn" ), iot_site_wise=iot_mixins.CfnTopicRulePropsMixin.IotSiteWiseActionProperty( put_asset_property_value_entries=[iot_mixins.CfnTopicRulePropsMixin.PutAssetPropertyValueEntryProperty( asset_id="assetId", entry_id="entryId", property_alias="propertyAlias", property_id="propertyId", property_values=[iot_mixins.CfnTopicRulePropsMixin.AssetPropertyValueProperty( quality="quality", timestamp=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyTimestampProperty( offset_in_nanos="offsetInNanos", time_in_seconds="timeInSeconds" ), value=iot_mixins.CfnTopicRulePropsMixin.AssetPropertyVariantProperty( boolean_value="booleanValue", double_value="doubleValue", integer_value="integerValue", string_value="stringValue" ) )] )], role_arn="roleArn" ), kafka=iot_mixins.CfnTopicRulePropsMixin.KafkaActionProperty( client_properties={ "client_properties_key": "clientProperties" }, destination_arn="destinationArn", headers=[iot_mixins.CfnTopicRulePropsMixin.KafkaActionHeaderProperty( key="key", value="value" )], key="key", partition="partition", topic="topic" ), kinesis=iot_mixins.CfnTopicRulePropsMixin.KinesisActionProperty( partition_key="partitionKey", role_arn="roleArn", stream_name="streamName" ), lambda_=iot_mixins.CfnTopicRulePropsMixin.LambdaActionProperty( function_arn="functionArn" ), location=iot_mixins.CfnTopicRulePropsMixin.LocationActionProperty( device_id="deviceId", latitude="latitude", longitude="longitude", role_arn="roleArn", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestampProperty( unit="unit", value="value" ), tracker_name="trackerName" ), open_search=iot_mixins.CfnTopicRulePropsMixin.OpenSearchActionProperty( endpoint="endpoint", id="id", index="index", role_arn="roleArn", type="type" ), republish=iot_mixins.CfnTopicRulePropsMixin.RepublishActionProperty( headers=iot_mixins.CfnTopicRulePropsMixin.RepublishActionHeadersProperty( content_type="contentType", correlation_data="correlationData", message_expiry="messageExpiry", payload_format_indicator="payloadFormatIndicator", response_topic="responseTopic", user_properties=[iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )] ), qos=123, role_arn="roleArn", topic="topic" ), s3=iot_mixins.CfnTopicRulePropsMixin.S3ActionProperty( bucket_name="bucketName", canned_acl="cannedAcl", key="key", role_arn="roleArn" ), sns=iot_mixins.CfnTopicRulePropsMixin.SnsActionProperty( message_format="messageFormat", role_arn="roleArn", target_arn="targetArn" ), sqs=iot_mixins.CfnTopicRulePropsMixin.SqsActionProperty( queue_url="queueUrl", role_arn="roleArn", use_base64=False ), step_functions=iot_mixins.CfnTopicRulePropsMixin.StepFunctionsActionProperty( execution_name_prefix="executionNamePrefix", role_arn="roleArn", state_machine_name="stateMachineName" ), timestream=iot_mixins.CfnTopicRulePropsMixin.TimestreamActionProperty( database_name="databaseName", dimensions=[iot_mixins.CfnTopicRulePropsMixin.TimestreamDimensionProperty( name="name", value="value" )], role_arn="roleArn", table_name="tableName", timestamp=iot_mixins.CfnTopicRulePropsMixin.TimestreamTimestampProperty( unit="unit", value="value" ) ) ), rule_disabled=False, sql="sql" )
Attributes
- actions
The actions associated with the rule.
- aws_iot_sql_version
The version of the SQL rules engine to use when evaluating the rule.
The default value is 2015-10-08.
- description
The description of the rule.
- error_action
The action to take when an error occurs.
- rule_disabled
Specifies whether the rule is disabled.
- sql
The SQL statement used to query the topic.
For more information, see AWS IoT SQL Reference in the AWS IoT Developer Guide .
UserPropertyProperty
- class CfnTopicRulePropsMixin.UserPropertyProperty(*, key=None, value=None)
Bases:
objectA key-value pair that you define in the header.
- Parameters:
key (
Optional[str]) – A key to be specified inUserProperty.value (
Optional[str]) – A value to be specified inUserProperty.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_iot import mixins as iot_mixins user_property_property = iot_mixins.CfnTopicRulePropsMixin.UserPropertyProperty( key="key", value="value" )
Attributes
- key
A key to be specified in
UserProperty.
- value
A value to be specified in
UserProperty.