2026/08/24 - Amazon Connect Contact Lens - 1 updated api methods
Changes This release adds the ExtractedInformation segment to the ListRealtimeContactAnalysisSegmentsV2 API, enabling customers to retrieve information extracted from real-time contact analysis.
{'Segments': {'ExtractedInformation': {'ExtractedValues': [{'Content': 'string',
'PointsOfInterest': [{'BeginOffsetMillis': 'integer',
'EndOffsetMillis': 'integer'}]}],
'ExtractionDefinitionDisplayLabel': 'string',
'ExtractionDefinitionId': 'string',
'ExtractionDefinitionName': 'string',
'FailureCode': 'QUOTA_EXCEEDED | '
'INSUFFICIENT_CONVERSATION_CONTENT '
'| '
'FAILED_SAFETY_GUIDELINES '
'| INTERNAL_ERROR | '
'MAX_PACKAGE_FEATURE_ONLY'}}}
Provides a list of analysis segments for a real-time analysis session for voice.
See also: AWS API Documentation
Request Syntax
client.list_realtime_contact_analysis_segments(
InstanceId='string',
ContactId='string',
MaxResults=123,
NextToken='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the contact.
integer
The maximum number of results to return per page.
string
The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
dict
Response Syntax
{
'Segments': [
{
'Transcript': {
'Id': 'string',
'ParticipantId': 'string',
'ParticipantRole': 'string',
'Content': 'string',
'BeginOffsetMillis': 123,
'EndOffsetMillis': 123,
'Sentiment': 'POSITIVE'|'NEUTRAL'|'NEGATIVE',
'IssuesDetected': [
{
'CharacterOffsets': {
'BeginOffsetChar': 123,
'EndOffsetChar': 123
}
},
]
},
'Categories': {
'MatchedCategories': [
'string',
],
'MatchedDetails': {
'string': {
'PointsOfInterest': [
{
'BeginOffsetMillis': 123,
'EndOffsetMillis': 123
},
]
}
}
},
'PostContactSummary': {
'Content': 'string',
'Status': 'FAILED'|'COMPLETED',
'FailureCode': 'QUOTA_EXCEEDED'|'INSUFFICIENT_CONVERSATION_CONTENT'|'FAILED_SAFETY_GUIDELINES'|'INVALID_ANALYSIS_CONFIGURATION'|'INTERNAL_ERROR'
},
'ExtractedInformation': {
'ExtractionDefinitionId': 'string',
'ExtractionDefinitionName': 'string',
'ExtractionDefinitionDisplayLabel': 'string',
'ExtractedValues': [
{
'Content': 'string',
'PointsOfInterest': [
{
'BeginOffsetMillis': 123,
'EndOffsetMillis': 123
},
]
},
],
'FailureCode': 'QUOTA_EXCEEDED'|'INSUFFICIENT_CONVERSATION_CONTENT'|'FAILED_SAFETY_GUIDELINES'|'INTERNAL_ERROR'|'MAX_PACKAGE_FEATURE_ONLY'
}
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
Segments (list) --
An analyzed transcript or category.
(dict) --
An analyzed segment for a real-time analysis session.
Transcript (dict) --
The analyzed transcript.
Id (string) --
The identifier of the transcript.
ParticipantId (string) --
The identifier of the participant. Valid values are CUSTOMER or AGENT.
ParticipantRole (string) --
The role of participant. For example, is it a customer, agent, or system.
Content (string) --
The content of the transcript.
BeginOffsetMillis (integer) --
The beginning offset in the contact for this transcript.
EndOffsetMillis (integer) --
The end offset in the contact for this transcript.
Sentiment (string) --
The sentiment detected for this piece of transcript.
IssuesDetected (list) --
List of positions where issues were detected on the transcript.
(dict) --
Potential issues that are detected based on an artificial intelligence analysis of each turn in the conversation.
CharacterOffsets (dict) --
The offset for when the issue was detected in the segment.
BeginOffsetChar (integer) --
The beginning of the issue.
EndOffsetChar (integer) --
The end of the issue.
Categories (dict) --
The matched category rules.
MatchedCategories (list) --
The category rules that have been matched in the analyzed segment.
(string) --
MatchedDetails (dict) --
The category rule that was matched and when it occurred in the transcript.
(string) --
(dict) --
Provides information about the category rule that was matched.
PointsOfInterest (list) --
The section of audio where the category rule was detected.
(dict) --
The section of the contact audio where a match was detected.
BeginOffsetMillis (integer) --
The beginning offset (in milliseconds) where the match was detected.
EndOffsetMillis (integer) --
The ending offset (in milliseconds) where the match was detected.
PostContactSummary (dict) --
Information about the post-contact summary.
Content (string) --
The content of the summary.
Status (string) --
Whether the summary was successfully COMPLETED or FAILED to be generated.
FailureCode (string) --
If the summary failed to be generated, one of the following failure codes occurs:
QUOTA_EXCEEDED: The number of concurrent analytics jobs reached your service quota.
INSUFFICIENT_CONVERSATION_CONTENT: The conversation needs to have at least one turn from both the participants in order to generate the summary.
FAILED_SAFETY_GUIDELINES: The generated summary cannot be provided because it failed to meet system safety guidelines.
INVALID_ANALYSIS_CONFIGURATION: This code occurs when, for example, you're using a language that isn't supported by generative AI-powered post-contact summaries.
INTERNAL_ERROR: Internal system error.
ExtractedInformation (dict) --
The extracted information from the conversation.
ExtractionDefinitionId (string) --
The identifier of the extraction definition that produced this result.
ExtractionDefinitionName (string) --
The name of the extraction definition that produced this result.
ExtractionDefinitionDisplayLabel (string) --
The display label of the extraction definition that produced this result.
ExtractedValues (list) --
The list of values extracted from the conversation for this extraction definition. This field is empty when a FailureCode is present.
(dict) --
An individual value extracted from the conversation, including its content and the locations where it was found.
Content (string) --
The text content of the extracted value.
PointsOfInterest (list) --
The sections in the conversation that indicate where the extracted value was found.
(dict) --
The section of the contact audio where a match was detected.
BeginOffsetMillis (integer) --
The beginning offset (in milliseconds) where the match was detected.
EndOffsetMillis (integer) --
The ending offset (in milliseconds) where the match was detected.
FailureCode (string) --
If the information failed to be extracted, one of the following failure codes occurs:
QUOTA_EXCEEDED: The number of concurrent analytics jobs reached your service quota.
INSUFFICIENT_CONVERSATION_CONTENT: Information extraction requires a conversation with at least one turn from each participant.
FAILED_SAFETY_GUIDELINES: The extracted information cannot be provided because it failed to meet system safety guidelines.
INTERNAL_ERROR: Internal system error.
MAX_PACKAGE_FEATURE_ONLY: Information extraction is only available in Amazon Connect Customer instances.
NextToken (string) --
If there are additional results, this is the token for the next set of results. If response includes nextToken there are two possible scenarios:
There are more segments so another call is required to get them.
There are no more segments at this time, but more may be available later (real-time analysis is in progress) so the client should call the operation again to get new segments.
If response does not include nextToken, the analysis is completed (successfully or failed) and there are no more segments to retrieve.