/*
* 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 connect-contact-lens-2020-08-21.normal.json service model.
*/
using System;
using System.Runtime.ExceptionServices;
using System.Threading;
using System.Threading.Tasks;
using System.Collections.Generic;
using System.Net;
using Amazon.ConnectContactLens.Model;
using Amazon.ConnectContactLens.Model.Internal.MarshallTransformations;
using Amazon.ConnectContactLens.Internal;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
using Amazon.Runtime.Internal.Auth;
using Amazon.Runtime.Internal.Transform;
namespace Amazon.ConnectContactLens
{
///
/// Implementation for accessing ConnectContactLens
///
/// Contact Lens for Amazon Connect enables you to analyze conversations between customer
/// and agents, by using speech transcription, natural language processing, and intelligent
/// search capabilities. It performs sentiment analysis, detects issues, and enables you
/// to automatically categorize contacts.
///
///
///
/// Contact Lens for Amazon Connect provides both real-time and post-call analytics of
/// customer-agent conversations. For more information, see Analyze
/// conversations using Contact Lens in the Amazon Connect Administrator Guide.
///
///
///
public partial class AmazonConnectContactLensClient : AmazonServiceClient, IAmazonConnectContactLens
{
private static IServiceMetadata serviceMetadata = new AmazonConnectContactLensMetadata();
private IConnectContactLensPaginatorFactory _paginators;
///
/// Paginators for the service
///
public IConnectContactLensPaginatorFactory Paginators
{
get
{
if (this._paginators == null)
{
this._paginators = new ConnectContactLensPaginatorFactory(this);
}
return this._paginators;
}
}
#region Constructors
///
/// Constructs AmazonConnectContactLensClient with the credentials loaded from the application's
/// default configuration, and if unsuccessful from the Instance Profile service on an EC2 instance.
///
/// Example App.config with credentials set.
///
/// <?xml version="1.0" encoding="utf-8" ?>
/// <configuration>
/// <appSettings>
/// <add key="AWSProfileName" value="AWS Default"/>
/// </appSettings>
/// </configuration>
///
///
///
public AmazonConnectContactLensClient()
: base(FallbackCredentialsFactory.GetCredentials(), new AmazonConnectContactLensConfig()) { }
///
/// Constructs AmazonConnectContactLensClient with the credentials loaded from the application's
/// default configuration, and if unsuccessful from the Instance Profile service on an EC2 instance.
///
/// Example App.config with credentials set.
///
/// <?xml version="1.0" encoding="utf-8" ?>
/// <configuration>
/// <appSettings>
/// <add key="AWSProfileName" value="AWS Default"/>
/// </appSettings>
/// </configuration>
///
///
///
/// The region to connect.
public AmazonConnectContactLensClient(RegionEndpoint region)
: base(FallbackCredentialsFactory.GetCredentials(), new AmazonConnectContactLensConfig{RegionEndpoint = region}) { }
///
/// Constructs AmazonConnectContactLensClient with the credentials loaded from the application's
/// default configuration, and if unsuccessful from the Instance Profile service on an EC2 instance.
///
/// Example App.config with credentials set.
///
/// <?xml version="1.0" encoding="utf-8" ?>
/// <configuration>
/// <appSettings>
/// <add key="AWSProfileName" value="AWS Default"/>
/// </appSettings>
/// </configuration>
///
///
///
/// The AmazonConnectContactLensClient Configuration Object
public AmazonConnectContactLensClient(AmazonConnectContactLensConfig config)
: base(FallbackCredentialsFactory.GetCredentials(config), config){}
///
/// Constructs AmazonConnectContactLensClient with AWS Credentials
///
/// AWS Credentials
public AmazonConnectContactLensClient(AWSCredentials credentials)
: this(credentials, new AmazonConnectContactLensConfig())
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Credentials
///
/// AWS Credentials
/// The region to connect.
public AmazonConnectContactLensClient(AWSCredentials credentials, RegionEndpoint region)
: this(credentials, new AmazonConnectContactLensConfig{RegionEndpoint = region})
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Credentials and an
/// AmazonConnectContactLensClient Configuration object.
///
/// AWS Credentials
/// The AmazonConnectContactLensClient Configuration Object
public AmazonConnectContactLensClient(AWSCredentials credentials, AmazonConnectContactLensConfig clientConfig)
: base(credentials, clientConfig)
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
public AmazonConnectContactLensClient(string awsAccessKeyId, string awsSecretAccessKey)
: this(awsAccessKeyId, awsSecretAccessKey, new AmazonConnectContactLensConfig())
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// The region to connect.
public AmazonConnectContactLensClient(string awsAccessKeyId, string awsSecretAccessKey, RegionEndpoint region)
: this(awsAccessKeyId, awsSecretAccessKey, new AmazonConnectContactLensConfig() {RegionEndpoint=region})
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Access Key ID, AWS Secret Key and an
/// AmazonConnectContactLensClient Configuration object.
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// The AmazonConnectContactLensClient Configuration Object
public AmazonConnectContactLensClient(string awsAccessKeyId, string awsSecretAccessKey, AmazonConnectContactLensConfig clientConfig)
: base(awsAccessKeyId, awsSecretAccessKey, clientConfig)
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// AWS Session Token
public AmazonConnectContactLensClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken)
: this(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, new AmazonConnectContactLensConfig())
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// AWS Session Token
/// The region to connect.
public AmazonConnectContactLensClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken, RegionEndpoint region)
: this(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, new AmazonConnectContactLensConfig{RegionEndpoint = region})
{
}
///
/// Constructs AmazonConnectContactLensClient with AWS Access Key ID, AWS Secret Key and an
/// AmazonConnectContactLensClient Configuration object.
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// AWS Session Token
/// The AmazonConnectContactLensClient Configuration Object
public AmazonConnectContactLensClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken, AmazonConnectContactLensConfig clientConfig)
: base(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, clientConfig)
{
}
#endregion
#region Overrides
///
/// Creates the signer for the service.
///
protected override AbstractAWSSigner CreateSigner()
{
return new AWS4Signer();
}
///
/// Customize the pipeline
///
///
protected override void CustomizeRuntimePipeline(RuntimePipeline pipeline)
{
pipeline.RemoveHandler();
pipeline.AddHandlerAfter(new AmazonConnectContactLensEndpointResolver());
}
///
/// Capture metadata for the service.
///
protected override IServiceMetadata ServiceMetadata
{
get
{
return serviceMetadata;
}
}
#endregion
#region Dispose
///
/// Disposes the service client.
///
protected override void Dispose(bool disposing)
{
base.Dispose(disposing);
}
#endregion
#region ListRealtimeContactAnalysisSegments
///
/// Provides a list of analysis segments for a real-time analysis session.
///
/// Container for the necessary parameters to execute the ListRealtimeContactAnalysisSegments service method.
///
/// The response from the ListRealtimeContactAnalysisSegments service method, as returned by ConnectContactLens.
///
/// You do not have sufficient access to perform this action.
///
///
/// Request processing failed due to an error or failure with the service.
///
///
/// The request is not valid.
///
///
/// The specified resource was not found.
///
///
/// The throttling limit has been exceeded.
///
/// REST API Reference for ListRealtimeContactAnalysisSegments Operation
public virtual ListRealtimeContactAnalysisSegmentsResponse ListRealtimeContactAnalysisSegments(ListRealtimeContactAnalysisSegmentsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListRealtimeContactAnalysisSegmentsRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListRealtimeContactAnalysisSegmentsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Provides a list of analysis segments for a real-time analysis session.
///
/// Container for the necessary parameters to execute the ListRealtimeContactAnalysisSegments service method.
///
/// A cancellation token that can be used by other objects or threads to receive notice of cancellation.
///
///
/// The response from the ListRealtimeContactAnalysisSegments service method, as returned by ConnectContactLens.
///
/// You do not have sufficient access to perform this action.
///
///
/// Request processing failed due to an error or failure with the service.
///
///
/// The request is not valid.
///
///
/// The specified resource was not found.
///
///
/// The throttling limit has been exceeded.
///
/// REST API Reference for ListRealtimeContactAnalysisSegments Operation
public virtual Task ListRealtimeContactAnalysisSegmentsAsync(ListRealtimeContactAnalysisSegmentsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
{
var options = new InvokeOptions();
options.RequestMarshaller = ListRealtimeContactAnalysisSegmentsRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListRealtimeContactAnalysisSegmentsResponseUnmarshaller.Instance;
return InvokeAsync(request, options, cancellationToken);
}
#endregion
}
}