CfnBotAliasPropsMixin
- class aws_cdk.mixins_preview.aws_lex.mixins.CfnBotAliasPropsMixin(props, *, strategy=None)
Bases:
MixinAmazon Lex V2 is the only supported version in CloudFormation .
Specifies an alias for the specified version of a bot. Use an alias to enable you to change the version of a bot without updating applications that use the bot.
For example, you can specify an alias called “PROD” that your applications use to call the Amazon Lex bot.
- see:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lex-botalias.html
- cloudformationResource:
AWS::Lex::BotAlias
- 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_lex import mixins as lex_mixins # sentiment_analysis_settings: Any cfn_bot_alias_props_mixin = lex_mixins.CfnBotAliasPropsMixin(lex_mixins.CfnBotAliasMixinProps( bot_alias_locale_settings=[lex_mixins.CfnBotAliasPropsMixin.BotAliasLocaleSettingsItemProperty( bot_alias_locale_setting=lex_mixins.CfnBotAliasPropsMixin.BotAliasLocaleSettingsProperty( code_hook_specification=lex_mixins.CfnBotAliasPropsMixin.CodeHookSpecificationProperty( lambda_code_hook=lex_mixins.CfnBotAliasPropsMixin.LambdaCodeHookProperty( code_hook_interface_version="codeHookInterfaceVersion", lambda_arn="lambdaArn" ) ), enabled=False ), locale_id="localeId" )], bot_alias_name="botAliasName", bot_alias_tags=[CfnTag( key="key", value="value" )], bot_id="botId", bot_version="botVersion", conversation_log_settings=lex_mixins.CfnBotAliasPropsMixin.ConversationLogSettingsProperty( audio_log_settings=[lex_mixins.CfnBotAliasPropsMixin.AudioLogSettingProperty( destination=lex_mixins.CfnBotAliasPropsMixin.AudioLogDestinationProperty( s3_bucket=lex_mixins.CfnBotAliasPropsMixin.S3BucketLogDestinationProperty( kms_key_arn="kmsKeyArn", log_prefix="logPrefix", s3_bucket_arn="s3BucketArn" ) ), enabled=False )], text_log_settings=[lex_mixins.CfnBotAliasPropsMixin.TextLogSettingProperty( destination=lex_mixins.CfnBotAliasPropsMixin.TextLogDestinationProperty( cloud_watch=lex_mixins.CfnBotAliasPropsMixin.CloudWatchLogGroupLogDestinationProperty( cloud_watch_log_group_arn="cloudWatchLogGroupArn", log_prefix="logPrefix" ) ), enabled=False )] ), description="description", sentiment_analysis_settings=sentiment_analysis_settings ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::Lex::BotAlias.- Parameters:
props (
Union[CfnBotAliasMixinProps,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 = ['botAliasLocaleSettings', 'botAliasName', 'botAliasTags', 'botId', 'botVersion', 'conversationLogSettings', 'description', 'sentimentAnalysisSettings']
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
AudioLogDestinationProperty
- class CfnBotAliasPropsMixin.AudioLogDestinationProperty(*, s3_bucket=None)
Bases:
objectSpecifies the S3 bucket location where audio logs are stored.
- Parameters:
s3_bucket (
Union[IResolvable,S3BucketLogDestinationProperty,Dict[str,Any],None]) – The S3 bucket location where audio logs are stored.- 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_lex import mixins as lex_mixins audio_log_destination_property = lex_mixins.CfnBotAliasPropsMixin.AudioLogDestinationProperty( s3_bucket=lex_mixins.CfnBotAliasPropsMixin.S3BucketLogDestinationProperty( kms_key_arn="kmsKeyArn", log_prefix="logPrefix", s3_bucket_arn="s3BucketArn" ) )
Attributes
- s3_bucket
The S3 bucket location where audio logs are stored.
AudioLogSettingProperty
- class CfnBotAliasPropsMixin.AudioLogSettingProperty(*, destination=None, enabled=None)
Bases:
objectSettings for logging audio of conversations between Amazon Lex and a user.
You specify whether to log audio and the Amazon S3 bucket where the audio file is stored.
- Parameters:
destination (
Union[IResolvable,AudioLogDestinationProperty,Dict[str,Any],None]) – The location of audio log files collected when conversation logging is enabled for a bot.enabled (
Union[bool,IResolvable,None]) – Determines whether audio logging in enabled for the bot.
- 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_lex import mixins as lex_mixins audio_log_setting_property = lex_mixins.CfnBotAliasPropsMixin.AudioLogSettingProperty( destination=lex_mixins.CfnBotAliasPropsMixin.AudioLogDestinationProperty( s3_bucket=lex_mixins.CfnBotAliasPropsMixin.S3BucketLogDestinationProperty( kms_key_arn="kmsKeyArn", log_prefix="logPrefix", s3_bucket_arn="s3BucketArn" ) ), enabled=False )
Attributes
- destination
The location of audio log files collected when conversation logging is enabled for a bot.
- enabled
Determines whether audio logging in enabled for the bot.
BotAliasLocaleSettingsItemProperty
- class CfnBotAliasPropsMixin.BotAliasLocaleSettingsItemProperty(*, bot_alias_locale_setting=None, locale_id=None)
Bases:
objectSpecifies settings that are unique to a locale.
For example, you can use different Lambda function depending on the bot’s locale.
- Parameters:
bot_alias_locale_setting (
Union[IResolvable,BotAliasLocaleSettingsProperty,Dict[str,Any],None]) – Specifies settings that are unique to a locale.locale_id (
Optional[str]) – The unique identifier of the locale.
- 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_lex import mixins as lex_mixins bot_alias_locale_settings_item_property = lex_mixins.CfnBotAliasPropsMixin.BotAliasLocaleSettingsItemProperty( bot_alias_locale_setting=lex_mixins.CfnBotAliasPropsMixin.BotAliasLocaleSettingsProperty( code_hook_specification=lex_mixins.CfnBotAliasPropsMixin.CodeHookSpecificationProperty( lambda_code_hook=lex_mixins.CfnBotAliasPropsMixin.LambdaCodeHookProperty( code_hook_interface_version="codeHookInterfaceVersion", lambda_arn="lambdaArn" ) ), enabled=False ), locale_id="localeId" )
Attributes
- bot_alias_locale_setting
Specifies settings that are unique to a locale.
- locale_id
The unique identifier of the locale.
BotAliasLocaleSettingsProperty
- class CfnBotAliasPropsMixin.BotAliasLocaleSettingsProperty(*, code_hook_specification=None, enabled=None)
Bases:
objectSpecifies settings that are unique to a locale.
For example, you can use different Lambda function depending on the bot’s locale.
- Parameters:
code_hook_specification (
Union[IResolvable,CodeHookSpecificationProperty,Dict[str,Any],None]) – Specifies the Lambda function that should be used in the locale.enabled (
Union[bool,IResolvable,None]) – Determines whether the locale is enabled for the bot. If the value isfalse, the locale isn’t available for use.
- 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_lex import mixins as lex_mixins bot_alias_locale_settings_property = lex_mixins.CfnBotAliasPropsMixin.BotAliasLocaleSettingsProperty( code_hook_specification=lex_mixins.CfnBotAliasPropsMixin.CodeHookSpecificationProperty( lambda_code_hook=lex_mixins.CfnBotAliasPropsMixin.LambdaCodeHookProperty( code_hook_interface_version="codeHookInterfaceVersion", lambda_arn="lambdaArn" ) ), enabled=False )
Attributes
- code_hook_specification
Specifies the Lambda function that should be used in the locale.
- enabled
Determines whether the locale is enabled for the bot.
If the value is
false, the locale isn’t available for use.
CloudWatchLogGroupLogDestinationProperty
- class CfnBotAliasPropsMixin.CloudWatchLogGroupLogDestinationProperty(*, cloud_watch_log_group_arn=None, log_prefix=None)
Bases:
objectThe Amazon CloudWatch Logs log group where the text and metadata logs are delivered.
The log group must exist before you enable logging.
- Parameters:
cloud_watch_log_group_arn (
Optional[str]) – The Amazon Resource Name (ARN) of the log group where text and metadata logs are delivered.log_prefix (
Optional[str]) – The prefix of the log stream name within the log group that you specified.
- 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_lex import mixins as lex_mixins cloud_watch_log_group_log_destination_property = lex_mixins.CfnBotAliasPropsMixin.CloudWatchLogGroupLogDestinationProperty( cloud_watch_log_group_arn="cloudWatchLogGroupArn", log_prefix="logPrefix" )
Attributes
- cloud_watch_log_group_arn
The Amazon Resource Name (ARN) of the log group where text and metadata logs are delivered.
- log_prefix
The prefix of the log stream name within the log group that you specified.
CodeHookSpecificationProperty
- class CfnBotAliasPropsMixin.CodeHookSpecificationProperty(*, lambda_code_hook=None)
Bases:
objectContains information about code hooks that Amazon Lex calls during a conversation.
- Parameters:
lambda_code_hook (
Union[IResolvable,LambdaCodeHookProperty,Dict[str,Any],None]) – Specifies a Lambda function that verifies requests to a bot or fulfills the user’s request to a bot.- 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_lex import mixins as lex_mixins code_hook_specification_property = lex_mixins.CfnBotAliasPropsMixin.CodeHookSpecificationProperty( lambda_code_hook=lex_mixins.CfnBotAliasPropsMixin.LambdaCodeHookProperty( code_hook_interface_version="codeHookInterfaceVersion", lambda_arn="lambdaArn" ) )
Attributes
- lambda_code_hook
Specifies a Lambda function that verifies requests to a bot or fulfills the user’s request to a bot.
ConversationLogSettingsProperty
- class CfnBotAliasPropsMixin.ConversationLogSettingsProperty(*, audio_log_settings=None, text_log_settings=None)
Bases:
objectConfigures conversation logging that saves audio, text, and metadata for the conversations with your users.
- Parameters:
audio_log_settings (
Union[IResolvable,Sequence[Union[IResolvable,AudioLogSettingProperty,Dict[str,Any]]],None]) – The Amazon S3 settings for logging audio to an S3 bucket.text_log_settings (
Union[IResolvable,Sequence[Union[IResolvable,TextLogSettingProperty,Dict[str,Any]]],None]) – The Amazon CloudWatch Logs settings for logging text and metadata.
- 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_lex import mixins as lex_mixins conversation_log_settings_property = lex_mixins.CfnBotAliasPropsMixin.ConversationLogSettingsProperty( audio_log_settings=[lex_mixins.CfnBotAliasPropsMixin.AudioLogSettingProperty( destination=lex_mixins.CfnBotAliasPropsMixin.AudioLogDestinationProperty( s3_bucket=lex_mixins.CfnBotAliasPropsMixin.S3BucketLogDestinationProperty( kms_key_arn="kmsKeyArn", log_prefix="logPrefix", s3_bucket_arn="s3BucketArn" ) ), enabled=False )], text_log_settings=[lex_mixins.CfnBotAliasPropsMixin.TextLogSettingProperty( destination=lex_mixins.CfnBotAliasPropsMixin.TextLogDestinationProperty( cloud_watch=lex_mixins.CfnBotAliasPropsMixin.CloudWatchLogGroupLogDestinationProperty( cloud_watch_log_group_arn="cloudWatchLogGroupArn", log_prefix="logPrefix" ) ), enabled=False )] )
Attributes
- audio_log_settings
The Amazon S3 settings for logging audio to an S3 bucket.
- text_log_settings
The Amazon CloudWatch Logs settings for logging text and metadata.
LambdaCodeHookProperty
- class CfnBotAliasPropsMixin.LambdaCodeHookProperty(*, code_hook_interface_version=None, lambda_arn=None)
Bases:
objectSpecifies a Lambda function that verifies requests to a bot or fulfills the user’s request to a bot.
- Parameters:
code_hook_interface_version (
Optional[str]) – The version of the request-response that you want Amazon Lex to use to invoke your Lambda function.lambda_arn (
Optional[str]) – The Amazon Resource Name (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_lex import mixins as lex_mixins lambda_code_hook_property = lex_mixins.CfnBotAliasPropsMixin.LambdaCodeHookProperty( code_hook_interface_version="codeHookInterfaceVersion", lambda_arn="lambdaArn" )
Attributes
- code_hook_interface_version
The version of the request-response that you want Amazon Lex to use to invoke your Lambda function.
- lambda_arn
The Amazon Resource Name (ARN) of the Lambda function.
S3BucketLogDestinationProperty
- class CfnBotAliasPropsMixin.S3BucketLogDestinationProperty(*, kms_key_arn=None, log_prefix=None, s3_bucket_arn=None)
Bases:
objectSpecifies an Amazon S3 bucket for logging audio conversations.
- Parameters:
kms_key_arn (
Optional[str]) – The Amazon Resource Name (ARN) of an AWS Key Management Service (KMS) key for encrypting audio log files stored in an Amazon S3 bucket.log_prefix (
Optional[str]) – The S3 prefix to assign to audio log files.s3_bucket_arn (
Optional[str]) – The Amazon Resource Name (ARN) of an Amazon S3 bucket where audio log files are stored.
- 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_lex import mixins as lex_mixins s3_bucket_log_destination_property = lex_mixins.CfnBotAliasPropsMixin.S3BucketLogDestinationProperty( kms_key_arn="kmsKeyArn", log_prefix="logPrefix", s3_bucket_arn="s3BucketArn" )
Attributes
- kms_key_arn
The Amazon Resource Name (ARN) of an AWS Key Management Service (KMS) key for encrypting audio log files stored in an Amazon S3 bucket.
- log_prefix
The S3 prefix to assign to audio log files.
- s3_bucket_arn
The Amazon Resource Name (ARN) of an Amazon S3 bucket where audio log files are stored.
SentimentAnalysisSettingsProperty
- class CfnBotAliasPropsMixin.SentimentAnalysisSettingsProperty(*, detect_sentiment=None)
Bases:
objectDetermines whether Amazon Lex will use Amazon Comprehend to detect the sentiment of user utterances.
- Parameters:
detect_sentiment (
Union[bool,IResolvable,None]) – Sets whether Amazon Lex uses Amazon Comprehend to detect the sentiment of user utterances.- 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_lex import mixins as lex_mixins sentiment_analysis_settings_property = lex_mixins.CfnBotAliasPropsMixin.SentimentAnalysisSettingsProperty( detect_sentiment=False )
Attributes
- detect_sentiment
Sets whether Amazon Lex uses Amazon Comprehend to detect the sentiment of user utterances.
TextLogDestinationProperty
- class CfnBotAliasPropsMixin.TextLogDestinationProperty(*, cloud_watch=None)
Bases:
objectDefines the Amazon CloudWatch Logs destination log group for conversation text logs.
- Parameters:
cloud_watch (
Union[IResolvable,CloudWatchLogGroupLogDestinationProperty,Dict[str,Any],None]) – Defines the Amazon CloudWatch Logs log group where text and metadata logs are delivered.- 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_lex import mixins as lex_mixins text_log_destination_property = lex_mixins.CfnBotAliasPropsMixin.TextLogDestinationProperty( cloud_watch=lex_mixins.CfnBotAliasPropsMixin.CloudWatchLogGroupLogDestinationProperty( cloud_watch_log_group_arn="cloudWatchLogGroupArn", log_prefix="logPrefix" ) )
Attributes
- cloud_watch
Defines the Amazon CloudWatch Logs log group where text and metadata logs are delivered.
TextLogSettingProperty
- class CfnBotAliasPropsMixin.TextLogSettingProperty(*, destination=None, enabled=None)
Bases:
objectDefines settings to enable text conversation logs.
- Parameters:
destination (
Union[IResolvable,TextLogDestinationProperty,Dict[str,Any],None]) – Defines the Amazon CloudWatch Logs destination log group for conversation text logs.enabled (
Union[bool,IResolvable,None]) – Determines whether conversation logs should be stored for an alias.
- 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_lex import mixins as lex_mixins text_log_setting_property = lex_mixins.CfnBotAliasPropsMixin.TextLogSettingProperty( destination=lex_mixins.CfnBotAliasPropsMixin.TextLogDestinationProperty( cloud_watch=lex_mixins.CfnBotAliasPropsMixin.CloudWatchLogGroupLogDestinationProperty( cloud_watch_log_group_arn="cloudWatchLogGroupArn", log_prefix="logPrefix" ) ), enabled=False )
Attributes
- destination
Defines the Amazon CloudWatch Logs destination log group for conversation text logs.
- enabled
Determines whether conversation logs should be stored for an alias.