EvaluateSession - Amazon Connect

EvaluateSession

Evaluates a specified session based on audio data accumulated during a streaming Amazon Connect Voice ID call.

Request Syntax

{ "DomainId": "string", "SessionNameOrId": "string" }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

DomainId

The identifier of the domain where the session started.

Type: String

Length Constraints: Fixed length of 22.

Pattern: ^[a-zA-Z0-9]{22}$

Required: Yes

SessionNameOrId

The session identifier, or name of the session, that you want to evaluate. In Voice ID integration, this is the Contact-Id.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 36.

Pattern: ^(id#[a-zA-Z0-9]{22}|[a-zA-Z0-9][a-zA-Z0-9_-]*)$

Required: Yes

Response Syntax

{ "AuthenticationResult": { "AudioAggregationEndedAt": number, "AudioAggregationStartedAt": number, "AuthenticationResultId": "string", "Configuration": { "AcceptanceThreshold": number }, "CustomerSpeakerId": "string", "Decision": "string", "GeneratedSpeakerId": "string", "Score": number }, "DomainId": "string", "FraudDetectionResult": { "AudioAggregationEndedAt": number, "AudioAggregationStartedAt": number, "Configuration": { "RiskThreshold": number, "WatchlistId": "string" }, "Decision": "string", "FraudDetectionResultId": "string", "Reasons": [ "string" ], "RiskDetails": { "KnownFraudsterRisk": { "GeneratedFraudsterId": "string", "RiskScore": number }, "VoiceSpoofingRisk": { "RiskScore": number } } }, "SessionId": "string", "SessionName": "string", "StreamingStatus": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

AuthenticationResult

Details resulting from the authentication process, such as authentication decision and authentication score.

Type: AuthenticationResult object

DomainId

The identifier of the domain that contains the session.

Type: String

Length Constraints: Fixed length of 22.

Pattern: ^[a-zA-Z0-9]{22}$

FraudDetectionResult

Details resulting from the fraud detection process, such as fraud detection decision and risk score.

Type: FraudDetectionResult object

SessionId

The service-generated identifier of the session.

Type: String

Length Constraints: Fixed length of 25.

Pattern: ^id#[a-zA-Z0-9]{22}$

SessionName

The client-provided name of the session.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 36.

Pattern: ^[a-zA-Z0-9][a-zA-Z0-9_-]*$

StreamingStatus

The current status of audio streaming for this session. This field is useful to infer next steps when the Authentication or Fraud Detection results are empty or the decision is NOT_ENOUGH_SPEECH. In this situation, if the StreamingStatus is ONGOING/PENDING_CONFIGURATION, it can mean that the client should call the API again later, after Voice ID has enough audio to produce a result. If the decision remains NOT_ENOUGH_SPEECH even after StreamingStatus is ENDED, it means that the previously streamed session did not have enough speech to perform evaluation, and a new streaming session is needed to try again.

Type: String

Valid Values: PENDING_CONFIGURATION | ONGOING | ENDED

Errors

For information about the errors that are common to all actions, see Common Errors.

AccessDeniedException

You do not have sufficient permissions to perform this action. Check the error message and try again.

HTTP Status Code: 400

ConflictException

The request failed due to a conflict. Check the ConflictType and error message for more details.

HTTP Status Code: 400

InternalServerException

The request failed due to an unknown error on the server side.

HTTP Status Code: 500

ResourceNotFoundException

The specified resource cannot be found. Check the ResourceType and error message for more details.

HTTP Status Code: 400

ThrottlingException

The request was denied due to request throttling. Please slow down your request rate. Refer to Amazon Connect Voice ID Service API throttling quotas and try your request again.

HTTP Status Code: 400

ValidationException

The request failed one or more validations; check the error message for more details.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: