Table Of Contents

Feedback

User Guide

First time using the AWS CLI? See the User Guide for help getting started.

Note: You are viewing the documentation for an older major version of the AWS CLI (version 1).

AWS CLI version 2, the latest major version of AWS CLI, is now stable and recommended for general use. To view this page for the AWS CLI version 2, click here. For more information see the AWS CLI version 2 installation instructions and migration guide.

[ aws . lex-runtime ]

get-session

Description

Returns session information for a specified bot, alias, and user ID.

See also: AWS API Documentation

See 'aws help' for descriptions of global parameters.

Synopsis

  get-session
--bot-name <value>
--bot-alias <value>
--user-id <value>
[--checkpoint-label-filter <value>]
[--cli-input-json <value>]
[--generate-cli-skeleton <value>]

Options

--bot-name (string)

The name of the bot that contains the session data.

--bot-alias (string)

The alias in use for the bot that contains the session data.

--user-id (string)

The ID of the client application user. Amazon Lex uses this to identify a user's conversation with your bot.

--checkpoint-label-filter (string)

A string used to filter the intents returned in the recentIntentSummaryView structure.

When you specify a filter, only intents with their checkpointLabel field set to that string are returned.

--cli-input-json (string) Performs service operation based on the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton. If other arguments are provided on the command line, the CLI values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.

--generate-cli-skeleton (string) Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input, prints a sample input JSON that can be used as an argument for --cli-input-json. If provided with the value output, it validates the command inputs and returns a sample output JSON for that command.

See 'aws help' for descriptions of global parameters.

Output

recentIntentSummaryView -> (list)

An array of information about the intents used in the session. The array can contain a maximum of three summaries. If more than three intents are used in the session, the recentIntentSummaryView operation contains information about the last three intents used.

If you set the checkpointLabelFilter parameter in the request, the array contains only the intents with the specified label.

(structure)

Provides information about the state of an intent. You can use this information to get the current state of an intent so that you can process the intent, or so that you can return the intent to its previous state.

intentName -> (string)

The name of the intent.

checkpointLabel -> (string)

A user-defined label that identifies a particular intent. You can use this label to return to a previous intent.

Use the checkpointLabelFilter parameter of the GetSessionRequest operation to filter the intents returned by the operation to those with only the specified label.

slots -> (map)

Map of the slots that have been gathered and their values.

key -> (string)

value -> (string)

confirmationStatus -> (string)

The status of the intent after the user responds to the confirmation prompt. If the user confirms the intent, Amazon Lex sets this field to Confirmed . If the user denies the intent, Amazon Lex sets this value to Denied . The possible values are:

  • Confirmed - The user has responded "Yes" to the confirmation prompt, confirming that the intent is complete and that it is ready to be fulfilled.
  • Denied - The user has responded "No" to the confirmation prompt.
  • None - The user has never been prompted for confirmation; or, the user was prompted but did not confirm or deny the prompt.

dialogActionType -> (string)

The next action that the bot should take in its interaction with the user. The possible values are:

  • ConfirmIntent - The next action is asking the user if the intent is complete and ready to be fulfilled. This is a yes/no question such as "Place the order?"
  • Close - Indicates that the there will not be a response from the user. For example, the statement "Your order has been placed" does not require a response.
  • ElicitIntent - The next action is to determine the intent that the user wants to fulfill.
  • ElicitSlot - The next action is to elicit a slot value from the user.

fulfillmentState -> (string)

The fulfillment state of the intent. The possible values are:

  • Failed - The Lambda function associated with the intent failed to fulfill the intent.
  • Fulfilled - The intent has fulfilled by the Lambda function associated with the intent.
  • ReadyForFulfillment - All of the information necessary for the intent is present and the intent ready to be fulfilled by the client application.

slotToElicit -> (string)

The next slot to elicit from the user. If there is not slot to elicit, the field is blank.

sessionAttributes -> (map)

Map of key/value pairs representing the session-specific context information. It contains application information passed between Amazon Lex and a client application.

key -> (string)

value -> (string)

sessionId -> (string)

A unique identifier for the session.

dialogAction -> (structure)

Describes the current state of the bot.

type -> (string)

The next action that the bot should take in its interaction with the user. The possible values are:

  • ConfirmIntent - The next action is asking the user if the intent is complete and ready to be fulfilled. This is a yes/no question such as "Place the order?"
  • Close - Indicates that the there will not be a response from the user. For example, the statement "Your order has been placed" does not require a response.
  • Delegate - The next action is determined by Amazon Lex.
  • ElicitIntent - The next action is to determine the intent that the user wants to fulfill.
  • ElicitSlot - The next action is to elicit a slot value from the user.

intentName -> (string)

The name of the intent.

slots -> (map)

Map of the slots that have been gathered and their values.

key -> (string)

value -> (string)

slotToElicit -> (string)

The name of the slot that should be elicited from the user.

fulfillmentState -> (string)

The fulfillment state of the intent. The possible values are:

  • Failed - The Lambda function associated with the intent failed to fulfill the intent.
  • Fulfilled - The intent has fulfilled by the Lambda function associated with the intent.
  • ReadyForFulfillment - All of the information necessary for the intent is present and the intent ready to be fulfilled by the client application.

message -> (string)

The message that should be shown to the user. If you don't specify a message, Amazon Lex will use the message configured for the intent.

messageFormat -> (string)

  • PlainText - The message contains plain UTF-8 text.
  • CustomPayload - The message is a custom format for the client.
  • SSML - The message contains text formatted for voice output.
  • Composite - The message contains an escaped JSON object containing one or more messages. For more information, see Message Groups .