Skip to content
v2.278.0

Experimental

@aws-cdk/aws-iotevents-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

ActionConfig Struct ​

Properties for a AWS IoT Events action.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as iotevents_alpha from '@aws-cdk/aws-iotevents-alpha';
const actionConfig: iotevents_alpha.ActionConfig = {
  configuration: {
    clearTimer: {
      timerName: 'timerName',
    },
    dynamoDb: {
      hashKeyField: 'hashKeyField',
      hashKeyValue: 'hashKeyValue',
      tableName: 'tableName',

      // the properties below are optional
      hashKeyType: 'hashKeyType',
      operation: 'operation',
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
      payloadField: 'payloadField',
      rangeKeyField: 'rangeKeyField',
      rangeKeyType: 'rangeKeyType',
      rangeKeyValue: 'rangeKeyValue',
    },
    dynamoDBv2: {
      tableName: 'tableName',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
    },
    firehose: {
      deliveryStreamName: 'deliveryStreamName',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
      separator: 'separator',
    },
    iotEvents: {
      inputName: 'inputName',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
    },
    iotSiteWise: {
      propertyValue: {
        value: {
          booleanValue: 'booleanValue',
          doubleValue: 'doubleValue',
          integerValue: 'integerValue',
          stringValue: 'stringValue',
        },

        // the properties below are optional
        quality: 'quality',
        timestamp: {
          timeInSeconds: 'timeInSeconds',

          // the properties below are optional
          offsetInNanos: 'offsetInNanos',
        },
      },

      // the properties below are optional
      assetId: 'assetId',
      entryId: 'entryId',
      propertyAlias: 'propertyAlias',
      propertyId: 'propertyId',
    },
    iotTopicPublish: {
      mqttTopic: 'mqttTopic',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
    },
    lambda: {
      functionArn: 'functionArn',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
    },
    resetTimer: {
      timerName: 'timerName',
    },
    setTimer: {
      timerName: 'timerName',

      // the properties below are optional
      durationExpression: 'durationExpression',
      seconds: 123,
    },
    setVariable: {
      value: 'value',
      variableName: 'variableName',
    },
    sns: {
      targetArn: 'targetArn',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
    },
    sqs: {
      queueUrl: 'queueUrl',

      // the properties below are optional
      payload: {
        contentExpression: 'contentExpression',
        type: 'type',
      },
      useBase64: false,
    },
  },
};
python
from aws_cdk.aws_iotevents.ActionProperty import ActionProperty
from aws_cdk.aws_iotevents.ClearTimerProperty import ClearTimerProperty
from aws_cdk.aws_iotevents.DynamoDBProperty import DynamoDBProperty
from aws_cdk.aws_iotevents.PayloadProperty import PayloadProperty, PayloadProperty, PayloadProperty, PayloadProperty, PayloadProperty, PayloadProperty, PayloadProperty, PayloadProperty
from aws_cdk.aws_iotevents.DynamoDBv2Property import DynamoDBv2Property
from aws_cdk.aws_iotevents.FirehoseProperty import FirehoseProperty
from aws_cdk.aws_iotevents.IotEventsProperty import IotEventsProperty
from aws_cdk.aws_iotevents.IotSiteWiseProperty import IotSiteWiseProperty
from aws_cdk.aws_iotevents.AssetPropertyValueProperty import AssetPropertyValueProperty
from aws_cdk.aws_iotevents.AssetPropertyVariantProperty import AssetPropertyVariantProperty
from aws_cdk.aws_iotevents.AssetPropertyTimestampProperty import AssetPropertyTimestampProperty
from aws_cdk.aws_iotevents.IotTopicPublishProperty import IotTopicPublishProperty
from aws_cdk.aws_iotevents.LambdaProperty import LambdaProperty
from aws_cdk.aws_iotevents.ResetTimerProperty import ResetTimerProperty
from aws_cdk.aws_iotevents.SetTimerProperty import SetTimerProperty
from aws_cdk.aws_iotevents.SetVariableProperty import SetVariableProperty
from aws_cdk.aws_iotevents.SnsProperty import SnsProperty
from aws_cdk.aws_iotevents.SqsProperty import SqsProperty
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.aws_iotevents_alpha as iotevents_alpha

action_config = iotevents_alpha.ActionConfig(
    configuration=ActionProperty(
        clear_timer=ClearTimerProperty(
            timer_name="timerName"
        ),
        dynamo_db=DynamoDBProperty(
            hash_key_field="hashKeyField",
            hash_key_value="hashKeyValue",
            table_name="tableName",

            # the properties below are optional
            hash_key_type="hashKeyType",
            operation="operation",
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            ),
            payload_field="payloadField",
            range_key_field="rangeKeyField",
            range_key_type="rangeKeyType",
            range_key_value="rangeKeyValue"
        ),
        dynamo_d_bv2=DynamoDBv2Property(
            table_name="tableName",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            )
        ),
        firehose=FirehoseProperty(
            delivery_stream_name="deliveryStreamName",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            ),
            separator="separator"
        ),
        iot_events=IotEventsProperty(
            input_name="inputName",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            )
        ),
        iot_site_wise=IotSiteWiseProperty(
            property_value=AssetPropertyValueProperty(
                value=AssetPropertyVariantProperty(
                    boolean_value="booleanValue",
                    double_value="doubleValue",
                    integer_value="integerValue",
                    string_value="stringValue"
                ),

                # the properties below are optional
                quality="quality",
                timestamp=AssetPropertyTimestampProperty(
                    time_in_seconds="timeInSeconds",

                    # the properties below are optional
                    offset_in_nanos="offsetInNanos"
                )
            ),

            # the properties below are optional
            asset_id="assetId",
            entry_id="entryId",
            property_alias="propertyAlias",
            property_id="propertyId"
        ),
        iot_topic_publish=IotTopicPublishProperty(
            mqtt_topic="mqttTopic",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            )
        ),
        lambda_=LambdaProperty(
            function_arn="functionArn",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            )
        ),
        reset_timer=ResetTimerProperty(
            timer_name="timerName"
        ),
        set_timer=SetTimerProperty(
            timer_name="timerName",

            # the properties below are optional
            duration_expression="durationExpression",
            seconds=123
        ),
        set_variable=SetVariableProperty(
            value="value",
            variable_name="variableName"
        ),
        sns=SnsProperty(
            target_arn="targetArn",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            )
        ),
        sqs=SqsProperty(
            queue_url="queueUrl",

            # the properties below are optional
            payload=PayloadProperty(
                content_expression="contentExpression",
                type="type"
            ),
            use_base64=False
        )
    )
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.iotevents.alpha.*;

ActionConfig actionConfig = ActionConfig.builder()
        .configuration(ActionProperty.builder()
                .clearTimer(ClearTimerProperty.builder()
                        .timerName("timerName")
                        .build())
                .dynamoDb(DynamoDBProperty.builder()
                        .hashKeyField("hashKeyField")
                        .hashKeyValue("hashKeyValue")
                        .tableName("tableName")

                        // the properties below are optional
                        .hashKeyType("hashKeyType")
                        .operation("operation")
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .payloadField("payloadField")
                        .rangeKeyField("rangeKeyField")
                        .rangeKeyType("rangeKeyType")
                        .rangeKeyValue("rangeKeyValue")
                        .build())
                .dynamoDBv2(DynamoDBv2Property.builder()
                        .tableName("tableName")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .build())
                .firehose(FirehoseProperty.builder()
                        .deliveryStreamName("deliveryStreamName")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .separator("separator")
                        .build())
                .iotEvents(IotEventsProperty.builder()
                        .inputName("inputName")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .build())
                .iotSiteWise(IotSiteWiseProperty.builder()
                        .propertyValue(AssetPropertyValueProperty.builder()
                                .value(AssetPropertyVariantProperty.builder()
                                        .booleanValue("booleanValue")
                                        .doubleValue("doubleValue")
                                        .integerValue("integerValue")
                                        .stringValue("stringValue")
                                        .build())

                                // the properties below are optional
                                .quality("quality")
                                .timestamp(AssetPropertyTimestampProperty.builder()
                                        .timeInSeconds("timeInSeconds")

                                        // the properties below are optional
                                        .offsetInNanos("offsetInNanos")
                                        .build())
                                .build())

                        // the properties below are optional
                        .assetId("assetId")
                        .entryId("entryId")
                        .propertyAlias("propertyAlias")
                        .propertyId("propertyId")
                        .build())
                .iotTopicPublish(IotTopicPublishProperty.builder()
                        .mqttTopic("mqttTopic")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .build())
                .lambda(LambdaProperty.builder()
                        .functionArn("functionArn")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .build())
                .resetTimer(ResetTimerProperty.builder()
                        .timerName("timerName")
                        .build())
                .setTimer(SetTimerProperty.builder()
                        .timerName("timerName")

                        // the properties below are optional
                        .durationExpression("durationExpression")
                        .seconds(123)
                        .build())
                .setVariable(SetVariableProperty.builder()
                        .value("value")
                        .variableName("variableName")
                        .build())
                .sns(SnsProperty.builder()
                        .targetArn("targetArn")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .build())
                .sqs(SqsProperty.builder()
                        .queueUrl("queueUrl")

                        // the properties below are optional
                        .payload(PayloadProperty.builder()
                                .contentExpression("contentExpression")
                                .type("type")
                                .build())
                        .useBase64(false)
                        .build())
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.IoTEvents.Alpha
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.IoTEvents.Alpha;

var actionConfig = new ActionConfig {
    Configuration = new ActionProperty {
        ClearTimer = new ClearTimerProperty {
            TimerName = "timerName"
        },
        DynamoDb = new DynamoDBProperty {
            HashKeyField = "hashKeyField",
            HashKeyValue = "hashKeyValue",
            TableName = "tableName",

            // the properties below are optional
            HashKeyType = "hashKeyType",
            Operation = "operation",
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            },
            PayloadField = "payloadField",
            RangeKeyField = "rangeKeyField",
            RangeKeyType = "rangeKeyType",
            RangeKeyValue = "rangeKeyValue"
        },
        DynamoDBv2 = new DynamoDBv2Property {
            TableName = "tableName",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            }
        },
        Firehose = new FirehoseProperty {
            DeliveryStreamName = "deliveryStreamName",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            },
            Separator = "separator"
        },
        IotEvents = new IotEventsProperty {
            InputName = "inputName",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            }
        },
        IotSiteWise = new IotSiteWiseProperty {
            PropertyValue = new AssetPropertyValueProperty {
                Value = new AssetPropertyVariantProperty {
                    BooleanValue = "booleanValue",
                    DoubleValue = "doubleValue",
                    IntegerValue = "integerValue",
                    StringValue = "stringValue"
                },

                // the properties below are optional
                Quality = "quality",
                Timestamp = new AssetPropertyTimestampProperty {
                    TimeInSeconds = "timeInSeconds",

                    // the properties below are optional
                    OffsetInNanos = "offsetInNanos"
                }
            },

            // the properties below are optional
            AssetId = "assetId",
            EntryId = "entryId",
            PropertyAlias = "propertyAlias",
            PropertyId = "propertyId"
        },
        IotTopicPublish = new IotTopicPublishProperty {
            MqttTopic = "mqttTopic",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            }
        },
        Lambda = new LambdaProperty {
            FunctionArn = "functionArn",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            }
        },
        ResetTimer = new ResetTimerProperty {
            TimerName = "timerName"
        },
        SetTimer = new SetTimerProperty {
            TimerName = "timerName",

            // the properties below are optional
            DurationExpression = "durationExpression",
            Seconds = 123
        },
        SetVariable = new SetVariableProperty {
            Value = "value",
            VariableName = "variableName"
        },
        Sns = new SnsProperty {
            TargetArn = "targetArn",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            }
        },
        Sqs = new SqsProperty {
            QueueUrl = "queueUrl",

            // the properties below are optional
            Payload = new PayloadProperty {
                ContentExpression = "contentExpression",
                Type = "type"
            },
            UseBase64 = false
        }
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdkioteventsalpha/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import iotevents_alpha "github.com/aws/aws-cdk-go/awscdkioteventsalpha"

actionConfig := &ActionConfig{
	Configuration: &ActionProperty{
		ClearTimer: &ClearTimerProperty{
			TimerName: jsii.String("timerName"),
		},
		DynamoDb: &DynamoDBProperty{
			HashKeyField: jsii.String("hashKeyField"),
			HashKeyValue: jsii.String("hashKeyValue"),
			TableName: jsii.String("tableName"),

			// the properties below are optional
			HashKeyType: jsii.String("hashKeyType"),
			Operation: jsii.String("operation"),
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
			PayloadField: jsii.String("payloadField"),
			RangeKeyField: jsii.String("rangeKeyField"),
			RangeKeyType: jsii.String("rangeKeyType"),
			RangeKeyValue: jsii.String("rangeKeyValue"),
		},
		DynamoDBv2: &DynamoDBv2Property{
			TableName: jsii.String("tableName"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
		},
		Firehose: &FirehoseProperty{
			DeliveryStreamName: jsii.String("deliveryStreamName"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
			Separator: jsii.String("separator"),
		},
		IotEvents: &IotEventsProperty{
			InputName: jsii.String("inputName"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
		},
		IotSiteWise: &IotSiteWiseProperty{
			PropertyValue: &AssetPropertyValueProperty{
				Value: &AssetPropertyVariantProperty{
					BooleanValue: jsii.String("booleanValue"),
					DoubleValue: jsii.String("doubleValue"),
					IntegerValue: jsii.String("integerValue"),
					StringValue: jsii.String("stringValue"),
				},

				// the properties below are optional
				Quality: jsii.String("quality"),
				Timestamp: &AssetPropertyTimestampProperty{
					TimeInSeconds: jsii.String("timeInSeconds"),

					// the properties below are optional
					OffsetInNanos: jsii.String("offsetInNanos"),
				},
			},

			// the properties below are optional
			AssetId: jsii.String("assetId"),
			EntryId: jsii.String("entryId"),
			PropertyAlias: jsii.String("propertyAlias"),
			PropertyId: jsii.String("propertyId"),
		},
		IotTopicPublish: &IotTopicPublishProperty{
			MqttTopic: jsii.String("mqttTopic"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
		},
		Lambda: &LambdaProperty{
			FunctionArn: jsii.String("functionArn"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
		},
		ResetTimer: &ResetTimerProperty{
			TimerName: jsii.String("timerName"),
		},
		SetTimer: &SetTimerProperty{
			TimerName: jsii.String("timerName"),

			// the properties below are optional
			DurationExpression: jsii.String("durationExpression"),
			Seconds: jsii.Number(123),
		},
		SetVariable: &SetVariableProperty{
			Value: jsii.String("value"),
			VariableName: jsii.String("variableName"),
		},
		Sns: &SnsProperty{
			TargetArn: jsii.String("targetArn"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
		},
		Sqs: &SqsProperty{
			QueueUrl: jsii.String("queueUrl"),

			// the properties below are optional
			Payload: &PayloadProperty{
				ContentExpression: jsii.String("contentExpression"),
				Type: jsii.String("type"),
			},
			UseBase64: jsii.Boolean(false),
		},
	},
}

Properties ​

configurationCfnDetectorModel.ActionPropertyconfigurationActionPropertyconfigurationActionPropertyConfigurationActionPropertyConfigurationActionProperty required #
The configuration for this action.