Ae Services DMCC Dotnet Programmers Guide 7 0
Ae Services DMCC Dotnet Programmers Guide 7 0
Release 7.0.0
1 02-602658
Issue 1
© 2014 Avaya Inc. accessed by multiple users. “Software” means the computer programs
All Rights Reserved. in object code, originally licensed by Avaya and ultimately utilized by
Notices End User, whether as stand-alone products or pre-installed on
While reasonable efforts have been made to ensure that the Hardware. “Hardware” means the standard hardware originally sold by
information in this document is complete and accurate at the time of Avaya and ultimately utilized by End User.
printing, Avaya assumes no liability for any errors. Avaya reserves the License types
right to make changes and corrections to the information in this Designated System(s) License (DS). End User may install and use
document without the obligation to notify any person or organization of each copy of the Software on only one Designated Processor, unless
such changes. a different number of Designated Processors is indicated in the
Documentation disclaimer Documentation or other materials available to End User. Avaya may
Avaya shall not be responsible for any modifications, additions, or require the Designated Processor(s) to be identified by type, serial
deletions to the original published version of this documentation unless number, feature key, location or other specific designation, or to be
such modifications, additions, or deletions were performed by Avaya. provided by End User to Avaya through electronic means established
End User agree to indemnify and hold harmless Avaya, Avaya's agents, by Avaya specifically for this purpose.
servants and employees against all claims, lawsuits, demands and Concurrent User License (CU). End User may install and use the
judgments arising out of, or in connection with, subsequent Software on multiple Designated Processors or one or more Servers,
modifications, additions or deletions to this documentation, to the so long as only the licensed number of Units are accessing and using
extent made by End User. the Software at any given time. A “Unit” means the unit on which Avaya,
Link disclaimer at its sole discretion, bases the pricing of its licenses and can be,
Avaya is not responsible for the contents or reliability of any linked Web without limitation, an agent, port or user, an e-mail or voice mail account
sites referenced within this site or documentation(s) provided by Avaya. in the name of a person or corporate function (e.g., webmaster or
Avaya is not responsible for the accuracy of any information, statement helpdesk), or a directory entry in the administrative database utilized
or content provided on these sites and does not necessarily endorse by the Software that permits one user to interface with the Software.
the products, services, or information described or offered within them. Units may be linked to a specific, identified Server.
Avaya does not guarantee that these links will work all the time and has Database License (DL). End User may install and use each copy of the
no control over the availability of the linked pages. Software on one Server or on multiple Servers provided that each of
Warranty the Servers on which the Software is installed communicate with no
Avaya provides a limited warranty on this product. Refer to your sales more than a single instance of the same database.
agreement to establish the terms of the limited warranty. In addition, CPU License (CP). End User may install and use each copy of the
Avaya’s standard warranty language, as well as information regarding Software on a number of Servers up to the number indicated by Avaya
support for this product, while under warranty, is available to Avaya provided that the performance capacity of the Server(s) does not
customers and other parties through the Avaya Support Web site: exceed the performance capacity specified for the Software. End User
http://www.avaya.com/support. Please note that if you acquired the may not re-install or operate the Software on Server(s) with a larger
product from an authorized Avaya reseller outside of the United States performance capacity without Avaya's prior consent and payment of an
and Canada, the warranty is provided to you by said Avaya reseller and upgrade fee
not by Avaya. Named User License (NU). End User may: (i) install and use the
Licenses Software on a single Designated Processor or Server per authorized
THE SOFTWARE LICENSE TERMS AVAILABLE ON THE AVAYA Named User (defined below); or (ii) install and use the Software on a
WEBSITE, HTTP://SUPPORT.AVAYA.COM/LICENSEINFO/ ARE Server so long as only authorized Named Users access and use the
APPLICABLE TO ANYONE WHO DOWNLOADS, USES AND/OR Software. “Named User,” means a user or device that has been
INSTALLS AVAYA SOFTWARE, PURCHASED FROM AVAYA INC., expressly authorized by Avaya to access and use the Software. At
ANY AVAYA AFFILIATE, OR AN AUTHORIZED AVAYA RESELLER Avaya's sole discretion, a “Named User” may be, without limitation,
(AS APPLICABLE) UNDER A COMMERCIAL AGREEMENT WITH designated by name, corporate function (e.g., webmaster or helpdesk),
AVAYA OR AN AUTHORIZED AVAYA RESELLER. UNLESS an e-mail or voice mail account in the name of a person or corporate
OTHERWISE AGREED TO BY AVAYA IN WRITING, AVAYA DOES function, or a directory entry in the administrative database utilized by
NOT EXTEND THIS LICENSE IF THE SOFTWARE WAS OBTAINED the Software that permits one user to interface with the Software.
FROM ANYONE OTHER THAN AVAYA, AN AVAYA AFFILIATE OR Shrinkwrap License (SR). With respect to Software that contains
AN elements provided by third party suppliers, End User may install and
AVAYA AUTHORIZED RESELLER, AND AVAYA RESERVES THE use the Software in accordance with the terms and conditions of the
RIGHT TO TAKE LEGAL ACTION AGAINST YOU AND ANYONE applicable license agreements, such as “shrinkwrap” or “clickwrap”
ELSE USING OR SELLING THE SOFTWARE WITHOUT A LICENSE. license accompanying or applicable to the Software (“Shrinkwrap
BY INSTALLING, DOWNLOADING OR USING THE SOFTWARE, OR License”). The text of the Shrinkwrap License will be available from
AUTHORIZING OTHERS TO DO SO, YOU, ON BEHALF OF Avaya upon End User’s request (see “Third-party Components” for
YOURSELF AND THE ENTITY FOR WHOM YOU ARE INSTALLING, more information).
DOWNLOADING OR USING THE SOFTWARE (HEREINAFTER Copyright
REFERRED TO INTERCHANGEABLY AS “YOU” AND “END USER”), Except where expressly stated otherwise, no use should be made of
AGREE TO THESE TERMS AND CONDITIONS AND CREATE A materials on this site, the Documentation(s) and Product(s) provided
BINDING CONTRACT BETWEEN YOU AND AVAYA INC. OR THE by Avaya. All content on this site, the documentation(s) and the
APPLICABLE AVAYA AFFILIATE (“AVAYA”). product(s) provided by Avaya including the selection, arrangement and
Avaya grants End User a license within the scope of the license types design of the content is owned either by Avaya or its licensors and is
described below. The applicable number of licenses and units of protected by copyright and other intellectual property laws including the
capacity for which the license is granted will be one (1), unless a sui generis rights relating to the protection of databases. You may not
different number of licenses or units of capacity is specified in the modify, copy, reproduce, republish, upload, post, transmit or distribute
Documentation or other materials available to End User. “Designated in any way any content, in whole or in part, including any code and
Processor” means a single stand-alone computing device. “Server” software. Unauthorized reproduction, transmission, dissemination,
means a Designated Processor that hosts a software application to be storage, and or use without the express written consent of Avaya can
be a criminal, as well as a civil, offense under the applicable law.
Release 7.0.0
2 02-602658
Issue 1
Third-party components
Certain software programs or portions thereof included in the Product
may contain software distributed under third party agreements (“Third
Party Components”), which may contain terms that expand or limit
rights to use certain portions of the Product (“Third Party Terms”).
Information regarding distributed Linux OS source code (for those
Products that have distributed the Linux OS source code), and
identifying the copyright holders of the Third Party Components and the
Third Party Terms that apply to them is available on the Avaya Support
Web site: http://www.avaya.com/support/Copyright/.
Preventing toll fraud
“Toll fraud” is the unauthorized use of your telecommunications system
by an unauthorized party (for example, a person who is not a corporate
employee, agent, subcontractor, or is not working on your company's
behalf). Be aware that there can be a risk of toll fraud associated with
your system and that, if toll fraud occurs, it can result in substantial
additional charges for your telecommunications services.
Avaya fraud intervention
If you suspect that you are being victimized by toll fraud and you need
technical assistance or support, call Technical Service Center Toll
Fraud Intervention Hotline at +1-800-643-2353 for the United States
and Canada. For additional support telephone numbers, see the Avaya
Support Web site: http://www.avaya.com/support/. Suspected security
vulnerabilities with Avaya products should be reported to Avaya by
sending mail to: [email protected].
Trademarks
Avaya Aura is a registered trademark of Avaya.
All non-Avaya trademarks are the property of their respective owners.
PuTTY is copyright 1997-2009 Simon Tatham.
Downloading documents
For the most current versions of documentation, see the Avaya Support
Web site: http://www.avaya.com/support
Contact Avaya Support
Avaya provides a telephone number for you to use to report problems
or to ask questions about your product. The support telephone number
is 1-800-242-2121 in the United States. For additional support
telephone numbers, see the Avaya Web site: http://www.avaya.com/
support
Release 7.0.0
3 02-602658
Issue 1
Contents
About this document ....................................................................................................................................... 9
Scope of this document .............................................................................................................................. 9
Intended Audience ....................................................................................................................................10
Conventions used in this document ..........................................................................................................10
Related documents ...................................................................................................................................11
Application Enablement Services documents.......................................................................................11
Communication Manager documents ...................................................................................................12
ECMA documents.................................................................................................................................12
Providing documentation feedback ...........................................................................................................13
New Features and Capabilities ......................................................................................................................14
Chapter 1: API Services .................................................................................................................................15
Service Provider Class ..............................................................................................................................18
Device Class .............................................................................................................................................22
Phone Class ..............................................................................................................................................22
Media Class ..............................................................................................................................................25
Call Information Link Class........................................................................................................................28
Third Party Call Controller Class ...............................................................................................................29
XML Processor Class ................................................................................................................................35
Constant Classes ......................................................................................................................................36
Call Associated Class................................................................................................................................37
Chapter 2: Getting started ..............................................................................................................................38
Setting up the development environment ..................................................................................................38
Downloading the Application Enablement Services Device, Media and Call Control .NET API SDK ...38
Setting up Visual Studio .......................................................................................................................39
Setting up your test environment ..........................................................................................................39
Understanding basic CSTA concepts ........................................................................................................39
First Party vs Third Party (Device and Media Control vs Call Control) .................................................40
Devices.................................................................................................................................................41
Physical Elements ................................................................................................................................41
Logical Elements ..................................................................................................................................41
Calls .....................................................................................................................................................41
Service Requests .................................................................................................................................41
Service Responses...............................................................................................................................42
Events ..................................................................................................................................................42
Negative acknowledgements................................................................................................................43
Call Recording...........................................................................................................................................43
Recording warning tone........................................................................................................................44
Signaling Encryption .................................................................................................................................44
Release 7.0.0
4 02-602658
Issue 1
Media Encryption ......................................................................................................................................45
Accessing the client API reference documentation ...................................................................................46
Using the Device, Media and Call Control Dashboard ..............................................................................46
Learning from sample code .......................................................................................................................46
Chapter 3: Writing a client application ............................................................................................................48
The Dashboard tool ...................................................................................................................................48
Receiving Negative Responses ................................................................................................................49
Session Management................................................................................................................................50
Start Application Session......................................................................................................................50
Reset Application Session Timer ..........................................................................................................52
Exercise: Starting the Application Session ...........................................................................................53
SessionCharacteristics ..............................................................................................................................54
DeviceID Type ......................................................................................................................................54
Event Filter Mode .................................................................................................................................55
Device Identifiers (DeviceID) .....................................................................................................................56
Getting Device Identifiers .....................................................................................................................57
Comparing Device Identifiers ...............................................................................................................58
Populating the Device ID Switch Name and Switch IP Interface fields .................................................58
Multiple DeviceIDs ................................................................................................................................60
Controllable By Other Sessions ............................................................................................................60
Device ID Instances..............................................................................................................................61
Getting Device State Information ..........................................................................................................61
Exercise: Getting A Device ID ..............................................................................................................62
Notification of Events ................................................................................................................................63
Register for Events ...............................................................................................................................64
Unregister for Events ............................................................................................................................65
Exercise: Registering for Events ..........................................................................................................65
Registering Devices ..................................................................................................................................66
Endpoint Registration Events ...............................................................................................................68
Endpoint Registration Information ........................................................................................................70
Controllable telephone types ................................................................................................................70
Registration Modes...............................................................................................................................71
Dependency Modes .........................................................................................................................71
Media Modes ...................................................................................................................................73
Choosing a media mode.......................................................................................................................74
Choosing a codec .................................................................................................................................77
Choosing the media encryption ............................................................................................................78
Redirecting Media ................................................................................................................................78
The "share-talk" button .........................................................................................................................79
Interpretation of the ’share-talk’ button lamp state ................................................................................79
Release 7.0.0
5 02-602658
Issue 1
Using E.164 Conversion Services ........................................................................................................80
Exercise: Performing a Device Registration .........................................................................................82
Exercise: Performing Operations on a Registered Device....................................................................85
Expanded help feature ..............................................................................................................................87
Writing Code .............................................................................................................................................89
Writing applications that run in a browser................................................................................................100
Telephony Logic ......................................................................................................................................101
Device and Media Control ..................................................................................................................101
Monitoring and Controlling Physical Elements ...............................................................................102
Knowing what buttons are administered ........................................................................................102
Detecting an incoming call .............................................................................................................103
Determining that far end has ended the call ..................................................................................104
Making a call ..................................................................................................................................104
Call Control.........................................................................................................................................106
Monitoring and Controlling Calls ....................................................................................................106
Making a call ..................................................................................................................................107
Answering a call.............................................................................................................................107
Ending a call ..................................................................................................................................107
Getting ANI information for a call ........................................................................................................108
Recording and playing voice media ....................................................................................................108
Media Operations ..........................................................................................................................110
Recording ......................................................................................................................................110
Playing a Recording Warning Tone ...............................................................................................111
Playing a recording warning tone - single step conference method ...............................................112
Playing a recording warning tone - multiple registration method ...................................................112
Dubbing .........................................................................................................................................113
Playing ...........................................................................................................................................113
Monitoring Media Events ...............................................................................................................114
Detecting and collecting DTMF tones .................................................................................................114
Detecting individual tones ..............................................................................................................116
Collecting multiple tones ................................................................................................................116
Determining when far-end RTP media parameters change................................................................118
Chapter 4: Recovery ....................................................................................................................................119
Session Recovery...............................................................................................................................120
Transfer Monitor Objects ....................................................................................................................122
Chapter 5: Cleanup ......................................................................................................................................124
Chapter 6: High Availability ..........................................................................................................................126
AE Services Geo-Redundant High Availability (GRHA) ..........................................................................126
DMCC Service Recovery ........................................................................................................................129
DMCC Support of Communication Manager High Availability Using ESS and LSP Servers ..................133
Release 7.0.0
6 02-602658
Issue 1
Programming Considerations for High Availability ..................................................................................135
Chapter 7: Media Encryption........................................................................................................................136
The AES Encryption Scheme ..................................................................................................................136
Specifying the Devices’ Encryption Capability.........................................................................................140
MediaStartEvent Handling.......................................................................................................................140
Media Encryption Information .............................................................................................................141
Encrypting and Decrypting the RTP Stream............................................................................................141
Roll Over Counter (ROC) ...................................................................................................................141
Creating the Encryption Keys Using the Pseudo Random Function ...................................................142
Creating the Initialization Vectors (IV) ................................................................................................143
Decrypting the Media Payload............................................................................................................144
Test Data ............................................................................................................................................145
Chapter 8: Security Considerations .............................................................................................................146
Advanced authentication and authorization policies ................................................................................147
User Authentication Policies....................................................................................................................148
User Authorization Policies .....................................................................................................................148
SDB ....................................................................................................................................................148
Enterprise Directory ............................................................................................................................149
Unrestricted Access............................................................................................................................149
AA Policy Use Cases ..............................................................................................................................150
Server based applications without enterprise user identities ..............................................................150
Enterprise user based applications where user controls only their own telephone.............................150
Chapter 9: Debugging ..................................................................................................................................152
Error Messages .......................................................................................................................................152
Possible race conditions..........................................................................................................................153
Improving performance ...........................................................................................................................153
Getting support........................................................................................................................................154
Appendix A: The J-Scripts Library................................................................................................................155
J-Script ....................................................................................................................................................155
ActiveX Service Provider .........................................................................................................................156
Static event handlers ...............................................................................................................................157
Requests, response events, and events .................................................................................................157
J-Script object .........................................................................................................................................159
Service Provider Methods and Events................................................................................................160
Phone Methods and Events ...............................................................................................................160
Media Methods and Events ................................................................................................................161
Third Party Call Controller Methods and Events.................................................................................162
Call Information Methods and Events .................................................................................................163
J-Script library configuration ....................................................................................................................163
Server-side Instructions...........................................................................................................................163
Release 7.0.0
7 02-602658
Issue 1
Client-side Instructions ............................................................................................................................164
Appendix B: Communication Manager Features..........................................................................................165
Appendix C: Constant Values ......................................................................................................................167
Phone Object Enumerations and Constants ...........................................................................................167
Media Enumerations ...............................................................................................................................176
Service Provider Enumeration.................................................................................................................177
Third Party Call Control Enumerations ....................................................................................................177
Appendix D: Unicode Mapping Table ...........................................................................................................179
Appendix E: DMCC Server Logging............................................................................................................180
Appendix F: TSAPI Error Code Definitions ..................................................................................................184
CSTA Universal Failures .........................................................................................................................184
ACS Universal Failures ...........................................................................................................................186
Appendix G: Routeing Services ...................................................................................................................188
Routeing Services Sequence Diagram....................................................................................................188
Requests to end a routeing registration session:................................................................................189
RouteRegister .........................................................................................................................................190
RouteRequest .........................................................................................................................................191
RouteSelect.............................................................................................................................................192
RouteUsed Event ....................................................................................................................................193
RouteEnd Request ..................................................................................................................................194
RouteEnd Event: .....................................................................................................................................194
RouteRegisterAbort.................................................................................................................................197
RouteRegisterCancel ..............................................................................................................................198
Appendix H: IPv6 Support ............................................................................................................................199
Usage of IPv6 addresses in AE Services ................................................................................................200
Mixed IPv4 and IPv6 networks ................................................................................................................201
Appendix I: ACS Universal Error Codes ......................................................................................................202
Glossary .......................................................................................................................................................204
Release 7.0.0
8 02-602658
Issue 1
About this document
This chapter describes the:
Intended Audience
This document is written for application developers. The .NET Client Library has been
tested with applications written in the following languages:
• C#
• Visual Basic
You do not need to understand CSTA concepts or the Avaya Communication Manager
features and concepts, but they both might be helpful.
If you are new to CSTA, you may wish to start by reading ECMA-269, section 6.1,
“CSTA Operational Model: Switching Sub-Domain Model”. Also become familiar with the
table of contents so that you know the kinds of information available there. All of the
descriptions of the services implemented by this API are also found in the Avaya Aura®
Application Enablement Services Device, Media and Call Control .NET Programmers
Reference, found online on the Avaya DevConnect Web site
(http://www.avaya.com/devconnect ) and on the Avaya Support Web site
(http://www.avaya.com/support ).
For those new to Avaya Communication Manager, you may wish to take a course from
Avaya University (http://www.avaya.com/learning ) to learn more about Communication
Manager and its features. It is recommended that you start with the Avaya
Communication Manager Overview course (course ID AVA00383WEN). You may also
wish to peruse Appendix B: Communication Manager Features in this guide to get some
ideas of how applications can take advantage of Communication Manager’s abilities.
Release 7.0.0
10 02-602658
Issue 1
Code and Linux commands request = new GetDeviceId();
Related documents
While planning, developing, deploying, or troubleshooting your application, you may
need to reference other Avaya Aura® Application Enablement Services documents,
Avaya Communication Manager documents or CSTA documents listed below.
For developers, another important source of .NET API information can be found in the
following documents:
• Avaya Aura® Application Enablement Services Device, Media and Call Control
.NET Programmer’s Reference
• Dashboard User’s Guide (see the SDK .exe file)
• ReadMe.txt (see the SDK .exe file)
In the above items, you can find details about each package, interface, class, method,
and field in the .NET API.
The following documents from the Communication Manager documentation set provide
additional information about administering Communication Manager for Device, Media
and Call Control API. They are on the Avaya Support Centre Web Site
(http://www.avaya.com/support ).
ECMA documents
The .NET Programmers Reference contains much of what you need to know about
CSTA services. For CSTA details not found in this document, please refer to the
Release 7.0.0
12 02-602658
Issue 1
following documents. They are found in the Publications section of the ECMA web site
(http://www.ecma-international.org/ ):
Thank you.
Release 7.0.0
13 02-602658
Issue 1
New Features and Capabilities
New features and capabilities in AE Services 7.0 are:
• Enhancements to the Application Enablement Service services
Increased the maximum number of DMCC station registrations from 4K
to 8K
Shared memory implementation for Transport Service to increase
reliability and performance.
• Enhancements to the Application Enablement Service DMCC .NET SDK
.NET SDK updated to support .NET Framework 4.5.2
• Enhancements to Application Enablement Services Geo-Redundancy High
Availability
The use of virtual IP addresses on all active interfaces.
Support for features similar to those used by the Fast-Reboot High
Availability (FRHA).
• Enhancements to the Application Enablement Services server
AE Services 7.0 runs on Red Hat Enterprise Linux version 6 update 5
(RHEL 6U5), with appropriate security patches from Red Hat.
Support for Out-of-Band Management (OOBM)
Support for the Avaya Aura Solution Deployment Manager
Support for the TLSv1.2 protocol
Use of a new 1year self-signed server certificate for the AE Services
server as the default server certificate‡
• Changes to the Application Enablement Services offer
Dropped support for the AE Services on Bundled offer
Dropped support for the AE Services on System Platform offer, including
the FRHA and MPHA features.
Removed support for the SSLv3 protocol
‡
WARNING: Since the default certificate used by earlier releases of AE Services has been replaced, any
applications that rely on this certificate for SSL/TLS will fail SSL negotiation with an AE Services 7.0 server.
To overcome this in your test environment, you will need to export the server certificate from the AE
Services and import into your application’s trust-store. Note that, for a production environment, you are
strongly advised to create your own server certificates and install them on the AE Services server (and
include the CA in your application’s trust-store). Please refer to the “certificates” section of the AE Services
Administration and Maintenance Guide for more details
Release 7.0.0
14 02-602658
Issue 1
Chapter 1: API Services
This chapter provides an overview of what CSTA services this API supports.
• Device Control
• Media Control (including call recording, message playing and dubbing)
• Call Control
• Tone Collection and Detection
• Routeing Services
These services are provided through an XML protocol which is wrapped by the .NET
API. Some of the interfaces of the XML protocol conform to the CSTA III standard
(ECMA-269) and some are Avaya extensions to the CSTA standard.
In CSTA, each service is defined to be a request that either comes from the application
to a switch or from a switch to the application. This API, however, is based on a
client/server model where the application is the client and the AE Services server
software and Communication Manager together act as the server. Thus, this API allows
an application:
• to request services of Communication Manager
• to request notification of asynchronous events on Communication Manager
CSTA specifies that for any given service some parameters are mandatory and some
parameters are optional. To determine which of the optional parameters Avaya supports
or which of the field values Avaya supports, refer to the requests and responses detailed
in the XML Programmer’s Reference on the Avaya Support site. The Dashborad tool is
also another good source to determine which parameters are optional.
The .NET API, which follows the event based asynchronous pattern, abstracts the XML
protocol requests and responses into a set of reusable service classes. The exposed
.NET classes will model all requests and responses (or exceptions) asynchronously and
will model all events and handlers using standard .NET conventions.
Release 7.0.0
15 02-602658
Issue 1
The following table provides a correlation between the supported CSTA services and
the .NET exposed service classes.
1
This API implements the intent of CSTA’s Monitoring Services using .NET Event Handlers
2
This API does not consume a license. However, it is necessary to register a DMCC endpoint in
order to use this service, and this registration will consume a DMCC or IP_API_A license.
Release 7.0.0
16 02-602658
Issue 1
The XML API provide extensions to the CSTA Service Set referred to as Avaya
Extensions that are meant to enhance the capabilities of CSTA and provide higher-level
services and useful events that make development of telephony applications easier.
The following table provides a correlation between the XML API Avaya Extensions and
the .NET exposed service classes.
Release 7.0.0
17 02-602658
Issue 1
Collection and buffers them as
Services and requested before
Events reporting them to the
application
Media Tone Replaces Detects DTMF tones None
Detection Data and reports each
Events Collection tone as it is detected
Services
The remaining sections of this chapter will provide additional details about the .NET
API classess. If you are interested in additional information about the supported CSTA
Services, please see the CSTA specifications listed in Table 1. For a general overview
of the CSTA Services and additional information about the Avaya Extensions please
see Chapter 1 of the Avaya Aura® Application Enablement Services Device, Media and
Call Control API XML Programmer Guide.
This class act as a bootstrap class for connecting to the server, performing session
management, retrieving other objects and disconnecting from the server. In addition to
these features, this class also provides support for the CSTA System Service to allow an
application to obtain the status of the TLink connections between the AE Services server
and Communication Manager. To learn how to use the Service Provider Class, see The
Dashboard tool on page 48.
Release 7.0.0
18 02-602658
Issue 1
Get Device Given a device name (Id), returns a reference to
the associated Device.
Get Device ID List Get all the Device IDs that are active on the
DMCC server.
Get Monitor List Get a list of all the monitors which are active on
this DMCC server.
Get New Device Creates a new Device object and returns a
reference to it.
Release 7.0.0
19 02-602658
Issue 1
SetSessionCharacteristics Configures the session characteristics
(specifically, Device ID Type, and Event Filter
Mode) for the session.
Release 7.0.0
20 02-602658
Issue 1
System Register Cancel Allows the application to cancel a previously
initiated System Register request.
Transfer Monitor Objects Transfer all the devices and monitors from one
session to another session. The session which
the monitors are being transferred from will be
closed by the DMCC server.
Get Actual Protocol Version Retrieves the API version for the server.
Get Call Information Link Returns a reference to the CallInformationLink
object.
Get Last Incoming Xml Message Retireves the last XML message received.
Missed At Least One Keep Alive Occurs if the server has missed at least one
Event keepalive
Server Connection Down Occurs if the socket to the AE Services server
has gone down for some reason
Server Connection Not Active Occurs if a message was received by the AE
Services server but the session has timed out
and been placed in the inactive state
System Register Abort Occurs when an active System Registration has
been cancelled (e.g. if the TSAPI Service is
stopped)
System Status Occurs for changes in the TLink status of one or
all administered TSAPI CTI links. Once an
application is registered, notifications are sent
when the TLink status changes (e.g.
linkup/linkDown).
Release 7.0.0
21 02-602658
Issue 1
Device Class
The Device Class is used to communicate to the server in order to get a new DeviceID
for a particular extension. The device object contains the phone object. There will be one
Device Object for every device that is being used in the application. To learn how to use
the Device Class, see The Dashboard tool .
Note:
Care must be taken when creating a Device ID to ensure that the switch name is
properly set in the Device ID. Please see “Populating the Device ID Switch Name
and Switch IP Interface fields” for more information.
Get Device ID As String Gets the device identifier that represents the
device described by its extension number and
the Communication Manager upon which it
resides, as a string
Get Extension Returns the extension associated with this
device.
Get Phone Returns the reference to the phone object for
this Device.
Get Service Provider Returns an instance of a Service Provider
object.
Get Device ID Gets the device identifier that represents the
device described by its extension number and
the Communication Manager upon which it
resides. Release 5.2 and later supports the
ability to also send the Device Instance (0, 1, or
2) which is to be created.
Release Device ID Sends a ReleaseDeviceId XML message to
the server.
Phone Class
The Phone Class provides physical device control which allows an application the ability
to manipulate and monitor the physical aspects of a device, which includes buttons,
lamps, the display, and the ringer. The services simulate manual action on a device as
Release 7.0.0
22 02-602658
Issue 1
well as provide the ability to request status of physical elements. The events provide
notification of changes to the physical elements of the device.
All services that operate on a particular device use a device identifier to specify the
device. This class will also provide a device identifier for a given extension on
Communication Manager.
The Phone Class will also provide the ability to gain Main, Dependent or Independent
control over a device and to specify the desired media mode for that device.
Main, Dependent and Independent control is described in the "Device and media
control" section of the "Capabilities of the API" chapter of the Avaya Aura® Application
Enablement Services Overview. For a list of device types that can be controlled with this
API and for further distinction between the registration modes, see the "Controllable
telephone types" section of the "Capabilities of the API" chapter of the Avaya Aura®
Application Enablement Services Overview.
The desired media parameters are also specified using the Phone Class. The options for
the Media parameters are described in the "Media control modes" section of the
"Capabilities of the API" chapter of the Avaya Aura® Application Enablement Services
Overview.
To learn how to use the Phone Class, see The Dashboard tool.
Note:
Care must be taken when creating a Device ID to ensure that the switch name is
properly set in the Device ID. Please see “Populating the Device ID Switch Name
and Switch IP Interface fields” for more information.
Change Device Security Code Allows a DMCC client to change the security
code of an extension on Communication
Manager.
Change Monitor Allows a DMCC client the ability to change the
attributes of an existing monitor.
Validate Device Security Code Allows a DMCC client to validate the security
code of an extension on Communication
Manager.
Get Device Returns the device that this phone object is in.
Get Media Mode Returns the current media mode that the phone
is in.
Release 7.0.0
23 02-602658
Issue 1
Get Media Returns the media object which will perform all
media operations on this phone.
Get Registered Returns true if the phone is currently in the
registered state.
Get Button Info Gets the button information for either a specified
button or all buttons on a device, including the
button identifier, button function, associated
extension (if applicable), and associated lamp
identifier (if applicable)
Get Display Gets a snapshot of the contents of the physical
device's display
Get Hookswitch Status Gets the hookswitch status of a specified device,
either on hook or off hook
Get Lamp Mode Gets the lamp mode status for either a specified
button or all buttons on a device, including how
the lamp is lit (flutter, off, steady, etc.), color and
associated button
Get Message Waiting Indicator Gets the message waiting status at a specified
device, either on or off
Get Registration State Get the current registration state for the phone.
If the state is “REGISTERED”, it also returns the
H.323 gatekeeper IP address.
Get Ringer Status Gets the ringer status of the ringer associated
with a device, including ring mode (ringing/not
ringing) and the ring pattern such as normal ring
or priority ring
Press Button Simulates the depression of a specified button
on a device
Redirect Media Instruct Communication Manager to direct the
media to a different IP Address
Register Terminal Registers a specific device with Communication
Manager in order to gain main, dependent or
independent control over the phone or extension
and specifies the desired media mode.
Applications can specify whether media
encryption is desired while registering.
Release 7.0.0
24 02-602658
Issue 1
Start Monitor Informs the API of what type of phone events
the application wishes to be notified of. Phone
events are events like lamp updates, display
updates, ringer updates, etc
Stop Monitor Cancels a previously initiated Start Monitor
request
Unregister Terminal Unregisters the specified device from
Communication Manager in order to give up
control of the device
Media Class
The Media Class provides an interface to allow media processing to be performed
including play, record and tone collection.
Release 7.0.0
25 02-602658
Issue 1
This class will allow an application to record voice stream data coming into a device and
to play messages to the device’s outgoing voice stream.
This class will also allow your application to collect DTMF tones coming into a device,
store them in a buffer, and report the tones based on application-specified retrieval
criteria. The retrieval criteria can be one or more of the following:
If multiple criteria are specified, then the first condition that occurs terminates the
retrieval and reports the string of DTMF tones collected. Both in-band and out-of-band
tone collection are supported. Out-of-band tone collection is recommended.
When tones are retrieved and reported to the application, they are removed from the
buffer. If the buffer fills up, the oldest tones are overwritten with the new detected tones.
The Tone Detection Events notifies an application whenever a DTMF tone has been
detected coming into a device. Both in-band and out-of-band tone detection is
supported. Out-of-band tone detection is recommended.
To learn how to use the Media Class, see “The Dashboard tool” and “Recording and
playing voice media” and “Detecting and collecting DTMF tones”.
Release 7.0.0
26 02-602658
Issue 1
Start Monitor Informs the API of what type of media events the
application wishes to be notified of. Media
events are events like media started, media
stopped, recording starting/playing, recording
stopped, tone detected, etc
Stop Monitor Cancels a previously initiated Monitor Start
request
Start Playing Sends a Start Playing XML message to the
server.
Stop Playing Stops only the player, not the recorder.
Suspend Playing Suspends only the player, not the recorder.
Start Recording Sends a Start Recording XML message to the
server.
Stop Recording Sends a Stop Recording XML message to the
server.
Suspend Recording Suspends only the recorder, not the player.
Start Dubbing Starts replacing an existing recording session
with the specified file
Stop Dubbing Stops replacement of an existing recording
session
Set Tone Retrieval Criteria Specifies the retrieval criteria
Start Tone Collection Used to start collecting DTMF tones sent to a
device and specifies the termination criteria.
Stop Tone Collection Used to stop collecting DTMF tones sent to a
device and report the tones that have been
buffered. This flushes the buffer.
Release 7.0.0
27 02-602658
Issue 1
Tones Retrieved Occurs when DTMF tones are retrieved from the
buffer. This event reports the retrieved tones to
the application.
Tone Detected Occurs when a DTMF tone has been sent to the
device
Media Started Indicates when the far-end RTP parameters
have changed and an RTP session has been
established. Also provides the media encryption
keys if media encryption is enabled for the
device.
Media Stopped Indicates when the far-end RTP parameters
have changed to null and the RTP session has
been disconnected
This class allows applications to get detailed call information and to determine the status
of the call information link. The call information link must be operational to get the call
information. The call information link is one of the communication links between
Communication Manager and the AE Services server.
The Call Information Link Class provides the following asynchronous operations:
Release 7.0.0
28 02-602658
Issue 1
Link Up Occurs when a link has come up and is now
active. Occurs the first time the link is brought
up, as well as every time the link is brought up
after being down.
Link Down Occurs when a link has gone down and is now
inactive. Occurs when it is determined that
Communication Manager is not responding or
Communication Manager and Device, Media
and Call Control API are out of sync.
Response will indicate which link is down and
whether the AE Services server will attempt to
reconnect automatically.
This class will provide single step conferencing capabilities to allow an application to add
a device into an existing call.
This class will allow an application to obtain 3rd party information about the devices
participating in a specified call. The information returned includes device identifiers, their
connections in the call, and local connection states of the devices in the call as well as
call related information.
This class provides information about calls associated with a given device. The
information provided identifies each call the device is participating in and the local
connection state of the device in that call.
The Call Control Services utilizes the TSAPI Service on the AE Services server. The use
of the Call Control Services requires the setup of the connection and cti-link between the
AE Services server and Communication Manager as well as a basic TSAPI license.
The use of the Snapshot Services requires the setup of the connection and cti-link
between the AE Services server and Communication Manager as well as a basic TSAPI
license
Note:
Care must be taken when creating a Device ID to ensure that the switch name is
properly set in the Device ID. Please see “Populating the Device ID Switch Name
and Switch IP Interface fields” for more information.
The Third Party Call Controller Class provides the following asynchronous operations:
Release 7.0.0
29 02-602658
Issue 1
Alternate Call Performs a third party Alternate Call
operation (put active call on hold and unhold
held call).
Answer Call Performs a third party Answer Call operation
(answers an incoming call).
Change Monitor Allows a DMCC client to change the
attributes of an existing monitor.
Clear Call Perform a third party Clear Call operation
(drops all parties on a call).
Clear Connection Performs a third party Clear Call operation
(drops all parties on a connection).
Release 7.0.0
30 02-602658
Issue 1
Generate Digits Performs a third party Generate Digits
operation (inject touch tone digits into an
active call).
Get Call Linkage Data Retrieve the Call Linkage Data for a normal
callID. (Avaya Universal Call ID - UCID).
Release 7.0.0
31 02-602658
Issue 1
Make Predictive Call Performs a third party Make Predictive Call
operation (originates a call between two
devices by first creating a connection to the
called device).
Single Step Transfer Call Performs a third party Single Step Transfer
Call operation (transfers an active call to
another device).
Snapshot Call Provides information about the devices
participating in a specified call.
Snapshot Device Provides information on the status of calls at
a specific device.
Release 7.0.0
33 02-602658
Issue 1
Start Monitor Informs the API of what type of Third Party
Call Control events the application wishes to
be notified of.
The Third Party Call Controller Class raises the following events for a device type
monitor or a call type monitor (Per Call or CallsViaDevice):
Agent Logged Off Occurs when an agent has logged off an ACD
device or an ACD group.
Release 7.0.0
34 02-602658
Issue 1
Endpoint Unregistered Event Occurs when a H.323 or SIP endpoint
unregisters from the device’s extension
number.
Note that the endpoint does not have to be
registered via DMCC, but the Communication
Manager must be CM 6.3 or later for H.323
endpoints and CM 6.3.2 or later for SIP
endpoints.
• It provides a method to allow a client to send their own XML messages to the
server and a response handle to then process the XML response. It also
provides an event handler to process any unhandled events coming from the
Release 7.0.0
35 02-602658
Issue 1
server. This allows an application to take advantage of new server features
without having to wait for a client with the support for that new feature.
• It provides the ability for the application to register two event handlers. One
handler is called when any request is sent to the server. The event includes the
XML message sent to the server. The 2nd handler is called when any request,
exception or event is received from the server. This can be useful for debug
purposes or for application developers working at the XML level who want to see
what these "raw" message look like.
Constant Classes
Constant classes are provided for the following:
Release 7.0.0
37 02-602658
Issue 1
Chapter 2: Getting started
This section describes what you need to do and what you need to know before you
begin programming to this API, including:
1. Go to www.avaya.com/devconnect
2. Select Member Login.
3. Log in with your email address and password.
4. Download the SDK (dmcc-dotnet-sdk-x.exe) from the DevConnect website
by navigating to the Application Enablement Services page and selecting the
appropriate SDK from the Technical Resources section. The download location
defaults to the desktop, but it does not matter where you download the files in
your directory system. The SDK file is dmcc-dotnet-sdk-x.exe, where x is the
load number.
Note:
The Application Enablement Services page can be located
through the Avaya Product Information/Documentation/SDKs link
under the left-hand Do Your Research menu options.
Release 7.0.0
38 02-602658
Issue 1
6. Follow the instructions to accept the End-User License Agreement (EULA) and
install the SDK. All of the SDK files are placed into a directory named dmcc-
dotnet-sdk.
The Avaya Application Enablement Services Device, Media and Call Control API,
implements a subset of the CSTA standard including some Avaya specific extentions to
the CSTA framework. The API supports monitoring and making calls at the physical
device level. Applications using this API have first party device control, first party media
control and third-party call control.
The following sections describe what you need to know about the following CSTA
concepts
• First Party vs Third Party (Device and Media Control vs Call Control)
• Devices
• Physical Elements
• Logical Elements
Release 7.0.0
39 02-602658
Issue 1
• Calls
• Service Requests
• Service Responses
• Events
• Negative Acknowledgements
First Party vs Third Party (Device and Media Control vs Call Control)
Basically, the differences between Device and Media Control and Call Control are the
differences between first-party and third-party call control.
AE Services’ Device and Media Control uses first-party call control, where an application
interacts with an endpoint using the model of a person physically manipulating a phone.
For example, to make a call a person picks up a handset and presses each digit, one
after the other. Similarly, to make a call an application invokes a method to cause the
endpoint to go off hook and invokes a PressButton method once for each digit. This
gives an application fine-grained control of and information about an endpoint’s state.
In contrast, AE Services’ Call Control uses third-party call control, where an application
issues higher level instructions. To make a call using third-party call control, an
application only has to invoke a single MakeCall method, which causes one endpoint to
call another. It is somewhat inexact, but you can think of the model of third-party call
control as a graph in which endpoints are nodes and calls are edges. The methods of
the API reconfigure the graph by adding, deleting, or moving edges.
Applications using Device and Media Control require the end-point used in the
application to be registered through AE Services. Registration of an end-point
associated with the Device, Media and Call Control API requires either a DMCC_DMC
license from WebLM (preferred) or an IP_API_A license from Communication Manager.
Applications using Call Control Services do not need to register devices, and thus do not
consume DMCC_DMC nor IP_API_A licenses; however, they do need a TSAPI or
UNIFIED_CC_DESKTOP license in order to use the Call Control service.
Note:
It is important to consider license consumption when deciding which style
of call control to use. If your application uses Device and Media control for
other reasons than controlling calls (for example, to record media or to
push feature buttons on a telephone) then you may want to consider
using first-party call control in order to not consume an additional license.
If, on the other hand, your application is primarily concerned with call
control, consider using Call Control Services as its higher level operations
and events are often easier to use.
Release 7.0.0
40 02-602658
Issue 1
Devices
In the context of this API, a device refers to a software instantiation of a phone or dial
string that is registered on Communication Manager. Such a device is also referred to as
a softphone. A device has physical and logical elements.
Physical Elements
The physical element of a device encompasses the set of attributes, features, and
services that have any association with physical components of the device that make up
the user interface of the device. Physical elements can be manipulated, such as pushing
buttons or going offhook, or they can be observed, such as observing the ringer or
whether a lamp is lit. The physical elements of a device include:
• Buttons
• Hookswitch
• Display
• Lamps
• Message waiting indicator
• Ringer
Logical Elements
A logical element is the part of a device that is used to manage and interact with calls at
a device. This element represents the media stream channels and associated call
handling facilities that are used by the device when involved in a call. The logical
elements that this API supports are:
• DTMF tones coming into the device
• Media stream coming into and out of the device
• Do Not Disturb
• Call Forwarding
Calls
Calls are made from and received by a device. CSTA performs most telephony services
against a connection that identifies a particular call.
Service Requests
In this API an application requests services of the AE Services server. Examples of a
request are “give me a device identifier”, “press a button”, “give me information about a
lamp’s status”, or “notify me when a tone comes into the device”.
Release 7.0.0
41 02-602658
Issue 1
Each request is processed by the AE Services server. The server may complete a
request synchronously in one logical step or it may take additional steps to pass the
request to Communication Manager and handle the response(s) before responding
asynchronously to the application with the request’s results in an event or negative
acknowledgement.
To make a request, the application must invoke the appropriate .NET class method.
Once the method is invoked, the .NET API will construct the required message and send
the request to the AE Services server.
Every time you request the API to do something (for example, push a button) and that
request results in a message being sent to the server, you will immediately get an
InvokeID back. The InvokeID is the message number that is sent to the server as
part of the request and returned as part of the response which may be useful in
debugging over on the server side.
Service Responses
Each service request is acknowledged with a service response (positive
acknowledgement). Some service requests, particularly those that request information,
are completed in a single logical step, thus the results of the request are reported in the
service response (single-step requests follow CSTA’s atomic model). Other service
requests, particularly those that require the AE Services server to pass on a request to
Communication Manager, take multiple steps to complete. (These follow CSTA’s multi-
step model.) Responses to multi-step requests merely indicate that the request was
received and is being processed. In some cases, response data values may indicate an
error in the request or in the processing of a single-step request.
When the request has been acted upon, the application will receive an asynchronous
message from the .NET API informing the application of the results of the request. In
order to get this message your application must have a registered Response Handler
(delegate) associated with the service request. You will see how to do this under
Learning from sample code on page 46.
Events
Events are asynchronous occurrences on a device that an application can choose to
listen for and respond to. Examples of events are the DisplayUpdatedEvent, which
indicates that the device’s display has changed, or TerminalUnregisteredEvent,
which indicates that the device has been unregistered by Communication Manager.
An application indicates its desire to be notified of events by using the Monitor Start
method on the various .NET API service classes. Once a monitor is established, the AE
Services server notifies the application of relevant activity by sending messages called
event reports, or simply events.
Note:
Release 7.0.0
42 02-602658
Issue 1
Once you receive an event, release the event thread immediately and
continue to do event processing on a different thread.
Negative acknowledgements
The AE Services server may respond to a service request with a negative
acknowledgement. A negative acknowledgement indicates that the service request has
failed. CSTA error categories are used to categorize errors into a hierarchy of error
return values. If an error is encountered, the details of the error will be in the "error"
string attribute of the appropriate response event.
Call Recording
Call recording provides the ability to record phone calls by employing the DMCC
Registration Services (see the “Registering Devices” and optionally see the “Recording
and Playing Voice Media” section in Chapter 3). If the client recording application
chooses not to employ the DMCC Voice Unit Services, then the application is
responsible for directing the RTP stream to a suitable recording application capable of
handling the media.
Note:
The Call Recording feature is supported for calls that are handled by DCP, H.323
and SIP endpoints, or by a mobile device.
The available methods for recording phone calls, via AE Services, include the following:
• Service observing method
A DMCC service client recording application registers as a Communication
Manager Service Observing extension in independent (or dependent) mode.
When a call is accepted by the user the Service Observer is added to the call.
• Single step conference method
A DMCC service client recording application registers as a standard
Communication Manager extension in independent (or dependent) mode. A
JTAPI, TSAPI or DMCC client application can monitor the user’s extension and,
when a call is accepted by the user, it conferences the recording client extension
into the call.
• Multiple registrations method
A DMCC service client recording application registers as the same extension
(either in dependent or independent mode) as that of the user who is taking the
calls. Since the incoming media in all of the extension’s RTP streams is the same
as for the main registrant (i.e. the user), the client application receives the same
RTP as the user, and can record the RTP. The DMCC service call recording
client is also able to register and connect after the user is already on the call.
Note:
Communication Manger does not play any warning tones into the call
while recording is in progress. It is up to the customer to warn the calling
parties via an announcement.
Release 7.0.0
43 02-602658
Issue 1
Note:
When the extension of the user taking the call is associated with a SIP
endpoint, the DMCC service client application must register in
Independent mode.
• Cell phone recording
AE Services 6.2 introduced the ability to record calls originating or terminating at
a cell phone. This feature combines the AE Services Multiple Registrations
method with the Avaya EC500 or the Avaya One-X Mobile (OPTIM) applications.
The DMCC service client application is able to connect to, and record, calls:
o answered either at the desk set or at the mobile device
o answered at the desk set and then extended to the mobile device
o answered at the mobile device and then retrieved at the desk set
Note:
For mobile calls and SIP endpoint calls, the Cell Phone Recording feature
does not use the call control aspect of the Multiple Registration feature.
Also, the Cell Phone Recording feature does not increase the number of
parties on a call.
Signaling Encryption
AE Services offers the ability to encrypt the signaling channel between the AE Services
server and Communication Manager. However, the option to encrypt this link is not
under the direct control of your application. Instead, it is an option that is provisioned on
Communication Manager, via the “set network-region” page. See the "Setting up a
network region for Device and Media Control" subsection of the "Administering
Communication Manager for AE Services" chapter of the Avaya Aura® Application
Enablement Services Administration and Maintenance Guide.
The encryption of the signaling link is automatically negotiated between the AE Services
server and Communication Manager during the device registration, and the resultant
encryption used is dependent on the options set for the network region. The following
encryption types are supported:
• Challenge
• Pin-Eke
• H323TLS
Release 7.0.0
44 02-602658
Issue 1
Note:
The H323TLS security profile option is only available for use with
Communication Manager 6.3.6, or later, running in Secure Mode with
FIPS. In this case, the AE Services Management Console screen,
“Communication Manager Interface” > “Switch Connections” > “Add/Edit
Connection”, must have the options “Secure H323 Connection” and
“Provide AE Services certificate to switch” check-boxes checked
When registering the device, the negotiated signaling encryption type is included as a
parameter in the RegisterTerminalResponse message.
Media Encryption
You have the ability to encrypt the RTP (media) stream between the application and the
other endpoint of the call.
The option to encrypt the RTP stream is provisioned on the Communication Manager via
the “change ip-codec-set” page. See the "Creating the Device and Media Control codec
set" subsection of the "Administering Communication Manager for AE Services" chapter
of the Avaya Aura® Application Enablement Services Administration and Maintenance
Guide. However, in this case, the application does have some (albeit limited) control
over the type of encryption used. The media encryption will be one of the following
types:
• Advanced Encryption Scheme (AES)
• SRTP encryption schemes (multiple options)
• no media encryption
When registering the device, the application may specify which media encryption
schemes that it supports. For more details see Choosing the media encryption on page
78.
The list of application-supported media encryption schemes will be matched to the list of
encryption schemes provisioned on Communication Manager’s “change ip-codec-set”
page for the device’s codec set. Communication Manager will pick an encryption
scheme that is common to both lists, if possible.
Note:
The encryption scheme and encryption keys (if any) chosen by
Communication Manager will be indicated in the MediaStartEvent
message. See MediaStartEvent Handling on page 140.
Release 7.0.0
45 02-602658
Issue 1
Accessing the client API reference documentation
You may need to reference the .NET Programmer’s Reference provided with this API. It
is available on the Avaya Support site (www.avaya.com/support ) as both a viewable
HTML document and a downloadable zip file.
This html documentation will also ship with the SDK. This documentation describes all of
the interfaces and their parameters. In addition, Visual Studio will provide help with the
parameters as you are writing the code.
For information on getting started with using the Dashboard tool, see The Dashboard
tool on page 48.
These code snippets are now available for use in your applications. To utilize these in
your code, right click in your source code and select Insert Snippet. You may then
specify which snippet to insert into your code.
Another key learning tool is the set of sample applications that are provided with this
API. These sample applications are located in the SDK in the following directories:
Release 7.0.0
46 02-602658
Issue 1
dmcc-dotnet-sdk/Examples and dmcc-dotnet-sdk/JScript. Additional
information pertaining to setup and configuration of the sample applications can be
obtained from the ReadMe.txt file in the SDK under the directory dmcc-dotnet-sdk.
Release 7.0.0
47 02-602658
Issue 1
Chapter 3: Writing a client application
This chapter describes how to write an application using the Application Enablement
Services.
The .NET SDK ships with a tool that will assist you in both aspects.
Note:
The Dashboard is a tool that is constantly evolving and being improved.
The following screenshots may not match the Dashboard exactly but
should be close enough to give you an idea of its capabilities.
The information in this chapter assumes a developer has zero knowledge of Device,
Media and Call Control.
We will outline the steps necessary to write a simple application. In general, most, if not
all, applications will need to do the following:
• Start a session with the AE Services server
• Get one or more devices that you are interested in monitoring.
• Register those Devices to the Communication Manager.
• Listen for events that you are interested in (e.g., lamp updates).
• Process those events.
For our sample application, we will assume the developer wants to do the following:
• monitor all incoming calls for extension 5382834
• log the duration of the calls
Release 7.0.0
48 02-602658
Issue 1
The system displays following:
Notice that most of the buttons are inactive. The only buttons that are active are the
ones that are valid given the current state of the Dashboard. In this case, the only button
that is active is the Start Application Session button.
It is recommended that the application, log all negative responses since this will be an
important source of information for debugging the application. Look at the server side
logs for more information about what happened. The logs will contain helpful information
that you may need to provide to DevConnect.
For more information on negative acknowledgements please see section 9.2.2 and 9.3
in the ECMA-269: Services for Computer Supported Telecommunications Applications
(CSTA) Phase III found in the Publications section of the ECMA web site
(http://www.ecma-international.org/).
Release 7.0.0
49 02-602658
Issue 1
The CSTA specification provides a long list of standard error messages that a request
could return. This list of standard CSTA errors is somewhat limiting in that it does not
cover all the possible errors. The latest version of the CSTA specification extended the
error message capability by allowing the creation of vendor specific errors. To utilize this
new capability an XSD, avaya-error.xsd, was created. This XSD specifies an
enumeration of all the extended error codes. Private error codes were added to convert
TSAPI ACS Universal errors. These errors will be sent to the application instead of the
generic CSTAErrorCode ‘unspecified’ when applicable. Appendix I: ACS Universal Error
Codes contains a table of the errors that were added and their meaning. The use of an
XSD will make it easy for any client (Java, C#, etc.) to have a programmatic way of
knowing what AE Services extended error codes are possible.
Session Management
An application session must be established between your application and the AE
Services server for the purpose of exchanging application messages. It is required that
an application session be established before application messages can be exchanged.
This allows you to recover and reestablish an existing session on a new connection. The
application session is established by the ServiceProvider class.
The ServiceProvider class is the starting point for all applications to:
• indicate which AE Services server to connect to
• identify the application
• establish an application session
• gain access to all API services
Release 7.0.0
50 02-602658
Issue 1
The input fields that turned light blue in this case are the parameters that are required by
the Start Application Session method.
Note:
We also see a tool tip that comes up when the mouse is held over a
button or an input field. The tool tip provides additional information about
that button or the input field.
We now know exactly what information is needed to start an Application Session. The
required information is:
• The IP Address (or DNS name) to the AE Services server
• The port that you want to connect to, typically 4721 or 4722 (4722 is the default
port for encrypted information)
Note:
If you want to use the non-secure port, first you must enable the
unencrypted port (4721) on the AE Services server. Using a browser, go
to the AE Services Management Console web-pages and click on
“Networking”, then “Ports”. On the “Ports” web-page, click to enable the
“Unencrypted Port”, then click “Apply Changes”. Also, note the directive to
restart the AE Services server.
• You need to indicate if this port is a secure socket (usually checked if port 4722
is used)
• You need to indicate if you want to allow a certificate name mismatch (only
necessary if a secure socket is used)
• You need to have a valid login name and password on the DMCC server
Release 7.0.0
51 02-602658
Issue 1
• You need to specify a name for the session
• You need to specify what protocol version you want to communicate to the
DMCC server on.
Note:
The .NET Service Provider class provides a set of constants that can be
used to set the Protocol Version. In the .NET Reference Documentation,
see ServiceProvider.DmccProtocolVersion.
Note:
Each release adds functionality to the previous releases. If you wish to
use an older specific release version protocol rather than the default
version for the SDK, you can specify the appropriate protocol version per
the release value. AE Services 3.x, 4.x and 5.x applications are expected
to run against the current release of AE Services as long as the protocol
version associated with the SDK is specified correctly. Appendix A in the
Avaya Aura® Application Enablement Services Overview document
contains more information on API and client compatibility.
• You need to specify how long the session (in seconds) should last if no keep
alives are returned. We recommend that you do not override the default of 180
seconds. The minimum value is 30 seconds, and the maximum value is 7200
seconds (2 hours).
• You need to specify (in seconds) how long the session is to be kept active in the
server AFTER the server tears the connection down due to no keep alives being
sent. This will allow you to attempt to reconnect the session if you are notified
that the session was terminated by the server. (60 is a reasonable value for this
field) The minimum value is 0 seconds, and the maximum value is 7200 seconds
(2 hours).
Note:
The AE Services server only allows session durations between 30
seconds and 2 hours. If you request a duration shorter than 30 seconds
or longer than 2 hours, the duration will automatically be set to the
negotationed value specified in the ResetApplicationSessionTimerPos
response message of either 30 seconds or 2 hours.
If the server session duration timer expires due to not having received the
ResetApplicationSessionTimer message, it will:
Release 7.0.0
52 02-602658
Issue 1
1. Close the socket
2. Mark the session as inactive
3. Start the cleanup timer using the time specified in the Cleanup Delay.
If the application then attempts to send any messages, it will receive a Negative
Acknowledgement response. If this happens, the application should then take recovery
actions as specified in the recovery section (Chapter 4: Recovery).
Release 7.0.0
53 02-602658
Issue 1
You now have a valid session established. The server may respond with a
StartApplicationSessionNegResponse with an error code to define why the server failed
to start the session. Your application may also receive a special negative response
message that is associated with a failure while attempting to recover a session. Please
see the Chapter 4: Recovery for details.
The next thing you need to do is to specify the session characteristics and obtain a
Device ID.
SessionCharacteristics
Since the 5.2 release of AE Services, DMCC applications are able to specify several
“Session Characteristics” that will alter the way their application interfaces with DMCC.
The SessionCharacteristics are optional and when they are not specified, previous
behaviors are preserved.
At present, there are no restrictions on the number of times that the Session
Characteristics may be changed for a given session. However, changing the
characteristics in the middle of a session may have unforeseen issues involving possible
Call Control services or events and their delivery to the client. Thus, it is recommended
that the Session Characteristics are set up immediately after the session has been
established. Thereafter, the application should exercise caution in setting new
characteristics for the session.
DeviceID Type
The two Device ID Types that can be specified are “DMCC” and “Tel URI”.
The DMCC Device ID type is the type that has been supported in previous releases of
DMCC and is the default if no DeviceID type is specified.
The “Tel URI” type allows an application to interact with DMCC using E.164 numbers
rather than switch-specific extensions and dial strings. DMCC leverages the Dial Plan
provisioning of the AE Services Management Console pages in order to work in this
mode.
While this mode can be extremely useful there are several important limitations to be
considered prior to using Tel URI mode.
• Only Monitoring Services, Call Control Services, Snapshot Services and Logical
Device Feature Services may be used when working in this mode.
• If Monitoring Services is used in Tel URI mode, the application must take care to
only subscribe to Call Control, Logical Device Feature and Endpoint Registration
events.
• The first request issued by the application must be a Monitor Start or Snapshot
Device request as those requests are used to associate the Tel URI with a
particular administered Switch.
• The Dial Plan must have been provisioned in the AE Services Management
Console pages for the Communication Manager(s) of interest.
• A given AE Services instance may only serve users in a single country, even if
the Communication Manager is a multi-national deployment. This is because the
dial plan rules do not take the calling number into account when determining how
to convert a called number.
For more details on how to provision Dial Plan rules, please see the section on DialPlan
Administration in the “Avaya Aura® Application Enablement Services Implementation
Guide for Microsoft Office Live Communications Server 2005 or Microsoft Office
Communications Server 2007”
“Desktop Call Control” event filtering may be leveraged by applications that are directly
representing call state to end-users. In this mode, DMCC will filter out events that would
otherwise lead to confusing call states for the user. The following events filtering is
applied in this mode:
• Delivered and Established events that would reveal the presence of a silent
observer. When Single Step Conference is used to add a participant to a call, an
application can optionally specify that the participant be added in “listen-only”
mode. This is generally used to add automata such as virtual call recording
extensions. A participant that has been added using the Communication
Manager Service Observing feature would also be a silent participant. It is
Release 7.0.0
55 02-602658
Issue 1
generally beneficial to hide the presence of such silent observers from an end-
user application that otherwise shows all parties on the call.
• Established events that indicate that a call has been answered at a different
device than the one being monitored. This generally occurs in a situation where
one user has a bridged appearance of another. In that scenario, both devices
alert and the call can be answered at either device. In general, an end-user
application showing call state on the device that did not answer would then want
to show that the call has been cleared. Consequently, DMCC will convert such
an Established event to a Connection Cleared event prior to sending the event to
the application.
• Bridged Appearance Alert provisioning is applied. This provisioning allows the
administrator to specify whether applications monitoring a station with bridged
appearances of another station should receive Delivered events that would
indicate that a bridged appearance is alerting. For example, consider a case
where an assistant has bridged appearances of several executives. In some
deployments, it may not be desirable for that assistant’s call control application to
indicate that there is an incoming call for one of these bridged appearances. In
other deployments, it may be desirable for the application to alert in this scenario.
The Bridged Appearance Alert provisioning allows the administrator to specify
which behavior is desired for their particular deployment, and even allows per-
user provisioning.
If an application is not using Call Information Services or the Third Party Call Control
Services, it is also valid to include only a switchIPInterface and dial string in the
getDeviceID request, and thereby not administer the H.323 Gatekeeper list.
Note:
The DeviceID format is subject to change in future releases. Your application
should not be parsing these ID’s, but rather should be using them as keys in their
requests.
Release 7.0.0
57 02-602658
Issue 1
Comparing Device Identifiers
Depending on how you obtained the DeviceIDs, there may be small formatting
differences between two DeviceIDs that you might think should be equal. A DeviceID
comprises of four main parts:
1. the phone extension – normally consists of 4-13 digits .
2. the name of the switch associated with the extension – this should match one of
the “Switch Connections” provisioned via the AE Services Management Console
web pages.
3. the IP address of the CLAN or Processor Ethernet interface used to connect the
phone to the switch (optional)
4. the instance of the phone extension – ranges from 0 -2 (default = 0)
Parts 1, 3 & 4 are comprised of numeric digits and normally pose no comparison
problems. However, part 2 (switchname) consists of alphanumeric characters and can
contain either upper-case or lower-case alphabetic letters. Thus, for example, it is
possible to obtain the DeviceIDs:
deviceId1 = “12345:myswitch:192.168.1.1:0”;
deviceId2 = “12345:MYSWITCH:192.168.1.1:0”;
where the first DeviceID may have been obtained from a “getDeviceID()” request, while
the second DeviceID may have been obtained from an event. Always perform case-
insensistive string comparisons when comparing DeviceIDs that contain a switchName.
As a way to assist the developer, the Device class contains two helper methods,
• DeviceIDComparer(String,String)
Performs a case insensitive string comparison of 2 DeviceIDs.
• ExtensionComparer(String,String)
Performs a case insensitive string comparison of the extension and switch name
portion of 2 DeviceIDs.
Release 7.0.0
58 02-602658
Issue 1
administration database, and will resolve the given switchIPInterface to a
switchName, then populate this value in the DeviceID.
• The AE Services server also offers a feature which will use a round-robin
algorithm to distribute softphones to a list of H.323 Gatekeepers (i.e. to
automatically populate the switchIPInterface). If using this feature, the
application need only know a symbolic name for the switch (i.e. switchName),
rather than maintaining a list of Gatekeepers with which it wishes to register. To
take advantage of this feature, the list of H.323 Gatekeepers must be
administered in the AE Services Management Console for the given Switch
Connection.
o Prior to AE Services 6.1, when getting a DeviceID, the application would
specify only a switchName and extension. Upon receiving the
“GetDeviceID” request, the switch would pick the next H.323
Gatekeeper from the list, and return it, as part of the DeviceID. Later,
when the application attempts to register the device, it would register
with that gatekeeper. Unfortunately, if the gatekeeper was out-of-service
when the device registration occurred, it was necessary for the
application to release the DeviceID and get another one before the
registration could be re-attempted.
o For AE Services 6.1 and later, if only the switchName and extension
are specified in the “GetDeviceID” request, the choice of H.323
Gatekeeper is delayed until the device is actually being registered. In
this case, the DeviceID that is returned to the application (in response to
GetDeviceID) will have “0.0.0.0” as the switchIPInterface portion of
the DeviceID. This designation is merely meant to indicate that the
H.323 Gatekeeper for registration has not yet been chosen. Delaying the
choice of gatekeeper until the device needs to be registered allows
greater flexibility for the application. Thus, if a gatekeeper is down or
out-of-service at the time of registration, then it will not be picked from
the list of gatekeepers. Instead, the out-of-service gatekeeper will be
skipped, and the next available in-service gatekeeper will be allocated
for the device registration. In this way, the need for the application to
invoke “ReleaseDeviceID” and re-invoke “GetDeviceID” (in order to pick
another gatekeeper) is avoided. Furthermore, the probability of picking
an out-of-service gatekeeper IP address is much reduced.
Note:
The H.323 gatekeeper being used for a given DeviceID can
actually change during the life of the registration. The most
common cause for this is a failover of the Communication
Manager to/from an ESS or LSP. If you need to know which
H.323 gatekeeper is currently being used for a given device
registration, then you can do one of the following:
Release 7.0.0
59 02-602658
Issue 1
• From your application program, issue a
“GetRegistrationState” request for the device. If the
device is registered, then the response will include the
current H.323 gatekeeper IP address.
Note:
The switchName field is only required for Call Information Services, Third
Party Call Control Services, and Phone Registration Services. If an
application is not using one of these services, it is not required to
administer a Switch Connection and an H.323 Gatekeeper List, nor to
specify a switchName in the GetDeviceID request. In this case, any calls
with this DeviceID to Call Information Services or Third Party Call Control
Services will fail. Calls to Phone Registration Services may succeed, but
will require an IP_API_A license from Communication Manager.
Multiple DeviceIDs
In AE Services 4.1, the ability to register up to three instances of the same deviceID was
introduced. This ability allowed the client application to implement a rudimentary, client-
side, high-availability setup, which allowed the client to “control” the extension from a
secondary or tertiary DeviceID, if control of the primary DeviceID failed. The deviceID
was identified by the extension number and the Communication Manager to which it was
being registered (either by switch-name and/or by IP address of the CLAN).
Release 7.0.0
60 02-602658
Issue 1
• Your application can specify Boolean.FALSE which means that only one session
can control the DeviceID. The effect is the same as not setting the
controllableByOtherSessions parameter. This is for backward compatibility
with applications that use an earlier version of the Java SDK.
• Your application can specify Boolean.TRUE which means that more than one
session can control the DeviceID. It is recommended that user authorization be
enabled for device(s) that can be controlled by multiple sessions. There are
three different authorization policies offered and that are explained in the “User
Authorization Policies” section
Device ID Instances
Starting with Communication Manager 5.2 and AE Services 5.2, the need for multiple AE
Services servers in order to register multiple instances of the same device with the same
switch has been eliminated.
The deviceID has been expanded to include the device instance, as well as the
extension, switchname and Gatekeeper IP address. Thus, you can obtain up to three
instances of the same deviceID through just one AE Services server.
When you obtain a deviceID (using Device services getDeviceID()), if you do not specify
which device instance you require, the instance will automatically default to instance ‘0’;
otherwise, you may specify which of the three possible instances of the deviceID that
you require.
• DeviceInstance.VALUE_0
• DeviceInstance.VALUE_1
• DeviceInstance.VALUE_2
Note:
The device instances can be used in any order – i.e. it is not necessary to get
instance ‘0’ before instance ‘1’, nor to get instance ‘1’ before instance ‘2’.
Release 7.0.0
61 02-602658
Issue 1
Since a user could have multiple DeviceID’s associated with a session, the results will
be returned to the application in a series of events. The application will need to register
for the appropriate SessionManagementEvents using the
SessionManagementStartMonitor request. In addition, the application will need to add
an OnGetDeviceIdListEvent delegate to allow the application to receive and process
the events. The event(s) the application will receive is the GetDeviceIdListEvent.
Note:
The specified requests, events, and delegates are defined in the ServiceProvider
class.
Note:
This exercise is a continuation of the previous exercise.
Specifically we need:
• Extension
• Switch Name (or IP Address)
Release 7.0.0
62 02-602658
Issue 1
• Do we want other sessions to also control this station
Fill in the required information and push the Get Dev. Id button:
Now that we have a Device ID, the next thing we need to do is detect that a user is on a
call. We have decided we want to monitor all phone events to see what is coming in. To
accomplish this we need to create a monitor for phone events.
Notification of Events
Your application can choose to be notified of asynchronous events that occur on a
device by implementing and registering a service delegate. Asynchronous events
include:
• Telephony events.
Examples of telephony events are when the lamp state has changed or a DTMF
tone has been detected.
• Asynchronous responses to service requests.
Release 7.0.0
63 02-602658
Issue 1
For example, after requesting to register a device an event is received from the
AE Services server indicating whether the request succeeded or failed.
The .NET API uses what the .NET Framework call delegates to be notified of events.
Each of the .NET API classes contains a set of deletegates called EventHandlers and
ResponseHandlers that an application can implement and register with the API.
For a complete list of the available handlers exposed by the .NET API, please see the
Avaya Aura® Application Enablement Services Device, Media and Call Control .NET
Programmer’s Reference.
Note:
The .NET Programmer’s Refeence is also available in the .NET SDK at
“dmcc-dotnet-sdk/Docs/html/index.htm”
In order to guarantee that events are not missed the event should be registered before
the device is registered. Your application should unregister all event monitors once they
are no longer needed.
This API will not block an application from registering multiple event monitors of the
same type (i.e. RegisterTerminalResponseHandler). In this scenario each registered
handler could perform a unique set of tasks.
Note:
It is a common mistake to inadvertently add the same handler
implementation multiple times. This is allowed, but may not be what your
application intends. Check your logic to be sure your code adds only the
number of handlers it intends. Programmatically, a list of monitors can be
retrieved from the server using the GetMonitorList request. Alternatively,
the event CrossRefID can be tested to verify that many identifiers do not
map to the same listener.
This will be performed from the Dashborad tool in the Registering for Events section.
Release 7.0.0
64 02-602658
Issue 1
Unregister for Events
Each of the .NET API services contains a method called Stop Monitor which is used to
unregister a monitor based on its monitor id.
For the Dashboard, select the appropriate monitor listedin the Monitor ID listbox and
click the Stop Monitor button.
Note:
This exercise is a continuation of the previous exercise.
We now see that we can monitor display updates, hookswitch updates, lamp mode
updates, ringer status updates, and get notified if the terminal is unregistered.
Since we are not sure which ones we want, we will monitor all phone events.
Release 7.0.0
65 02-602658
Issue 1
So we push the Start Phone Monitor button.
Now that we have the monitor started, we need to register the terminal.
Registering Devices
The registering of devices with Communication Manager, in AE Services, is done
through Device and Media Control to monitor or control a device using first-party call
control. This tells Communication Manager which dependency mode you want (Main,
Dependent or Independent control of the device) and what kind of media mode you
want. Only devices that are softphone enabled on Communication Manager’s Station
form can be registered.
Note:
The registration dependency modes and media modes are described in
“Dependency Modes” and “Media Modes”. You will find information on the call
capacities your application can expect to be able to handle in the "Capacities for
calls in Device, Media and Call Control applications" section of the "Capacities
Release 7.0.0
66 02-602658
Issue 1
for types of applications" chapter of the Avaya Aura® Application Enablement
Services Overview.
Note:
Registering a device with Communication Manager is only necessary for
Device and Media Control. This is not necessary for Call Control.
AE Services will verify that the user invoking any DeviceID based service request is
authorized to control that DeviceID. An error will be returned if an unauthorized user
attempts to control a device.
Communication Manager 5.0 and later allows up to three Device, Media and Call Control
station clients to register to one extension. This extension must be administered as a
DCP or Avaya H323 IP Softphone. If necessary, all three DMCC endpoints registered to
a common extension can be configured to be in 3 different “network regions”. All three
endpoints that are registering to an extension can request separate media streams.
Each DMCC endpoint registration must either:
• act through different AE Services servers, if they specify the same instance of the
deviceID (instance ‘0’ by default).
• act through one AE Services server, if they specify different instances of the
deviceID.
The first option provides a measure of high availability with standalone (not in a standard
High-Availability configuration) AE Services servers. For example, the client could
register the same endpoint through two different AE Services servers and have recorded
media flowing to both. The second option also provides the ability to record dual feeds
for recorded media, but provides High-Availability through the standard AE Services
paired-servers configuration.
Each media (RTP) stream is the summed stream of all the participants in the call. For
example, if an Agent using a physical phone with extension 1000, is talking to extension
1001 and extension 1002. And a DMCC endpoint is registered to extension 1000 as
Dependent in Client media mode, at the time of the call, the DMCC endpoint will receive
the summed talk streams of the Agent (at extension 1000) and extensions 1001 and
1002.
Note:
The DMCC endpoint registered in Dependent (or Independent mode when a
physical set is registered/present), is connected to the call in listen only mode.
Therefore no additional talk time slot is allocated for this DMCC endpoint. Also,
this DMCC endpoint does not count toward the number of participants that can
be in a conference call.
Release 7.0.0
67 02-602658
Issue 1
RegisterTerminal request you must at a minimum specify which device to register
and the password that is administered for the device on the Communication Manager
Station form. There are also a number of options to choose from. For more details on
setting up a RegisterTerminal request, see the .NET Programmer’s Reference.
Some important decisions you will need to make when registering a device include:
• What registration dependency mode to choose
• What registration media mode to choose
• What codecs to choose
• What media encryption to choose
Note:
If your application needs to register many devices, we recommend you spread
out the registration of the devices. Register no more than 50 stations at one time
and wait until your application has received all of the responses before
attempting to register more stations.
The main difference between Endpoint Registration events and the existing Registration
& Terminal events is that Endpoint Registration events can be monitored for any H.323
or SIP endpoint that can be registered to Communication Manager. The endpoints do
not have to be registered using DMCC, as is the case for the existing Registration &
Terminal events. For Endpoint Registration events, the endpoints can be registered to
Communication Manager via any current means, provided they use the H.323 or SIP
protocol for registering.
Similarly to the existing Registration events, Endpoint Registration events are monitored
on a "per device" basis. Whenever the monitored endpoint registers or unregisters
against the Communication Manager switch, the appropriate EndpointRegistered or
Release 7.0.0
68 02-602658
Issue 1
EndpointUnregistered event will be called, enabling the DMCC application to handle the
event and the data contained within it.
Release 7.0.0
69 02-602658
Issue 1
6. Code – an integer value indicating the reason for the unregistration.
7. Set Type – the model of the phone as provisioned in Communication Manager.
8. Service State – the overall service state of the station after the endpoint has
unregistered. Note that the overall service state may still be “in-service” if there
are other endpoints registered to the same extension.
If the specified device has one or more endpoints registered against Communication
Manager for that extension, then the response will contain a set of data for each of the
registered endpoints. The set of data for each registered endpoint is identical to the data
outlined in the Endpoint RegisteredEvent. However, if there are no endpoints registered
against Communication Manager for the specified device, then the response to the
Endpoint Registration Information request will be empty.
Note:
For details on how to softphone enable a device, see the appropriate Avaya
Aura® Application Enablement Services Installation and Upgrade Guide for the
offer you have purchased (VMware or Software Only).
Device and Media Control support of SIP endpoints is extremely limited. Of course,
DMCC can register a virtual H.323 station which can then be used to record calls that
involve SIP stations. However, you cannot register an independent or dependent DMCC
Release 7.0.0
70 02-602658
Issue 1
station against a SIP endpoint, so you cannot exercise device monitoring/control over it.
Note that, DMCC can register an H.323 station in main mode against an extension that
is provisioned as a SIP set. The use case here would be that the user has a SIP station
on their desk but also wants to use a DMCC app to register in telecommuter mode when
they’re at home. However, in this case, a special Feature Named Extension (FNE) has
to be dialed to tell CM whether ASAI should be controlling / monitoring the H.323 set or
the SIP set at any given time."
For DMCC Call Control Services, any Communication Manager supported endpoint can
be controlled by the AE Services server. This includes some of the available SIP
endpoints, as well as DCP and H.323 IP endpoints.
Note:
You cannot choose Independent or Dependent dependency mode with SIP
endpoints, so you cannot exercise device monitoring/control over them.
For more information on the types of endpoints supported for Call Control Services, see
the AE Services TSAPI documentation. Finally, for more specific information on SIP
device support, see the AE Services Overview document.
Registration Modes
Dependency Modes
At registration time, the application specifies the desired registration dependency mode.
This indicates who controls the device’s physical elements and media.
Only an endpoint registered as Main can block the transfer of talk capability to
an endpoint registered as Dependent or Independent via the "share-talk"
button.
Note:
Release 7.0.0
71 02-602658
Issue 1
The "share-talk" button push is processed only if an endpoint registers
using any media mode other than No Media.
An instance of a device that registers in this mode can originate and receive calls
and can talk and listen even when the Main device is not registered.
A device will be allowed to register in this mode only if another device is already
registered to Communication Manager using the same extension in Main mode.
A request to register using Dependent mode will fail unless another endpoint is
already registered to that extension in Main mode.
When to use:
• Main
Use this mode when you need to be able to answer calls, make calls, talk, or
listen, regardless of the presence of other registrants.
This mode can be used with any Media Mode including No Media.
• Independent
Release 7.0.0
72 02-602658
Issue 1
Use this mode when you wish registration to succeed regardless of whether a
Main registrant already exists.
• Dependent
Use this mode when you wish registration to succeed only if a Main registrant
already exists and you want to unregister when the Main registrant unregisters.
This mode can be useful if you wish to listen to a call whose device is already
registered as Main.
This mode would also be useful if you wish to monitor/control a physical device.
Media Modes
When a device is registered by an application, the application has access to the real-
time protocol (RTP) media stream coming into and going out from the softphone.
There are four media modes available when a device is registered in Main dependency
mode: server media, client media, telecommuter, and No Media.
The following table, Registration Dependency and Media modes, illustrates what media
modes are allowed with each dependency mode.
2
Corresponds to Exclusive Control in previous releases.
3
Corresponds to Shared Control in previous releases. In this mode, the user of a telephone is not
notified of actions initiated by an application except through resulting status changes to the device’s
lamps and display. Also in this mode, the application is not notified of actions initiated by a user of
the telephone except by status changes to device’s hookswitch, lamps, ringer, and display.
Release 7.0.0
73 02-602658
Issue 1
When multiple endpoints are registered to the same extensions, all endpoints see
activity on other endpoints when status changes to the device’s hookswitch, lamps,
ringer, and display. An endpoint in this case would not be aware of the following action
taken by another endpoint:
• If endpoint A presses a digit to make a call, other endpoints (for examples, B and
C, assuming 3 endpoints registered to an extension) will not see the digits sent
by A to the AE Services server.
• Speaker button press, head-set button press and taking head-set off the cradle
are all seen as off-hook requests by Communication Manager. And therefore
other endpoints registered to the same extension will only see an off-hook event.
• Feature button presses are undetectable unless the feature button has a lamp
that toggles when the button is pressed.
The RTP parameters that an application can control or state preferences for at
registration time are:
The following table “Choosing a media mode” shows the media modes available, when
to use each, and how to request each:
Note:
Although it is possible for the client application to start a monitor on a
terminal that is registered in telecommuter or no-media mode, the client
application will not receive MediaStart or MediaStop events.
Release 7.0.0
74 02-602658
Issue 1
Table 20: Choosing a media mode
Release 7.0.0
75 02-602658
Issue 1
Table 20: Choosing a media mode
The following table Media Control Capabilities shows the media control capabilities of
the AE Services server for both server media mode and client media mode.
Record media from a call into a WAV provided by the provided by the
file server application
Release 7.0.0
76 02-602658
Issue 1
Table 21: Media Control Capabilities
Choosing a codec
A codec is the algorithm used to encode and decode audio media. For devices choosing
media modes of either client-media or server-media, the application can optionally
specify at registration time what codecs are preferred for the device. The codec options
are:
Specify the set of codecs your application supports and list them in preferential order in
the Phone.MediaInfo parameter of RegisterTerminal request. If you do not
specify a set of codecs in the Phone.MediaInfo parameter of the
RegisterTerminal request, the AE Services server will default to G.711 A-law as the
first choice and G.711 Mu-law as the second choice. If Communication Manager cannot
4
Media encryption is provided by the application unless the application is using the Avaya provided
client media stack in which case it will be provided by the server.
Release 7.0.0
77 02-602658
Issue 1
satisfy your request for specific codecs, then calls will still go through, but there will be
no media.
Note:
For server media mode you cannot specify a mixture of G.711 and G.729
codecs for a single device. This is because there is no conversion offered
by the server.
For more information about selecting and administering network regions and their
codecs, see the Avaya Aura® Application Enablement Services Administration and
Maintenance Guide.
Specify the set of encryption options your application supports and list them, in
preferential order, in the MediaInfo parameter of the RegisterTerminal request. If
you do not specify a set of encryption options in the MediaInfo parameter, the AE
Services server will default to "none" (no media encryption).
Note:
You will find information on call capacities your application can expect to
be able to handle in the "Capacities for calls in Device, Media and Call
Control applications" section of the "Capacities for types of applications"
chapter of the Avaya Aura® Application Enablement Services Overview.
This section includes information on how the choice of registration
dependency modes, media modes, codecs and encryption can affect the
performance of your applications.
Redirecting Media
This request is provided by the Medis class. It allows an application that has registered a
device in client media mode to redirect the media to any destination, even in the middle
of a call.
If a call is underway, redirecting the media stream causes the current media stream to
be directed to the requested location; otherwise, it will cause any future media stream to
be directed to the requested location. The new media destination will remain in effect
until another RedirectMedia request is received or the device is unregistered.
Release 7.0.0
78 02-602658
Issue 1
There is a known limitation in the implementation of this feature in Communication
Manager. The CM expectation is that the media will be directed to a new IP destination.
Thus, when CM checks the RedirectMedia request for a new destination, it only checks if
the IP address has changed (not the port number). Thus, a RedirectMedia request that
specifies the same IP address, but a different port number, will not be redirected for the
call in progress. However, there is a workaround for this scenario. This workaround
requires the application to send two RedirectMedia requests, instead of one.
For example, if the media is currently going to IP address 10.9.20.17 and port 4725, and
you want to redirect it to port 4730 at the same IP address, you could do the following:
1. RedirectMedia to IP address 0.0.0.0 and port 4725 (specifying a null IP
address will effectively stop the media to the device, but will not end the call)
2. RedirectMedia to IP address 10.9.20.17 and port 4730 (since the IP address
has now changed, Communication Manager will correctly process this request)
If your application wants the ability to share the talk capability, you will use the "share-
talk" button. The "share-talk" button must have been administered in Communication
Manager. For information on how to administer the share-talk button on Communication
Manager, please see the Avaya Aura® Application Enablement Services Administration
and Maintenance Guide.
Communication Manager will process a "share-talk" button push only if the media mode
of that endpoint is not No Media and the extension is in a call.
Once in a call, an endpoint registered as Main can press this button to block any
endpoint registered as Dependent or Independent from taking over the talk capability.
The Main endpoint can then unblock it by pushing this button again.
If a Main endpoint has not blocked the talk capability, a Dependent or Independent
endpoint can press this button to acquire the "Talk" capability. The Dependent or
Independent endpoint can press this button a second time to move the talk capability
back to the Main endpoint.
Many organizations use E.164 format when storing employee’s telephone numbers in
their directory (for example, Microsoft Active Directory or Lotus Domino). If your
application performs directory queries based on an individual’s name, it may receive
E.164 format numbers in return. In such cases, you must convert the E.164 number to a
Communication Manager extension or dial string before getting a Device ID to use with
the Device, Media and Call Control services.
Release 7.0.0
80 02-602658
Issue 1
E.164 Conversion, in conjunction with the AE Services Dial Plan rules, can help your
application perform both of these conversions. The ServiceProvider class supports the
following:
• ConvertDialStringToE164 (String, List<String>,Object)
• ConvertE164ToDialString(String, List<String>,Object)
The following code snippet shows how you can convert E.164 numbers into
Communication Manager extensions/dial strings.
Note:
This example presumes that dial plan rules have been administered to indicate
that numbers starting with "+1303538" are Communication Manager extensions
that should be converted to 7 digit numbers, and that any other numbers starting
with "+1" should have an ARS code (for example, ’9’ for an outside number)
placed in front. The resulting converted numbers would then be "5381212",
"5381234" and "917205554321".
…
string[] e164Array = {"+13035381212", "+13035381234", "+17205554321"};
string mySwitch = “myCM”;
ConvertE164ToDialStringRequest(e164SplitList, mySwitch)
…
InvokeId =
ServiceProvider.ConvertE164ToDialString(mySwitch, e164List, null);
}
catch (Exception exc)
{
List<ServiceProvider.ConvertE164ToDialStringResponseArgs.Result>
ResultList = e.getResultList;
for (int i = 0; i < ResultList.Count; i++)
{
ServiceProvider.ConvertE164ToDialStringResponseArgs.Result Result;
Result = e.getResultList[i];
MessageBox.Show(" e164: " + Result.gete164 + "
Dial String: " +
Result.getDialString + " Result Type: " +
Result.getResultType + "\r\n");
}
}
catch (Exception exc)
{
MessageBox.Show("\r\nServiceProvider_OnConvertE164ToDialStringResponse
Exception: " + exc.Message);
}
}
For more information on administering dial plan rules, see the Administering Dial Plan
Settings chapter of the Avaya Aura® Application Enablement Services Administration
and Maintenance Guide.
Notice that the Register Terminal button is now available. If we hold the mouse over the
Register Terminal button we see what information we need to fill in.
Release 7.0.0
82 02-602658
Issue 1
Specifically we need:
• Password
• E911 Information (if any)
• Force Login
• Media Mode
• Dependency Mode
Release 7.0.0
83 02-602658
Issue 1
Fill in the required information and push the Register Terminal button:
Release 7.0.0
84 02-602658
Issue 1
Exercise: Performing Operations on a Registered Device
Note:
This exercise is a continuation of the previous exercise.
So, let’s make an outgoing call to 5386000 and see what happens.
Release 7.0.0
85 02-602658
Issue 1
In the Events textbox are we see a lot of display updates, lamp updates, and hook
switch updates.
We now make and receive a few calls and observe the Events textbox.
By scrolling the Events textbox area we notice that we are getting an OFF HOOK event
every time the phone makes or answers a call and an ON HOOK event every time a
user disconnects a call. We decide, for this example, that monitoring the hookswitch
status is how we want to decide if the user is on a call or not.
To do this:
• Stop the existing phone monitor by selecting the monitor in the Monitor Ids
textbox and then pushing the Stop Monitor Button
• Start another one that just monitor hook switch changes by unchecking all the
events in the Phone Events area except for Hookswitch and then push the Start
Phone Monitor button.
Release 7.0.0
86 02-602658
Issue 1
A new monitor was created.
Once you have done the above your application should be able to record the call
duration.
Note:
In addition, in most cases you will be prompted to also launch a browser
which will take you directly to the documentation on the Avaya
DevConnect site for that particular method.
If you do this with the Register Terminal button the following dialog will appear:
Internet Explorer will bring up the Programmers Reference with the information about the
RegisterTerminal method. From there you can click on the links to learn more about the
parameters or other related methods.
Release 7.0.0
88 02-602658
Issue 1
Writing Code
This section covers starting an application session. The other steps are virtually
identical.
Start Visual Studio. We will assume you are familiar with Visual Studio so start a new
Windows Application project and for this example call your application logger.
Before we add any code, we need to add a reference to the ServiceProvider.dll file.
Release 7.0.0
89 02-602658
Issue 1
Right click on References and select Add Reference
Release 7.0.0
90 02-602658
Issue 1
A dialog will show up, select the Browse tab and go to the folder where the
ServiceProvider.dll file resides (it comes with the .NET SDK).
Release 7.0.0
91 02-602658
Issue 1
Select OK and you should now see it in the list of references.
Release 7.0.0
92 02-602658
Issue 1
Now right click on Form1.cs and select View Code.
Go back to design view by double clicking on the Form1.cs file in the Solution Explorer.
Release 7.0.0
93 02-602658
Issue 1
Release 7.0.0
94 02-602658
Issue 1
Create the handler for the Start Application Session button by double clicking on it.
Release 7.0.0
95 02-602658
Issue 1
Code will automatically be brought in to your workspace.
There will be comments on what you need to do in order to make it work and fields will
be highlighted on what needs to be changed.
Release 7.0.0
96 02-602658
Issue 1
The build was successful.
Add the code to handle the response for the Start Application Session.
As the comments for Start Application Session indicate, we want to insert the event
manager code right after we create it r (i.e., do a New).
Put the curser right after the code that creates it:
• Right click
• select Insert Snippet --> DMCCCodeSnippetsC# --> Events -->
StartApplicationSessionResponseEvent
Release 7.0.0
97 02-602658
Issue 1
The code is brought in, modify as the comments direct you to.
Modify the response handler to give you a pop-up message when it arrives.
Release 7.0.0
98 02-602658
Issue 1
Run the application.
You have finished putting in the code for Start Application Session. By using the
included Code Snippets, very little code had to be written from scratch.
You need to follow these same steps to write the code for Get Device, Start
Monitors, and Register.
In this context we have ignored error detection and correction. However, this small
example should provide you with the tools you need to start writing Device, Media and
Call Control .NET applications.
Note:
If you want to write the code in Visual Basic, follow the same steps using
the supplied Visual Basic code snippets instead.
Release 7.0.0
99 02-602658
Issue 1
The Dashboard exposes all the DMCC functionality which is available to you from .NET
including, but not limited to:
• Playing wave files
• Recording Wave files
• All Third party call control features
• Receiving RTP media
• Tone Detection
• Liink Status
• Getting Button Information
• Pushing Buttons
• Making Calls
• Answering Calls
• Conference and Transfer
• Monitoring XML messages going to/from the DMCC server
• Ability to Inject and XML message that you want
Note:
The combination of the Dashboard and code snippets should allow
you to not only quickly learn about what DMCC can do but also be
able to write applications very quickly.
Note:
This API is not compatible with non Microsoft browsers.
Extensive JavaScript libraries have been provided to make it relatively easy to write thin
clients.
An HTML version of the Dashboard ships with the SDK. It allows you to try out the
various interfaces in Internet Explorer. You can also view sample JavaScript code from
the browser dashboard.
The HTML version of the dashboard is located in the jscript/dashboard folder and
the html file is called dashboard.html.
By looking at the source code for the softphone and using the dashboard you should be
able to start writing thin client applications with minimal effort.
Release 7.0.0
100 02-602658
Issue 1
Telephony Logic
The AE Services server notifies your application when requested telephony events
occur:
• Registration events indicate unregistration by Communication Manager.
• Endpoint Registration events, available in AE Services 6.3 and later, indicate
device registration and unregistration by Communication Manager.
• Physical Device events indicate changes to the status of the ringer, display, and
lamps.
• Media Control events indicate when the media stream parameters have
changed.
• Voice Unit events indicate the status of recording and playing messages.
• Tone Detection events indicate when DTMF digits are received.
• Tone Collection events indicate when specified tone retrieval criteria are met,
and when collection begins and ends.
• Call Control events indicate changes to the status of the call.
• Logical Device Feature events indicate when agent status events occur.
• System Status events indicate when a TSAPI Tlink comes up or goes down.
• Call Associated events indicate when a regenerated telephony tone request
fails.
The following sections will give general instruction how to perform common things
around the telephone.
Note:
We encourage you to use the Dashboard application to investigate the
available features of the .NET SDK further. The actual .NET source code is
available by using the Visual Studio Code Snippets that are in the SDK.
Release 7.0.0
101 02-602658
Issue 1
Once a device is registered, your application may begin monitoring or controlling it with
any of the services provided by the ServiceProvider.
As part of the registration initialization process, multiple physical device events are sent
by the Communication Manager indicating the initial states of the lamps, ringer,
hookswitch and display. These events may occur before and/or after the Registered
event.
Note:
If your application needs to register many devices, we recommend you spread
out the registration of the devices. Register no more than 50 stations at one time
and wait until your application has received all of the responses before
attempting to register more stations.
Physical elements of a device are monitored and controlled with the Phone class. An
instance of the Phone class can be used to manipulate a device and start a monitor to be
notified about changes related to the physical aspects of the device (i.e. lamp state
change, switchhook state change, etc.).
Using the Dashboard, the Phone events can be configured using the tab under the
Event Registration section on the Main tab. The buttons in the upper left corner of the
Dashboard can be used to manipulate a phone and the Phone Commnads tab can be
used to obtain data related to the physical aspect of a registered device. The actual
.NET source code is available by using the Visual Studio Code Snippets that are in the
SDK.
If your application needs to press any buttons or determine which lamps have changed
state, you will need to know what buttons are administered on the device. Buttons are
assigned to devices during station administration via the Communication Manager
system access terminal (SAT) interface.
Release 7.0.0
102 02-602658
Issue 1
Your application must use the Phone.GetButtonInfo()method to ask about a
particular button or to ask to get all button information. Look under the Dashboard
"Phone Commands" to test this functionality.
Note:
There is no direct indication provided by the API to the application of changes to
the provisioned information for a monitored device. Thus, collecting the device's
configuration, when the application initializes is an incomplete solution. A robust
application should periodically validate that the current configuration of the device
is aligned with the representation of that configuration as derived by the
application. In order to do so, an audit of the information should be developed
and run at some recurring cycle, or when unexpected feedback to button presses
is received. An audit can be realized by utilizing the Phone.GetButtonInfo
request and comparing the results with the previously obtained information.
When a call comes into a device, these three changes occur to the physical device:
• The phone rings.
• A green call appearance lamp flashes.
• The display changes to show caller information.
Therefore, the following events will be sent to an application that has started a Phone
monitor for these events:
• RingerStatusEvent - The ring pattern is supplied in the event structure. For a list
of possible ring patterns see Appendix C: Constant Values for “Ringer Pattern
Constants”.
• LampModeEvent - The identifier of the lamp that has changed and the lamp’s
mode is supplied in the event structure. Once you know where the call
appearance lamps are (see Knowing what buttons are administered), you can
determine if it is a call appearance lamp and if it is flashing by comparing the
lamp mode against the FLASH constant. For a complete list of the possible
lamp modes, see Appendix C: Constant Values for Lamp Mode Constants.
Release 7.0.0
103 02-602658
Issue 1
• DisplayUpdatedEvent - The display contents are supplied in the event structure.
In general, the number of DisplayUpdatedEvent messages you will receive
before the display update is complete can vary.
You may want your application to key off of just the LampModeEvent, or it may want to
wait for the other events before responding to an incoming call. The events may come in
any order.
You can try this in the dashboard and use the Visual Studio code snippets to look at
sample source code.
If all far-end parties drop on a call, these changes occur on the local device:
• The call appearance green lamp turns off.
• The display is updated based on the current state of the extension.
For example:
o Returns to an idle state showing extension, date and time information
o Begins showing information about a ringing call at the extension
o Is not updated and continues to show information relative to an active
display feature such as Directory Lookup
Therefore the following events will be sent to an application that has started a Phone
monitor for these events:
• LampModeEvent - The identifier of the lamp that has changed and the lamp’s
mode is supplied in the event structure. Once you know where the call
appearance lamps are (see Knowing what buttons are administered), you can
determine if it is a call appearance lamp and if the lamp is now off by comparing
the green lamp mode against the OFF constant. A complete list of possible lamp
modes can be found in Appendix C: Constant Values under Lamp Mode
Constants.
Note:
Communication Manager sends lamp updates not only for lamp
transitions, but also to refresh lamps. Therefore, some LampModeEvents
indicate that the lamp is in the same state it was in before the event.
• DisplayUpdateEvent - The display contents are supplied in the event structure.
You can try this in the dashboard and use the Visual Studio code snippets to look at
sample source code.
Making a call
Release 7.0.0
105 02-602658
Issue 1
You can try this in the dashboard and use the Visual Studio code snippets to look at
sample source code.
Call Control
Before attempting to use Call Control Services, you must first perform the following:
• Acquire an instance of ServiceProvider.
• Acquire the ThirdPartyCallControl instance from the ServiceProvider instance.
• Acquire a ThirdParty Call Control DeviceID.
• Using the ThirdPartyCallControl instance register the call control events.
When a Call Control request requires a ConnectionID parameter, it can be obtained from
a previous call control response, event or by issuing a
ThirdPartyCallController.SnapshotDevice request.
When a DeviceID representing an extension is needed in the request, the DeviceID can
be obtained from a previous call control response, a previous call control event or by
using the ThirdPartyCallController.GetThirdPartyDeviceId request.
//
// Register the response handler
//
ServiceProvider.getThirdPartyCallController.OnGetThirdPartyDeviceIdResp
onse += new
GetThirdPartyDeviceIdResponseHandler(My_OnGetThirdPartyDeviceIdResponse
);
//
// GetThirdPartyDeviceId Response Callback Handler
//
void My_OnGetThirdPartyDeviceIdResponse(object sender,
ThirdPartyCallController.GetThirdPartyDeviceIdResponseArgs e)
Release 7.0.0
106 02-602658
Issue 1
{
try
{
OneThreadAtATimeEvent.WaitOne(5000, false);
if (e.getError != "")
{
// Handle Error
}
else
{
thirdPartyDeviceId = e.getDeviceIdAsString;
}
}
catch (Exception) { }
finally { OneThreadAtATimeEvent.Set(); }
}
//
// GetThirdPartyDeviceId Request
//
int InvokeId;
string switchName = “myServer”;
string myExtension = “5551234”;
InvokeId =
ServiceProvider.getThirdPartyCallController.GetThirdPartyDeviceId(switc
hName, myExtension, null);
Making a call
Answering a call
If your application receives the DeliveredEvent your application may answer the call,
using the connectionID from the DeliveredEvent with the
ThirdPartyCallController.AnswerCall request.
Ending a call
Release 7.0.0
107 02-602658
Issue 1
After your application has received the EstablishedEvent and you wish to end the
call. Your application may end the call, using the
ThirdPartyCallController.ClearConnection request. When a call has ended, your
application will receive a ConnectionClearedEvent.
• Use the conference display button to get ANI information for a call.
If the application wishes to use only device and media control, it can alternatively
use the conference display button.
In order to use the conference display button to get ANI information for the call,
the conference display button (conf-dsp) will have to have been administered for
that extension in Communication Manager.
Once an incoming call is received by your application for the extension, your
application should press the conference display button of the extension
repeatedly to get the ANI information (through the DisplayUpdatedEvent of
Phone Services) for each party on the call.
This section describes how to use the Media Object to have the AE Services server
record and play media for you. The supported services are described in the Media Class
on page 25. The details about using the services are described in the Programmers
Reference. To see sample code using the Media Class, see the sample application
called SimpleRecord referenced in Learning from sample code on page 46.
Release 7.0.0
108 02-602658
Issue 1
G.729 formatted files, however, use non-standard field values in some of the
standard format chunk fields. They are:
Compression code value: 131 (0x0083)
Block align value: 10 (0x000A)
Bits per sample value: 1 (0x0001)
An external G.729 converter is required to convert a G.729 Wave file into a
standard RIFF Wave file that can be played.
• Files on the AE Services server
All Wave files are assumed to be on the AE Services server machine in the
directories specified in the AE Services Management Console interface under
the media properties as the player directory and the recorder directory.
Note:
These two directories do not have to be the same. These directories are
the root directory of the relative paths specified in the playMessage and
recordMessage requests.
• Encoding algorithms
Files to be played can be encoded in these formats:
PCM 8-bit or 16-bit
G.711 A-law
G.711 Mu-law
G.729
G.729A
Recordings can be made of calls in these formats
PCM 8-bit or 16-bit
G.711 A-law
G.711 Mu-law
G.729
Note:
Once the call has been established, you can find out what codecs have
been chosen by Communication Manager from the
MediaStartedEvent, which will contain a list of the codecs.
Release 7.0.0
109 02-602658
Issue 1
Messages to be recorded can be converted from G.711 to PCM. No other
conversions are supported for recording.
• Using with Tone Detection or Tone Collection Services
The Voice Unit Services player and recorder may be setup to detect DTMF tones
at the same time Tone Detection or Tone Collection Services is being used.
However, there is no guarantee which service will detect a tone first. See
Possible race conditions for more specifics.
Media Operations
Media operations such as Recording, Dubbing, playing wave files are all done through
the Media Object. Use the dashboard tool to learn more about these capabilities and use
the Visual Studio code snippets to help you write the actual code.
Recording
To record the RTP media stream of a device, use the Media.StartRecording request.
This will record only the media coming from other parties on the call to the device not the
media that is being played from this device using the Media.StartPlaying request.
Only media packets that are received are recorded: lost packets are not replaced.
The application can specify an alphanumeric filename for the recording or let the
filename default to a format of <timestamp><extension>.wav. The alphanumeric
filename may contain a relative directory path. Filenames specified for recorded files
must be relative to the configured directory, their directories must already exist, and
recordings cannot overwrite an existing file. If it is defaulted, then the resulting filename
is returned in the RecordMessageResponse.
Since recording is associated with a device rather than a call, a recording could contain
the incoming media from multiple calls. Recording continues until one of the following
occurs:
• Application explicitly stops the recording with a Media.StopRecording request.
• Application requests that the AE Services server automatically stop the recording
when a specified termination criterion is met. Multiple termination criteria can be
specified in which case the first criterion that is met stops the recording.
Termination criteria options include:
o when a DTMF tone is received by the device. To request this
termination criterion, set the toneTermination parameter’s terminating
conditions so that DTMFDigitDetected is set to true.
o when recording reaches a specified duration. To request this
termination criterion, set the duration parameter to the maximum
number of milliseconds allowed for the recording.
Release 7.0.0
110 02-602658
Issue 1
If you wish to record one entire call and only one call, then your application can watch
the lamp events to determine when the call has ended and explicitly stop the recording
after the call has ended.
Note:
No exception is thrown if the application requests that recording stop when there
is no active recording.
Once an active recording on a device has been stopped, a StopEvent, sent to the
application, indicates that the recording has finished and the recorded file is ready for the
application.
AE Services 6.3 and later and Communication Manager 6.3 and later, provides the
ability for an application to request Communication Manager to insert a tone into the
audio stream of the parties in a call. This tone serves to indicate that the audio stream is
being recorded using either the Single Step Conferencing method or the Multiple
Registrations method. The tone that is played is inserted by Communication Manager
and is identical to that already used by the Service Observing feature.
Note:
The client application requests the recording warning tone for a specific device,
not a specific call. Thus, if the recording warning tone has been activated for a
device, any time that the specified device is included in a call, the recording
warning tone will be inserted into the call. This will continue to be the case for
every call in which the device is a party, until such time that the client application
requests that Communication Manager deactivate the recording warning tone.
To activate the recording warning tone for a device, use the GenerateTelephonyTones
request from the Call Associated service. And to deactivate the tone for the device, use
the CancelTelephonyTones request.
Note:
If the client application requests the activation of the recording warning tone while
the specified device is already in a call, the tone will not be applied to the existing
Release 7.0.0
111 02-602658
Issue 1
call. However, the tone will be applied to all subsequent calls in which the device
is a party.
In order to stop monitoring for the event, the application can remove the appropriate Call
Associated Service monitor by using the StopMonitor request.
To use the Single Step Conference method, a recording application registers to Avaya
Aura® Communications Manager extension “A” and monitors a user’s extension “B” that
will be recorded. Prior to the user accepting any calls, the recording application sends a
GenerateTelephonyTones request for the extension to which it is registered (“A”). When
the user’s extension (“B”) accepts a call, the recording application joins the call using
Single Step Conference and begins recording the call. The warning tone is played when
the recording application extension (“A”) joins the call at the user’s extension (“B”).
After the final call to be recorded has finished, the recording application sends a
CancelTelephonyTones request to the extension to which it is registered (“A”) to stop the
warning tone from being played.
To use the Multiple Registration method, a recording application registers to the same
extension (in either dependent or independent DependencyMode) of the user that is
taking the calls to be recorded. Prior to the user accepting any calls, the recording
application sends a GenerateTelephonyTone request for the extension to which it is
registered. When the (Main) user answers a call, the recording application is
automatically connected to the call and a warning tone is played.
After the final call to be recorded has finished, the recording application sends a
CancelTelephonyTones request to the extension to which it is registered, to stop the
warning tone from being played.
Release 7.0.0
112 02-602658
Issue 1
Dubbing
A recording can be dubbed with another Wave file by using Media.StartDubbing and
Media.StopDubbing requests. Dubbing records the specified Wave file over the
recording repeatedly from the time Media.StartDubbing is called until
Media.StopDubbing is called. This may be helpful to avoid recording sensitive
information such as a spoken password or other private or security-based information.
Since the application must explicitly stop the dubbing, the application must have the
logic to know when to stop. It may be based on time, an incoming DTMF tone such as
“#”, or a manual action by an agent who is listening
Playing
To play one or more messages to the RTP stream of a call as if the message(s) are
coming from the device, use the Media.StartPlaying request. The message(s) can be
played once, multiple times, for a particular duration, or until a DTMF tone is received by
the device.
The filename of the file to be played can be alphanumeric. The alphanumeric filename
may contain a relative directory path. One or more files can be specified as long as they
are of the same encoding type. For an example of how multiple files can be specified,
see the Dashboard.
Since playing is associated with a device rather than a call, the playing of the
message(s) may continue across multiple calls to which the device is a party. Playing
continues until one of the following occurs:
• Application explicitly stops the playing with the Media.StopPlaying request.
• A specified termination criterion is met.
Multiple termination criteria can be specified, in which case the first criterion
that is met stops the playing. Termination criteria options include:
1. When a DTMF tone is received by the device.
Release 7.0.0
113 02-602658
Issue 1
To request this termination criterion, set PlayCount and PlayInterval
in the repeatInfo parameter using Media.PlayRepeatInfo.
If you wish to play message(s) to one entire call and only one call, then your application
can watch the lamp events to determine when the call has ended and explicitly stop the
playing after the call has ended.
Once active playing on a device has stopped, a StopEvent, sent to the application,
indicates that the playing has finished.
Note:
No exception is thrown and no event is generated if the application requests that
playing stop when there is no active message playing.
Your application can receive and respond to the Media events and responses by
invoking the Media.StartMonitor request and adding delegates to the Media instance (i.e.
Media.OnMediaStartedEvent). The Media events and responses will indicate when
requests have been accepted, processing has begun and when processing has ended.
If your application needs to detect DTMF tones coming to a device from another party on
the call, then you can use AE Services DMCC ToneDetectionServices or
ToneCollectionServices. To use these services, you must either:
• Register the device in server media mode to detect both out-of-band and in-band
tones.
• Register the device in client media mode to detect only out-of-band tones.
DTMF tones are generated by parties on a call by pressing the dial pad digits 0 through
9 and * and # during the call. If the device that is being monitored is on a call and
another party on the call presses a dial pad digit, then a registered
Media.OnToneDetectedEvent delegate can be used to report each DTMF tone to the
application. The Media.MediaEvents should be configured to monitor for the
ToneDetectedEvent issued by the AE Services server using Media.StartMonitor.
Release 7.0.0
114 02-602658
Issue 1
In contrast, Media.StartToneCollection can be used to buffer the received tones and
report them to the application when the specified retrieval criteria are met. The retrieval
criteria, specified with the Media.SetToneRetrievalCriteria request, may be one or
more of the following:
• A specified number of tones have been detected.
• A specified tone (called a "flush character") has been detected.
• A specified amount of time (called a "timeout interval") has elapsed.
When at least one of the retrieval criteria is met, the following retrieval steps are
performed by the AE Services server:
1. The buffered tones up to and including the tone which met the retrieval criteria,
are removed from the buffer.
2. The retrieval criteria are cleared (optional).
3. The application is notified of the retrieved tones with the TonesRetrievedEvent.
If more than one retrieval criterion is specified, the first one to occur causes the retrieval
criteria to be met.
Note:
Use the Dashboard tool to learn more about these capabilities and use the Visual
Studio code snippets to help you write the actual code.
Both sets of services can detect in-band and out-of-band DTMF tones. In-band
tones are transmitted within the media stream. Out-of-band tones are
transmitted in the signalling channel. The AE Services server always detects
out-of-band tones. If the application wishes to also detect in-band tones (in-
band tone detection is not recommended), then the tone detection mode must
be explicitly set to in-band.
Set the tone detection mode before the AE Services server is started up. The
mode is provisioned in the AE Services Management Console web pages on
the “AE Services > DMCC > Media Properties” screen as the ttd_mode.
Release 7.0.0
115 02-602658
Issue 1
To detect only out-of-band, set the mode to OUT_BAND (default). To detect both
in-band and out-of-band, set to IN_BAND. See the appropriate Avaya Aura®
Application Enablement Services Installation and Upgrade Guide for the offer
you have purchased (VMware or Software Only) for instructions on how to
choose between in-band and out-of-band for the AE Services server and for
Communication Manager, and how to setup the ttd_mode property.
The Media Player and Recorder may be set up to detect DTMF tones at the
same time Tone Detection or Tone Collection is being used. However, there is
no guarantee which service will detect a tone first, see “Possible race
conditions” for more specifics.
To detect DTMF tones one at a time, use the Media methods in this order:
1. Implement the Media.OnToneDetectedEvent delegate to handle each tone that
is detected.
2. The Media.MediaEvents must be configured to monitor for the
ToneDetectedEvent issued by the AE Services server using the
Media.StartMonitor request.
3. Now each time a tone is detected by the AE Services server, a
ToneDetectedEvent is issued to the application and handled by the registered
delegate.
4. When you no longer wish to be notified of detected tones, remove the listener
with the Media.StopMonitor request.
You may want to set up interdigit timers limiting the maximum amount of time the
application will wait between tones or a duration timer limiting the maximum amount of
time before stopping the tone detection.
Use the Dashboard tool to experiment and use the Visual Studio code snippets to help
you write the code.
To have the AE Services server collect multiple DTMF tones and report them to the
application based on specified retrieval criteria, use the Media Tone Collection methods
in this order:
1. Implement the Media.OnToneRetrievedEvent delegate to handle a retrieved set
of tones. The TonesRetrievedEvent , issued by the AE Services server, that is
Release 7.0.0
116 02-602658
Issue 1
passed to the delegate, supplies the set of tones that were retrieved and the
cause of the event. The cause of the event may be any of the following:
• BUFFERFLUSHED - when the flushBuffer method is called
• CHARCOUNTRECEIVED - when the number of tones specified in the
retrieval criteria is received
• FLUSHCHARRECEIVED - when the tone specified in the retrieval
criteria is received
• TIMEOUT - when the amount of time specified in the retrieval criteria
has elapsed
2. Add the listener to the device with the Media.StartMonitor request. The
Media.MediaEvents must be configured to monitor for the
TonesRetrievedEvent.
Note:
Adding the listerner does not start the buffering of tones.
3. Start tone collection with the Media.StartToneCollection request. This
causes each detected tone to be put in a buffer.
4. Set the retrieval criteria with the Media.SetToneRetrievalCriteria request.
5. When one of the retrieval criteria is met, the application’s delegate,
Media.OnToneRetrievedEvent, is called and optionally, the retrieval criteria
are cleared. The AE Services server continues buffering detected tones.
6. If you wish to be notified of more tones, call the
Media.SetToneRetrievalCriteria request again. There is no need to stop
and restart the collection.
7. You can add and remove listeners at any time during collection.
8. If for any reason you wish to flush the buffer during collection, use the
Media.FlushToneCollectionBuffer request. This will report the tones
collected since the last time the buffer was flushed in the
TonesRetrievedEvent. You may want to flush the buffer at the end of a call.
9. When you no longer wish to be notified of collected tones, stop tone collection
with the Media.StopMonitor request. This will cause the server to stop
collecting DTMF tones sent to a device and report the tones that have been
buffered. This flushes the buffer. The delegate may be removed if it is no longer
needed.
Use the Dashboard tool to experiment and use the Visual Studio code snippets to help
you write the code.
Release 7.0.0
117 02-602658
Issue 1
Determining when far-end RTP media parameters change
Applications that control their own media (client media mode) will need to use the Media
monitors to determine when the far-end RTP media parameters change. Here is the
sequence of media control events an application should be prepared to receive:
For example, if the media is going from calling party A to Communication Manager and
then to called party B, Communication Manager may choose to change the media path
such that it goes directly between endpoints A and B. In this case, Communication
Manager would tell both A and B to stop using the Communication Manager address as
the far-end address and to start using the other endpoint as the far-end address. In other
words, A would be notified that B is now the far end and B would be notified that A is the
far end. Later Communication Manager may choose to change the path again due to
some change in the call, such as a conference or transfer. Each time the path changes,
the endpoints are notified via media control events to stop using the current far-end
address and to start using the new far-end address.
In server media mode all of this is usually transparent to the user, unless the codec
happens to change. In this case you may need to play a different wav file in the codec of
the new form. For this reason it is recommended that you give a single codec when
registering devices.
You should use Media.StartMonitor to set a monitor for the MediaStartEvent and
MediaStopEvent. When the RTP media changes, you will be notified by these events by
registering a Media.OnMediaStartedEvent and Media.OnStoppedEvent delegate. Use
the Dashboard tool to experiment and use the Visual Studio code snippets to help you
write the code.
Release 7.0.0
118 02-602658
Issue 1
Chapter 4: Recovery
This section informs you how to take advantage of the recovery feature to design a more
robust Device, Media and Call Control application.
The application session protocol has several recovery benefits for the Device, Media and
Call Control application. The “keep alive” (ResetApplicationSessionTimer) messages
that are sent periodically by the .NET API to the AE Services server provide a way for
the AE Services server to verify that the client application is still operational, even if there
is no other activity from the application. Similarly, the server response
(ResetApplicationSessionTimerPosResponse) messages allow the application to
verify that the AE Services server is also still responsive.
Note:
The “keep alive” message exchange is initiated and completely handled
by the .NET API. Also, the frequency of the “keep alive” messages
depends on the value of the “session duration” specified during the
initial creation of the application session.
The session cleanup delay provides a mechanism for the application to reestablish its
session after a short network interruption without having to reestablish their state (e.g.
register devices again).
Two important times are defined as part of the application session creation. These are:
• Session duration - the maximum time that the AE Services server will wait for a
timer reset, before moving the session to the inactive state. This timer is reset
when the server receives a ResetApplicationSessionTimer message from
the application.
• Session cleanup time – the amount of time that the AE Services server waits,
after the connection to the client has been lost. Once this time has expired, the
session, and any devices, monitors and device registrations associated with the
session, are cleaned up. This timer defaults to 0 for backwards compatibility
purposes, but it is recommended that it be set to a higher value, such as 60.
In order for the application to be notified about some form of connection failure,
reconnect failure, or heartbeat failure, the application should implement the following
event/response handlers:
• ServiceProvider.OnStartApplicationSessionResponse
• ServiceProvider.OnServerConnectionDownEvent
• ServiceProvider.OnServerConnectionNotActiveEvent
Release 7.0.0
119 02-602658
Issue 1
• ServiceProvider.OnMissedAtLeastOneKeepAliveEvent
Session Recovery
Since the session cleanup time delays the cleanup of a client application’s session, it
provides a mechanism for the application to reestablish its session after a short network
interruption. Following the short network interruption, the client application can resume
the same session, without having to reestablish its state information (e.g. monitor and
register devices again). This section tells you how to take advantage of these new
features to design a more robust Device, Media and Call Control application.
The best way to monitor for problems with a session is to monitor for
ServerConnectionDownEvents, ServerConnectionNotActiveEvents, and
MissedAtLeastOneKeepAliveEvents within the Service Provider object. The
following is a description of the events the application can receive and the proper
recovery actions to take in the case of each event.
The recovery action to take for this event is to call reconnect on the application’s
ServiceProvider instance. This method will attempt to open a new socket to
the AE Services server, and to reestablish the existing session with a new
socket.
If successful, the application should be able to resume operations without
reestablishing its state although your application may have missed some events.
To be sure that you know the current state of the lamps, hookswitch and display,
you will have to query for those states using getLampState, getHookswitch
and getDisplay to update the states.
The operation may fail if the network is down, or if the session has been
terminated on the AE Services server because the cleanup timer expired. If the
session has already been terminated by the server, the getError() method
associated with the received StartApplicationSessionResponse will contain a
StartApplicationSessionNegResponse XML string with additional information
about the reconnect failure.
For example:
<StartApplicationSessionNegResponse xmlns="http://www.ecma-
international.org/standards/ecma-354/appl_session">
<errorCode>
<applError>
Terminated session can not be reconnected.
Reason: Session timer timed out
</applError>
</errorCode>
Release 7.0.0
120 02-602658
Issue 1
</StartApplicationSessionNegResponse>
In order for the application to connect to the AE Services server again after a
session cleanup, a new ServiceProvider.StartApplicationSession request
will need to be issued. If any other exception or error message is received, like a
network failure, the application should set a timer and try to reconnect again at
some later time. Any requests that the application was trying to send that timed
out in the interval will generate an exception or error message from the SDK.
Note:
By default, the .NET Service Provider handles the automatic sending of
Keep Alives to the AE Services server for you. However, you can turn this
capability off via the StopAutoKeepAlive()method in the Service
Provider object (use StartAutoKeepAlive()method to start the
processing back up).
The following figure shows the sequence of events that occurs between the client
application, the API library and the AE Services server during establishment of an
application session, and an instance of a ServerConnectionDownEvent occurring
during subsequent session management.
Release 7.0.0
121 02-602658
Issue 1
Figure 1: Session Management Recovery
<StartApplicationSession>
<StartApplicationSessionResponse>
<GetServiceProviderResponse>
<ResetApplicationSessionTimer>
<ResetApplicationSessionNegResponse>
<ServerConnectionDownEvent>
<reconnect>
<StartApplicationSession>
<StartApplicationSessionResponse>
Release 7.0.0
122 02-602658
Issue 1
response will contain a MonitorStartResponse for each valid monitor that is
associated with a transferred device ID.
Important side effects and recommended client application actions:
• The client application must set up the new session to receive the events from
the transferred monitors.
• All the monitors for each device ID will be transferred from the original to the
new session.
• The original session will be removed at the end of the transfer.
• The client application must release the resources that were allocated for the
original session.
Note:
The transfer request should be issued from the new session in order to pull in the
transferred objects from the old session.
Use the Dashboard tool to experiment and use the Visual Studio code snippets to help
you write the code.
Release 7.0.0
123 02-602658
Issue 1
Chapter 5: Cleanup
If the cleanup session expires, resources are reclaimed. It is important to free resources
when they are no longer needed. This is most likely to occur when your application:
• detects the end of a call
• is finished with a device
• is about to exit
Release 7.0.0
124 02-602658
Issue 1
When your application no longer needs to receive events for a device, stop the
monitors that were started using the StopMonitor() methods for the
appropriate services.
5. Release the device identifier
When finished with a device identifier, release it using the
Device.ReleaseDeviceID method.
When the application is about to exit, release each device identifier.
6. Stop the Application Session
Stop the application session by calling the StopApplicationSession method
on the application’s ServiceProvider instance.
Release 7.0.0
125 02-602658
Issue 1
Chapter 6: High Availability
AE Services 5.2 introduced a number of High Availability (HA) feature enhancements to
the platform. One of these feature enhancements is the AE Services 5.2 DMCC
Service Recovery feature, which increases the availability of the DMCC service to a
client application. This feature is available on all of the AE Services server platforms.
For additional information, please see the “DMCC Service Recovery” section. The other
HA feature was Fast Reboot High Availability (FRHA). With FRHA, the standby server
monitors the active server and takes over when the active server fails on a System
Platform High Availability configuration.
In AE Services 6.1 another HA feature was added to provide better support for Avaya
Aura® Communication Manager failover strategies. In particularly, it supports
Communication Manager’s failover to an Enterprise Survivable Server (ESS) and/or to
a Local Survivable Processor (LSP). For additional information, please see the “DMCC
Support of Communication Manager High Availability Using ESS and LSP Servers”
section.
In AE Services 6.2 another enhancement was added, Machine Preserving High
Availability (MPHA), which offered faster and smoother recovery than FRHA whenever
AE Services fails over to the standby server of a System Platform High Availability
configuration.
In AE Services 6.3.1, the Geo Redundant High Availability (GRHA) feature set was
introduced. GRHA was later enhanced in AE Services 7.0. The GRHA feature allows
the active and standby AE Services servers to be in either one or two different data-
centers separated by a LAN/WAN.
Note:
Starting with the AE Services 7.0 release, the System Platform offer, including
the FRHA and MPHA features has been dropped.
This chapter describes all of the High Availability features available with AE Services:
• AE Services Geo-Redundant High Availability
• DMCC Service Recovery
• DMCC Support of Communication Manager High Availability Using ESS and LSP
Servers
• Programming Considerations for High Availability
In the AE Services 6.3.1 release, GRHA was introduced as a HA option that allows the
active and standby AE Services servers to be in two different data-centers that are
separated by a LAN/WAN, provided that the maximum round trip network delay is
within 100 milliseconds. This ensured that failures that affect the entire data-center (for
example, a power failure) can be minimized.
In AE Services 7.0, the GRHA feature was enhanced to allow the active and standby
servers to be in the same data-center connected by a LAN, thus mimicking the FRHA
feature from previous AE Services releases.
Active Standby
AES GRHA AES
VM VM
Active Active
VMware Host VMware Host
LAN/WAN
< 100ms RTT
For the purposes of this discussion, the term “controlled” failover refers to a failover
requested by either an administrator or by software logic, when it detects degradation
in state of health of the current active server. The term “uncontrolled” failover refers to a
failover which occurs because the current active server is not reachable from the
current standby server.
Release 7.0.0
127 02-602658
Issue 1
When a controlled failover occurs, AE Services are turned off on the current active
server and are turned on for the new active (previously standby) server. In the case of
an “uncontrolled” failover, AE Services are started on new active (previously standby)
server. Depending on the “uncontrolled” failover reason, the previous active could
continue to be in an isolated network, or it could be in shutdown state.
Release 7.0.0
128 02-602658
Issue 1
• Preservation of the current state of the system (if a virtual IP address is not
used for the Communication Manager connections). After a GRHA failover has
occurred, and once the application has connected to the new active AE
Services server, the application must re-establish any:
o Sessions
o DeviceIDs
o Device and Call Monitors
o Device Registrations
o System Registrations
o Recording Warning Tones
• Protection against AE Services software failures. However, DMCC Service
Recovery (discussed in the next section) does recover from software failure.
• Service on IPv6 networks. Currently, GRHA is only supported on IPv4 networks.
How does DMCC Service Recovery differ from releases prior to AE Services 5.2?
Release 7.0.0
131 02-602658
Issue 1
The DMCC Service Recovery subsystem may cause the AE Services server to act a
little differently to previous releases. The following is a list of points to keep in mind when
dealing with AE Services 5.2 and later:
• The DMCC Service recovery time will vary depending on the number of call
control service monitors and H.323 registrations that need to be recovered. This
is because such recovery actions require asynchronous protocol messaging to
the Communication Manager across an IP network.
• A recovered session that is not re-established by the client application will be
released:
o Immediately if the cleanup timeout value equals 0 mins.
o After 5 minutes if the cleanup timeout value is less than 5 mins.
o After the cleanup timeout expires if it is more than 5 mins.
• There is no event to indicate that DMCC service recovery has completed.
However, there are events to indicate that a registration or a monitor was lost
during recovery. In contrast, the loss of a session will be detected when an
attempt to re-establish it fails. Similarly, the loss of a device will be detected
when a device based API service request fails.
Note:
For the AE Services on VMware offer, the GRHA failover may take a few
minutes, and so, any session re-establishment failures within this
interval will not be valid.
• In general, a recovered session can be re-established before the reconstruction
of its associated runtime state is completed. This can lead to undesirable
behavior, if the client application assumes that all reconstruction was
completed. A client application may explicitly determine whether a given
resource is ready to be used, through the existing API methods
GetSessionIdList, GetDeviceIdList, GetMonitorList and
GetRegistrationState. It can implicitly determine readiness of a resource
from the responses to other API service requests.
• Some requests or events in progress at the time of the failover may be lost,
although every effort will be made by the AE Services server to retain all
requests in progress.
• Only Time-to-Service (TTS) H.323 registrations can be recovered by the DMCC
service. The client application is responsible for recovering (i.e. re-registering)
all non-TTS registrations.
• DMCC Service Recovery will not preserve an “in-progress” server-media
recording or playback of a “wav” file. However, following the successful
recovery of the device registration(s) after a fault, a new recording or playback
may be started on the device(s).
How does Time-to-Service Support differ from releases prior to AE Services 5.2?
Note:
Release 7.0.0
132 02-602658
Issue 1
The DMCC Service Recovery subsystem relies on the Time-to-Service
feature of Communication Manager to allow the recovery of device
registrations.
Some side-effects of TTS registration include:
• The RAS keep-alive messages between the AE Services server and
Communication Manager, for each device registration, are much less frequent.
Instead of occurring every minute (as for non-TTS registrations), the keep-alive
messages will be sent only every 7 hours, under some conditions.
• The Q931 signaling channel between the AE Services server and
Communication Manager, for each device registration, may be torn down by
Communication Manager, and re-established when needed. The loss of the
signaling channel will no longer cause the endpoint to be unregistered.
• If a client application makes a request that requires the Q931 signaling channel
(e.g. an off-hook or on-hook request), there may be a slight delay (usually
milliseconds) while the signaling channel is re-established.
Release 7.0.0
133 02-602658
Issue 1
each ESS and LSP, since registration to anything other than the Main, using the
switchName, was not possible.
Release 7.0.0
134 02-602658
Issue 1
This list and its hierarchy will be used by the AE Services Transport server (in
conjunction with the Communication Manager nodes themselves) to determine which
Switch Connection is active, at any given time, and (hence) which nodes are providing
service.
Typically, the outage can last anywhere from one to several minutes depending on the
factors mentioned above.
On detecting a temporary network outage, the client application should attempt to re-
establish the connection and its associated DMCC session(s).
The DMCC Dashboard can be used to simulate session recovery and failover by
unchecking the “Auto Cleanup” checkbox at the top of the Main dashboard screen.
Release 7.0.0
135 02-602658
Issue 1
Chapter 7: Media Encryption
Application Enablement Services offers the user the ability to encrypt the voice RTP
streams between the DMCC softphone and the far end of the call when the application
chooses to use server media mode.
For Application Enablement Services, the only encryption scheme available is the
Advanced Encryption Standard (AES) media encryption.
Note:
This Chapter was taken from the DMCC Java Programmers Guide to be
used as a reference for .NET developers. A future release of this
document will provide the .NET equivalent of the Java Cryptography
Extension (JCE) code examples.
IV IV+1 IV+2
Let
r=i DIV key_derivation_rate
where DIV denotes integer division rounded down with the convention that
dividing by 0 equals 0. The SRTP algorithm supports changing the keys
periodically, even while the voice stream is active. The key derivation rate is the
rate of this change. A value of zero indicates that the keys are not changed
periodically. When the rate is zero, “r” is also zero (48 bits). Note that in the first
computation of “r”, the value of SEQ used in the computation of “i” is the initial
value at the beginning of the media stream.
Release 7.0.0
137 02-602658
Issue 1
Let
key_id = <label> || r
where <label> = 0x00 for RTP packet encryption and 0x02 for the salting key
used to generate the IV as illustrated in Figure 4 .
8 bits of label
The keys for encryption and IV generation are the result of encryption of (“x” *
216) with a key called the master key. (The master key is distributed by the Media
Gateway Controller for each voice IP media link as the link is established.)
The values of “x” for Avaya’s implementation are shown in figure 6. Note that
two values of “x” are computed, one (xe) is used to compute the value of KE and
a second value of “x” (xs) is used in the computation of the IV.
For Avaya’s implementation: Key_derivation_rate = 0 Master_salt =
0
Release 7.0.0
138 02-602658
Issue 1
3. Creating the Initialization Vector
The Initialization Vector (IV) changes for each packet (1280 voice bits for 20ms
G.711) according to the following equation: IV = (SSRC * 264) XOR (KS *
216) XOR (i * 216)
where KS is known as the session salting key and SSRC is the synchronization
source from the RTP packet currently being encrypted. Note that “i” contains the
packet sequence number SEQ and therefore the IV must be recalculated for
each RTP packet.
The 112 bit KS is computed from xs using the pseudo random function (PRF) as
follows.
KS = PRF_112 (master_key, xs * 216)
The pseudo random function is defined to be AES in counter mode with its
output stream truncated as necessary (left most bits are retained).
The process for IV generation is shown in Figure 7.
Release 7.0.0
139 02-602658
Issue 1
The process for generating the session key (KE) uses the pseudo random
function (AES in counter mode) to produce a 128 bit value as follows: KE =
PRF_128 (master_key, xE * 216)
This specifies that the DMCC softphone will support both AES encryption and no media
encryption. In this case, the decision to encrypt the media stream is left up to the
Communication Manager (as specified in the CM’s “change ip-codec” form).
MediaStartEvent Handling
If you have chosen to receive and handle the media stream as part of your application
(you have chosen client-media mode), you will receive the media encryption information
in the MediaStartEvent. In addition to the usual “RTP address”, “RTP port”, “codec”
etc., the MediaStartEvent will also contain an “Encryption” object containing the
encryption protocol and keys chosen by Communication Manager.
When you start to process the RTP stream, you need to pass the encryption information
to your RTP stream read/write methods to enable them to do the media
encryption/decryption. On receipt of a new MediaStartEvent, you must use the new
encryption keys provided in the event, recalculate the Initialization vector (IV), and reset
the Roll Over Counter (ROC).
If you are using Avaya’s client-media-stack, you may call the Audio “start” method (as
usual) passing the encryption information as an extra parameter:
Release 7.0.0
140 02-602658
Issue 1
MediaEncryption encryption = new MediaEncryption();
encryption.setProtocol(startEvent.getEncryption().getProtocol());
encryption.setTransmitKey(startEvent.getEncryption().getTransmitKey());
encryption.setReceiveKey(startEvent.getEncryption().getReceiveKey());
encryption.setPayloadType(startEvent.getEncryption().getPayloadType().i
ntValue());
audio.start(rtpAddress, rtcpAddress, codec, packetSize, encryption);
For release 3.1, the encryption keys and the payload type are only required if the
encryption protocol is “MediaConstants.AES”.
For SDK compatibility reasons, the transmit and receive keys are formatted as Strings.
and similarly for the receive key. The curly braces and commas are actually part of the
String. In order to be used by the encryption/decryption routines, the keys need to be
converted to byte arrays of the form (for example):
byte[] txKey = { 0x38, 0x4F, 0x0B, 0x34, 0xDF, 0x00, 0x2A, 0xBE, 0xF0,
0xC7, 0x55, 0x80, 0x1D, 0x1D, 0x33, 0xA8 };
If you use Avaya’s client-media-stack, the Audio “start” method will automatically do the
String to byte[] conversion for you.
Once the media receive and transmit encryption keys (Ke-Rx and Ke-Tx) are created,
they will be used within the AES algorithm to encrypt and decrypt the RTP stream.
// Generate the symmetric key using the JCE Engine and the
// readMasterKey from the
// MediaStart event and then use the Acaya Xs value to calculate
// the Ks-Rx value
see.generateKey(readMasterKey);
Ks-Rx = see.encrypBlock(Xs);
KsBuffer.put(Ks-Rx, 0, Ks-Rx.length-2);
// Grab the SSRC from the RTP header and populate the SSRCbuffer
ssrcBuffer.position(4);
ssrcBuffer.putInt(ssrc);
dst.position(hLength);
byte[] buf2 = new byte[pLength];
dst.get(buf2, 0, pLength);
// Decrypt payload
byte[] buf3 = decryptEngine.decryptBlock(buf2, iv-Rx, Ke-Rx);
Release 7.0.0
144 02-602658
Issue 1
Test Data
In order to validate your code, we present here some test data against which you may
run your decipher code. Following that is the expected output.
• Input Data
// From the MediaStart event, we get
byte[] readMasterKey = {
(byte)0xaa,(byte)0xaa,(byte)0xaa,(byte)0xaa,
(byte)0xaa,(byte)0xaa,(byte)0xaa,(byte)0xaa,
(byte)0xaa,(byte)0xaa,(byte)0xaa,(byte)0xaa,
(byte)0xaa,(byte)0xaa,(byte)0xaa,(byte)0xaa
};
• Expected Output
Ke-Rx:
(byte)0xba, (byte)0xeb, (byte)0xc6, (byte)0x18, (byte)0xa5,
(byte)0x5c, (byte)0x35, (byte)0x1f, (byte)0x25, (byte)0xce,
(byte)0xdf, (byte)0x37, (byte)0xbf, (byte)0x70, (byte)0xf3,
(byte)0x90
Ks-Rx:
(byte)0x98, (byte)0x12, (byte)0xf4, (byte)0x3c, (byte)0x17,
(byte)0xc5, (byte)0xd4, (byte)0x0e, (byte)0xe3,
(byte)0x8f, (byte)0x09, (byte)0xe1, (byte)0x7f, (byte)0xa8,
(byte)0xba, (byte)0xb7
IV-Rx:
(byte)0x98, (byte)0x12, (byte)0xf4, (byte)0x3c, (byte)0x2d,
(byte)0x11, (byte)0x4e, (byte)0xef, (byte)0xe3,
(byte)0x8f, (byte)0x09, (byte)0xe1, (byte)0x7f, (byte)0xab,
(byte)0x00, (byte)0x00
Release 7.0.0
145 02-602658
Issue 1
Chapter 8: Security Considerations
Your application development organization has the responsibility of providing the
appropriate amount of security for your particular application and/or recommending
appropriate security measures to your application customers for the deployment of your
application. Therefore you should be aware of the security measures that AE Services
Device, Media and Call Control API already take and what risks are known.
In addition to the advanced authentication and authorization policies outlined in the next
section, Application Enablement Services provides these basic security measures:
• Username and password are authenticated by the Device, Media and Call
Control service. Optionally, user authentication can be disabled by provisioning
a security policy for a machine, as detailed in the “Advanced Authentication and
Authorization Policies” section below.
• Authorization Measures:
The DMCC service supports three different authorization mechanisms. See the
"Advanced Authentication and Authorization Policies" section for more details.
- Unrestricted Access
• Only files within the configured recorder directory can be deleted using the
Media.DeleteMessage method.
Application Enablement Services offers the user the ability to encrypt the voice RTP
streams between the IP softphone and the far end of the call. See Chapter 7: Media
Encryption for more information.
If you are using encryption, AE Services Device, Media and Call Control API provides
these additional security measures:
For a complete discussion of the security guidelines for AE Services, see the White-
paper on Security in Avaya Aura® Application Enablement Services. This white paper is
available on the Avaya support site along with the customer documents.
SDB
This authorization policy states that the AE Services Security Database (SDB) shall be
used for authorization. When this policy is applied, DMCC applies SDB-based
authorization exactly as it did in previous releases of AE Services.
AE Services can optionally enforce an authorization policy as specified in the Security
Database (SDB) to ensure that only authorized users can monitor and control a given
device.
The SDB allows an administrator to give a user control of a specific device or list of
devices. An administrator can also allow a user to monitor/control any device by
granting them "Unrestricted Access". The administrator can also disable the SDB
entirely, which turns off all authorization enforcement and allows any user to monitor or
control any device. See the Avaya Aura® AE Services Administration and Maintenance
Guide for more information about SDB administration.
For AE Services 5.x and later when used with Communication Manager 5.1 or later, the
client application does not have to know the extension password to register a device,
provided the following is true:
• The DeviceID contains the administered switch name associated with a valid
switch connection to Communication Manager
• The switch connection to the Communication Manager is active and talking
• The SDB on the AE Services server is enabled
• The CTI user has “Unrestricted Access” in the SDB
Note:
A CTI user can be administered for "Unrestricted Access" via the "Edit
CTI User" web page on the AE Services Management Console.
Release 7.0.0
148 02-602658
Issue 1
• The extension’s class of restriction (COR) on the Communication Manager has:
o “Can Be Service Observed” set to “y”
o “Can Be a Service Observer” set to “y”
Note:
If the “Enabled SDB for DMCC Service” is not checked on the “Security
Database -> Control” page, no authorization enforcement will occur even if an
SDB authorization policy has been specified for a given host.
Enterprise Directory
This authorization policy states that an LDAP enterprise directory shall be used for
authorization. This authorization mechanism leverages the AE Services Management
Console web page, “Enterprise Directory”. In addition to specifying basic connection
parameters, this page contains the following fields that are critical to this authorization
method:
• Search Filter Attribute Name: This indicates the attribute name in the user
record that corresponds to username. DMCC will attempt to match a username
to the contents of this attribute. An example is “SAM-Account-Name” in
Windows Active Directory.
• Device ID Attribute: This indicates the attribute name in the user record that
corresponds to the device ID to be authorized for the user. A primary example
here would be an attribute such as “Phone Number” that contains a provisioned
E.164 number for users.
When this authorization mechanism is selected, DMCC will use LDAP to query the user
record for the provisioned Device ID (e.g. Phone Number) and will cache the retrieved
Device ID. When DMCC attempts to authorize a request, it will verify that the Device
ID retrieved from the user record is a substring of the Device ID specified in the
request. This allows per-user authorization without per-user provisioning on AE
Services. The substring match accounts for a very common scenario where a Tel URI
is specified in the request (e.g. tel:+13035381234) but the user record contains an
E.164 number (+13035381234) or extension (5380112).
Unrestricted Access
This authorization policy states that DMCC shall not apply any authorization checks to
sessions originating from the specified host. This allows the administrator to give a
specific application unrestricted access to all devices without provisioning a “user” for
that application.
Release 7.0.0
149 02-602658
Issue 1
AA Policy Use Cases
The following are some use cases that illustrate the value in AA policy provisioning.
Release 7.0.0
150 02-602658
Issue 1
application, but the administrator would ensure that this authentication would
not use the internal User Management database. Instead the authentication
would be performed against the enterprise directory using the provisioned
Enterprise Directory configuration, or would be performed using Kerberos as
specified in the Avaya Aura® AE Services Administration and Maintenance
Guide.
• User Authentication Not Required: With this mechanism, DMCC trusts the
application to have properly authenticated the user, and allows the application
to assert a user identity. This sort of mechanism would make sense for a web
app where the user has already authenticated with the web app and AE
Services has been provisioned to trust the web app host with respect to user
identity.
Release 7.0.0
151 02-602658
Issue 1
Chapter 9: Debugging
This section assumes that you have verified the operation of your AE Services server
using the verification application that comes with the AE Services server RPM file.
Please refer to the appropriate Avaya Aura® Application Enablement Services
Installation and Upgrade Guide for the offer you have purchased (AE Services on
VMware or Software Only) for troubleshooting procedures if this verification application
does not function properly.
Error Messages
In debugging your application, you will rely on Error Messages returned in response
events. Every request you make to the .NET API which results in a message being sent
to the AE Services server should result in a response message coming back. You
should always have an event handler for every message you send and when you get the
event, verify that the error attribute of the response is an empty string. If it is not an
empty string, the error attribute will contain information on why the response failed.
You should always catch exceptions when invoking methods in the API. The most
common exception is trying to send a message to the AE Services server after the
socket has been closed.
The .Net SDK ships with a DMCC.config file. This file is the configuration file for the
lognet error logger. By changing the log levels you can enable all XML messages sent
to/from your application and the AE Services server, to be logged to a file. In addition,
you can also enable logging of internal error conditions that may have occurred in the
API. The DMCC.config file has comments in it instructing you how to do this. In order
for your application to load and use the DMCC.config file the file must be located in the
same folder as your applications .exe file. The DMCC.config file also has a logger just
for the dashboard and information on how to enable it is in the file.
If you want to use the Device, Media and Call Control’s .NET log4net capabilities in
your application, you need to add the following code to your application:
Where NAME_OF_YOUR_LOGGER is how you want you logger identified in the DMCC.config
file.
<logger name="NAME_OF_YOUR_LOGGER">
<!-- <appender-ref ref="B" /> -->
<level value="DEBUG" />
<appender-ref ref="RollingLogFileAppender"/>
<appender-ref ref="ConsoleAppender" />
Release 7.0.0
152 02-602658
Issue 1
</logger>
The AE Services server side logs will also be helpful when debugging your application.
Please see Appendix E: DMCC Server Logging for additional information.
Improving performance
Many different factors may potentially affect the performance of your system. The
system has three main parts that may be affected:
• The AE Services server
• Communication Manager
• The network
An excessive load on any of these may slow down the overall system. Here are other
factors to check that also may affect your system performance.
Release 7.0.0
153 02-602658
Issue 1
• Update the Linux kernel with the latest updates available.
On Communication Manager:
• Ensure that Communication Manager is properly configured for your network and
business needs. Misconfigured Communication Manager elements can lead to
performance issues.
On the network:
• Ensure that your network traffic is properly balanced. One way to do this
professionally is to ask Avaya to perform a network assessment. There is also a
VoIP Readiness Guide available from the Avaya Support Centre
(http://www.avaya.com/support). For more information about improving the
performance of your network, see the “Network Quality and Management”
section of Administration for Network Connectivity for Avaya Communication
Manager (555-233-504).
Getting support
Development support is only available through Avaya's DevConnect Program at this
time. As an Innovator/Premier/Strategic level member of the DevConnect Program,
technical support questions can be answered through the DevConnect Portal at
www.avaya.com/devconnect
As a Registered member of the program, support is not available. If you require support
as a Registered member, you can apply for a higher level of membership that offers
support and testing opportunities through the DevConnect Portal. Membership at the
Innovator/Premier/Strategic level is not open to all companies. Avaya determines
membership status above the Registered level.
The DevConnect web site offers discussion forums for a variety of Device, Media and
Call Control areas. There is one that is dedicated to the .NET API. If you have a question
regarding the .NET API feel free to post the question on the forum. Before posting,
please look at the other topics which have already been posted to see if your question
has already been asked and answered.
Release 7.0.0
154 02-602658
Issue 1
Appendix A: The J-Scripts Library
Application Enablement (AE) Services Device, Media and Call Control .NET API offers a
thin client prototype which uses a modified .NET SDK inside Internet Explorer. The
modified .NET SDK – call it the ActiveX ServiceProvider – combines into one class all of
the methods of all of the classes of the unmodified SDK. In order to use the ActiveX
ServiceProvider, a web application has to interact with it using Jscript.
The purpose of this appendix is to define the interface and implementation of a JScript
library with which you can develop web applications using the ActiveX ServiceProvider.
In this interface the method signatures are almost identical to the methods of the .NET
SDK, making this interface general-purpose and easy to use.
J-Script
We have developed the Jscript library with the assumption that it will be imported into
HTML documents by way of the src attribute of a script element, as in:
This helps maintain a strict separation of concerns; our Jscript library publishes an
interface and the developer writes code using that interface, all in separate files. It
simplifies your HTML files by allowing you to remove large blocks of JavaScript code
from them – that is, it helps keep content and behavior separate.
We will also use namespaces for each of the Jscript objects (not classes) described
below. Namespaces prevent name collisions and, when used with an anonymous
function can “seal” a JavaScript object so that its private properties are invisible outside
of the scope of the object. The following code is an example of creating
com.avaya.dmcc and populating it with a constructor:
var com;
if (!com){
com = {}
} else if (typeof com != object) {
throw new Error("com is not an object")
}
if (!com.avaya) {
com.avaya = {}
} else if (typeof com.avaya != object) {
throw new Error("com.avaya is not an object")
}
if (!com.avaya.dmcc) {
com.avaya.dmcc = {}
} else if (typeof com.avaya.dmcc != object) {
throw new Error("com.avaya.dmcc is not an object")
}
/* Begin anonymous function */
Release 7.0.0
155 02-602658
Issue 1
(function() {
function ServiceProvider() { /* empty */ }
ServiceProvider.prototype.startApplicationSession =
function(/* args list */) {
/* body of function */
}
ServiceProvider.prototype.stopApplicationSession =
function(/* args list */) {
/* body of function */
}
/* Populate the namespace */
com.avaya.dmcc.ServiceProvider = ServiceProvider
})(); // End anonymous function and invoke it
sp = new com.avaya.dmcc.ServiceProvider();
sp.startApplicationSession();
Note:
JavaScript is an object- or prototype-based object-oriented language. We
saw an example of prototypes occurs in the code above, where the
instance functions startApplicationSession and
stopApplicationSession are created using the prototype for the
ServiceProvider object.
To create an instance of the ActiveX ServiceProvider inside Internet Explorer, the web
application developer will need to include an HTML object element in their web page(s).
The Jscript library assumes that the value of the element’s id attribute is DMCC; it will
not function if the object element is missing from the page, the id attribute is missing
from the object element, or the id attribute has a different value. The element looks like
this:
Also, the Jscript library will not function if the ActiveX ServiceProvider object has not
been instantiated, so the object element must appear before the script element in the
HTML document.
Release 7.0.0
156 02-602658
Issue 1
Static event handlers
It is not possible to instantiate COM objects dynamically (using new) in Jscript when you
need to be able to handle events propagated through Interop Services.
JavaScript and Jscript natively handle asynchronous browser events, such as page
loads, button clicks, and so on, but those events originate in the browser or from the
user. Consequently, we must statically define handlers for events in the Jscript library.
Using the Jscript extension to JavaScript for handling events via Interop Services, the
signature of a static handler looks like:
function DMCC::MediaStartedEvent(
deviceId, monitorId,
rtpAddress, rtpPort,
rtcpAddress, rtcpPort, packetSize)
Since only one static handler exists for a event, the static handler will be responsible for
dispatching events and response events to the object to which they ultimately belong.
Basically, the declaration of this function binds the function to a C# delegate in the
ActiveX ServiceProvider. Note that the prefix of the function name – DMCC:: – refers to
the value of the id attribute of the object element in the web page. This binds the function
mediaStartedEvent to the instance of the ActiveX ServiceProvider instantiated by
Internet Explorer and acts as a proxy between the ActiveX ServiceProvider and the
Jscript callback provided by the web application developer.
Static handlers will be defined for each event and each response event.
The Jscript library forwards the parameters to the corresponding method in the ActiveX
ServiceProvider (without the developer-provided function), which in turn, creates an
Invoke ID, converts the request to XML, sends it to the server and returns the
Invoke ID to the Jscript library. The Jscript library places the Invoke ID along with
the developer-provided function into a hash. A response event occurs when the server’s
response is received, at which time the ActiveX ServiceProvider invokes the static
handler, RegisterTerminalResponseEvent, passing it the Device ID string, the
Invoke ID, and some other parameters. Using the Invoke ID, the static handler
Release 7.0.0
157 02-602658
Issue 1
retrieves the developer –provided function, deletes it from the hash, and invokes it with
all of the arguments that were passed to its self.
This process is similar for regular events. To register interest in an event, the developer
calls startMonitor() using a reference to a Phone, Media, CallControl, or
CallInformation object. Instead of passing in a boolean value to indicate interest
in a particular type of event, however, the developer will pass in a function to be called
when an event of that type occurs.
The primary differences between response events and regular events are:
• an Invoke ID is not returned when the developer calls startMonitor()
• the function that the developer provides for an event type remains in the library’s
internal hash for that event type until it is deleted when the developer calls
stopMonitor().
The normal value of the Invoke ID is in correlating responses with requests. The
function-based approach just described manages this for the developer, so the value of
the Invoke ID to the user is unknown. Each request method in the Jscript library will
nonetheless return the Invoke ID, should the user wish to do something with it.
The following code are examples of registering for and handling request events and
events.
Release 7.0.0
158 02-602658
Issue 1
When the StartApplicationSessionRequestEvent occurs, the function
sasCallback is invoked.
sp = new com.avaya.dmcc.ServiceProvider();
events.displayUpdated = displayUpdatedHandler;
phone.startMonitor(events, 0, responseFunc)
J-Script object
The Jscript library will have objects with the following names: ServiceProvider,
Device, Phone, Media, ThirdPartyCallController, and
CallInformation.
Note:
An XMLProcessor object is not included in this design, but can be added
if requested.
The following tables show the methods and events belonging to each object. The
methods that do not take a callback function as the final argument are italicized.
An object will not have a method named after an event. The object will have a method
for registering a function (which is anonymous from the perspective of the Jscript library)
to handle events of that type.
Note:
If this list is not exhaustive, any additional methods or events not shown
here will be added when they are added to the ActiveX ServiceProvider.
startApplicationSession serverConnectionDownEvent
stopApplicationSession serverConnectionNotActiveEvent
reconnect missedAtLeastOneKeepAliveEvent
getNewDevice
startAutoKeepAlive
stopAutoKeepAlive
shutdown
getSessionId
getAutoKeepAliveEnabled
getDeviceId
releaseDeviceId
getThirdPartyDeviceId
startMonitor displayUpdatedEvent
Release 7.0.0
160 02-602658
Issue 1
stopMonitor lampUpdatedEvent
registerTerminal ringerStatusEvent
unregisterTerminal terminalUnregisteredEvent
redirectMedia hookSwitchUpdatedEvent
getHookswitchStatus
setHookswitchStatus
pressButton
getButtonInfo
getDisplay
getLampMode
getMessageWaitingIndicator
getRingerStatus
startMonitor mediaStartedEvent
stopMonitor mediaStoppedEvent
mediaDeleteMessage mediaPlayingEvent
mediaSetToneRetrievalCriteria mediaPlayingStoppedEvent
mediaStartDubbing mediaPlayingSuspendedEvent
mediaStopDubbing mediaRecordingEvent
mediaStartRecording mediaRecordingStoppedEvent
mediaStopRecording mediaRecordingSuspendedEvent
mediaSuspendRecording mediaToneDetectedEvent
mediaResumeRecording mediaTonesRetrievedEvent
mediaStartPlaying
mediaSuspendPlaying
mediaResumePlaying
Release 7.0.0
161 02-602658
Issue 1
mediaStartToneCollection
mediaStopToneCollection
mediaFlushToneCollectionBuffer
startMonitor conferencedEvent
stopMonitor deliveredEvent
snapshotDevice connectionClearedEvent
singleStepConferenceCall doNotDisturbEvent
alternateCall establishedEvent
answerCall failedEvent
clearCall forwardingEvent
clearConnection heldEvent
conferenceCall originatedEvent
consultationCall retrievedEvent
deflectCall transferredEvent
generateDigits
holdCall
makeCall
getDoNotDisturb
getForwarding
reconnectCall
retrieveCall
setDisplay
setDoNotDisturb
setForwarding
singleStepTransfer
Release 7.0.0
162 02-602658
Issue 1
snapshotCall
transferCall
startMonitor linkUpEvent
stopMonitor linkDownEvent
getCallInformation
getLinkStatus
Server-side Instructions
Modify the object element that appears near the top of dashboard.html.
• Do not change the value of the object element's id attribute; doing so will cause
the dashboard and any DMCC JScript library-based application to fail to function.
Release 7.0.0
163 02-602658
Issue 1
Client-side Instructions
In order for the dashboard page to function in Internet Explorer, you must do the
following:
You may also have to configure additional security settings in Internet Explorer. They
can be set by going to Tools --> Internet Options --> Security--> Local Intranet -->
Custom Level.
The setting that affect whether or how this page (including ServiceProvider.dll) functions
are:
1. Run components signed with Authenticode
2. Download signed ActiveX controls
3. Run ActiveX controls and plugins
4. Script ActiveX controls marked safe for scripting
The dashboard page has only been tested with Internet Explorer 6 on Windows XP.
Release 7.0.0
164 02-602658
Issue 1
Appendix B: Communication Manager
Features
Here is a list of key features in Communication Manager that you may wish to take
advantage of in developing your applications. This is not an exhaustive list - just a
subset of features most likely to be used in applications. For descriptions of these
features, see any of the Communication Manager administration guides.
• AAR/ARS Partitioning
• Abbreviated Dialing
• Abbreviated and Delayed Ringing
• Abbreviated Programming
• Administration Without Hardware
• Authorization Codes
• Automatic Alternate Routing (AAR)
• Automatic Call Distribution (ACD) Features
o Announcements
o Automatic Answering With Zip Tone
o Multiple Call Handling
o Service Observing
• Observe Digital Sets/IP Phones
• Observe Logical Agent IDs
• Automatic Call Distribution (ACD) Features:
o Basic Hunt Group Call
o Agents in Multiple Splits
o Agent Login/Out
o Display - Agent Terminal
• Automatic Callback (on Busy)
• Automatic Callback on Don’t Answer
• Automatic Route Selection (ARS)
• Bridged Call Appearance (single-line, multi-appearance)
o Hunt Group Redirect Coverage
o Multiple Coverage Paths
o Temporary Bridged Appearance
o Remove Temporary Bridged Appearance
• Call Coverage Features
o Call Coverage Consult with Conference/Transfer
• Call Coverage Features
o Consult
o Coverage Paths
o Send All Calls
o Temporary Bridged Appearance
• Call Forwarding / Busy Don’t Answer @ Call Vectoring
o VDN of Origin Announcements
• Call Forwarding by Service Observer
• Call Forwarding by Service Observed
• Call Forwarding Features:
Release 7.0.0
165 02-602658
Issue 1
o Call Forwarding All Calls
o Call Forwarding - Busy and Don’t Answer
o Call Forwarding - Don’t Answer
o Call Forwarding - Off Net
• Call Park
• Call Pickup
o Directed Call Pickup
o Remove Temporary Bridged Appearance
o Remove Auto-Intercom
• Call Vectoring:
o VDN of Origin Display
• Consult
• Coverage of Calls Redirected Off Net
• Drop (button operation)
• Group Paging
• Hold (single-line, multi-appearance)
• Hold - Automatic
• Hold (single-line, multi-appearance)
• Hold - Automatic [from IR1V4 WCC]
• Hunting/Hunt Groups
• IP Trunks
• Last Number Dialed
• Leave Word Calling - Switch
• Malicious Call Trace
• Message Waiting Indication
• Music-on-Hold Access
o Held Calls
o Conference-Terminal Calls
o Transferred Trunk Calls
• Personalized Ringing
• Personal Station Access
• Priority Calling
• Recorded Announcement
• Terminal Translation Initialization (TTI)
• Tone on Hold
• Transfer (single-line, multi-appearance)
• Voice Terminal Display
o Calling Number Display (SID/ANI/Extn ID)
o Called Number Display (internal & DCS)
o Stored Button Display
Release 7.0.0
166 02-602658
Issue 1
Appendix C: Constant Values
Here are tables describing the values for the XML message parameters which take a
constant value and that are switch specific. These values are specific to Avaya’s
Communication Manager switch. These include:
• Phone Object Enumerations and Constants
o Lamp State - enumeration which defines all of the lamp states
o Lamp Color - enumeration which defines all of the lamp colors
o Button Function - enumeration which defines all of the button functions
o Button ID - enumeration which defines all of the button ID’s
o Registration States - enumeration which defines all of the registration
states
o Dependency Modes - enumeration which defines all of the dependency
modes
o Ringer Pattern Constants
o Registration Constants
• Media Mode Enumerations
o Media Mode - enumeration which defines all of the media modes
• Service Provider Enumerations
o Convert E164 to Dial String - enumeration which defines
o Convert Dial String to E164 - enumeration which defines
• Third Party Call Control Enumeration
o Single Step Conference Call - enumeration which defines all of the Single
Step Conference Call states
o Call Forwarding - enumeration which defines all of the Call Forwarding
states
Release 7.0.0
167 02-602658
Issue 1
Flash Lamp is flashing. Usually indicates a call is on
hold or a feature is pending activation.
Inverted Flash Lamp is flashing in reverse. Usually indicates
some kind of denial.
Undefined Some other lamp state. You should never get
this.
Release 7.0.0
168 02-602658
Issue 1
ATD_QTIME Attended group - oldest time
AUDIX_REC Audix One-Step Recording
AUT_MSG_WT Automatic message waiting indication
AUTO_CBACK Auo call back
AUTO_ICOM Auto-dial ICOM
AUTO_IN ACD - Auto-In
AUTO_WKUP Automatic Wakeup entry mode
AUTODIAL Autodial button
AUX_WOR
Release 7.0.0
170 02-602658
Issue 1
IN_CALL_ID
Release 7.0.0
172 02-602658
Issue 1
SHARE_TALK
TERM_X_GR
Release 7.0.0
174 02-602658
Issue 1
DISPLAY_MODULE_START The first button in the Display Module starts here.
If you want to get to other feature buttons start with
this number and add the appropriate offset. For
example, Display Module Button 3 would be
(DISPLAY_MODULE_START + 2)
COVERAGE_MODULE_START The first button in the Coverage Module starts
here. If you want to get to other feature buttons
start with this number and add the appropriate
offset. For example, Coverage Module Button 3
would be (COVERAGE_MODULE_START + 2)
Idle
Registering
Registered
Unregistering
Unknown
Main
Independent
Dependent
Ringer Off 0
Manual Signal 1
Attendant Incoming Call 4
Attendant Held Call 5
Attendant Call Waiting 6
Attendant Emergency 7
Release 7.0.0
175 02-602658
Issue 1
Intercom 9
Standard Ring 11
DID/Attendant Ring 12
Priority Ring 13
Ring Ping 14
Media Enumerations
Table 35: Media Modes Enumeration
Name Description
Release 7.0.0
176 02-602658
Issue 1
Client_Mode Selecting CLIENT_MODE mode allows you to register the
phone directly on the computer where the application is
running. You can specify where the media is supposed
to go. You can monitor all messages going to/from the
phone and inject messages (e.g., go off hook, push a
button). However, you have no access to media itself.
Since the application has access to the media it can do
whatever it wants to with it.
UNDEFINED UNDEFINED mode should never be used.
CONVERTED
NO_MATCH
INVALID_INPUT
CONVERTED
NO_MATCH
INVALID_INPUT
Release 7.0.0
177 02-602658
Issue 1
Name Description
Release 7.0.0
178 02-602658
Issue 1
Appendix D: Unicode Mapping Table
When the Unicode Script parameter is used in the Register Terminal Request the
following table indicates the number of bits 1 should be shifted to the left. Multiple
character sets may be specified by ‘ORing’ the values together. For example, if Basic
Latin and Armenian were desired then the value for the Unicode Script would be (1 << 0
| 1 << 6) which is 0x41.
NOTE: Communication Manager requires Basic Latin to be specified when any other
character set is specified.
Release 7.0.0
179 02-602658
Issue 1
Appendix E: DMCC Server Logging
If you want to increase the detail of the DMCC logging, you will want to change what is getting logged to
the dmcc-trace.log.* files. You will need to edit the /opt/mvap/conf/dmcc-logging.properties file, replacing
the text in /opt/mvap/conf/dmcc-logging.properties with the text below (or similar).
The new logging levels/information can be enabled by one of the following:
• Restart the AE Services as the root user via the following command line interface:
[root@youraes ~]# /sbin/service aesvcs restart
• To enable the logging levels without a service disruption, you may restart the DmccMain JVM from
the command line as follows as a root user:
[root@youraes ~]# jps
3250 Bootstrap
3732 run.jar
3707 WrapperSimpleApp
5552 Jps
4119 SnmpAgent
3649 Main
3466 LcmMain
8035 DmccMain
Release 7.0.0
180 02-602658
Issue 1
handlers=com.avaya.common.logger.ThreadedHandler
com.avaya.common.logger.ErrorFileHandler
com.avaya.common.logger.ApiFileHandler
com.avaya.common.logger.NistFileHandler
Release 7.0.0
181 02-602658
Issue 1
############################################################
# configure com.avaya.common.logger.ErrorFileHandler
# This handler contains code that uses a MemoryHandler that
# pushes to a ThreadedHandler whose target is a FileHandler
# with the pattern specified here. The level set here
# is propagated through the entire Handler chain.
# The result is a log containing detailed error pretext.
com.avaya.common.logger.ErrorFileHandler.level=WARNING
com.avaya.common.logger.ErrorFileHandler.pattern=../logs/dmcc-error.log
############################################################
############################################################
# configure java.util.logging.MemoryHandler
# filter specifies the name of a Filter class to use (defaults to no Filter).
# level specifies the level for the Handler (defaults to Level.ALL)
# size defines the buffer size (defaults to 1000).
# push defines the pushLevel (defaults to level.SEVERE).
# target specifies the name of the target Handler class. (no default).
java.util.logging.MemoryHandler.level=FINEST
java.util.logging.MemoryHandler.size=1000
java.util.logging.MemoryHandler.push=WARNING
############################################################
############################################################
# configure com.avaya.common.logger.ApiFileHandler
# This handler is a ThreadedHandler whose target is a
# FileHandler with the pattern specified here. The level set
# here is propagated to the FileHandler. By default, this
# Handler is configured with a filter to log all API calls.
# filter specifies the name of a Filter class to use (defaults to no Filter).
com.avaya.common.logger.ApiFileHandler.level=FINE
com.avaya.common.logger.ApiFileHandler.pattern=../logs/dmcc-api.log
com.avaya.common.logger.ApiFileHandler.filter=com.avaya.common.logger.R
egExFilter
############################################################
############################################################
# configure com.avaya.common.logger.RegExFilter
# Filters LogRecords by matching their Logger name using the
# regular expression specified in the pattern property.
Release 7.0.0
182 02-602658
Issue 1
com.avaya.common.logger.RegExFilter.pattern=^com\.avaya\.api.*
############################################################
############################################################
# Facility specific properties (extra control per logger)
#com.xyz.foo.level = SEVERE
sun.rmi.level = WARNING
com.avaya.platform.jmx.Mx4jXSLTProcessor.level = WARNING
############################################################
# configure com.avaya.common.logger.NistFileHandler
# It is configured with a filter to log nist sip stack output.
# NIST SIP Stack log level : FINEST, FINER, INFO, WARNING, OFF
############################################################
com.avaya.common.logger.NistFileHandler.level=OFF
com.avaya.common.logger.NistFileHandler.pattern=/var/log/avaya/aes/dmcc
-nist.log
com.avaya.common.logger.NistFileHandler.filter=com.avaya.common.logger.
NistRegExFilter
com.avaya.common.logger.NistRegExFilter.pattern=^gov\.nist\.javax\.sip\
.stack\.ServerLog
com.avaya.common.logger.NistFileHandler.LOG_MESSAGE_CONTENT=true
############################################################
# #################################################
# Enable tracing of all XML messages into the dmcc-trace.log.* files
com.avaya.mvcs.proxy.CstaMarshallerNode.level=FINEST
com.avaya.mvcs.proxy.CstaUnmarshallerNode.level=FINEST
############################################################
Release 7.0.0
183 02-602658
Issue 1
Appendix F: TSAPI Error Code Definitions
This appendix lists all of the values for the TSAPI error codes that you may encounter
in the DMCC/TSAPI logfiles, when employing DMCC Call Control Services. These error
codes are generated by TSAPI and passed on to DMCC which, in turn, may convert
them into Java Exceptions in the DMCC server side log files. A CSTA Error will be
issued to the client.
There are two major classes of TSAPI error codes:
• CSTA universal Failures
• ACS Universal Failures
Release 7.0.0
184 02-602658
Issue 1
invalidFeature 15
invalidAllocationState 16
invalidCrossRefId 17
invalidObjectType 18
securityViolation 19
genericStateIncompatibility 21
invalidObjectState 22
invalidConnectionIdForActiveCall 23
noActiveCall 24
noHeldCall 25
noCallToClear 26
noConnectionToClear 27
noCallToAnswer 28
noCallToComplete 29
genericSystemResourceAvailability 31
serviceBusy 32
resourceBusy 33
resourceOutOfService 34
networkBusy 35
networkOutOfService 36
overallMonitorLimitExceeded 37
conferenceMemberLimitExceeded 38
genericSubscribedResourceAvailability 41
objectMonitorLimitExceeded 42
externalTrunkLimitExceeded 43
outstandingRequestLimitExceeded 44
genericPerformanceManagement 51
performanceLimitExceeded 52
unspecifiedSecurityError 60
sequenceNumberViolated 61
timeStampViolated 62
Release 7.0.0
185 02-602658
Issue 1
pacViolated 63
sealViolated 64
genericUnspecifiedRejection 70
genericOperationRejection 71
duplicateInvocationRejection 72
unrecognizedOperationRejection 73
mistypedArgumentRejection 74
resourceLimitationRejection 75
acsHandleTerminationRejection 76
serviceTerminationRejection 77
requestTimeoutRejection 78
requestsOnDeviceExceededRejection 79
unrecognizedApduRejection 80
mistypedApduRejection 81
badlyStructuredApduRejection 82
initiatorReleasingRejection 83
unrecognizedLinkedidRejection 84
linkedResponseUnexpectedRejection 85
unexpectedChildOperationRejection 86
mistypedResultRejection 87
unrecognizedErrorRejection 88
unexpectedErrorRejection 89
mistypedParameterRejection 90
nonStandard 100
Release 7.0.0
186 02-602658
Issue 1
ACS Error Definitions
Error Numeric Code Description
ACSERR_APIVERDENIED -1 This return indicates that the API
Version requested is invalid and not
supported by the existing API Client
Library.
ACSERR_BADPARAMETER -2 One or more of the parameters is
invalid.
ACSERR_DUPSTREAM -3 This return indicates that an ACS
Stream is already established with
the requested Server.
ACSERR_NODRIVER -4 This error return value indicates that
no API Client Library Driver was
found or installed on the system.
ACSERR_NOSERVER -5 This indicates that the requested
Server is not present in the network.
ACSERR_NORESOURCE -6 This return value indicates that there
are insufficient resourcesto open a
ACS Stream.
ACSERR_UBUFSMALL -7 The user buffer size was smaller
than the size of the next available
event.
ACSERR_NOMESSAGE -8 There were no messages available
to return to the application.
ACSERR_UNKNOWN -9 The ACS Stream has encountered
an unspecified error.
ACSERR_BADHDL -10 The ACS Handle is invalid.
ACSERR_STREAM_FAILED -11 The ACS Stream has failed due to
network problems. No further
operations are possible on this
stream.
ACSERR_NOBUFFERS -12 There were not enough buffers
available to place an outgoing
message on the send queue. No
message has been sent.
ACSERR_QUEUE_FULL -13 The send queue is full.
Release 7.0.0
187 02-602658
Issue 1
Appendix G: Routeing Services
Release 7.0.0
189 02-602658
Issue 1
RouteRegister
Client applications use RouteRegister request to register as a routing server for
RouteReques(s) from a specific device. The application must register for routing
services before it can receive any RouteRequest(s) from the routing device. An
application may be a routing server for more that one routing device. For a specific
routing device,however, only one application is allowed to be registered as the routing
server. If a routing device already has a routing server registered, subsequent
RouteRegister requests will be negatively acknowledged, except as described in
Special usage cases.
Special usage cases: In some cases it is desirable to allow the same application to re-
register as a routing device. That is, if a routing device already has a routing server
registered, subsequent RouteRegister requests will be positvely acknowledged if
certain criteria conditions are satisfied. For example, if a link goes down with an AE
Services application, the application can re-establish itself if the following criteria are
met:
• If the login matches that of the previously registered application
• If the application name matches that of the previously registered application
• If the IP address of the client machine matches that of the previously registered
Application
RouteRegister Request
ErrorValue Description
OutstandingRequestLimitExceeded The specified routing device already has a
registered routing server.
Release 7.0.0
190 02-602658
Issue 1
RouteRequest
The switch sends a RouteRequest to request a destination for a call arrived on a
routing device from a routing server application. The application may have registered
as the routing server for the routing device on the switch that is making the request, or
it may have registered as the default routing server. The RouteRequest includes call-
related information. A routing server application typically uses the call-related
information and a database to determine the destination for the call. The routing server
application responds to the RouteRequest via a RouteSelect request that specifies a
destination for the call or a RouteEnd request, if the application has no destination for
the call.
The Routing Request Service can only be administered through the Basic Call
Vectoring feature. The switch initiates the Routing Request when the Call Vectoring
processing encounters the adjunct routing command in a call vector. The vector
command will specify a CTI link’s extension through which the switch will send the
RouteRequest to AE Services DMCC through the TSAPI Service.
Multiple adjunct routing commands are allowed in a call vector. In G3V3, the Multiple
Outstanding Route Requests feature allows 16 outstanding Route Requests per call.
The Route Requests can be over the same or different CTI links. The requests are all
made from the same vector. They may be specified back-to-back, without intermediate
(wait, announcement, goto, or stop) steps. If the adjunct routing commands are not
specified back-to-back, pre-G3V3 adjunct routing functionality will apply. This means
that previous outstanding RouteRequests are canceled when an adjunct routing vector
step is executed.
The first RouteSelect response received by the switch is used as the route for the call,
and all other Route Requests for the call are canceled via RouteEnd event(s).
Release 7.0.0
191 02-602658
Issue 1
RouteSelect
The routing server application uses RouteSelect to provide a destination to the switch
in response to a RouteRequest for a call.
An application may receive one RouteEnd event and one Error for a
RouteSelect request for the same call in one of the following call scenarios:
• A RouteRequest is sent to the application.
• Caller drops the call.
• Application sends a RouteSelect request.
• A RouteEnd event (errorValue = NoActiveCall) is sent to the application.
• TheRouteSelect request is sent, but the call has been dropped.
• An Error is sent for the RouteSelect request (errorValue = InvalidCrossRefId) to
application.
RouteSelect Request
ErrorValue Description
InvalidDeviceId An invalid
routeRegisterReqID has been specified in the RouteEndInv()
request
InvalidCrossRefId An invalid routeCrossRefID has been
specified in the Route Select request.
Release 7.0.0
192 02-602658
Issue 1
RouteUsed Event
The switch uses a RouteUsed to provide a destination to the routing server application
with the actual destination of a call for which the application previously sent a request
containing a destination. The routeUsed and destRoute parameters contain the same
information specified in the routeSelected and destRoute parameters of the previous
RouteSelect request of this call, respectively. The callingDevice parameter contains the
same calling device number provided in the previous RouteRequest of this call.
Note that the number provided in the routeUsed parameter is from the routeSelected
parameter of the previous RouteSelect request of this call received by the TSAPI
Service. This information in routeUsed is not from Communication Manager and it may
not represent the true route that Communication Manager used.
Note that the number provided in the destRoute parameter is from the destRoute
parameter of the previous RouteSelect request of this call received by the TSAPI
Service. This information in destRoute is not from the Communication Manager and it
may not represent the true route that the Communication Manager used.
The number provided in the callingDevice parameter is from the callingDevice
parameter of the previous RouteRequest of this call sent by the TSAPI Service.
Release 7.0.0
193 02-602658
Issue 1
RouteEnd Request
This request is sent by the routing server application to terminate a routing dialog for a
call. The service request includes a cause value giving the reason for the routing dialog
termination.
• If an application terminates a RouteRequest via a RouteEnd request, the switch
continues vector processing.
• An application may receive one RouteEnd Event and one Error for a RouteEnd
request for the same call in the following call scenario:
o A RouteRequest is sent to the application.
o Caller drops the call.
o Application sends a RouteEnd request.
o A RouteEnd Event (errorValue = NoActiveCall) is sent to the application.
o TSAPI Service receives the cstaRouteEndInv() request, but call has
been dropped.
o TSAPI Service sends universalFailure for the cstaRouteEndInv() request
(errorValue = INVALID_CROSS_REF_ID) to application.
The errorValue is ignored by Communication Manager and has no effect for the routed
call, but it must be present in the API. Suggested error codes that may be useful for
error logging purposes are:
RouteEnd Request
ErrorValue Description
Generic Normal termination (for example, application does not want to
route the call or does not know how to route
the call).
RouteEnd Event:
This event is sent by the switch to terminate a routing dialog for a call and to inform the
routing server application of the outcome of the call routing.
Release 7.0.0
194 02-602658
Issue 1
An application may receive one RouteEnd Event and one Error for a RouteSelect
request for the same call in one of the following call scenarios:
• A RouteRequest is sent to the application.
• Caller drops the call.
• Application sends a RouteSelect Request.
• A RouteEnd Event (errorValue = NoActiveCall) is sent to the application.
• The TSAPI Service receives the RouteSelect Request, but call has been
dropped.
• An error is sent for the RouteSelect request (errorValue =InvalidCrossRefId) to
application.
RouteEnd Event
ErrorValue Description
Generic The call has been successfully routed or The
adjunct route request to route using NCR resulted
in the call not being routed by NCR because of an
internal system error.
Release 7.0.0
195 02-602658
Issue 1
RouteEnd Event
ErrorValue Description
NetworkOutOfService The adjunct route request to route using NCR
resulted in the call not being routed by NCR
because the NCT contained an invalid PSTN
number, and the second leg can not be set up.
Release 7.0.0
196 02-602658
Issue 1
RouteRegisterAbort
This event notifies the application that the TSAPI Service or switch aborted a routing
registration session. After the abort occurs, the application receives no more
RouteRequest(s) from this routing registration session and the routeRegisterReqID is
no longer valid. The routing requests coming from the routing device will be sent to the
default routing server, if a default routing registration is still active.
• If no CTI link has ever received any RouteRequest(s) for the registered routing
device and all of the CTI links are down, this event is not sent.
• In a multi-link configuration, if at least one link that has received at least one
RouteRequest for the registered routing device is up, this event is not sent. It is
sent only when all of the CTI links that have received at least one
RouteRequest for the registered routing device are down.
Note:
How Communication Manager sends the RouteRequest (s) for the registered
routing device, via which CTI links, is controlled by the call vectoring
administered on the switch. A routing device can receive RouteRequest (s)
from different CTI links. It is possible that links are up and down without
generating this event.
• If the application wants to continue the routing service after the CTI link is up, it
must issue a RouteRegister request to re-establish a routing registration
session for the routing device.
• The RouteRegisterAbort Event is sent when a competing application sends a
RouteRequest and it has the same criteria (login, application name, and IP
address).
Release 7.0.0
197 02-602658
Issue 1
RouteRegisterCancel
Client applications use RouteRegisterCancel to cancel a previously registered
RouteRegister session. When this service request is positively acknowledged, the
client application is no longer a routing server for the specific routing device and the
RouteRequest(s) are not longer sent for the specific routing device associated with the
routeRegisterReqID to the requesting client application. Any further RouteRequest(s)
from the routing device will be sent to the default routing server application, if there is
one registered.
RouteRegisterCancel Request
ErrorValue Description
InvalidDeviceId An invalid routeRegisterReqID has been specified in
the RouteEndInv() request
Release 7.0.0
198 02-602658
Issue 1
Appendix H: IPv6 Support
Network layer Internet Protocol version 6 (IPv6) increases the IP address field from 32
bits wide to 128 bits, allowing a greater number of addressable nodes (among other
improvements). With the internet migrating to IPv6 addressing, AE Services support for
it will ensure Application Enablement Services’ compatibility with the new Internet
Protocol.
Thus, in release 6.1 of Application Enablement Services, support for IPv6 networks
were added. This includes:
• Support for “pure” IPv6 networks
• Support for mixed IPv4 & IPv6 networks
IPv6 addresses are normally written as eight groups of four hexadecimal digits. There
are 3 defined forms for representing IPv6 addresses as text strings:
1. The preferred form is x:x:x:x:x:x:x:x, where the 'x's are one to four hexadecimal digits of
the eight 16-bit pieces of the address. Examples include:
• ABCD:EF01:2345:6789:ABCD:EF01:2345:6789
• 2001:DB8:0:0:8:800:200C:417A
2. It may be common for addresses to contain long strings of zeroes. In order to make
writing addresses containing zero bits easier, a special syntax is available to compress
the zeros. The use of "::" indicates one or more groups of 16 bits of zeros. The "::" can
only appear once in an address. The "::" can also be used to compress leading or trailing
zeros in an address. For example, the following addresses:
• 2001:DB8:0:0:8:800:200C:417A a unicast address
• FF01:0:0:0:0:0:0:101 a multicast address
• 0:0:0:0:0:0:0:1 the loopback address
• 0:0:0:0:0:0:0:0 the unspecified (wildcard) address
may be represented as:
• 2001:DB8::8:800:200C:417A a unicast address
• FF01::101 a multicast address
• ::1 the loopback address
• :: the unspecified (wildcard) address
3. An alternative form that may be convenient when dealing with a mixed environment of
IPv4 and IPv6 nodes is ::FFFF:d.d.d.d, where the 'd's are the decimal values of the four
low-order 8-bit pieces of the address (standard IPv4 representation). Examples include:
• 0:0:0:0:0:FFFF:13.1.68.3
• 0:0:0:0:0:FFFF:129.144.52.38
which are compressed to:
• ::FFFF:13.1.68.3
• ::FFFF:129.144.52.38
This form, also known as an “IPv4-mapped address”, is not commonly used at the user
application layer. There are security concerns associated with this form, and several
Microsoft Windows implementations do not support it. To address these concerns and
Release 7.0.0
199 02-602658
Issue 1
limitations, the network stacks specifically require either an IPv4 address or an IPv6
address. Thus, the use of this form in Application Enablement Services is discouraged.
To use a literal IPv6 address in a URL, the literal address should be enclosed in “[“ and
“]” characters. For example the literal IPv6 address “1080:0:0:0:8:800:200C:417A”
would be represented as: “[1080:0:0:0:8:800:200C:417A]”. This notation allows parsing
a URL with no confusion between the IPv6 address and port number. For example:
https://[2001:0db8:85a3:08d3:1319:8a2e:0370:7344]:443/index.html
Oracle (Sun) Java version 1.4 and later versions are IPv6-enabled with the extending
of the InetAddress class to the Inet6Address and Inet4Address classes. The JVM
determines whether to use Inet4Address or Inet6Address automatically, which is
transparent to the developer. For example:
• InetAddress ip = InetAddress.getByName(“java.sun.com”); or:
• InetAddress ip = InetAddress.getByName(“135.9.30.40”); or:
• InetAddress ip = InetAddress.getByName(“2001:db8::1428:57ab”); then:
• Socket s = new Socket(ip, 80);
In fact, wherever an IPv4 address can be used in AE Services, an IPv6 address can
now also be employed - assuming, of course, that it makes sense for the target network
topography. Thus, IPv6 addresses can be used for such things as:
Release 7.0.0
200 02-602658
Issue 1
• Communication Manager addresses of various types, including:
Note that Communication Manager 6.0 or later is required for IPv6 connections
between AE Services and Communication Manager. Also note that there is no official
support of IPv6 for the CLANs. Processor Ethernet connections to Communication
Manager should be used in IPv6 networks.
Release 7.0.0
201 02-602658
Issue 1
Appendix I: ACS Universal Error Codes
The following table contains a list of private error codes that may be returned instead of
the generic CSTA Error Code that was returned as a negative acknowledgement in
previous releases of AE Services.
ACS Error Code
Release 7.0.0
202 02-602658
Issue 1
acsError24 TSAPI Bad Stream Type
Release 7.0.0
203 02-602658
Issue 1
Glossary
A
AE
Used as a “shorthand” term in this documentation for Application Enablement.
AES
Stands for Advanced Encryption Scheme.
API
Application Programming Interface. A “shorthand” term in this documentation for the
Java interface provided by the Application Enablement Services. See also connector
client API library
application machine
The hardware platform that the connector client API library and the client application
are running on
B
BHCC
busy hour call capacity
C
client application
An application created using the Device, Media and Call Control API
CMAPI softphone
Application Enablement Services Device, Media and Call Control API software objects
that represent softphone-enabled, Communication Manager telephones or extensions
Application Enablement Services Device, Media and Call Control API
The product name. This includes the server-side runtime software (see the AE Services
server software ) and the connector client API library . This term is never used to
reference only the client API library.
connector
This describes the function of Application Enablement Services Device, Media and Call
Control API.
In this context, “connector” means software and communications protocol(s) that allow
two disparate systems to communicate. Often used to provide open access to a
proprietary system. In the case of Application Enablement Services Device, Media and
Call Control API, the connector enables applications running on a computing platform to
incorporate telephony functionality through interaction with Communication Manager.
connector client API library
The Application Enablement Services Device, Media and Call Control Java API, also
referred to as the AE
connector server machine
The hardware platform that the connector server software is running on. In these
documents, the term “connector server” by itself never refers to the connector server
machine. See connector server software .
connector server software
The Application Enablement Services server-side runtime software, often referred to as
the “connector server” in these documents
CSTA
Computer-Supported Telecommunications Applications
D
DMA
Release 7.0.0
204 02-602658
Issue 1
Direct memory access
DMCC softphone
Application Enablement Services Device, Media and Call Control API software objects
that represent softphone-enabled, Communication Manager telephones or extensions
E
ECMA
European Computer Manufacturers Association. A European association for
standardizing information and communication systems in order to reflect the international
activities of the organization.
H
hold time
The total length of time in minutes and seconds that a facility is used during a call
J
JDK
Java Developers Kit
J2SE
Java 2 Platform, Standard Edition
JMX
Release 7.0.0
206 02-602658
Issue 1