Module Values.PutIntentResponseSource

Creates an intent or replaces an existing intent. To define the interaction between the user and your bot, you use one or more intents. For a pizza ordering bot, for example, you would create an OrderPizza intent. To create an intent or replace an existing intent, you must provide the following: Intent name. For example, OrderPizza. Sample utterances. For example, "Can I order a pizza, please." and "I want to order a pizza." Information to be gathered. You specify slot types for the information that your bot will request from the user. You can specify standard slot types, such as a date or a time, or custom slot types such as the size and crust of a pizza. How the intent will be fulfilled. You can provide a Lambda function or configure the intent to return the intent information to the client application. If you use a Lambda function, when all of the intent information is available, Amazon Lex invokes your Lambda function. If you configure your intent to return the intent information to the client application. You can specify other optional information in the request, such as: A confirmation prompt to ask the user to confirm an intent. For example, "Shall I order your pizza?" A conclusion statement to send to the user after the intent has been fulfilled. For example, "I placed your pizza order." A follow-up prompt that asks the user for additional activity. For example, asking "Do you want to order a drink with your pizza?" If you specify an existing intent name to update the intent, Amazon Lex replaces the values in the $LATEST version of the intent with the values in the request. Amazon Lex removes fields that you don't provide in the request. If you don't specify the required fields, Amazon Lex throws an exception. When you update the $LATEST version of an intent, the status field of any bot that uses the $LATEST version of the intent is set to NOT_BUILT. For more information, see how-it-works. This operation requires permissions for the lex:PutIntent action.

Sourcetype nonrec t = {
  1. name : IntentName.t option;
    (*

    The name of the intent.

    *)
  2. description : Description.t option;
    (*

    A description of the intent.

    *)
  3. slots : SlotList.t option;
    (*

    An array of intent slots that are configured for the intent.

    *)
  4. sampleUtterances : IntentUtteranceList.t option;
    (*

    An array of sample utterances that are configured for the intent.

    *)
  5. confirmationPrompt : Prompt.t option;
    (*

    If defined in the intent, Amazon Lex prompts the user to confirm the intent before fulfilling it.

    *)
  6. rejectionStatement : Statement.t option;
    (*

    If the user answers "no" to the question defined in confirmationPrompt Amazon Lex responds with this statement to acknowledge that the intent was canceled.

    *)
  7. followUpPrompt : FollowUpPrompt.t option;
    (*

    If defined in the intent, Amazon Lex uses this prompt to solicit additional user activity after the intent is fulfilled.

    *)
  8. conclusionStatement : Statement.t option;
    (*

    After the Lambda function specified in thefulfillmentActivityintent fulfills the intent, Amazon Lex conveys this statement to the user.

    *)
  9. dialogCodeHook : CodeHook.t option;
    (*

    If defined in the intent, Amazon Lex invokes this Lambda function for each user input.

    *)
  10. fulfillmentActivity : FulfillmentActivity.t option;
    (*

    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.

    *)
  11. parentIntentSignature : BuiltinIntentSignature.t option;
    (*

    A unique identifier for the built-in intent that this intent is based on.

    *)
  12. lastUpdatedDate : Timestamp.t option;
    (*

    The date that the intent was updated. When you create a resource, the creation date and last update dates are the same.

    *)
  13. createdDate : Timestamp.t option;
    (*

    The date that the intent was created.

    *)
  14. version : Version.t option;
    (*

    The version of the intent. For a new intent, the version is always $LATEST.

    *)
  15. checksum : String_.t option;
    (*

    Checksum of the $LATESTversion of the intent created or updated.

    *)
  16. createVersion : Boolean.t option;
    (*

    True if a new version of the intent was created. If the createVersion field was not specified in the request, the createVersion field is set to false in the response.

    *)
  17. kendraConfiguration : KendraConfiguration.t option;
    (*

    Configuration information, if any, required to connect to an Amazon Kendra index and use the AMAZON.KendraSearchIntent intent.

    *)
  18. inputContexts : InputContextList.t option;
    (*

    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.

    *)
  19. outputContexts : OutputContextList.t option;
    (*

    An array of OutputContext objects that lists the contexts that the intent activates when the intent is fulfilled.

    *)
}
Sourcetype nonrec error = [
  1. | `BadRequestException of BadRequestException.t
  2. | `ConflictException of ConflictException.t
  3. | `InternalFailureException of InternalFailureException.t
  4. | `LimitExceededException of LimitExceededException.t
  5. | `PreconditionFailedException of PreconditionFailedException.t
  6. | `Unknown_operation_error of string * string option
]
Sourceval make : ?name:??? -> ?description:??? -> ?slots:??? -> ?sampleUtterances:??? -> ?confirmationPrompt:??? -> ?rejectionStatement:??? -> ?followUpPrompt:??? -> ?conclusionStatement:??? -> ?dialogCodeHook:??? -> ?fulfillmentActivity:??? -> ?parentIntentSignature:??? -> ?lastUpdatedDate:??? -> ?createdDate:??? -> ?version:??? -> ?checksum:??? -> ?createVersion:??? -> ?kendraConfiguration:??? -> ?inputContexts:??? -> ?outputContexts:??? -> unit -> t
Sourceval error_of_json : string -> Yojson.Safe.t -> [> `BadRequestException of BadRequestException.t | `ConflictException of ConflictException.t | `InternalFailureException of InternalFailureException.t | `LimitExceededException of LimitExceededException.t | `PreconditionFailedException of PreconditionFailedException.t | `Unknown_operation_error of string * string option ]
Sourceval error_of_xml : string -> Awso.Xml.t -> [> `BadRequestException of BadRequestException.t | `ConflictException of ConflictException.t | `InternalFailureException of InternalFailureException.t | `LimitExceededException of LimitExceededException.t | `PreconditionFailedException of PreconditionFailedException.t | `Unknown_operation_error of string * string option ]
Sourceval error_to_json : error -> Yojson.Safe.t
Sourceval to_value : t -> [> `Structure of (string * [> `Boolean of Boolean.t | `List of [> `String of Utterance.t | `Structure of (string * [> `Enum of string | `Integer of Priority.t | `List of [> `String of Utterance.t ] list | `String of SlotName.t | `Structure of (string * [> `Integer of PromptMaxAttempts.t | `List of [> `Structure of (string * [> `Enum of string | `Integer of GroupNumber.t | `String of ContentString.t ]) list ] list | `String of ResponseCard.t ]) list ]) list ] list | `String of IntentName.t | `Structure of (string * [> `Enum of string | `Integer of PromptMaxAttempts.t | `List of [> `Structure of (string * [> `Enum of string | `Integer of GroupNumber.t | `String of ContentString.t ]) list ] list | `String of ResponseCard.t | `Structure of (string * [> `Integer of PromptMaxAttempts.t | `List of [> `Structure of (string * [> `Enum of string | `Integer of GroupNumber.t | `String of ContentString.t ]) list ] list | `String of ResponseCard.t ]) list ]) list | `Timestamp of Timestamp.t ]) list ]
Sourceval to_query : t -> Awso.Client.Query.t
Sourceval of_xml : Awso.Xml.t -> t
Sourceval of_string : string -> t
Sourceval of_json : Yojson.Safe.t -> t
Sourceval to_json : t -> Yojson.Safe.t