Skip to content
v2.277.0

DialogStateProperty Struct ​

The current state of the conversation with the user.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_lex as lex } from 'aws-cdk-lib';

declare const slotValueOverrideProperty_: lex.CfnBot.SlotValueOverrideProperty;
const dialogStateProperty: lex.CfnBot.DialogStateProperty = {
  dialogAction: {
    type: 'type',

    // the properties below are optional
    slotToElicit: 'slotToElicit',
    suppressNextMessage: false,
  },
  intent: {
    name: 'name',
    slots: [{
      slotName: 'slotName',
      slotValueOverride: {
        shape: 'shape',
        value: {
          interpretedValue: 'interpretedValue',
        },
        values: [slotValueOverrideProperty_],
      },
    }],
  },
  sessionAttributes: [{
    key: 'key',

    // the properties below are optional
    value: 'value',
  }],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_lex as lex

# slot_value_override_property_: lex.CfnBot.SlotValueOverrideProperty

dialog_state_property = lex.CfnBot.DialogStateProperty(
    dialog_action=lex.CfnBot.DialogActionProperty(
        type="type",

        # the properties below are optional
        slot_to_elicit="slotToElicit",
        suppress_next_message=False
    ),
    intent=lex.CfnBot.IntentOverrideProperty(
        name="name",
        slots=[lex.CfnBot.SlotValueOverrideMapProperty(
            slot_name="slotName",
            slot_value_override=lex.CfnBot.SlotValueOverrideProperty(
                shape="shape",
                value=lex.CfnBot.SlotValueProperty(
                    interpreted_value="interpretedValue"
                ),
                values=[slot_value_override_property_]
            )
        )]
    ),
    session_attributes=[lex.CfnBot.SessionAttributeProperty(
        key="key",

        # the properties below are optional
        value="value"
    )]
)
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.lex.*;

SlotValueOverrideProperty slotValueOverrideProperty_;

DialogStateProperty dialogStateProperty = DialogStateProperty.builder()
        .dialogAction(DialogActionProperty.builder()
                .type("type")

                // the properties below are optional
                .slotToElicit("slotToElicit")
                .suppressNextMessage(false)
                .build())
        .intent(IntentOverrideProperty.builder()
                .name("name")
                .slots(List.of(SlotValueOverrideMapProperty.builder()
                        .slotName("slotName")
                        .slotValueOverride(SlotValueOverrideProperty.builder()
                                .shape("shape")
                                .value(SlotValueProperty.builder()
                                        .interpretedValue("interpretedValue")
                                        .build())
                                .values(List.of(slotValueOverrideProperty_))
                                .build())
                        .build()))
                .build())
        .sessionAttributes(List.of(SessionAttributeProperty.builder()
                .key("key")

                // the properties below are optional
                .value("value")
                .build()))
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Lex;

SlotValueOverrideProperty slotValueOverrideProperty_;

var dialogStateProperty = new DialogStateProperty {
    DialogAction = new DialogActionProperty {
        Type = "type",

        // the properties below are optional
        SlotToElicit = "slotToElicit",
        SuppressNextMessage = false
    },
    Intent = new IntentOverrideProperty {
        Name = "name",
        Slots = new [] { new SlotValueOverrideMapProperty {
            SlotName = "slotName",
            SlotValueOverride = new SlotValueOverrideProperty {
                Shape = "shape",
                Value = new SlotValueProperty {
                    InterpretedValue = "interpretedValue"
                },
                Values = new [] { slotValueOverrideProperty_ }
            }
        } }
    },
    SessionAttributes = new [] { new SessionAttributeProperty {
        Key = "key",

        // the properties below are optional
        Value = "value"
    } }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

var slotValueOverrideProperty_ SlotValueOverrideProperty

dialogStateProperty := &DialogStateProperty{
	DialogAction: &DialogActionProperty{
		Type: jsii.String("type"),

		// the properties below are optional
		SlotToElicit: jsii.String("slotToElicit"),
		SuppressNextMessage: jsii.Boolean(false),
	},
	Intent: &IntentOverrideProperty{
		Name: jsii.String("name"),
		Slots: []interface{}{
			&SlotValueOverrideMapProperty{
				SlotName: jsii.String("slotName"),
				SlotValueOverride: &SlotValueOverrideProperty{
					Shape: jsii.String("shape"),
					Value: &SlotValueProperty{
						InterpretedValue: jsii.String("interpretedValue"),
					},
					Values: []interface{}{
						slotValueOverrideProperty_,
					},
				},
			},
		},
	},
	SessionAttributes: []interface{}{
		&SessionAttributeProperty{
			Key: jsii.String("key"),

			// the properties below are optional
			Value: jsii.String("value"),
		},
	},
}

Properties ​

dialogActionoptionalIResolvable | CfnBot.DialogActionPropertydialog_actionoptionaltyping.Union[IResolvable, DialogActionProperty]dialogActionoptionalIResolvableDialogActionoptionalIResolvableDialogActionoptionalinterface{}#
Defines the action that the bot executes at runtime when the conversation reaches this step.
intentoptionalIResolvable | CfnBot.IntentOverridePropertyintentoptionaltyping.Union[IResolvable, IntentOverrideProperty]intentoptionalIResolvableIntentoptionalIResolvableIntentoptionalinterface{}#
Override settings to configure the intent state.
sessionAttributesoptionalIResolvable | IResolvable | CfnBot.SessionAttributeProperty[]session_attributesoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, SessionAttributeProperty]]]sessionAttributesoptionalIResolvableSessionAttributesoptionalIResolvableSessionAttributesoptionalinterface{}#
Map of key/value pairs representing session-specific context information.

It contains application information passed between Amazon Lex and a client application.