2026/01/23 - Amazon Connect Service - 11 new api methods
Changes Amazon Connect now offers public APIs to programmatically configure and run automated tests for contact center experiences. Integrate testing into CICD pipelines, run multiple tests at scale, and retrieve results via API to automate validation of voice interactions and workflows.
Starts executing a published test case.
See also: AWS API Documentation
Request Syntax
client.start_test_case_execution(
InstanceId='string',
TestCaseId='string',
ClientToken='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case to execute.
string
A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.
dict
Response Syntax
{
'TestCaseExecutionId': 'string',
'TestCaseId': 'string',
'Status': 'INITIATED'|'PASSED'|'FAILED'|'IN_PROGRESS'|'STOPPED'
}
Response Structure
(dict) --
TestCaseExecutionId (string) --
The identifier of the test case execution.
TestCaseId (string) --
The identifier of the test case resource that was executed.
Status (string) --
The status of a test case execution.
Deletes the test case that has already been created for the specified Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.delete_test_case(
InstanceId='string',
TestCaseId='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case to delete.
dict
Response Syntax
{}
Response Structure
(dict) --
Retrieves an overview of a test execution that includes the status of the execution, start and end time, and observation summary.
See also: AWS API Documentation
Request Syntax
client.get_test_case_execution_summary(
InstanceId='string',
TestCaseId='string',
TestCaseExecutionId='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case.
string
[REQUIRED]
The identifier of the test case execution.
dict
Response Syntax
{
'StartTime': datetime(2015, 1, 1),
'EndTime': datetime(2015, 1, 1),
'Status': 'INITIATED'|'PASSED'|'FAILED'|'IN_PROGRESS'|'STOPPED',
'ObservationSummary': {
'TotalObservations': 123,
'ObservationsPassed': 123,
'ObservationsFailed': 123
}
}
Response Structure
(dict) --
StartTime (datetime) --
The timestamp when the test case execution started.
EndTime (datetime) --
The timestamp when the test case execution ended.
Status (string) --
The status of the test case execution.
ObservationSummary (dict) --
Summary statistics for the test case execution.
TotalObservations (integer) --
The total number of observations in the test case.
ObservationsPassed (integer) --
The number of observations that passed during execution.
ObservationsFailed (integer) --
The number of observations that failed during execution.
Lists detailed steps of test case execution that includes all observations along with actions taken and data associated in the specified Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.list_test_case_execution_records(
InstanceId='string',
TestCaseId='string',
TestCaseExecutionId='string',
Status='INITIATED'|'PASSED'|'FAILED'|'IN_PROGRESS'|'STOPPED',
NextToken='string',
MaxResults=123
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case.
string
[REQUIRED]
The identifier of the test case execution.
string
Filter execution records by status.
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.
integer
The maximum number of results to return per page.
dict
Response Syntax
{
'ExecutionRecords': [
{
'ObservationId': 'string',
'Status': 'PASSED'|'FAILED'|'IN_PROGRESS'|'STOPPED',
'Timestamp': datetime(2015, 1, 1),
'Record': 'string'
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
ExecutionRecords (list) --
An array of test case execution record objects.
(dict) --
Contains information about a test case execution record.
ObservationId (string) --
The identifier of the execution record.
Status (string) --
The status of the action execution.
Timestamp (datetime) --
The timestamp when the action was executed.
Record (string) --
The details of the executed record.
NextToken (string) --
If there are additional results, this is the token for the next set of results.
Updates any of the metadata for a test case, such as the name, description, and status or content of an existing test case. This API doesn't allow customers to update the tags of the test case resource for the specified Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.update_test_case(
InstanceId='string',
TestCaseId='string',
Content='string',
EntryPoint={
'Type': 'VOICE_CALL',
'VoiceCallEntryPointParameters': {
'SourcePhoneNumber': 'string',
'DestinationPhoneNumber': 'string',
'FlowId': 'string'
}
},
InitializationData='string',
Name='string',
Description='string',
Status='PUBLISHED'|'SAVED',
LastModifiedTime=datetime(2015, 1, 1),
LastModifiedRegion='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case to update.
string
The JSON string that represents the content of the test.
dict
Defines the starting point for your test.
Type (string) --
The type of entry point.
VoiceCallEntryPointParameters (dict) --
Parameters for voice call entry point.
SourcePhoneNumber (string) --
The source phone number for the test.
DestinationPhoneNumber (string) --
The destination phone number for the test.
FlowId (string) --
The flow identifier for the test.
string
Defines the test attributes for precise data representation.
string
The name of the test case.
string
The description of the test case.
string
Indicates the test status as either SAVED or PUBLISHED. The PUBLISHED status will initiate validation on the content. The SAVED status does not initiate validation of the content.
datetime
The time at which the resource was last modified.
string
The region in which the resource was last modified
dict
Response Syntax
{}
Response Structure
(dict) --
Describes the specified test case and allows you to get the content and metadata of the test case for the specified Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.describe_test_case(
InstanceId='string',
TestCaseId='string',
Status='PUBLISHED'|'SAVED'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case.
string
The status of the test case version to retrieve. If not specified, returns the published version if available, otherwise returns the saved version.
dict
Response Syntax
{
'TestCase': {
'Arn': 'string',
'Id': 'string',
'Name': 'string',
'Content': 'string',
'EntryPoint': {
'Type': 'VOICE_CALL',
'VoiceCallEntryPointParameters': {
'SourcePhoneNumber': 'string',
'DestinationPhoneNumber': 'string',
'FlowId': 'string'
}
},
'InitializationData': 'string',
'Description': 'string',
'Status': 'PUBLISHED'|'SAVED',
'LastModifiedTime': datetime(2015, 1, 1),
'LastModifiedRegion': 'string',
'Tags': {
'string': 'string'
},
'TestCaseSha256': 'string'
}
}
Response Structure
(dict) --
TestCase (dict) --
The test case object containing all test case information.
Arn (string) --
The Amazon Resource Name (ARN) of the test case.
Id (string) --
The identifier of the test case.
Name (string) --
The name of the test case.
Content (string) --
The JSON string that represents the content of the test.
EntryPoint (dict) --
Defines the starting point for the test, including channel type and parameters.
Type (string) --
The type of entry point.
VoiceCallEntryPointParameters (dict) --
Parameters for voice call entry point.
SourcePhoneNumber (string) --
The source phone number for the test.
DestinationPhoneNumber (string) --
The destination phone number for the test.
FlowId (string) --
The flow identifier for the test.
InitializationData (string) --
Defines the test attributes for precise data representation.
Description (string) --
The description of the test case.
Status (string) --
Indicates the test status as either SAVED or PUBLISHED.
LastModifiedTime (datetime) --
The time at which the test case was last modified.
LastModifiedRegion (string) --
The region in which the test case was last modified.
Tags (dict) --
The tags used to organize, track, or control access for this resource.
(string) --
(string) --
TestCaseSha256 (string) --
The SHA256 hash of the test case content.
Lists all test case executions and allows filtering by test case id, test case name, start time, end time or status of the execution for the specified Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.list_test_case_executions(
InstanceId='string',
TestCaseId='string',
TestCaseName='string',
StartTime=datetime(2015, 1, 1),
EndTime=datetime(2015, 1, 1),
Status='INITIATED'|'PASSED'|'FAILED'|'IN_PROGRESS'|'STOPPED',
NextToken='string',
MaxResults=123
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
Filter executions by test case identifier.
string
Filter executions by test case name.
datetime
Filter executions that started after this time.
datetime
Filter executions that started before this time.
string
Filter executions by status.
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.
integer
The maximum number of results to return per page.
dict
Response Syntax
{
'TestCaseExecutions': [
{
'StartTime': datetime(2015, 1, 1),
'EndTime': datetime(2015, 1, 1),
'TestCaseExecutionId': 'string',
'TestCaseId': 'string',
'TestCaseExecutionStatus': 'INITIATED'|'PASSED'|'FAILED'|'IN_PROGRESS'|'STOPPED',
'Tags': {
'string': 'string'
}
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
TestCaseExecutions (list) --
An array of test case execution summary objects.
(dict) --
Contains information about a test case execution.
StartTime (datetime) --
The timestamp when the test case execution started.
EndTime (datetime) --
The timestamp when the test case execution ended.
TestCaseExecutionId (string) --
The identifier of the test case execution.
TestCaseId (string) --
The identifier of the test case.
TestCaseExecutionStatus (string) --
The status of the test case execution.
Tags (dict) --
The tags used to organize, track, or control access for this resource.
(string) --
(string) --
NextToken (string) --
If there are additional results, this is the token for the next set of results.
Lists the test cases present in the specific Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.list_test_cases(
InstanceId='string',
NextToken='string',
MaxResults=123
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
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.
integer
The maximum number of results to return per page.
dict
Response Syntax
{
'TestCaseSummaryList': [
{
'Id': 'string',
'Arn': 'string',
'Name': 'string',
'Status': 'PUBLISHED'|'SAVED',
'LastModifiedTime': datetime(2015, 1, 1),
'LastModifiedRegion': 'string'
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
TestCaseSummaryList (list) --
Information about the tests.
(dict) --
Contains summary information about a test case.
Id (string) --
The identifier of the test case.
Arn (string) --
The Amazon Resource Name (ARN) of the test case.
Name (string) --
The name of the test case.
Status (string) --
The status of the test case.
LastModifiedTime (datetime) --
The time at which the test case was last modified.
LastModifiedRegion (string) --
The region in which the test case was last modified.
NextToken (string) --
If there are additional results, this is the token for the next set of results.
Creates a test case with its content and metadata for the specified Amazon Connect instance.
See also: AWS API Documentation
Request Syntax
client.create_test_case(
InstanceId='string',
Name='string',
Description='string',
Content='string',
EntryPoint={
'Type': 'VOICE_CALL',
'VoiceCallEntryPointParameters': {
'SourcePhoneNumber': 'string',
'DestinationPhoneNumber': 'string',
'FlowId': 'string'
}
},
InitializationData='string',
Status='PUBLISHED'|'SAVED',
TestCaseId='string',
Tags={
'string': 'string'
},
LastModifiedTime=datetime(2015, 1, 1),
LastModifiedRegion='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The name of the test.
string
The description of the test.
string
[REQUIRED]
The JSON string that represents the content of the test.
dict
Defines the starting point for your test.
Type (string) --
The type of entry point.
VoiceCallEntryPointParameters (dict) --
Parameters for voice call entry point.
SourcePhoneNumber (string) --
The source phone number for the test.
DestinationPhoneNumber (string) --
The destination phone number for the test.
FlowId (string) --
The flow identifier for the test.
string
Defines the initial custom attributes for your test.
string
Indicates the test status as either SAVED or PUBLISHED. The PUBLISHED status will initiate validation on the content. The SAVED status does not initiate validation of the content.
string
Id of the test case if you want to create it in a replica region using Amazon Connect Global Resiliency
dict
The tags used to organize, track, or control access for this resource.
(string) --
(string) --
datetime
The time at which the resource was last modified.
string
The region in which the resource was last modified
dict
Response Syntax
{
'TestCaseId': 'string',
'TestCaseArn': 'string'
}
Response Structure
(dict) --
TestCaseId (string) --
The identifier of the test.
TestCaseArn (string) --
The Amazon Resource Name (ARN) of the test.
Searches for test cases in the specified Amazon Connect instance, with optional filtering.
See also: AWS API Documentation
Request Syntax
client.search_test_cases(
InstanceId='string',
NextToken='string',
MaxResults=123,
SearchFilter={
'TagFilter': {
'OrConditions': [
[
{
'TagKey': 'string',
'TagValue': 'string'
},
],
],
'AndConditions': [
{
'TagKey': 'string',
'TagValue': 'string'
},
],
'TagCondition': {
'TagKey': 'string',
'TagValue': 'string'
}
}
},
SearchCriteria={
'OrConditions': [
{'... recursive ...'},
],
'AndConditions': [
{'... recursive ...'},
],
'StringCondition': {
'FieldName': 'string',
'Value': 'string',
'ComparisonType': 'STARTS_WITH'|'CONTAINS'|'EXACT'
},
'StatusCondition': 'PUBLISHED'|'SAVED'
}
)
string
[REQUIRED]
The identifier of the Amazon Connect instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.
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.
integer
The maximum number of results to return per page.
dict
Filters to be applied to search results.
TagFilter (dict) --
An object that can be used to specify Tag conditions inside the SearchFilter. This accepts an OR of AND (List of List) input where: Top level list specifies conditions that need to be applied with OR operator. Inner list specifies conditions that need to be applied with AND operator.
OrConditions (list) --
A list of conditions which would be applied together with an OR condition.
(list) --
(dict) --
A leaf node condition which can be used to specify a tag condition, for example, HAVE BPO = 123.
TagKey (string) --
The tag key in the tag condition.
TagValue (string) --
The tag value in the tag condition.
AndConditions (list) --
A list of conditions which would be applied together with an AND condition.
(dict) --
A leaf node condition which can be used to specify a tag condition, for example, HAVE BPO = 123.
TagKey (string) --
The tag key in the tag condition.
TagValue (string) --
The tag value in the tag condition.
TagCondition (dict) --
A leaf node condition which can be used to specify a tag condition.
TagKey (string) --
The tag key in the tag condition.
TagValue (string) --
The tag value in the tag condition.
dict
The search criteria to be used to return test cases.
OrConditions (list) --
A list of conditions which would be applied together with an OR condition.
(dict) --
The search criteria to be used to return test cases.
AndConditions (list) --
A list of conditions which would be applied together with an AND condition.
(dict) --
The search criteria to be used to return test cases.
StringCondition (dict) --
A leaf node condition which can be used to specify a string condition.
FieldName (string) --
The name of the field in the string condition.
Value (string) --
The value of the string.
ComparisonType (string) --
The type of comparison to be made when evaluating the string condition.
StatusCondition (string) --
The status of the test case.
dict
Response Syntax
{
'TestCases': [
{
'Arn': 'string',
'Id': 'string',
'Name': 'string',
'Content': 'string',
'EntryPoint': {
'Type': 'VOICE_CALL',
'VoiceCallEntryPointParameters': {
'SourcePhoneNumber': 'string',
'DestinationPhoneNumber': 'string',
'FlowId': 'string'
}
},
'InitializationData': 'string',
'Description': 'string',
'Status': 'PUBLISHED'|'SAVED',
'LastModifiedTime': datetime(2015, 1, 1),
'LastModifiedRegion': 'string',
'Tags': {
'string': 'string'
},
'TestCaseSha256': 'string'
},
],
'NextToken': 'string',
'ApproximateTotalCount': 123
}
Response Structure
(dict) --
TestCases (list) --
Information about the test cases.
(dict) --
Contains information about a test case.
Arn (string) --
The Amazon Resource Name (ARN) of the test case.
Id (string) --
The identifier of the test case.
Name (string) --
The name of the test case.
Content (string) --
The JSON string that represents the content of the test.
EntryPoint (dict) --
Defines the starting point for the test, including channel type and parameters.
Type (string) --
The type of entry point.
VoiceCallEntryPointParameters (dict) --
Parameters for voice call entry point.
SourcePhoneNumber (string) --
The source phone number for the test.
DestinationPhoneNumber (string) --
The destination phone number for the test.
FlowId (string) --
The flow identifier for the test.
InitializationData (string) --
Defines the test attributes for precise data representation.
Description (string) --
The description of the test case.
Status (string) --
Indicates the test status as either SAVED or PUBLISHED.
LastModifiedTime (datetime) --
The time at which the test case was last modified.
LastModifiedRegion (string) --
The region in which the test case was last modified.
Tags (dict) --
The tags used to organize, track, or control access for this resource.
(string) --
(string) --
TestCaseSha256 (string) --
The SHA256 hash of the test case content.
NextToken (string) --
If there are additional results, this is the token for the next set of results.
ApproximateTotalCount (integer) --
The total number of test cases which matched your search query.
Stops a running test execution.
See also: AWS API Documentation
Request Syntax
client.stop_test_case_execution(
InstanceId='string',
TestCaseExecutionId='string',
TestCaseId='string',
ClientToken='string'
)
string
[REQUIRED]
The identifier of the Amazon Connect instance.
string
[REQUIRED]
The identifier of the test case execution to stop.
string
[REQUIRED]
The identifier of the test case.
string
A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.
dict
Response Syntax
{}
Response Structure
(dict) --