/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the runtime.lex-2016-11-28.normal.json service model. */ using System; using System.Collections.Generic; using System.Xml.Serialization; using System.Text; using System.IO; using System.Net; using Amazon.Runtime; using Amazon.Runtime.Internal; namespace Amazon.Lex.Model { /// /// Container for the parameters to the PutSession operation. /// Creates a new session or modifies an existing session with an Amazon Lex bot. Use /// this operation to enable your application to set the state of the bot. /// /// /// /// For more information, see Managing /// Sessions. /// /// public partial class PutSessionRequest : AmazonLexRequest { private string _accept; private List _activeContexts = new List(); private string _botAlias; private string _botName; private DialogAction _dialogAction; private List _recentIntentSummaryView = new List(); private Dictionary _sessionAttributes = new Dictionary(); private string _userId; /// /// Gets and sets the property Accept. /// /// The message that Amazon Lex returns in the response can be either text or speech based /// depending on the value of this field. /// ///
  • /// /// If the value is text/plain; charset=utf-8, Amazon Lex returns text in /// the response. /// ///
  • /// /// If the value begins with audio/, Amazon Lex returns speech in the response. /// Amazon Lex uses Amazon Polly to generate the speech in the configuration that you /// specify. For example, if you specify audio/mpeg as the value, Amazon /// Lex returns speech in the MPEG format. /// ///
  • /// /// If the value is audio/pcm, the speech is returned as audio/pcm /// in 16-bit, little endian format. /// ///
  • /// /// The following are the accepted values: /// ///
    • /// /// audio/mpeg /// ///
    • /// /// audio/ogg /// ///
    • /// /// audio/pcm /// ///
    • /// /// audio/* (defaults to mpeg) /// ///
    • /// /// text/plain; charset=utf-8 /// ///
///
public string Accept { get { return this._accept; } set { this._accept = value; } } // Check to see if Accept property is set internal bool IsSetAccept() { return this._accept != null; } /// /// Gets and sets the property ActiveContexts. /// /// A list of contexts active for the request. A context can be activated when a previous /// intent is fulfilled, or by including the context in the request, /// /// /// /// If you don't specify a list of contexts, Amazon Lex will use the current list of contexts /// for the session. If you specify an empty list, all contexts for the session are cleared. /// /// [AWSProperty(Sensitive=true, Min=0, Max=20)] public List ActiveContexts { get { return this._activeContexts; } set { this._activeContexts = value; } } // Check to see if ActiveContexts property is set internal bool IsSetActiveContexts() { return this._activeContexts != null && this._activeContexts.Count > 0; } /// /// Gets and sets the property BotAlias. /// /// The alias in use for the bot that contains the session data. /// /// [AWSProperty(Required=true)] public string BotAlias { get { return this._botAlias; } set { this._botAlias = value; } } // Check to see if BotAlias property is set internal bool IsSetBotAlias() { return this._botAlias != null; } /// /// Gets and sets the property BotName. /// /// The name of the bot that contains the session data. /// /// [AWSProperty(Required=true)] public string BotName { get { return this._botName; } set { this._botName = value; } } // Check to see if BotName property is set internal bool IsSetBotName() { return this._botName != null; } /// /// Gets and sets the property DialogAction. /// /// Sets the next action that the bot should take to fulfill the conversation. /// /// public DialogAction DialogAction { get { return this._dialogAction; } set { this._dialogAction = value; } } // Check to see if DialogAction property is set internal bool IsSetDialogAction() { return this._dialogAction != null; } /// /// Gets and sets the property RecentIntentSummaryView. /// /// A summary of the recent intents for the bot. You can use the intent summary view to /// set a checkpoint label on an intent and modify attributes of intents. You can also /// use it to remove or add intent summary objects to the list. /// /// /// /// An intent that you modify or add to the list must make sense for the bot. For example, /// the intent name must be valid for the bot. You must provide valid values for: /// ///
  • /// /// intentName /// ///
  • /// /// slot names /// ///
  • /// /// slotToElict /// ///
/// /// If you send the recentIntentSummaryView parameter in a PutSession /// request, the contents of the new summary view replaces the old summary view. For example, /// if a GetSession request returns three intents in the summary view and /// you call PutSession with one intent in the summary view, the next call /// to GetSession will only return one intent. /// ///
[AWSProperty(Min=0, Max=3)] public List RecentIntentSummaryView { get { return this._recentIntentSummaryView; } set { this._recentIntentSummaryView = value; } } // Check to see if RecentIntentSummaryView property is set internal bool IsSetRecentIntentSummaryView() { return this._recentIntentSummaryView != null && this._recentIntentSummaryView.Count > 0; } /// /// Gets and sets the property SessionAttributes. /// /// Map of key/value pairs representing the session-specific context information. It contains /// application information passed between Amazon Lex and a client application. /// /// [AWSProperty(Sensitive=true)] public Dictionary SessionAttributes { get { return this._sessionAttributes; } set { this._sessionAttributes = value; } } // Check to see if SessionAttributes property is set internal bool IsSetSessionAttributes() { return this._sessionAttributes != null && this._sessionAttributes.Count > 0; } /// /// Gets and sets the property UserId. /// /// The ID of the client application user. Amazon Lex uses this to identify a user's conversation /// with your bot. /// /// [AWSProperty(Required=true, Min=2, Max=100)] public string UserId { get { return this._userId; } set { this._userId = value; } } // Check to see if UserId property is set internal bool IsSetUserId() { return this._userId != null; } } }