pub struct Client { /* private fields */ }
Expand description
Client for Amazon Lex Model Building Service
Client for invoking operations on Amazon Lex Model Building Service. Each operation on Amazon Lex Model Building Service is a method on this
this struct. .send()
MUST be invoked on the generated operations to dispatch the request to the service.
§Constructing a Client
A Config
is required to construct a client. For most use cases, the aws-config
crate should be used to automatically resolve this config using
aws_config::load_from_env()
, since this will resolve an SdkConfig
which can be shared
across multiple different AWS SDK clients. This config resolution process can be customized
by calling aws_config::from_env()
instead, which returns a ConfigLoader
that uses
the builder pattern to customize the default config.
In the simplest case, creating a client looks as follows:
let config = aws_config::load_from_env().await;
let client = aws_sdk_lexmodelbuilding::Client::new(&config);
Occasionally, SDKs may have additional service-specific values that can be set on the Config
that
is absent from SdkConfig
, or slightly different settings for a specific client may be desired.
The Builder
struct implements From<&SdkConfig>
, so setting these specific settings can be
done as follows:
let sdk_config = ::aws_config::load_from_env().await;
let config = aws_sdk_lexmodelbuilding::config::Builder::from(&sdk_config)
.some_service_specific_setting("value")
.build();
See the aws-config
docs and Config
for more information on customizing configuration.
Note: Client construction is expensive due to connection thread pool initialization, and should be done once at application start-up.
§Using the Client
A client has a function for every operation that can be performed by the service.
For example, the CreateBotVersion
operation has
a Client::create_bot_version
, function which returns a builder for that operation.
The fluent builder ultimately has a send()
function that returns an async future that
returns a result, as illustrated below:
let result = client.create_bot_version()
.name("example")
.send()
.await;
The underlying HTTP requests that get made by this can be modified with the customize_operation
function on the fluent builder. See the customize
module for more
information.
Implementations§
Source§impl Client
impl Client
Sourcepub fn create_bot_version(&self) -> CreateBotVersionFluentBuilder
pub fn create_bot_version(&self) -> CreateBotVersionFluentBuilder
Constructs a fluent builder for the CreateBotVersion
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot that you want to create a new version of. The name is case sensitive.
checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseIdentifies a specific revision of the
$LATEST
version of the bot. If you specify a checksum and the$LATEST
version of the bot has a different checksum, aPreconditionFailedException
exception is returned and Amazon Lex doesn’t publish a new version. If you don’t specify a checksum, Amazon Lex publishes the$LATEST
version.
- On success, responds with
CreateBotVersionOutput
with field(s):name(Option<String>)
:The name of the bot.
description(Option<String>)
:A description of the bot.
intents(Option<Vec::<Intent>>)
:An array of
Intent
objects. For more information, seePutBot
.clarification_prompt(Option<Prompt>)
:The message that Amazon Lex uses when it doesn’t understand the user’s request. For more information, see
PutBot
.abort_statement(Option<Statement>)
:The message that Amazon Lex uses to cancel a conversation. For more information, see
PutBot
.status(Option<Status>)
:When you send a request to create or update a bot, Amazon Lex sets the
status
response element toBUILDING
. After Amazon Lex builds the bot, it setsstatus
toREADY
. If Amazon Lex can’t build the bot, it setsstatus
toFAILED
. Amazon Lex returns the reason for the failure in thefailureReason
response element.failure_reason(Option<String>)
:If
status
isFAILED
, Amazon Lex provides the reason that it failed to build the bot.last_updated_date(Option<DateTime>)
:The date when the
$LATEST
version of this bot was updated.created_date(Option<DateTime>)
:The date when the bot version was created.
idle_session_ttl_in_seconds(Option<i32>)
:The maximum time in seconds that Amazon Lex retains the data gathered in a conversation. For more information, see
PutBot
.voice_id(Option<String>)
:The Amazon Polly voice ID that Amazon Lex uses for voice interactions with the user.
checksum(Option<String>)
:Checksum identifying the version of the bot that was created.
version(Option<String>)
:The version of the bot.
locale(Option<Locale>)
:Specifies the target locale for the bot.
child_directed(Option<bool>)
:For each Amazon Lex bot created with the Amazon Lex Model Building Service, you must specify whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to the Children’s Online Privacy Protection Act (COPPA) by specifying
true
orfalse
in thechildDirected
field. By specifyingtrue
in thechildDirected
field, you confirm that your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. By specifyingfalse
in thechildDirected
field, you confirm that your use of Amazon Lex is not related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. You may not specify a default value for thechildDirected
field that does not accurately reflect whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA.If your use of Amazon Lex relates to a website, program, or other application that is directed in whole or in part, to children under age 13, you must obtain any required verifiable parental consent under COPPA. For information regarding the use of Amazon Lex in connection with websites, programs, or other applications that are directed or targeted, in whole or in part, to children under age 13, see the Amazon Lex FAQ.
enable_model_improvements(Option<bool>)
:Indicates whether the bot uses accuracy improvements.
true
indicates that the bot is using the improvements, otherwise,false
.detect_sentiment(Option<bool>)
:Indicates whether utterances entered by the user should be sent to Amazon Comprehend for sentiment analysis.
- On failure, responds with
SdkError<CreateBotVersionError>
Source§impl Client
impl Client
Sourcepub fn create_intent_version(&self) -> CreateIntentVersionFluentBuilder
pub fn create_intent_version(&self) -> CreateIntentVersionFluentBuilder
Constructs a fluent builder for the CreateIntentVersion
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the intent that you want to create a new version of. The name is case sensitive.
checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseChecksum of the
$LATEST
version of the intent that should be used to create the new version. If you specify a checksum and the$LATEST
version of the intent has a different checksum, Amazon Lex returns aPreconditionFailedException
exception and doesn’t publish a new version. If you don’t specify a checksum, Amazon Lex publishes the$LATEST
version.
- On success, responds with
CreateIntentVersionOutput
with field(s):name(Option<String>)
:The name of the intent.
description(Option<String>)
:A description of the intent.
slots(Option<Vec::<Slot>>)
:An array of slot types that defines the information required to fulfill the intent.
sample_utterances(Option<Vec::<String>>)
:An array of sample utterances configured for the intent.
confirmation_prompt(Option<Prompt>)
:If defined, the prompt that Amazon Lex uses to confirm the user’s intent before fulfilling it.
rejection_statement(Option<Statement>)
:If the user answers “no” to the question defined in
confirmationPrompt
, Amazon Lex responds with this statement to acknowledge that the intent was canceled.follow_up_prompt(Option<FollowUpPrompt>)
:If defined, Amazon Lex uses this prompt to solicit additional user activity after the intent is fulfilled.
conclusion_statement(Option<Statement>)
:After the Lambda function specified in the
fulfillmentActivity
field fulfills the intent, Amazon Lex conveys this statement to the user.dialog_code_hook(Option<CodeHook>)
:If defined, Amazon Lex invokes this Lambda function for each user input.
fulfillment_activity(Option<FulfillmentActivity>)
:Describes how the intent is fulfilled.
parent_intent_signature(Option<String>)
:A unique identifier for a built-in intent.
last_updated_date(Option<DateTime>)
:The date that the intent was updated.
created_date(Option<DateTime>)
:The date that the intent was created.
version(Option<String>)
:The version number assigned to the new version of the intent.
checksum(Option<String>)
:Checksum of the intent version created.
kendra_configuration(Option<KendraConfiguration>)
:Configuration information, if any, for connecting an Amazon Kendra index with the
AMAZON.KendraSearchIntent
intent.input_contexts(Option<Vec::<InputContext>>)
:An array of
InputContext
objects that lists the contexts that must be active for Amazon Lex to choose the intent in a conversation with the user.output_contexts(Option<Vec::<OutputContext>>)
:An array of
OutputContext
objects that lists the contexts that the intent activates when the intent is fulfilled.
- On failure, responds with
SdkError<CreateIntentVersionError>
Source§impl Client
impl Client
Sourcepub fn create_slot_type_version(&self) -> CreateSlotTypeVersionFluentBuilder
pub fn create_slot_type_version(&self) -> CreateSlotTypeVersionFluentBuilder
Constructs a fluent builder for the CreateSlotTypeVersion
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the slot type that you want to create a new version for. The name is case sensitive.
checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseChecksum for the
$LATEST
version of the slot type that you want to publish. If you specify a checksum and the$LATEST
version of the slot type has a different checksum, Amazon Lex returns aPreconditionFailedException
exception and doesn’t publish the new version. If you don’t specify a checksum, Amazon Lex publishes the$LATEST
version.
- On success, responds with
CreateSlotTypeVersionOutput
with field(s):name(Option<String>)
:The name of the slot type.
description(Option<String>)
:A description of the slot type.
enumeration_values(Option<Vec::<EnumerationValue>>)
:A list of
EnumerationValue
objects that defines the values that the slot type can take.last_updated_date(Option<DateTime>)
:The date that the slot type was updated. When you create a resource, the creation date and last update date are the same.
created_date(Option<DateTime>)
:The date that the slot type was created.
version(Option<String>)
:The version assigned to the new slot type version.
checksum(Option<String>)
:Checksum of the
$LATEST
version of the slot type.value_selection_strategy(Option<SlotValueSelectionStrategy>)
:The strategy that Amazon Lex uses to determine the value of the slot. For more information, see
PutSlotType
.parent_slot_type_signature(Option<String>)
:The built-in slot type used a the parent of the slot type.
slot_type_configurations(Option<Vec::<SlotTypeConfiguration>>)
:Configuration information that extends the parent built-in slot type.
- On failure, responds with
SdkError<CreateSlotTypeVersionError>
Source§impl Client
impl Client
Sourcepub fn delete_bot(&self) -> DeleteBotFluentBuilder
pub fn delete_bot(&self) -> DeleteBotFluentBuilder
Constructs a fluent builder for the DeleteBot
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot. The name is case sensitive.
- On success, responds with
DeleteBotOutput
- On failure, responds with
SdkError<DeleteBotError>
Source§impl Client
impl Client
Sourcepub fn delete_bot_alias(&self) -> DeleteBotAliasFluentBuilder
pub fn delete_bot_alias(&self) -> DeleteBotAliasFluentBuilder
Constructs a fluent builder for the DeleteBotAlias
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the alias to delete. The name is case sensitive.
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the bot that the alias points to.
- On success, responds with
DeleteBotAliasOutput
- On failure, responds with
SdkError<DeleteBotAliasError>
Source§impl Client
impl Client
Sourcepub fn delete_bot_channel_association(
&self,
) -> DeleteBotChannelAssociationFluentBuilder
pub fn delete_bot_channel_association( &self, ) -> DeleteBotChannelAssociationFluentBuilder
Constructs a fluent builder for the DeleteBotChannelAssociation
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the association. The name is case sensitive.
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the Amazon Lex bot.
bot_alias(impl Into<String>)
/set_bot_alias(Option<String>)
:
required: trueAn alias that points to the specific version of the Amazon Lex bot to which this association is being made.
- On success, responds with
DeleteBotChannelAssociationOutput
- On failure, responds with
SdkError<DeleteBotChannelAssociationError>
Source§impl Client
impl Client
Sourcepub fn delete_bot_version(&self) -> DeleteBotVersionFluentBuilder
pub fn delete_bot_version(&self) -> DeleteBotVersionFluentBuilder
Constructs a fluent builder for the DeleteBotVersion
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot.
version(impl Into<String>)
/set_version(Option<String>)
:
required: trueThe version of the bot to delete. You cannot delete the
$LATEST
version of the bot. To delete the$LATEST
version, use theDeleteBot
operation.
- On success, responds with
DeleteBotVersionOutput
- On failure, responds with
SdkError<DeleteBotVersionError>
Source§impl Client
impl Client
Sourcepub fn delete_intent(&self) -> DeleteIntentFluentBuilder
pub fn delete_intent(&self) -> DeleteIntentFluentBuilder
Constructs a fluent builder for the DeleteIntent
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the intent. The name is case sensitive.
- On success, responds with
DeleteIntentOutput
- On failure, responds with
SdkError<DeleteIntentError>
Source§impl Client
impl Client
Sourcepub fn delete_intent_version(&self) -> DeleteIntentVersionFluentBuilder
pub fn delete_intent_version(&self) -> DeleteIntentVersionFluentBuilder
Constructs a fluent builder for the DeleteIntentVersion
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the intent.
version(impl Into<String>)
/set_version(Option<String>)
:
required: trueThe version of the intent to delete. You cannot delete the
$LATEST
version of the intent. To delete the$LATEST
version, use theDeleteIntent
operation.
- On success, responds with
DeleteIntentVersionOutput
- On failure, responds with
SdkError<DeleteIntentVersionError>
Source§impl Client
impl Client
Sourcepub fn delete_slot_type(&self) -> DeleteSlotTypeFluentBuilder
pub fn delete_slot_type(&self) -> DeleteSlotTypeFluentBuilder
Constructs a fluent builder for the DeleteSlotType
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the slot type. The name is case sensitive.
- On success, responds with
DeleteSlotTypeOutput
- On failure, responds with
SdkError<DeleteSlotTypeError>
Source§impl Client
impl Client
Sourcepub fn delete_slot_type_version(&self) -> DeleteSlotTypeVersionFluentBuilder
pub fn delete_slot_type_version(&self) -> DeleteSlotTypeVersionFluentBuilder
Constructs a fluent builder for the DeleteSlotTypeVersion
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the slot type.
version(impl Into<String>)
/set_version(Option<String>)
:
required: trueThe version of the slot type to delete. You cannot delete the
$LATEST
version of the slot type. To delete the$LATEST
version, use theDeleteSlotType
operation.
- On success, responds with
DeleteSlotTypeVersionOutput
- On failure, responds with
SdkError<DeleteSlotTypeVersionError>
Source§impl Client
impl Client
Sourcepub fn delete_utterances(&self) -> DeleteUtterancesFluentBuilder
pub fn delete_utterances(&self) -> DeleteUtterancesFluentBuilder
Constructs a fluent builder for the DeleteUtterances
operation.
- The fluent builder is configurable:
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the bot that stored the utterances.
user_id(impl Into<String>)
/set_user_id(Option<String>)
:
required: trueThe unique identifier for the user that made the utterances. This is the user ID that was sent in the PostContent or PostText operation request that contained the utterance.
- On success, responds with
DeleteUtterancesOutput
- On failure, responds with
SdkError<DeleteUtterancesError>
Source§impl Client
impl Client
Sourcepub fn get_bot(&self) -> GetBotFluentBuilder
pub fn get_bot(&self) -> GetBotFluentBuilder
Constructs a fluent builder for the GetBot
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot. The name is case sensitive.
version_or_alias(impl Into<String>)
/set_version_or_alias(Option<String>)
:
required: trueThe version or alias of the bot.
- On success, responds with
GetBotOutput
with field(s):name(Option<String>)
:The name of the bot.
description(Option<String>)
:A description of the bot.
intents(Option<Vec::<Intent>>)
:An array of
intent
objects. For more information, seePutBot
.enable_model_improvements(Option<bool>)
:Indicates whether the bot uses accuracy improvements.
true
indicates that the bot is using the improvements, otherwise,false
.nlu_intent_confidence_threshold(Option<f64>)
:The score that determines where Amazon Lex inserts the
AMAZON.FallbackIntent
,AMAZON.KendraSearchIntent
, or both when returning alternative intents in a PostContent or PostText response.AMAZON.FallbackIntent
is inserted if the confidence score for all intents is below this value.AMAZON.KendraSearchIntent
is only inserted if it is configured for the bot.clarification_prompt(Option<Prompt>)
:The message Amazon Lex uses when it doesn’t understand the user’s request. For more information, see
PutBot
.abort_statement(Option<Statement>)
:The message that Amazon Lex returns when the user elects to end the conversation without completing it. For more information, see
PutBot
.status(Option<Status>)
:The status of the bot.
When the status is
BUILDING
Amazon Lex is building the bot for testing and use.If the status of the bot is
READY_BASIC_TESTING
, you can test the bot using the exact utterances specified in the bot’s intents. When the bot is ready for full testing or to run, the status isREADY
.If there was a problem with building the bot, the status is
FAILED
and thefailureReason
field explains why the bot did not build.If the bot was saved but not built, the status is
NOT_BUILT
.failure_reason(Option<String>)
:If
status
isFAILED
, Amazon Lex explains why it failed to build the bot.last_updated_date(Option<DateTime>)
:The date that the bot was updated. When you create a resource, the creation date and last updated date are the same.
created_date(Option<DateTime>)
:The date that the bot was created.
idle_session_ttl_in_seconds(Option<i32>)
:The maximum time in seconds that Amazon Lex retains the data gathered in a conversation. For more information, see
PutBot
.voice_id(Option<String>)
:The Amazon Polly voice ID that Amazon Lex uses for voice interaction with the user. For more information, see
PutBot
.checksum(Option<String>)
:Checksum of the bot used to identify a specific revision of the bot’s
$LATEST
version.version(Option<String>)
:The version of the bot. For a new bot, the version is always
$LATEST
.locale(Option<Locale>)
:The target locale for the bot.
child_directed(Option<bool>)
:For each Amazon Lex bot created with the Amazon Lex Model Building Service, you must specify whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to the Children’s Online Privacy Protection Act (COPPA) by specifying
true
orfalse
in thechildDirected
field. By specifyingtrue
in thechildDirected
field, you confirm that your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. By specifyingfalse
in thechildDirected
field, you confirm that your use of Amazon Lex is not related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. You may not specify a default value for thechildDirected
field that does not accurately reflect whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA.If your use of Amazon Lex relates to a website, program, or other application that is directed in whole or in part, to children under age 13, you must obtain any required verifiable parental consent under COPPA. For information regarding the use of Amazon Lex in connection with websites, programs, or other applications that are directed or targeted, in whole or in part, to children under age 13, see the Amazon Lex FAQ.
detect_sentiment(Option<bool>)
:Indicates whether user utterances should be sent to Amazon Comprehend for sentiment analysis.
- On failure, responds with
SdkError<GetBotError>
Source§impl Client
impl Client
Sourcepub fn get_bot_alias(&self) -> GetBotAliasFluentBuilder
pub fn get_bot_alias(&self) -> GetBotAliasFluentBuilder
Constructs a fluent builder for the GetBotAlias
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot alias. The name is case sensitive.
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the bot.
- On success, responds with
GetBotAliasOutput
with field(s):name(Option<String>)
:The name of the bot alias.
description(Option<String>)
:A description of the bot alias.
bot_version(Option<String>)
:The version of the bot that the alias points to.
bot_name(Option<String>)
:The name of the bot that the alias points to.
last_updated_date(Option<DateTime>)
:The date that the bot alias was updated. When you create a resource, the creation date and the last updated date are the same.
created_date(Option<DateTime>)
:The date that the bot alias was created.
checksum(Option<String>)
:Checksum of the bot alias.
conversation_logs(Option<ConversationLogsResponse>)
:The settings that determine how Amazon Lex uses conversation logs for the alias.
- On failure, responds with
SdkError<GetBotAliasError>
Source§impl Client
impl Client
Sourcepub fn get_bot_aliases(&self) -> GetBotAliasesFluentBuilder
pub fn get_bot_aliases(&self) -> GetBotAliasesFluentBuilder
Constructs a fluent builder for the GetBotAliases
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the bot.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token for fetching the next page of aliases. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of aliases, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of aliases to return in the response. The default is 50. .
name_contains(impl Into<String>)
/set_name_contains(Option<String>)
:
required: falseSubstring to match in bot alias names. An alias will be returned if any part of its name matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.”
- On success, responds with
GetBotAliasesOutput
with field(s):bot_aliases(Option<Vec::<BotAliasMetadata>>)
:An array of
BotAliasMetadata
objects, each describing a bot alias.next_token(Option<String>)
:A pagination token for fetching next page of aliases. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of aliases, specify the pagination token in the next request.
- On failure, responds with
SdkError<GetBotAliasesError>
Source§impl Client
impl Client
Sourcepub fn get_bot_channel_association(
&self,
) -> GetBotChannelAssociationFluentBuilder
pub fn get_bot_channel_association( &self, ) -> GetBotChannelAssociationFluentBuilder
Constructs a fluent builder for the GetBotChannelAssociation
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the association between the bot and the channel. The name is case sensitive.
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the Amazon Lex bot.
bot_alias(impl Into<String>)
/set_bot_alias(Option<String>)
:
required: trueAn alias pointing to the specific version of the Amazon Lex bot to which this association is being made.
- On success, responds with
GetBotChannelAssociationOutput
with field(s):name(Option<String>)
:The name of the association between the bot and the channel.
description(Option<String>)
:A description of the association between the bot and the channel.
bot_alias(Option<String>)
:An alias pointing to the specific version of the Amazon Lex bot to which this association is being made.
bot_name(Option<String>)
:The name of the Amazon Lex bot.
created_date(Option<DateTime>)
:The date that the association between the bot and the channel was created.
r#type(Option<ChannelType>)
:The type of the messaging platform.
bot_configuration(Option<HashMap::<String, String>>)
:Provides information that the messaging platform needs to communicate with the Amazon Lex bot.
status(Option<ChannelStatus>)
:The status of the bot channel.
-
CREATED
- The channel has been created and is ready for use. -
IN_PROGRESS
- Channel creation is in progress. -
FAILED
- There was an error creating the channel. For information about the reason for the failure, see thefailureReason
field.
-
failure_reason(Option<String>)
:If
status
isFAILED
, Amazon Lex provides the reason that it failed to create the association.
- On failure, responds with
SdkError<GetBotChannelAssociationError>
Source§impl Client
impl Client
Sourcepub fn get_bot_channel_associations(
&self,
) -> GetBotChannelAssociationsFluentBuilder
pub fn get_bot_channel_associations( &self, ) -> GetBotChannelAssociationsFluentBuilder
Constructs a fluent builder for the GetBotChannelAssociations
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the Amazon Lex bot in the association.
bot_alias(impl Into<String>)
/set_bot_alias(Option<String>)
:
required: trueAn alias pointing to the specific version of the Amazon Lex bot to which this association is being made.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token for fetching the next page of associations. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of associations, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of associations to return in the response. The default is 50.
name_contains(impl Into<String>)
/set_name_contains(Option<String>)
:
required: falseSubstring to match in channel association names. An association will be returned if any part of its name matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.” To return all bot channel associations, use a hyphen (“-”) as the
nameContains
parameter.
- On success, responds with
GetBotChannelAssociationsOutput
with field(s):bot_channel_associations(Option<Vec::<BotChannelAssociation>>)
:An array of objects, one for each association, that provides information about the Amazon Lex bot and its association with the channel.
next_token(Option<String>)
:A pagination token that fetches the next page of associations. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of associations, specify the pagination token in the next request.
- On failure, responds with
SdkError<GetBotChannelAssociationsError>
Source§impl Client
impl Client
Sourcepub fn get_bot_versions(&self) -> GetBotVersionsFluentBuilder
pub fn get_bot_versions(&self) -> GetBotVersionsFluentBuilder
Constructs a fluent builder for the GetBotVersions
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot for which versions should be returned.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token for fetching the next page of bot versions. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of versions, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of bot versions to return in the response. The default is 10.
- On success, responds with
GetBotVersionsOutput
with field(s):bots(Option<Vec::<BotMetadata>>)
:An array of
BotMetadata
objects, one for each numbered version of the bot plus one for the$LATEST
version.next_token(Option<String>)
:A pagination token for fetching the next page of bot versions. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of versions, specify the pagination token in the next request.
- On failure, responds with
SdkError<GetBotVersionsError>
Source§impl Client
impl Client
Sourcepub fn get_bots(&self) -> GetBotsFluentBuilder
pub fn get_bots(&self) -> GetBotsFluentBuilder
Constructs a fluent builder for the GetBots
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token that fetches the next page of bots. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of bots, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of bots to return in the response that the request will return. The default is 10.
name_contains(impl Into<String>)
/set_name_contains(Option<String>)
:
required: falseSubstring to match in bot names. A bot will be returned if any part of its name matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.”
- On success, responds with
GetBotsOutput
with field(s):bots(Option<Vec::<BotMetadata>>)
:An array of
botMetadata
objects, with one entry for each bot.next_token(Option<String>)
:If the response is truncated, it includes a pagination token that you can specify in your next request to fetch the next page of bots.
- On failure, responds with
SdkError<GetBotsError>
Source§impl Client
impl Client
Sourcepub fn get_builtin_intent(&self) -> GetBuiltinIntentFluentBuilder
pub fn get_builtin_intent(&self) -> GetBuiltinIntentFluentBuilder
Constructs a fluent builder for the GetBuiltinIntent
operation.
- The fluent builder is configurable:
signature(impl Into<String>)
/set_signature(Option<String>)
:
required: trueThe unique identifier for a built-in intent. To find the signature for an intent, see Standard Built-in Intents in the Alexa Skills Kit.
- On success, responds with
GetBuiltinIntentOutput
with field(s):signature(Option<String>)
:The unique identifier for a built-in intent.
supported_locales(Option<Vec::<Locale>>)
:A list of locales that the intent supports.
slots(Option<Vec::<BuiltinIntentSlot>>)
:An array of
BuiltinIntentSlot
objects, one entry for each slot type in the intent.
- On failure, responds with
SdkError<GetBuiltinIntentError>
Source§impl Client
impl Client
Sourcepub fn get_builtin_intents(&self) -> GetBuiltinIntentsFluentBuilder
pub fn get_builtin_intents(&self) -> GetBuiltinIntentsFluentBuilder
Constructs a fluent builder for the GetBuiltinIntents
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
locale(Locale)
/set_locale(Option<Locale>)
:
required: falseA list of locales that the intent supports.
signature_contains(impl Into<String>)
/set_signature_contains(Option<String>)
:
required: falseSubstring to match in built-in intent signatures. An intent will be returned if any part of its signature matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.” To find the signature for an intent, see Standard Built-in Intents in the Alexa Skills Kit.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token that fetches the next page of intents. If this API call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of intents, use the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of intents to return in the response. The default is 10.
- On success, responds with
GetBuiltinIntentsOutput
with field(s):intents(Option<Vec::<BuiltinIntentMetadata>>)
:An array of
builtinIntentMetadata
objects, one for each intent in the response.next_token(Option<String>)
:A pagination token that fetches the next page of intents. If the response to this API call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of intents, specify the pagination token in the next request.
- On failure, responds with
SdkError<GetBuiltinIntentsError>
Source§impl Client
impl Client
Sourcepub fn get_builtin_slot_types(&self) -> GetBuiltinSlotTypesFluentBuilder
pub fn get_builtin_slot_types(&self) -> GetBuiltinSlotTypesFluentBuilder
Constructs a fluent builder for the GetBuiltinSlotTypes
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
locale(Locale)
/set_locale(Option<Locale>)
:
required: falseA list of locales that the slot type supports.
signature_contains(impl Into<String>)
/set_signature_contains(Option<String>)
:
required: falseSubstring to match in built-in slot type signatures. A slot type will be returned if any part of its signature matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.”
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token that fetches the next page of slot types. If the response to this API call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of slot types, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of slot types to return in the response. The default is 10.
- On success, responds with
GetBuiltinSlotTypesOutput
with field(s):slot_types(Option<Vec::<BuiltinSlotTypeMetadata>>)
:An array of
BuiltInSlotTypeMetadata
objects, one entry for each slot type returned.next_token(Option<String>)
:If the response is truncated, the response includes a pagination token that you can use in your next request to fetch the next page of slot types.
- On failure, responds with
SdkError<GetBuiltinSlotTypesError>
Source§impl Client
impl Client
Sourcepub fn get_export(&self) -> GetExportFluentBuilder
pub fn get_export(&self) -> GetExportFluentBuilder
Constructs a fluent builder for the GetExport
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot to export.
version(impl Into<String>)
/set_version(Option<String>)
:
required: trueThe version of the bot to export.
resource_type(ResourceType)
/set_resource_type(Option<ResourceType>)
:
required: trueThe type of resource to export.
export_type(ExportType)
/set_export_type(Option<ExportType>)
:
required: trueThe format of the exported data.
- On success, responds with
GetExportOutput
with field(s):name(Option<String>)
:The name of the bot being exported.
version(Option<String>)
:The version of the bot being exported.
resource_type(Option<ResourceType>)
:The type of the exported resource.
export_type(Option<ExportType>)
:The format of the exported data.
export_status(Option<ExportStatus>)
:The status of the export.
-
IN_PROGRESS
- The export is in progress. -
READY
- The export is complete. -
FAILED
- The export could not be completed.
-
failure_reason(Option<String>)
:If
status
isFAILED
, Amazon Lex provides the reason that it failed to export the resource.url(Option<String>)
:An S3 pre-signed URL that provides the location of the exported resource. The exported resource is a ZIP archive that contains the exported resource in JSON format. The structure of the archive may change. Your code should not rely on the archive structure.
- On failure, responds with
SdkError<GetExportError>
Source§impl Client
impl Client
Sourcepub fn get_import(&self) -> GetImportFluentBuilder
pub fn get_import(&self) -> GetImportFluentBuilder
Constructs a fluent builder for the GetImport
operation.
- The fluent builder is configurable:
import_id(impl Into<String>)
/set_import_id(Option<String>)
:
required: trueThe identifier of the import job information to return.
- On success, responds with
GetImportOutput
with field(s):name(Option<String>)
:The name given to the import job.
resource_type(Option<ResourceType>)
:The type of resource imported.
merge_strategy(Option<MergeStrategy>)
:The action taken when there was a conflict between an existing resource and a resource in the import file.
import_id(Option<String>)
:The identifier for the specific import job.
import_status(Option<ImportStatus>)
:The status of the import job. If the status is
FAILED
, you can get the reason for the failure from thefailureReason
field.failure_reason(Option<Vec::<String>>)
:A string that describes why an import job failed to complete.
created_date(Option<DateTime>)
:A timestamp for the date and time that the import job was created.
- On failure, responds with
SdkError<GetImportError>
Source§impl Client
impl Client
Sourcepub fn get_intent(&self) -> GetIntentFluentBuilder
pub fn get_intent(&self) -> GetIntentFluentBuilder
Constructs a fluent builder for the GetIntent
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the intent. The name is case sensitive.
version(impl Into<String>)
/set_version(Option<String>)
:
required: trueThe version of the intent.
- On success, responds with
GetIntentOutput
with field(s):name(Option<String>)
:The name of the intent.
description(Option<String>)
:A description of the intent.
slots(Option<Vec::<Slot>>)
:An array of intent slots configured for the intent.
sample_utterances(Option<Vec::<String>>)
:An array of sample utterances configured for the intent.
confirmation_prompt(Option<Prompt>)
:If defined in the bot, Amazon Lex uses prompt to confirm the intent before fulfilling the user’s request. For more information, see
PutIntent
.rejection_statement(Option<Statement>)
:If the user answers “no” to the question defined in
confirmationPrompt
, Amazon Lex responds with this statement to acknowledge that the intent was canceled.follow_up_prompt(Option<FollowUpPrompt>)
:If defined in the bot, Amazon Lex uses this prompt to solicit additional user activity after the intent is fulfilled. For more information, see
PutIntent
.conclusion_statement(Option<Statement>)
:After the Lambda function specified in the
fulfillmentActivity
element fulfills the intent, Amazon Lex conveys this statement to the user.dialog_code_hook(Option<CodeHook>)
:If defined in the bot, Amazon Amazon Lex invokes this Lambda function for each user input. For more information, see
PutIntent
.fulfillment_activity(Option<FulfillmentActivity>)
:Describes how the intent is fulfilled. For more information, see
PutIntent
.parent_intent_signature(Option<String>)
:A unique identifier for a built-in intent.
last_updated_date(Option<DateTime>)
:The date that the intent was updated. When you create a resource, the creation date and the last updated date are the same.
created_date(Option<DateTime>)
:The date that the intent was created.
version(Option<String>)
:The version of the intent.
checksum(Option<String>)
:Checksum of the intent.
kendra_configuration(Option<KendraConfiguration>)
:Configuration information, if any, to connect to an Amazon Kendra index with the
AMAZON.KendraSearchIntent
intent.input_contexts(Option<Vec::<InputContext>>)
:An array of
InputContext
objects that lists the contexts that must be active for Amazon Lex to choose the intent in a conversation with the user.output_contexts(Option<Vec::<OutputContext>>)
:An array of
OutputContext
objects that lists the contexts that the intent activates when the intent is fulfilled.
- On failure, responds with
SdkError<GetIntentError>
Source§impl Client
impl Client
Sourcepub fn get_intent_versions(&self) -> GetIntentVersionsFluentBuilder
pub fn get_intent_versions(&self) -> GetIntentVersionsFluentBuilder
Constructs a fluent builder for the GetIntentVersions
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the intent for which versions should be returned.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token for fetching the next page of intent versions. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of versions, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of intent versions to return in the response. The default is 10.
- On success, responds with
GetIntentVersionsOutput
with field(s):intents(Option<Vec::<IntentMetadata>>)
:An array of
IntentMetadata
objects, one for each numbered version of the intent plus one for the$LATEST
version.next_token(Option<String>)
:A pagination token for fetching the next page of intent versions. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of versions, specify the pagination token in the next request.
- On failure, responds with
SdkError<GetIntentVersionsError>
Source§impl Client
impl Client
Sourcepub fn get_intents(&self) -> GetIntentsFluentBuilder
pub fn get_intents(&self) -> GetIntentsFluentBuilder
Constructs a fluent builder for the GetIntents
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token that fetches the next page of intents. If the response to this API call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of intents, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of intents to return in the response. The default is 10.
name_contains(impl Into<String>)
/set_name_contains(Option<String>)
:
required: falseSubstring to match in intent names. An intent will be returned if any part of its name matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.”
- On success, responds with
GetIntentsOutput
with field(s):intents(Option<Vec::<IntentMetadata>>)
:An array of
Intent
objects. For more information, seePutBot
.next_token(Option<String>)
:If the response is truncated, the response includes a pagination token that you can specify in your next request to fetch the next page of intents.
- On failure, responds with
SdkError<GetIntentsError>
Source§impl Client
impl Client
Sourcepub fn get_migration(&self) -> GetMigrationFluentBuilder
pub fn get_migration(&self) -> GetMigrationFluentBuilder
Constructs a fluent builder for the GetMigration
operation.
- The fluent builder is configurable:
migration_id(impl Into<String>)
/set_migration_id(Option<String>)
:
required: trueThe unique identifier of the migration to view. The
migrationID
is returned by the operation.
- On success, responds with
GetMigrationOutput
with field(s):migration_id(Option<String>)
:The unique identifier of the migration. This is the same as the identifier used when calling the
GetMigration
operation.v1_bot_name(Option<String>)
:The name of the Amazon Lex V1 bot migrated to Amazon Lex V2.
v1_bot_version(Option<String>)
:The version of the Amazon Lex V1 bot migrated to Amazon Lex V2.
v1_bot_locale(Option<Locale>)
:The locale of the Amazon Lex V1 bot migrated to Amazon Lex V2.
v2_bot_id(Option<String>)
:The unique identifier of the Amazon Lex V2 bot that the Amazon Lex V1 is being migrated to.
v2_bot_role(Option<String>)
:The IAM role that Amazon Lex uses to run the Amazon Lex V2 bot.
migration_status(Option<MigrationStatus>)
:Indicates the status of the migration. When the status is
COMPLETE
the migration is finished and the bot is available in Amazon Lex V2. There may be alerts and warnings that need to be resolved to complete the migration.migration_strategy(Option<MigrationStrategy>)
:The strategy used to conduct the migration.
-
CREATE_NEW
- Creates a new Amazon Lex V2 bot and migrates the Amazon Lex V1 bot to the new bot. -
UPDATE_EXISTING
- Overwrites the existing Amazon Lex V2 bot metadata and the locale being migrated. It doesn’t change any other locales in the Amazon Lex V2 bot. If the locale doesn’t exist, a new locale is created in the Amazon Lex V2 bot.
-
migration_timestamp(Option<DateTime>)
:The date and time that the migration started.
alerts(Option<Vec::<MigrationAlert>>)
:A list of alerts and warnings that indicate issues with the migration for the Amazon Lex V1 bot to Amazon Lex V2. You receive a warning when an Amazon Lex V1 feature has a different implementation if Amazon Lex V2.
For more information, see Migrating a bot in the Amazon Lex V2 developer guide.
- On failure, responds with
SdkError<GetMigrationError>
Source§impl Client
impl Client
Sourcepub fn get_migrations(&self) -> GetMigrationsFluentBuilder
pub fn get_migrations(&self) -> GetMigrationsFluentBuilder
Constructs a fluent builder for the GetMigrations
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
sort_by_attribute(MigrationSortAttribute)
/set_sort_by_attribute(Option<MigrationSortAttribute>)
:
required: falseThe field to sort the list of migrations by. You can sort by the Amazon Lex V1 bot name or the date and time that the migration was started.
sort_by_order(SortOrder)
/set_sort_by_order(Option<SortOrder>)
:
required: falseThe order so sort the list.
v1_bot_name_contains(impl Into<String>)
/set_v1_bot_name_contains(Option<String>)
:
required: falseFilters the list to contain only bots whose name contains the specified string. The string is matched anywhere in bot name.
migration_status_equals(MigrationStatus)
/set_migration_status_equals(Option<MigrationStatus>)
:
required: falseFilters the list to contain only migrations in the specified state.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of migrations to return in the response. The default is 10.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token that fetches the next page of migrations. If the response to this operation is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of migrations, specify the pagination token in the request.
- On success, responds with
GetMigrationsOutput
with field(s):migration_summaries(Option<Vec::<MigrationSummary>>)
:An array of summaries for migrations from Amazon Lex V1 to Amazon Lex V2. To see details of the migration, use the
migrationId
from the summary in a call to the operation.next_token(Option<String>)
:If the response is truncated, it includes a pagination token that you can specify in your next request to fetch the next page of migrations.
- On failure, responds with
SdkError<GetMigrationsError>
Source§impl Client
impl Client
Sourcepub fn get_slot_type(&self) -> GetSlotTypeFluentBuilder
pub fn get_slot_type(&self) -> GetSlotTypeFluentBuilder
Constructs a fluent builder for the GetSlotType
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the slot type. The name is case sensitive.
version(impl Into<String>)
/set_version(Option<String>)
:
required: trueThe version of the slot type.
- On success, responds with
GetSlotTypeOutput
with field(s):name(Option<String>)
:The name of the slot type.
description(Option<String>)
:A description of the slot type.
enumeration_values(Option<Vec::<EnumerationValue>>)
:A list of
EnumerationValue
objects that defines the values that the slot type can take.last_updated_date(Option<DateTime>)
:The date that the slot type was updated. When you create a resource, the creation date and last update date are the same.
created_date(Option<DateTime>)
:The date that the slot type was created.
version(Option<String>)
:The version of the slot type.
checksum(Option<String>)
:Checksum of the
$LATEST
version of the slot type.value_selection_strategy(Option<SlotValueSelectionStrategy>)
:The strategy that Amazon Lex uses to determine the value of the slot. For more information, see
PutSlotType
.parent_slot_type_signature(Option<String>)
:The built-in slot type used as a parent for the slot type.
slot_type_configurations(Option<Vec::<SlotTypeConfiguration>>)
:Configuration information that extends the parent built-in slot type.
- On failure, responds with
SdkError<GetSlotTypeError>
Source§impl Client
impl Client
Sourcepub fn get_slot_type_versions(&self) -> GetSlotTypeVersionsFluentBuilder
pub fn get_slot_type_versions(&self) -> GetSlotTypeVersionsFluentBuilder
Constructs a fluent builder for the GetSlotTypeVersions
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the slot type for which versions should be returned.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token for fetching the next page of slot type versions. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of versions, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of slot type versions to return in the response. The default is 10.
- On success, responds with
GetSlotTypeVersionsOutput
with field(s):slot_types(Option<Vec::<SlotTypeMetadata>>)
:An array of
SlotTypeMetadata
objects, one for each numbered version of the slot type plus one for the$LATEST
version.next_token(Option<String>)
:A pagination token for fetching the next page of slot type versions. If the response to this call is truncated, Amazon Lex returns a pagination token in the response. To fetch the next page of versions, specify the pagination token in the next request.
- On failure, responds with
SdkError<GetSlotTypeVersionsError>
Source§impl Client
impl Client
Sourcepub fn get_slot_types(&self) -> GetSlotTypesFluentBuilder
pub fn get_slot_types(&self) -> GetSlotTypesFluentBuilder
Constructs a fluent builder for the GetSlotTypes
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseA pagination token that fetches the next page of slot types. If the response to this API call is truncated, Amazon Lex returns a pagination token in the response. To fetch next page of slot types, specify the pagination token in the next request.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of slot types to return in the response. The default is 10.
name_contains(impl Into<String>)
/set_name_contains(Option<String>)
:
required: falseSubstring to match in slot type names. A slot type will be returned if any part of its name matches the substring. For example, “xyz” matches both “xyzabc” and “abcxyz.”
- On success, responds with
GetSlotTypesOutput
with field(s):slot_types(Option<Vec::<SlotTypeMetadata>>)
:An array of objects, one for each slot type, that provides information such as the name of the slot type, the version, and a description.
next_token(Option<String>)
:If the response is truncated, it includes a pagination token that you can specify in your next request to fetch the next page of slot types.
- On failure, responds with
SdkError<GetSlotTypesError>
Source§impl Client
impl Client
Sourcepub fn get_utterances_view(&self) -> GetUtterancesViewFluentBuilder
pub fn get_utterances_view(&self) -> GetUtterancesViewFluentBuilder
Constructs a fluent builder for the GetUtterancesView
operation.
- The fluent builder is configurable:
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the bot for which utterance information should be returned.
bot_versions(impl Into<String>)
/set_bot_versions(Option<Vec::<String>>)
:
required: trueAn array of bot versions for which utterance information should be returned. The limit is 5 versions per request.
status_type(StatusType)
/set_status_type(Option<StatusType>)
:
required: trueTo return utterances that were recognized and handled, use
Detected
. To return utterances that were not recognized, useMissed
.
- On success, responds with
GetUtterancesViewOutput
with field(s):bot_name(Option<String>)
:The name of the bot for which utterance information was returned.
utterances(Option<Vec::<UtteranceList>>)
:An array of
UtteranceList
objects, each containing a list ofUtteranceData
objects describing the utterances that were processed by your bot. The response contains a maximum of 100UtteranceData
objects for each version. Amazon Lex returns the most frequent utterances received by the bot in the last 15 days.
- On failure, responds with
SdkError<GetUtterancesViewError>
Source§impl Client
impl Client
Constructs a fluent builder for the ListTagsForResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:
required: trueThe Amazon Resource Name (ARN) of the resource to get a list of tags for.
- On success, responds with
ListTagsForResourceOutput
with field(s):tags(Option<Vec::<Tag>>)
:The tags associated with a resource.
- On failure, responds with
SdkError<ListTagsForResourceError>
Source§impl Client
impl Client
Sourcepub fn put_bot(&self) -> PutBotFluentBuilder
pub fn put_bot(&self) -> PutBotFluentBuilder
Constructs a fluent builder for the PutBot
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the bot. The name is not case sensitive.
description(impl Into<String>)
/set_description(Option<String>)
:
required: falseA description of the bot.
intents(Intent)
/set_intents(Option<Vec::<Intent>>)
:
required: falseAn array of
Intent
objects. Each intent represents a command that a user can express. For example, a pizza ordering bot might support an OrderPizza intent. For more information, seehow-it-works
.enable_model_improvements(bool)
/set_enable_model_improvements(Option<bool>)
:
required: falseSet to
true
to enable access to natural language understanding improvements.When you set the
enableModelImprovements
parameter totrue
you can use thenluIntentConfidenceThreshold
parameter to configure confidence scores. For more information, see Confidence Scores.You can only set the
enableModelImprovements
parameter in certain Regions. If you set the parameter totrue
, your bot has access to accuracy improvements.The Regions where you can set the
enableModelImprovements
parameter totrue
are:-
US East (N. Virginia) (us-east-1)
-
US West (Oregon) (us-west-2)
-
Asia Pacific (Sydney) (ap-southeast-2)
-
EU (Ireland) (eu-west-1)
In other Regions, the
enableModelImprovements
parameter is set totrue
by default. In these Regions setting the parameter tofalse
throws aValidationException
exception.-
nlu_intent_confidence_threshold(f64)
/set_nlu_intent_confidence_threshold(Option<f64>)
:
required: falseDetermines the threshold where Amazon Lex will insert the
AMAZON.FallbackIntent
,AMAZON.KendraSearchIntent
, or both when returning alternative intents in a PostContent or PostText response.AMAZON.FallbackIntent
andAMAZON.KendraSearchIntent
are only inserted if they are configured for the bot.You must set the
enableModelImprovements
parameter totrue
to use confidence scores in the following regions.-
US East (N. Virginia) (us-east-1)
-
US West (Oregon) (us-west-2)
-
Asia Pacific (Sydney) (ap-southeast-2)
-
EU (Ireland) (eu-west-1)
In other Regions, the
enableModelImprovements
parameter is set totrue
by default.For example, suppose a bot is configured with the confidence threshold of 0.80 and the
AMAZON.FallbackIntent
. Amazon Lex returns three alternative intents with the following confidence scores: IntentA (0.70), IntentB (0.60), IntentC (0.50). The response from thePostText
operation would be:-
AMAZON.FallbackIntent
-
IntentA
-
IntentB
-
IntentC
-
clarification_prompt(Prompt)
/set_clarification_prompt(Option<Prompt>)
:
required: falseWhen Amazon Lex doesn’t understand the user’s intent, it uses this message to get clarification. To specify how many times Amazon Lex should repeat the clarification prompt, use the
maxAttempts
field. If Amazon Lex still doesn’t understand, it sends the message in theabortStatement
field.When you create a clarification prompt, make sure that it suggests the correct response from the user. for example, for a bot that orders pizza and drinks, you might create this clarification prompt: “What would you like to do? You can say ‘Order a pizza’ or ‘Order a drink.’”
If you have defined a fallback intent, it will be invoked if the clarification prompt is repeated the number of times defined in the
maxAttempts
field. For more information, see AMAZON.FallbackIntent.If you don’t define a clarification prompt, at runtime Amazon Lex will return a 400 Bad Request exception in three cases:
-
Follow-up prompt - When the user responds to a follow-up prompt but does not provide an intent. For example, in response to a follow-up prompt that says “Would you like anything else today?” the user says “Yes.” Amazon Lex will return a 400 Bad Request exception because it does not have a clarification prompt to send to the user to get an intent.
-
Lambda function - When using a Lambda function, you return an
ElicitIntent
dialog type. Since Amazon Lex does not have a clarification prompt to get an intent from the user, it returns a 400 Bad Request exception. -
PutSession operation - When using the
PutSession
operation, you send anElicitIntent
dialog type. Since Amazon Lex does not have a clarification prompt to get an intent from the user, it returns a 400 Bad Request exception.
-
abort_statement(Statement)
/set_abort_statement(Option<Statement>)
:
required: falseWhen Amazon Lex can’t understand the user’s input in context, it tries to elicit the information a few times. After that, Amazon Lex sends the message defined in
abortStatement
to the user, and then cancels the conversation. To set the number of retries, use thevalueElicitationPrompt
field for the slot type.For example, in a pizza ordering bot, Amazon Lex might ask a user “What type of crust would you like?” If the user’s response is not one of the expected responses (for example, “thin crust, “deep dish,” etc.), Amazon Lex tries to elicit a correct response a few more times.
For example, in a pizza ordering application,
OrderPizza
might be one of the intents. This intent might require theCrustType
slot. You specify thevalueElicitationPrompt
field when you create theCrustType
slot.If you have defined a fallback intent the cancel statement will not be sent to the user, the fallback intent is used instead. For more information, see AMAZON.FallbackIntent.
idle_session_ttl_in_seconds(i32)
/set_idle_session_ttl_in_seconds(Option<i32>)
:
required: falseThe maximum time in seconds that Amazon Lex retains the data gathered in a conversation.
A user interaction session remains active for the amount of time specified. If no conversation occurs during this time, the session expires and Amazon Lex deletes any data provided before the timeout.
For example, suppose that a user chooses the OrderPizza intent, but gets sidetracked halfway through placing an order. If the user doesn’t complete the order within the specified time, Amazon Lex discards the slot information that it gathered, and the user must start over.
If you don’t include the
idleSessionTTLInSeconds
element in aPutBot
operation request, Amazon Lex uses the default value. This is also true if the request replaces an existing bot.The default is 300 seconds (5 minutes).
voice_id(impl Into<String>)
/set_voice_id(Option<String>)
:
required: falseThe Amazon Polly voice ID that you want Amazon Lex to use for voice interactions with the user. The locale configured for the voice must match the locale of the bot. For more information, see Voices in Amazon Polly in the Amazon Polly Developer Guide.
checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseIdentifies a specific revision of the
$LATEST
version.When you create a new bot, leave the
checksum
field blank. If you specify a checksum you get aBadRequestException
exception.When you want to update a bot, set the
checksum
field to the checksum of the most recent revision of the$LATEST
version. If you don’t specify thechecksum
field, or if the checksum does not match the$LATEST
version, you get aPreconditionFailedException
exception.process_behavior(ProcessBehavior)
/set_process_behavior(Option<ProcessBehavior>)
:
required: falseIf you set the
processBehavior
element toBUILD
, Amazon Lex builds the bot so that it can be run. If you set the element toSAVE
Amazon Lex saves the bot, but doesn’t build it.If you don’t specify this value, the default value is
BUILD
.locale(Locale)
/set_locale(Option<Locale>)
:
required: trueSpecifies the target locale for the bot. Any intent used in the bot must be compatible with the locale of the bot.
The default is
en-US
.child_directed(bool)
/set_child_directed(Option<bool>)
:
required: trueFor each Amazon Lex bot created with the Amazon Lex Model Building Service, you must specify whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to the Children’s Online Privacy Protection Act (COPPA) by specifying
true
orfalse
in thechildDirected
field. By specifyingtrue
in thechildDirected
field, you confirm that your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. By specifyingfalse
in thechildDirected
field, you confirm that your use of Amazon Lex is not related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. You may not specify a default value for thechildDirected
field that does not accurately reflect whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA.If your use of Amazon Lex relates to a website, program, or other application that is directed in whole or in part, to children under age 13, you must obtain any required verifiable parental consent under COPPA. For information regarding the use of Amazon Lex in connection with websites, programs, or other applications that are directed or targeted, in whole or in part, to children under age 13, see the Amazon Lex FAQ.
detect_sentiment(bool)
/set_detect_sentiment(Option<bool>)
:
required: falseWhen set to
true
user utterances are sent to Amazon Comprehend for sentiment analysis. If you don’t specifydetectSentiment
, the default isfalse
.create_version(bool)
/set_create_version(Option<bool>)
:
required: falseWhen set to
true
a new numbered version of the bot is created. This is the same as calling theCreateBotVersion
operation. If you don’t specifycreateVersion
, the default isfalse
.tags(Tag)
/set_tags(Option<Vec::<Tag>>)
:
required: falseA list of tags to add to the bot. You can only add tags when you create a bot, you can’t use the
PutBot
operation to update the tags on a bot. To update tags, use theTagResource
operation.
- On success, responds with
PutBotOutput
with field(s):name(Option<String>)
:The name of the bot.
description(Option<String>)
:A description of the bot.
intents(Option<Vec::<Intent>>)
:An array of
Intent
objects. For more information, seePutBot
.enable_model_improvements(Option<bool>)
:Indicates whether the bot uses accuracy improvements.
true
indicates that the bot is using the improvements, otherwise,false
.nlu_intent_confidence_threshold(Option<f64>)
:The score that determines where Amazon Lex inserts the
AMAZON.FallbackIntent
,AMAZON.KendraSearchIntent
, or both when returning alternative intents in a PostContent or PostText response.AMAZON.FallbackIntent
is inserted if the confidence score for all intents is below this value.AMAZON.KendraSearchIntent
is only inserted if it is configured for the bot.clarification_prompt(Option<Prompt>)
:The prompts that Amazon Lex uses when it doesn’t understand the user’s intent. For more information, see
PutBot
.abort_statement(Option<Statement>)
:The message that Amazon Lex uses to cancel a conversation. For more information, see
PutBot
.status(Option<Status>)
:When you send a request to create a bot with
processBehavior
set toBUILD
, Amazon Lex sets thestatus
response element toBUILDING
.In the
READY_BASIC_TESTING
state you can test the bot with user inputs that exactly match the utterances configured for the bot’s intents and values in the slot types.If Amazon Lex can’t build the bot, Amazon Lex sets
status
toFAILED
. Amazon Lex returns the reason for the failure in thefailureReason
response element.When you set
processBehavior
toSAVE
, Amazon Lex sets the status code toNOT BUILT
.When the bot is in the
READY
state you can test and publish the bot.failure_reason(Option<String>)
:If
status
isFAILED
, Amazon Lex provides the reason that it failed to build the bot.last_updated_date(Option<DateTime>)
:The date that the bot was updated. When you create a resource, the creation date and last updated date are the same.
created_date(Option<DateTime>)
:The date that the bot was created.
idle_session_ttl_in_seconds(Option<i32>)
:The maximum length of time that Amazon Lex retains the data gathered in a conversation. For more information, see
PutBot
.voice_id(Option<String>)
:The Amazon Polly voice ID that Amazon Lex uses for voice interaction with the user. For more information, see
PutBot
.checksum(Option<String>)
:Checksum of the bot that you created.
version(Option<String>)
:The version of the bot. For a new bot, the version is always
$LATEST
.locale(Option<Locale>)
:The target locale for the bot.
child_directed(Option<bool>)
:For each Amazon Lex bot created with the Amazon Lex Model Building Service, you must specify whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to the Children’s Online Privacy Protection Act (COPPA) by specifying
true
orfalse
in thechildDirected
field. By specifyingtrue
in thechildDirected
field, you confirm that your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. By specifyingfalse
in thechildDirected
field, you confirm that your use of Amazon Lex is not related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA. You may not specify a default value for thechildDirected
field that does not accurately reflect whether your use of Amazon Lex is related to a website, program, or other application that is directed or targeted, in whole or in part, to children under age 13 and subject to COPPA.If your use of Amazon Lex relates to a website, program, or other application that is directed in whole or in part, to children under age 13, you must obtain any required verifiable parental consent under COPPA. For information regarding the use of Amazon Lex in connection with websites, programs, or other applications that are directed or targeted, in whole or in part, to children under age 13, see the Amazon Lex FAQ.
create_version(Option<bool>)
:True
if a new version of the bot was created. If thecreateVersion
field was not specified in the request, thecreateVersion
field is set to false in the response.detect_sentiment(Option<bool>)
:true
if the bot is configured to send user utterances to Amazon Comprehend for sentiment analysis. If thedetectSentiment
field was not specified in the request, thedetectSentiment
field isfalse
in the response.tags(Option<Vec::<Tag>>)
:A list of tags associated with the bot.
- On failure, responds with
SdkError<PutBotError>
Source§impl Client
impl Client
Sourcepub fn put_bot_alias(&self) -> PutBotAliasFluentBuilder
pub fn put_bot_alias(&self) -> PutBotAliasFluentBuilder
Constructs a fluent builder for the PutBotAlias
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the alias. The name is not case sensitive.
description(impl Into<String>)
/set_description(Option<String>)
:
required: falseA description of the alias.
bot_version(impl Into<String>)
/set_bot_version(Option<String>)
:
required: trueThe version of the bot.
bot_name(impl Into<String>)
/set_bot_name(Option<String>)
:
required: trueThe name of the bot.
checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseIdentifies a specific revision of the
$LATEST
version.When you create a new bot alias, leave the
checksum
field blank. If you specify a checksum you get aBadRequestException
exception.When you want to update a bot alias, set the
checksum
field to the checksum of the most recent revision of the$LATEST
version. If you don’t specify thechecksum
field, or if the checksum does not match the$LATEST
version, you get aPreconditionFailedException
exception.conversation_logs(ConversationLogsRequest)
/set_conversation_logs(Option<ConversationLogsRequest>)
:
required: falseSettings for conversation logs for the alias.
tags(Tag)
/set_tags(Option<Vec::<Tag>>)
:
required: falseA list of tags to add to the bot alias. You can only add tags when you create an alias, you can’t use the
PutBotAlias
operation to update the tags on a bot alias. To update tags, use theTagResource
operation.
- On success, responds with
PutBotAliasOutput
with field(s):name(Option<String>)
:The name of the alias.
description(Option<String>)
:A description of the alias.
bot_version(Option<String>)
:The version of the bot that the alias points to.
bot_name(Option<String>)
:The name of the bot that the alias points to.
last_updated_date(Option<DateTime>)
:The date that the bot alias was updated. When you create a resource, the creation date and the last updated date are the same.
created_date(Option<DateTime>)
:The date that the bot alias was created.
checksum(Option<String>)
:The checksum for the current version of the alias.
conversation_logs(Option<ConversationLogsResponse>)
:The settings that determine how Amazon Lex uses conversation logs for the alias.
tags(Option<Vec::<Tag>>)
:A list of tags associated with a bot.
- On failure, responds with
SdkError<PutBotAliasError>
Source§impl Client
impl Client
Sourcepub fn put_intent(&self) -> PutIntentFluentBuilder
pub fn put_intent(&self) -> PutIntentFluentBuilder
Constructs a fluent builder for the PutIntent
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the intent. The name is not case sensitive.
The name can’t match a built-in intent name, or a built-in intent name with “AMAZON.” removed. For example, because there is a built-in intent called
AMAZON.HelpIntent
, you can’t create a custom intent calledHelpIntent
.For a list of built-in intents, see Standard Built-in Intents in the Alexa Skills Kit.
description(impl Into<String>)
/set_description(Option<String>)
:
required: falseA description of the intent.
slots(Slot)
/set_slots(Option<Vec::<Slot>>)
:
required: falseAn array of intent slots. At runtime, Amazon Lex elicits required slot values from the user using prompts defined in the slots. For more information, see
how-it-works
.sample_utterances(impl Into<String>)
/set_sample_utterances(Option<Vec::<String>>)
:
required: falseAn array of utterances (strings) that a user might say to signal the intent. For example, “I want {PizzaSize} pizza”, “Order {Quantity} {PizzaSize} pizzas”.
In each utterance, a slot name is enclosed in curly braces.
confirmation_prompt(Prompt)
/set_confirmation_prompt(Option<Prompt>)
:
required: falsePrompts the user to confirm the intent. This question should have a yes or no answer.
Amazon Lex uses this prompt to ensure that the user acknowledges that the intent is ready for fulfillment. For example, with the
OrderPizza
intent, you might want to confirm that the order is correct before placing it. For other intents, such as intents that simply respond to user questions, you might not need to ask the user for confirmation before providing the information.You you must provide both the
rejectionStatement
and theconfirmationPrompt
, or neither.rejection_statement(Statement)
/set_rejection_statement(Option<Statement>)
:
required: falseWhen the user answers “no” to the question defined in
confirmationPrompt
, Amazon Lex responds with this statement to acknowledge that the intent was canceled.You must provide both the
rejectionStatement
and theconfirmationPrompt
, or neither.follow_up_prompt(FollowUpPrompt)
/set_follow_up_prompt(Option<FollowUpPrompt>)
:
required: falseAmazon Lex uses this prompt to solicit additional activity after fulfilling an intent. For example, after the
OrderPizza
intent is fulfilled, you might prompt the user to order a drink.The action that Amazon Lex takes depends on the user’s response, as follows:
-
If the user says “Yes” it responds with the clarification prompt that is configured for the bot.
-
if the user says “Yes” and continues with an utterance that triggers an intent it starts a conversation for the intent.
-
If the user says “No” it responds with the rejection statement configured for the the follow-up prompt.
-
If it doesn’t recognize the utterance it repeats the follow-up prompt again.
The
followUpPrompt
field and theconclusionStatement
field are mutually exclusive. You can specify only one.-
conclusion_statement(Statement)
/set_conclusion_statement(Option<Statement>)
:
required: falseThe statement that you want Amazon Lex to convey to the user after the intent is successfully fulfilled by the Lambda function.
This element is relevant only if you provide a Lambda function in the
fulfillmentActivity
. If you return the intent to the client application, you can’t specify this element.The
followUpPrompt
andconclusionStatement
are mutually exclusive. You can specify only one.dialog_code_hook(CodeHook)
/set_dialog_code_hook(Option<CodeHook>)
:
required: falseSpecifies a Lambda function to invoke for each user input. You can invoke this Lambda function to personalize user interaction.
For example, suppose your bot determines that the user is John. Your Lambda function might retrieve John’s information from a backend database and prepopulate some of the values. For example, if you find that John is gluten intolerant, you might set the corresponding intent slot,
GlutenIntolerant
, to true. You might find John’s phone number and set the corresponding session attribute.fulfillment_activity(FulfillmentActivity)
/set_fulfillment_activity(Option<FulfillmentActivity>)
:
required: falseRequired. Describes how the intent is fulfilled. For example, after a user provides all of the information for a pizza order,
fulfillmentActivity
defines how the bot places an order with a local pizza store.You might configure Amazon Lex to return all of the intent information to the client application, or direct it to invoke a Lambda function that can process the intent (for example, place an order with a pizzeria).
parent_intent_signature(impl Into<String>)
/set_parent_intent_signature(Option<String>)
:
required: falseA unique identifier for the built-in intent to base this intent on. To find the signature for an intent, see Standard Built-in Intents in the Alexa Skills Kit.
checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseIdentifies a specific revision of the
$LATEST
version.When you create a new intent, leave the
checksum
field blank. If you specify a checksum you get aBadRequestException
exception.When you want to update a intent, set the
checksum
field to the checksum of the most recent revision of the$LATEST
version. If you don’t specify thechecksum
field, or if the checksum does not match the$LATEST
version, you get aPreconditionFailedException
exception.create_version(bool)
/set_create_version(Option<bool>)
:
required: falseWhen set to
true
a new numbered version of the intent is created. This is the same as calling theCreateIntentVersion
operation. If you do not specifycreateVersion
, the default isfalse
.kendra_configuration(KendraConfiguration)
/set_kendra_configuration(Option<KendraConfiguration>)
:
required: falseConfiguration information required to use the
AMAZON.KendraSearchIntent
intent to connect to an Amazon Kendra index. For more information, see AMAZON.KendraSearchIntent.input_contexts(InputContext)
/set_input_contexts(Option<Vec::<InputContext>>)
:
required: falseAn array of
InputContext
objects that lists the contexts that must be active for Amazon Lex to choose the intent in a conversation with the user.output_contexts(OutputContext)
/set_output_contexts(Option<Vec::<OutputContext>>)
:
required: falseAn array of
OutputContext
objects that lists the contexts that the intent activates when the intent is fulfilled.
- On success, responds with
PutIntentOutput
with field(s):name(Option<String>)
:The name of the intent.
description(Option<String>)
:A description of the intent.
slots(Option<Vec::<Slot>>)
:An array of intent slots that are configured for the intent.
sample_utterances(Option<Vec::<String>>)
:An array of sample utterances that are configured for the intent.
confirmation_prompt(Option<Prompt>)
:If defined in the intent, Amazon Lex prompts the user to confirm the intent before fulfilling it.
rejection_statement(Option<Statement>)
:If the user answers “no” to the question defined in
confirmationPrompt
Amazon Lex responds with this statement to acknowledge that the intent was canceled.follow_up_prompt(Option<FollowUpPrompt>)
:If defined in the intent, Amazon Lex uses this prompt to solicit additional user activity after the intent is fulfilled.
conclusion_statement(Option<Statement>)
:After the Lambda function specified in the
fulfillmentActivity
intent fulfills the intent, Amazon Lex conveys this statement to the user.dialog_code_hook(Option<CodeHook>)
:If defined in the intent, Amazon Lex invokes this Lambda function for each user input.
fulfillment_activity(Option<FulfillmentActivity>)
:If defined in the intent, Amazon Lex invokes this Lambda function to fulfill the intent after the user provides all of the information required by the intent.
parent_intent_signature(Option<String>)
:A unique identifier for the built-in intent that this intent is based on.
last_updated_date(Option<DateTime>)
:The date that the intent was updated. When you create a resource, the creation date and last update dates are the same.
created_date(Option<DateTime>)
:The date that the intent was created.
version(Option<String>)
:The version of the intent. For a new intent, the version is always
$LATEST
.checksum(Option<String>)
:Checksum of the
$LATEST
version of the intent created or updated.create_version(Option<bool>)
:True
if a new version of the intent was created. If thecreateVersion
field was not specified in the request, thecreateVersion
field is set to false in the response.kendra_configuration(Option<KendraConfiguration>)
:Configuration information, if any, required to connect to an Amazon Kendra index and use the
AMAZON.KendraSearchIntent
intent.input_contexts(Option<Vec::<InputContext>>)
:An array of
InputContext
objects that lists the contexts that must be active for Amazon Lex to choose the intent in a conversation with the user.output_contexts(Option<Vec::<OutputContext>>)
:An array of
OutputContext
objects that lists the contexts that the intent activates when the intent is fulfilled.
- On failure, responds with
SdkError<PutIntentError>
Source§impl Client
impl Client
Sourcepub fn put_slot_type(&self) -> PutSlotTypeFluentBuilder
pub fn put_slot_type(&self) -> PutSlotTypeFluentBuilder
Constructs a fluent builder for the PutSlotType
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the slot type. The name is not case sensitive.
The name can’t match a built-in slot type name, or a built-in slot type name with “AMAZON.” removed. For example, because there is a built-in slot type called
AMAZON.DATE
, you can’t create a custom slot type calledDATE
.For a list of built-in slot types, see Slot Type Reference in the Alexa Skills Kit.
description(impl Into<String>)
/set_description(Option<String>)
:
required: falseA description of the slot type.
enumeration_values(EnumerationValue)
/set_enumeration_values(Option<Vec::<EnumerationValue>>)
:
required: falseA list of
EnumerationValue
objects that defines the values that the slot type can take. Each value can have a list ofsynonyms
, which are additional values that help train the machine learning model about the values that it resolves for a slot.A regular expression slot type doesn’t require enumeration values. All other slot types require a list of enumeration values.
When Amazon Lex resolves a slot value, it generates a resolution list that contains up to five possible values for the slot. If you are using a Lambda function, this resolution list is passed to the function. If you are not using a Lambda function you can choose to return the value that the user entered or the first value in the resolution list as the slot value. The
valueSelectionStrategy
field indicates the option to use.checksum(impl Into<String>)
/set_checksum(Option<String>)
:
required: falseIdentifies a specific revision of the
$LATEST
version.When you create a new slot type, leave the
checksum
field blank. If you specify a checksum you get aBadRequestException
exception.When you want to update a slot type, set the
checksum
field to the checksum of the most recent revision of the$LATEST
version. If you don’t specify thechecksum
field, or if the checksum does not match the$LATEST
version, you get aPreconditionFailedException
exception.value_selection_strategy(SlotValueSelectionStrategy)
/set_value_selection_strategy(Option<SlotValueSelectionStrategy>)
:
required: falseDetermines the slot resolution strategy that Amazon Lex uses to return slot type values. The field can be set to one of the following values:
-
ORIGINAL_VALUE
- Returns the value entered by the user, if the user value is similar to the slot value. -
TOP_RESOLUTION
- If there is a resolution list for the slot, return the first value in the resolution list as the slot type value. If there is no resolution list, null is returned.
If you don’t specify the
valueSelectionStrategy
, the default isORIGINAL_VALUE
.-
create_version(bool)
/set_create_version(Option<bool>)
:
required: falseWhen set to
true
a new numbered version of the slot type is created. This is the same as calling theCreateSlotTypeVersion
operation. If you do not specifycreateVersion
, the default isfalse
.parent_slot_type_signature(impl Into<String>)
/set_parent_slot_type_signature(Option<String>)
:
required: falseThe built-in slot type used as the parent of the slot type. When you define a parent slot type, the new slot type has all of the same configuration as the parent.
Only
AMAZON.AlphaNumeric
is supported.slot_type_configurations(SlotTypeConfiguration)
/set_slot_type_configurations(Option<Vec::<SlotTypeConfiguration>>)
:
required: falseConfiguration information that extends the parent built-in slot type. The configuration is added to the settings for the parent slot type.
- On success, responds with
PutSlotTypeOutput
with field(s):name(Option<String>)
:The name of the slot type.
description(Option<String>)
:A description of the slot type.
enumeration_values(Option<Vec::<EnumerationValue>>)
:A list of
EnumerationValue
objects that defines the values that the slot type can take.last_updated_date(Option<DateTime>)
:The date that the slot type was updated. When you create a slot type, the creation date and last update date are the same.
created_date(Option<DateTime>)
:The date that the slot type was created.
version(Option<String>)
:The version of the slot type. For a new slot type, the version is always
$LATEST
.checksum(Option<String>)
:Checksum of the
$LATEST
version of the slot type.value_selection_strategy(Option<SlotValueSelectionStrategy>)
:The slot resolution strategy that Amazon Lex uses to determine the value of the slot. For more information, see
PutSlotType
.create_version(Option<bool>)
:True
if a new version of the slot type was created. If thecreateVersion
field was not specified in the request, thecreateVersion
field is set to false in the response.parent_slot_type_signature(Option<String>)
:The built-in slot type used as the parent of the slot type.
slot_type_configurations(Option<Vec::<SlotTypeConfiguration>>)
:Configuration information that extends the parent built-in slot type.
- On failure, responds with
SdkError<PutSlotTypeError>
Source§impl Client
impl Client
Sourcepub fn start_import(&self) -> StartImportFluentBuilder
pub fn start_import(&self) -> StartImportFluentBuilder
Constructs a fluent builder for the StartImport
operation.
- The fluent builder is configurable:
payload(Blob)
/set_payload(Option<Blob>)
:
required: trueA zip archive in binary format. The archive should contain one file, a JSON file containing the resource to import. The resource should match the type specified in the
resourceType
field.resource_type(ResourceType)
/set_resource_type(Option<ResourceType>)
:
required: trueSpecifies the type of resource to export. Each resource also exports any resources that it depends on.
-
A bot exports dependent intents.
-
An intent exports dependent slot types.
-
merge_strategy(MergeStrategy)
/set_merge_strategy(Option<MergeStrategy>)
:
required: trueSpecifies the action that the
StartImport
operation should take when there is an existing resource with the same name.-
FAIL_ON_CONFLICT - The import operation is stopped on the first conflict between a resource in the import file and an existing resource. The name of the resource causing the conflict is in the
failureReason
field of the response to theGetImport
operation.OVERWRITE_LATEST - The import operation proceeds even if there is a conflict with an existing resource. The $LASTEST version of the existing resource is overwritten with the data from the import file.
-
tags(Tag)
/set_tags(Option<Vec::<Tag>>)
:
required: falseA list of tags to add to the imported bot. You can only add tags when you import a bot, you can’t add tags to an intent or slot type.
- On success, responds with
StartImportOutput
with field(s):name(Option<String>)
:The name given to the import job.
resource_type(Option<ResourceType>)
:The type of resource to import.
merge_strategy(Option<MergeStrategy>)
:The action to take when there is a merge conflict.
import_id(Option<String>)
:The identifier for the specific import job.
import_status(Option<ImportStatus>)
:The status of the import job. If the status is
FAILED
, you can get the reason for the failure using theGetImport
operation.tags(Option<Vec::<Tag>>)
:A list of tags added to the imported bot.
created_date(Option<DateTime>)
:A timestamp for the date and time that the import job was requested.
- On failure, responds with
SdkError<StartImportError>
Source§impl Client
impl Client
Sourcepub fn start_migration(&self) -> StartMigrationFluentBuilder
pub fn start_migration(&self) -> StartMigrationFluentBuilder
Constructs a fluent builder for the StartMigration
operation.
- The fluent builder is configurable:
v1_bot_name(impl Into<String>)
/set_v1_bot_name(Option<String>)
:
required: trueThe name of the Amazon Lex V1 bot that you are migrating to Amazon Lex V2.
v1_bot_version(impl Into<String>)
/set_v1_bot_version(Option<String>)
:
required: trueThe version of the bot to migrate to Amazon Lex V2. You can migrate the
$LATEST
version as well as any numbered version.v2_bot_name(impl Into<String>)
/set_v2_bot_name(Option<String>)
:
required: trueThe name of the Amazon Lex V2 bot that you are migrating the Amazon Lex V1 bot to.
-
If the Amazon Lex V2 bot doesn’t exist, you must use the
CREATE_NEW
migration strategy. -
If the Amazon Lex V2 bot exists, you must use the
UPDATE_EXISTING
migration strategy to change the contents of the Amazon Lex V2 bot.
-
v2_bot_role(impl Into<String>)
/set_v2_bot_role(Option<String>)
:
required: trueThe IAM role that Amazon Lex uses to run the Amazon Lex V2 bot.
migration_strategy(MigrationStrategy)
/set_migration_strategy(Option<MigrationStrategy>)
:
required: trueThe strategy used to conduct the migration.
-
CREATE_NEW
- Creates a new Amazon Lex V2 bot and migrates the Amazon Lex V1 bot to the new bot. -
UPDATE_EXISTING
- Overwrites the existing Amazon Lex V2 bot metadata and the locale being migrated. It doesn’t change any other locales in the Amazon Lex V2 bot. If the locale doesn’t exist, a new locale is created in the Amazon Lex V2 bot.
-
- On success, responds with
StartMigrationOutput
with field(s):v1_bot_name(Option<String>)
:The name of the Amazon Lex V1 bot that you are migrating to Amazon Lex V2.
v1_bot_version(Option<String>)
:The version of the bot to migrate to Amazon Lex V2.
v1_bot_locale(Option<Locale>)
:The locale used for the Amazon Lex V1 bot.
v2_bot_id(Option<String>)
:The unique identifier for the Amazon Lex V2 bot.
v2_bot_role(Option<String>)
:The IAM role that Amazon Lex uses to run the Amazon Lex V2 bot.
migration_id(Option<String>)
:The unique identifier that Amazon Lex assigned to the migration.
migration_strategy(Option<MigrationStrategy>)
:The strategy used to conduct the migration.
migration_timestamp(Option<DateTime>)
:The date and time that the migration started.
- On failure, responds with
SdkError<StartMigrationError>
Source§impl Client
impl Client
Sourcepub fn tag_resource(&self) -> TagResourceFluentBuilder
pub fn tag_resource(&self) -> TagResourceFluentBuilder
Constructs a fluent builder for the TagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:
required: trueThe Amazon Resource Name (ARN) of the bot, bot alias, or bot channel to tag.
tags(Tag)
/set_tags(Option<Vec::<Tag>>)
:
required: trueA list of tag keys to add to the resource. If a tag key already exists, the existing value is replaced with the new value.
- On success, responds with
TagResourceOutput
- On failure, responds with
SdkError<TagResourceError>
Source§impl Client
impl Client
Sourcepub fn untag_resource(&self) -> UntagResourceFluentBuilder
pub fn untag_resource(&self) -> UntagResourceFluentBuilder
Constructs a fluent builder for the UntagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:
required: trueThe Amazon Resource Name (ARN) of the resource to remove the tags from.
tag_keys(impl Into<String>)
/set_tag_keys(Option<Vec::<String>>)
:
required: trueA list of tag keys to remove from the resource. If a tag key does not exist on the resource, it is ignored.
- On success, responds with
UntagResourceOutput
- On failure, responds with
SdkError<UntagResourceError>
Source§impl Client
impl Client
Sourcepub fn from_conf(conf: Config) -> Self
pub fn from_conf(conf: Config) -> Self
Creates a new client from the service Config
.
§Panics
This method will panic in the following cases:
- Retries or timeouts are enabled without a
sleep_impl
configured. - Identity caching is enabled without a
sleep_impl
andtime_source
configured. - No
behavior_version
is provided.
The panic message for each of these will have instructions on how to resolve them.
Source§impl Client
impl Client
Sourcepub fn new(sdk_config: &SdkConfig) -> Self
pub fn new(sdk_config: &SdkConfig) -> Self
Creates a new client from an SDK Config.
§Panics
- This method will panic if the
sdk_config
is missing an async sleep implementation. If you experience this panic, set thesleep_impl
on the Config passed into this function to fix it. - This method will panic if the
sdk_config
is missing an HTTP connector. If you experience this panic, set thehttp_connector
on the Config passed into this function to fix it. - This method will panic if no
BehaviorVersion
is provided. If you experience this panic, setbehavior_version
on the Config or enable thebehavior-version-latest
Cargo feature.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Client
impl !RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl !UnwindSafe for Client
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the foreground set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red()
and
green()
, which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg()
:
use yansi::{Paint, Color};
painted.fg(Color::White);
Set foreground color to white using white()
.
use yansi::Paint;
painted.white();
Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the background set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red()
and
on_green()
, which have the same functionality but
are pithier.
§Example
Set background color to red using fg()
:
use yansi::{Paint, Color};
painted.bg(Color::Red);
Set background color to red using on_red()
.
use yansi::Paint;
painted.on_red();
Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute
value
.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold()
and
underline()
, which have the same functionality
but are pithier.
§Example
Make text bold using attr()
:
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);
Make text bold using using bold()
.
use yansi::Paint;
painted.bold();
Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi
Quirk
value
.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask()
and
wrap()
, which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk()
:
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);
Enable wrapping using wrap()
.
use yansi::Paint;
painted.wrap();
Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition
value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted
only when both stdout
and stderr
are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);