Interface ConnectParticipantClient
-
- All Superinterfaces:
AutoCloseable,AwsClient,SdkAutoCloseable,SdkClient
@Generated("software.amazon.awssdk:codegen") @ThreadSafe public interface ConnectParticipantClient extends AwsClient
Service client for accessing Amazon Connect Participant. This can be created using the staticbuilder()method.Amazon Connect is an easy-to-use omnichannel cloud contact center service that enables companies of any size to deliver superior customer service at a lower cost. Amazon Connect communications capabilities make it easy for companies to deliver personalized interactions across communication channels, including chat.
Use the Amazon Connect Participant Service to manage participants (for example, agents, customers, and managers listening in), and to send messages and events within a chat contact. The APIs in the service enable the following: sending chat messages, attachment sharing, managing a participant's connection state and message events, and retrieving chat transcripts.
-
-
Field Summary
Fields Modifier and Type Field Description static StringSERVICE_METADATA_IDValue for looking up the service's metadata from theServiceMetadataProvider.static StringSERVICE_NAME
-
Method Summary
All Methods Static Methods Instance Methods Default Methods Modifier and Type Method Description static ConnectParticipantClientBuilderbuilder()Create a builder that can be used to configure and create aConnectParticipantClient.default CompleteAttachmentUploadResponsecompleteAttachmentUpload(Consumer<CompleteAttachmentUploadRequest.Builder> completeAttachmentUploadRequest)Allows you to confirm that the attachment has been uploaded using the pre-signed URL provided in StartAttachmentUpload API.default CompleteAttachmentUploadResponsecompleteAttachmentUpload(CompleteAttachmentUploadRequest completeAttachmentUploadRequest)Allows you to confirm that the attachment has been uploaded using the pre-signed URL provided in StartAttachmentUpload API.static ConnectParticipantClientcreate()Create aConnectParticipantClientwith the region loaded from theDefaultAwsRegionProviderChainand credentials loaded from theDefaultCredentialsProvider.default CreateParticipantConnectionResponsecreateParticipantConnection(Consumer<CreateParticipantConnectionRequest.Builder> createParticipantConnectionRequest)Creates the participant's connection.default CreateParticipantConnectionResponsecreateParticipantConnection(CreateParticipantConnectionRequest createParticipantConnectionRequest)Creates the participant's connection.default DescribeViewResponsedescribeView(Consumer<DescribeViewRequest.Builder> describeViewRequest)Retrieves the view for the specified view token.default DescribeViewResponsedescribeView(DescribeViewRequest describeViewRequest)Retrieves the view for the specified view token.default DisconnectParticipantResponsedisconnectParticipant(Consumer<DisconnectParticipantRequest.Builder> disconnectParticipantRequest)Disconnects a participant.default DisconnectParticipantResponsedisconnectParticipant(DisconnectParticipantRequest disconnectParticipantRequest)Disconnects a participant.default GetAttachmentResponsegetAttachment(Consumer<GetAttachmentRequest.Builder> getAttachmentRequest)Provides a pre-signed URL for download of a completed attachment.default GetAttachmentResponsegetAttachment(GetAttachmentRequest getAttachmentRequest)Provides a pre-signed URL for download of a completed attachment.default GetTranscriptResponsegetTranscript(Consumer<GetTranscriptRequest.Builder> getTranscriptRequest)Retrieves a transcript of the session, including details about any attachments.default GetTranscriptResponsegetTranscript(GetTranscriptRequest getTranscriptRequest)Retrieves a transcript of the session, including details about any attachments.default GetTranscriptIterablegetTranscriptPaginator(Consumer<GetTranscriptRequest.Builder> getTranscriptRequest)Retrieves a transcript of the session, including details about any attachments.default GetTranscriptIterablegetTranscriptPaginator(GetTranscriptRequest getTranscriptRequest)Retrieves a transcript of the session, including details about any attachments.default SendEventResponsesendEvent(Consumer<SendEventRequest.Builder> sendEventRequest)Sends an event.default SendEventResponsesendEvent(SendEventRequest sendEventRequest)Sends an event.default SendMessageResponsesendMessage(Consumer<SendMessageRequest.Builder> sendMessageRequest)Sends a message.default SendMessageResponsesendMessage(SendMessageRequest sendMessageRequest)Sends a message.default ConnectParticipantServiceClientConfigurationserviceClientConfiguration()static ServiceMetadataserviceMetadata()default StartAttachmentUploadResponsestartAttachmentUpload(Consumer<StartAttachmentUploadRequest.Builder> startAttachmentUploadRequest)Provides a pre-signed Amazon S3 URL in response for uploading the file directly to S3.default StartAttachmentUploadResponsestartAttachmentUpload(StartAttachmentUploadRequest startAttachmentUploadRequest)Provides a pre-signed Amazon S3 URL in response for uploading the file directly to S3.-
Methods inherited from interface software.amazon.awssdk.utils.SdkAutoCloseable
close
-
Methods inherited from interface software.amazon.awssdk.core.SdkClient
serviceName
-
-
-
-
Field Detail
-
SERVICE_NAME
static final String SERVICE_NAME
- See Also:
- Constant Field Values
-
SERVICE_METADATA_ID
static final String SERVICE_METADATA_ID
Value for looking up the service's metadata from theServiceMetadataProvider.- See Also:
- Constant Field Values
-
-
Method Detail
-
completeAttachmentUpload
default CompleteAttachmentUploadResponse completeAttachmentUpload(CompleteAttachmentUploadRequest completeAttachmentUploadRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, ServiceQuotaExceededException, ConflictException, AwsServiceException, SdkClientException, ConnectParticipantException
Allows you to confirm that the attachment has been uploaded using the pre-signed URL provided in StartAttachmentUpload API.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
completeAttachmentUploadRequest-- Returns:
- Result of the CompleteAttachmentUpload operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.ServiceQuotaExceededException- The number of attachments per contact exceeds the quota.ConflictException- An attachment with that identifier is already being uploaded.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
completeAttachmentUpload
default CompleteAttachmentUploadResponse completeAttachmentUpload(Consumer<CompleteAttachmentUploadRequest.Builder> completeAttachmentUploadRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, ServiceQuotaExceededException, ConflictException, AwsServiceException, SdkClientException, ConnectParticipantException
Allows you to confirm that the attachment has been uploaded using the pre-signed URL provided in StartAttachmentUpload API.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
CompleteAttachmentUploadRequest.Builderavoiding the need to create one manually viaCompleteAttachmentUploadRequest.builder()- Parameters:
completeAttachmentUploadRequest- AConsumerthat will call methods onCompleteAttachmentUploadRequest.Builderto create a request.- Returns:
- Result of the CompleteAttachmentUpload operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.ServiceQuotaExceededException- The number of attachments per contact exceeds the quota.ConflictException- An attachment with that identifier is already being uploaded.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
createParticipantConnection
default CreateParticipantConnectionResponse createParticipantConnection(CreateParticipantConnectionRequest createParticipantConnectionRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Creates the participant's connection.
ParticipantTokenis used for invoking this API instead ofConnectionToken.The participant token is valid for the lifetime of the participant – until they are part of a contact.
The response URL for
WEBSOCKETType has a connect expiry timeout of 100s. Clients must manually connect to the returned websocket URL and subscribe to the desired topic.For chat, you need to publish the following on the established websocket connection:
{"topic":"aws/subscribe","content":{"topics":["aws/chat"]}}Upon websocket URL expiry, as specified in the response ConnectionExpiry parameter, clients need to call this API again to obtain a new websocket URL and perform the same steps as before.
Message streaming support: This API can also be used together with the StartContactStreaming API to create a participant connection for chat contacts that are not using a websocket. For more information about message streaming, Enable real-time chat message streaming in the Amazon Connect Administrator Guide.
Feature specifications: For information about feature specifications, such as the allowed number of open websocket connections per participant, see Feature specifications in the Amazon Connect Administrator Guide.
The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
createParticipantConnectionRequest-- Returns:
- Result of the CreateParticipantConnection operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
createParticipantConnection
default CreateParticipantConnectionResponse createParticipantConnection(Consumer<CreateParticipantConnectionRequest.Builder> createParticipantConnectionRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Creates the participant's connection.
ParticipantTokenis used for invoking this API instead ofConnectionToken.The participant token is valid for the lifetime of the participant – until they are part of a contact.
The response URL for
WEBSOCKETType has a connect expiry timeout of 100s. Clients must manually connect to the returned websocket URL and subscribe to the desired topic.For chat, you need to publish the following on the established websocket connection:
{"topic":"aws/subscribe","content":{"topics":["aws/chat"]}}Upon websocket URL expiry, as specified in the response ConnectionExpiry parameter, clients need to call this API again to obtain a new websocket URL and perform the same steps as before.
Message streaming support: This API can also be used together with the StartContactStreaming API to create a participant connection for chat contacts that are not using a websocket. For more information about message streaming, Enable real-time chat message streaming in the Amazon Connect Administrator Guide.
Feature specifications: For information about feature specifications, such as the allowed number of open websocket connections per participant, see Feature specifications in the Amazon Connect Administrator Guide.
The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
CreateParticipantConnectionRequest.Builderavoiding the need to create one manually viaCreateParticipantConnectionRequest.builder()- Parameters:
createParticipantConnectionRequest- AConsumerthat will call methods onCreateParticipantConnectionRequest.Builderto create a request.- Returns:
- Result of the CreateParticipantConnection operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
describeView
default DescribeViewResponse describeView(DescribeViewRequest describeViewRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ResourceNotFoundException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Retrieves the view for the specified view token.
- Parameters:
describeViewRequest-- Returns:
- Result of the DescribeView operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ResourceNotFoundException- The resource was not found.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
describeView
default DescribeViewResponse describeView(Consumer<DescribeViewRequest.Builder> describeViewRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ResourceNotFoundException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Retrieves the view for the specified view token.
This is a convenience which creates an instance of the
DescribeViewRequest.Builderavoiding the need to create one manually viaDescribeViewRequest.builder()- Parameters:
describeViewRequest- AConsumerthat will call methods onDescribeViewRequest.Builderto create a request.- Returns:
- Result of the DescribeView operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ResourceNotFoundException- The resource was not found.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
disconnectParticipant
default DisconnectParticipantResponse disconnectParticipant(DisconnectParticipantRequest disconnectParticipantRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Disconnects a participant.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
disconnectParticipantRequest-- Returns:
- Result of the DisconnectParticipant operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
disconnectParticipant
default DisconnectParticipantResponse disconnectParticipant(Consumer<DisconnectParticipantRequest.Builder> disconnectParticipantRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Disconnects a participant.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
DisconnectParticipantRequest.Builderavoiding the need to create one manually viaDisconnectParticipantRequest.builder()- Parameters:
disconnectParticipantRequest- AConsumerthat will call methods onDisconnectParticipantRequest.Builderto create a request.- Returns:
- Result of the DisconnectParticipant operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
getAttachment
default GetAttachmentResponse getAttachment(GetAttachmentRequest getAttachmentRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Provides a pre-signed URL for download of a completed attachment. This is an asynchronous API for use with active contacts.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
getAttachmentRequest-- Returns:
- Result of the GetAttachment operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
getAttachment
default GetAttachmentResponse getAttachment(Consumer<GetAttachmentRequest.Builder> getAttachmentRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Provides a pre-signed URL for download of a completed attachment. This is an asynchronous API for use with active contacts.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
GetAttachmentRequest.Builderavoiding the need to create one manually viaGetAttachmentRequest.builder()- Parameters:
getAttachmentRequest- AConsumerthat will call methods onGetAttachmentRequest.Builderto create a request.- Returns:
- Result of the GetAttachment operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
getTranscript
default GetTranscriptResponse getTranscript(GetTranscriptRequest getTranscriptRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Retrieves a transcript of the session, including details about any attachments. For information about accessing past chat contact transcripts for a persistent chat, see Enable persistent chat.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
getTranscriptRequest-- Returns:
- Result of the GetTranscript operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
getTranscript
default GetTranscriptResponse getTranscript(Consumer<GetTranscriptRequest.Builder> getTranscriptRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Retrieves a transcript of the session, including details about any attachments. For information about accessing past chat contact transcripts for a persistent chat, see Enable persistent chat.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
GetTranscriptRequest.Builderavoiding the need to create one manually viaGetTranscriptRequest.builder()- Parameters:
getTranscriptRequest- AConsumerthat will call methods onGetTranscriptRequest.Builderto create a request.- Returns:
- Result of the GetTranscript operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
getTranscriptPaginator
default GetTranscriptIterable getTranscriptPaginator(GetTranscriptRequest getTranscriptRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Retrieves a transcript of the session, including details about any attachments. For information about accessing past chat contact transcripts for a persistent chat, see Enable persistent chat.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a variant of
getTranscript(software.amazon.awssdk.services.connectparticipant.model.GetTranscriptRequest)operation. The return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle making service calls for you.When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response pages by making service calls until there are no pages left or your iteration stops. If there are errors in your request, you will see the failures only after you start iterating through the iterable.
The following are few ways to iterate through the response pages:
1) Using a Stream
2) Using For loopsoftware.amazon.awssdk.services.connectparticipant.paginators.GetTranscriptIterable responses = client.getTranscriptPaginator(request); responses.stream().forEach(....);{ @code software.amazon.awssdk.services.connectparticipant.paginators.GetTranscriptIterable responses = client .getTranscriptPaginator(request); for (software.amazon.awssdk.services.connectparticipant.model.GetTranscriptResponse response : responses) { // do something; } }3) Use iterator directlysoftware.amazon.awssdk.services.connectparticipant.paginators.GetTranscriptIterable responses = client.getTranscriptPaginator(request); responses.iterator().forEachRemaining(....);Please notice that the configuration of MaxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTranscript(software.amazon.awssdk.services.connectparticipant.model.GetTranscriptRequest)operation.- Parameters:
getTranscriptRequest-- Returns:
- A custom iterable that can be used to iterate through all the response pages.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
getTranscriptPaginator
default GetTranscriptIterable getTranscriptPaginator(Consumer<GetTranscriptRequest.Builder> getTranscriptRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Retrieves a transcript of the session, including details about any attachments. For information about accessing past chat contact transcripts for a persistent chat, see Enable persistent chat.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a variant of
getTranscript(software.amazon.awssdk.services.connectparticipant.model.GetTranscriptRequest)operation. The return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle making service calls for you.When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response pages by making service calls until there are no pages left or your iteration stops. If there are errors in your request, you will see the failures only after you start iterating through the iterable.
The following are few ways to iterate through the response pages:
1) Using a Stream
2) Using For loopsoftware.amazon.awssdk.services.connectparticipant.paginators.GetTranscriptIterable responses = client.getTranscriptPaginator(request); responses.stream().forEach(....);{ @code software.amazon.awssdk.services.connectparticipant.paginators.GetTranscriptIterable responses = client .getTranscriptPaginator(request); for (software.amazon.awssdk.services.connectparticipant.model.GetTranscriptResponse response : responses) { // do something; } }3) Use iterator directlysoftware.amazon.awssdk.services.connectparticipant.paginators.GetTranscriptIterable responses = client.getTranscriptPaginator(request); responses.iterator().forEachRemaining(....);Please notice that the configuration of MaxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTranscript(software.amazon.awssdk.services.connectparticipant.model.GetTranscriptRequest)operation.This is a convenience which creates an instance of the
GetTranscriptRequest.Builderavoiding the need to create one manually viaGetTranscriptRequest.builder()- Parameters:
getTranscriptRequest- AConsumerthat will call methods onGetTranscriptRequest.Builderto create a request.- Returns:
- A custom iterable that can be used to iterate through all the response pages.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
sendEvent
default SendEventResponse sendEvent(SendEventRequest sendEventRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Sends an event.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
sendEventRequest-- Returns:
- Result of the SendEvent operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
sendEvent
default SendEventResponse sendEvent(Consumer<SendEventRequest.Builder> sendEventRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Sends an event.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
SendEventRequest.Builderavoiding the need to create one manually viaSendEventRequest.builder()- Parameters:
sendEventRequest- AConsumerthat will call methods onSendEventRequest.Builderto create a request.- Returns:
- Result of the SendEvent operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
sendMessage
default SendMessageResponse sendMessage(SendMessageRequest sendMessageRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Sends a message.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
sendMessageRequest-- Returns:
- Result of the SendMessage operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
sendMessage
default SendMessageResponse sendMessage(Consumer<SendMessageRequest.Builder> sendMessageRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, AwsServiceException, SdkClientException, ConnectParticipantException
Sends a message.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
SendMessageRequest.Builderavoiding the need to create one manually viaSendMessageRequest.builder()- Parameters:
sendMessageRequest- AConsumerthat will call methods onSendMessageRequest.Builderto create a request.- Returns:
- Result of the SendMessage operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
startAttachmentUpload
default StartAttachmentUploadResponse startAttachmentUpload(StartAttachmentUploadRequest startAttachmentUploadRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, ServiceQuotaExceededException, AwsServiceException, SdkClientException, ConnectParticipantException
Provides a pre-signed Amazon S3 URL in response for uploading the file directly to S3.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
- Parameters:
startAttachmentUploadRequest-- Returns:
- Result of the StartAttachmentUpload operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.ServiceQuotaExceededException- The number of attachments per contact exceeds the quota.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
startAttachmentUpload
default StartAttachmentUploadResponse startAttachmentUpload(Consumer<StartAttachmentUploadRequest.Builder> startAttachmentUploadRequest) throws AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, ServiceQuotaExceededException, AwsServiceException, SdkClientException, ConnectParticipantException
Provides a pre-signed Amazon S3 URL in response for uploading the file directly to S3.
ConnectionTokenis used for invoking this API instead ofParticipantToken.The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
This is a convenience which creates an instance of the
StartAttachmentUploadRequest.Builderavoiding the need to create one manually viaStartAttachmentUploadRequest.builder()- Parameters:
startAttachmentUploadRequest- AConsumerthat will call methods onStartAttachmentUploadRequest.Builderto create a request.- Returns:
- Result of the StartAttachmentUpload operation returned by the service.
- Throws:
AccessDeniedException- You do not have sufficient access to perform this action.InternalServerException- This exception occurs when there is an internal failure in the Amazon Connect service.ThrottlingException- The request was denied due to request throttling.ValidationException- The input fails to satisfy the constraints specified by Amazon Connect.ServiceQuotaExceededException- The number of attachments per contact exceeds the quota.SdkException- Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.SdkClientException- If any client side error occurs such as an IO related failure, failure to get credentials, etc.ConnectParticipantException- Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.AwsServiceException- See Also:
- AWS API Documentation
-
create
static ConnectParticipantClient create()
Create aConnectParticipantClientwith the region loaded from theDefaultAwsRegionProviderChainand credentials loaded from theDefaultCredentialsProvider.
-
builder
static ConnectParticipantClientBuilder builder()
Create a builder that can be used to configure and create aConnectParticipantClient.
-
serviceMetadata
static ServiceMetadata serviceMetadata()
-
serviceClientConfiguration
default ConnectParticipantServiceClientConfiguration serviceClientConfiguration()
- Specified by:
serviceClientConfigurationin interfaceAwsClient- Specified by:
serviceClientConfigurationin interfaceSdkClient
-
-