Attempting to add an Agent ARN or Queue ARN through the Add Participant action results in a CAN_NOT_ADD_PARTICIPANT error with the message: "Invalid agent or contact state.
Steps to Reproduce
Observed Behavior
The request fails and the following error is logged:
SCV dispatched error CAN_NOT_ADD_PARTICIPANT for eventType ADD_PARTICIPANT
{
"type": "InvalidStateException",
"message": "Cannot create new connection by endpoint ARN: <Agent ARN>: Invalid agent or contact state."
}
Expected Behavior
The specified agent or queue should be added to the active call successfully.
Resolution
When using the Voice Toolkit API addParticipant method to add an agent or queue to an active call, the corresponding Quick Connect ARN should be used as the destination rather than the Agent ARN or Queue ARN directly.
Using an Agent ARN or Queue ARN may result in an InvalidStateException and prevent the participant from being added to the call.
005387384

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.