using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace ProxyTunnel.Models
{
    public class ExternalIntegrationBotExchangeRequest
    {
        /// <summary>
        /// Name of Business Unit's bot to identify the registered bot being invoked.
        /// This name should be unique to the Business Unit
        /// </summary>
        public string virtualAgentId { get; set; }

        /// <summary>
        /// Configuration object registered with the bot being invoked
        /// </summary>
        public dynamic botConfig { get; set; }

        /// <summary>
        /// Input from a user instigating a bot interaction.  This may be sourced from a chat client, transcribed from audio input or DTMF, or input from other other media types.
        /// 
        /// Depending on 'userInputType', this value may be automated to have specific values for known Use Cases, several of which are REQUIRED to be handled
        /// (see required Use Cases)
        /// </summary>
        /// <example>Men's basketball shoes</example>
        public string userInput { get; set; }

        /// <summary>
        /// Specifies the type of 'userInput'.  It can be either:
        /// •TEXT (transcribed audio or user entered chat text in the 'userInput' field.) 
        /// •DTMF_AS_TEXT (Numeric string as entered from touch tones from a phone.  For example '4678')
        /// •NO_INPUT - No response was collected from the user
        /// --If 'userInput' has a value of 'SILENCE', then a timeout occurred without the user providing any input. The bot response may be something like 'Are you still there?'        
        /// •USER_ENDED_SESSION - The user ended the bot session (hung up the phone, closed chat window, etc).  IMPORTANT NOTE--All bot providers MUST implement session timeouts and NOT rely on this event to clean up resources
        /// •AUTOMATED_TEXT - 'userInput' specifies the desired Intent by a label.  The BotResponse should include an appropriate response
        /// --If 'userInput' has a value of 'WELCOME', the BotResponse should be an appropriate initial message for a new session.  Something like 'Thanks for contacting us!  How can I help you?'  (REQUIRED USE CASE!)
        /// •BASE64_ENCODED_G711_ULAW_WAV_FILE (this only happens if the registered bot specifies that it wants raw audio input (rather than inContact providing transcription)
        /// --This is an entire utterance audio file---(including the WAV header!!!).  This will be G.711 U-law 8 kHz 8 bit Mono.
        /// </summary>
        public UserInputType userInputType { get; set; }

        /// <summary>
        /// Telemetry and debug information.  This object provides Business Unit identifier, contactId (unique session identifier), and details about script execution.
        /// If nothing else, please log this data as it will be useful to inContact support trying to troubleshoot
        /// </summary>
        public ActionExecutionInfo executionInfo { get; set; }

        /// <summary>
        /// Data that may be useful for debugging, and/or telemetry data(billing, usage reports, etc).
        /// This is debug data that is NOT tied to an inContact script action, but related to behind-the-scenes infrastructures
        /// If nothing else, please log this data as it will be useful to inContact support trying to troubleshoot
        /// </summary>
        public SystemTelemetryData systemTelemetryData { get; set; }

        //
        // Summary:
        //     Base64 encoded audio populated by MediaServer with RestPrompt action. When present,
        //     this will be mono g711 ulaw 8bit 8khz including wav header.
        public string base64wavFile { get; set; }

        public object botSessionState { get; set; }
        public object customPayload { get; set; }
        public string mediaType { get; set; }
    }
}
