Updated Element API Documentation (Mar 2026)
🔄 Updated
Element API
The Element API documentation has been updated with corrected code examples to ensure accuracy and consistency with the TypeScript interfaces. In addition, the @avaya/infinity-elements-api npm package has been updated with new APIs, updated method signatures, and improved documentation.
Note: The npm package changes listed below are not yet reflected in the portal documentation. Install the latest package version to access these features. See Resources for the npm package link.
What's New:
- Fixed
getUsers()code examples to use correct property interpolation syntax, replacing malformed placeholder strings with accurate object property references - New
completeConference()method — merges all parties into a conference call rather than completing a transfer - New
onCompleteAsConference()event subscription for conference completion - New
onChangedAgentState()event subscription for agent state changes (Available, Away, Busy) - New
InteractionContextOptionsinterface for managing app-level vs. interaction-level widget context - New
AgentStateChangedCallbackandCompleteAsConferenceCallbackcallback types - New
COMPLETE_AS_CONFERENCEandAGENT_STATE_CHANGEDentries added toCHANNEL_NAMES
| Updated Content |
|---|
| Element API |
| @avaya/infinity-elements-api (npm) |
Key Improvements:
Corrected getUsers() Examples
The getUsers() examples now use accurate TypeScript property interpolation throughout all five example variants. The previous version contained unfilled placeholder strings (such as $USER.FULLNAME and $USER.PRESENCE) that did not reflect actual object property access syntax.
The corrected examples now consistently reference the correct GetUsersResponse properties:
user.fullName— the agent's full nameuser.presence— the agent's VoIP/presence statususer.extension— the agent's extension numberuser.cxStatus.status— the agent's CX status display name
Conference Call Support (npm package)
A new completeConference() method allows elements to merge all parties into a conference call, providing an alternative to completing an attended transfer. The accompanying onCompleteAsConference() event subscription enables elements to react when a conference is completed.
Agent State Change Events (npm package)
A new onChangedAgentState() event subscription allows elements to listen for agent state transitions between Available, Away, and Busy statuses. The AgentStateChangedCallback type is provided for strongly typed callback implementations.
App-Level Widget Context (npm package)
A new InteractionContextOptions interface has been introduced to support app-level widget scenarios. The following interaction methods now accept an optional parameter:
options?: InteractionContextOptionsAffected methods: getInteraction(), endInteraction(), startVoiceCall(), viewerRemoveInteraction(), acceptInteraction(), completeAttendedTransfer(), attendedTransferWarm(), attendedTransferCancel(), sendDialpadDigit(), and insertTextIntoFeedInput().
An optional property has also been added to ElementAPIOptions to support adaptor and bridge use cases:
requestTarget?: WindowUpdated Method Signatures (npm package)
Several interfaces and callbacks have been updated:
SingleStepTransferParams— new optionalinteractionIdfieldSendRichMediaMessageOptions— new optionalinteractionIdfieldgetTransferQueuesInteraction()params — new optionalinteractionIdfieldFeedMessageCallback— now receives(message, interactionId?)instead of(message)only
Improved JSDoc (npm package)
Package documentation now explicitly describes the sandboxed iframe environment and postMessage-based communication model. Inter-element communication docs have been updated to reflect host-routed messaging, replacing the previous BroadcastChannel description.
