Author Message
calculus_entropy
Joined: Apr 21, 2021
Messages: 6
Offline
Hi, all, I'm a ServiceNow developer. I have no idea about the technical side of Avaya. I am trying to see if there's a way I can access Avaya CM web services to update a user's phone status in a queue? Is there an endpoint I can hit (e.g., myinstance.avaya.com or something)? Is there documentation on REST calls for this somewhere out there?

Thanks!
calculus_entropy
Joined: Apr 21, 2021
Messages: 6
Offline
Is this the official documentation to use?
https://documentation.avaya.com/bundle/SessionManagerRoutingWebServices_r8.1/page/Functional_scope.html
JohnBiggs
Joined: Jun 20, 2005
Messages: 1139
Location: Rural, Virginia
Offline
There are not currently any RESTful interfaces that allow agent state monitoring nor agent state updates.

The routing web service you reference will not provide current agent state, nor allow updates to an agent's state.

I have another thread in email that I perceive is directly related to this same question by way of Harold C.

I am posting my response to Harold here.

Agent state ‘monitoring’ and agent state updates require use of TSAPI, JTAPI or DMCC API. The difference is largely what programming language suits you.

TSAPI is C++
JTAPI is Java
DMCC has three flavors. C#, Java, and access to the protocol XSDs which can be used by various code generators to produce interface source code.

There are ways of accessing this content through some other mechanisms such as the Client SDK and I believe Breeze APIs, but that is awkward way to access the functionality based on the use case that was described.

In all three cases you need to utilize TSAPI Basic user licensing. This is a per agent seat license. However in this context you only need one license PER OUTSTANDING QUERY or state update request. You can and should have multiple outstanding queries and potentially update requests. Anyone building such a solution should read this PSN https://downloads.avaya.com/css/P8/documents/101036842

In all three cases you have to _poll_ to find agent state. There is no agent state change event provided to third party applications. This is due to decisions Avaya made a decade or more ago about making agent state knowledge more difficult to access for 3rd party applications in order to advantage Avaya contact center solutions in the market place.

Updating agent state can be done via an API call that varies slightly based on which SDK is chosen for the work.

All of the API documentation can be found by selecting the appropriate interface on this page
https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/releases/8_1_3/index.gsp#tabs-product-horiz-2

Select a ‘tab’ such as JTAPI and scroll down to see the available documentation for that interface type.

There are sample apps included with the SDK and some additional ones on our portal along with tutorials, and other educational content
https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/educational_resources/index.gsp

This particular TSAPI sample application may be interesting to look at:
https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/educational_resources/sample_applications/tsapi/agent_view/index.gsp

Instead of spend a bunch of time trying to describe more detail about these approaches I would prefer to know the API of choice first.

I highly encourage any company interested in acquiring technical assistance with Avaya APIs to become a support enabled member in the DevConnect program in order to get their questions about the API answered and get technical support if/when they encounter development related issues/questions. For information on membership visit: https://www.devconnectprogram.com/site/global/program_benefits/membership_overview/index.gsp#tabs-1
calculus_entropy
Joined: Apr 21, 2021
Messages: 6
Offline
Ha, yes, I was working off of Harold's response he wrote us as via email as our sales engineer which was apparently what you posted, minus these lines:
"There are not currently any RESTful interfaces that allow agent state monitoring nor agent state updates.

"The routing web service you reference will not provide current agent state, nor allow updates to an agent's state."

I literally just joined this site a few hours ago to see if I could get more input and had no idea you are the originator of these thoughts... whoops :)

I'm and developer and not a programmer and work in JS, Angular, SN APIs, so it seems too heavy a lift to write something in one of the C's or Java for the simple function of updating an agent's phone status. I really wouldn't know where to start using the Avaya SDK since this is not an application I work in.

I was hoping there's just be an endpoint I could hit either with SOAP or REST, do some gets and post some updates without going down the routes you outlined.

"There is no agent state change event provided to third party applications." Are you saying even if I could get this to work, it would only be 1 way? Avaya will not produce a agent state change event for ServiceNow to consume?
JohnBiggs
Joined: Jun 20, 2005
Messages: 1139
Location: Rural, Virginia
Offline
as I reread, I embellished to fill in some gaps in what I had previously written.

These are very old APIs - predating WebServices by more than a decade. They have yet to be revisited and RESTful versions implemented. I suspect with your Java Script background and looking at some of the Java sample code you can find a path to success here.

"There is no agent state change event provided to third party applications." Are you saying even if I could get this to work, it would only be 1 way? Avaya will not produce a agent state change event for ServiceNow to consume?

I am not trying to say things are one way... you must query for CM agent state - there is no event sent when CM changes state. If the response to the query doesn't match ServiceNow's state, you have do decide which side to 'correct' and update that side.

Conversely you query ServiceNow's state (or get an event indicating the state has changed) and then query CM's state. If they dont match you have to decide which system to update the state in.

CM does support a request to change an agent's state.
calculus_entropy
Joined: Apr 21, 2021
Messages: 6
Offline
Ok, so REST is out. Guessing JSON objects are a no go as well. What is the protocol here? SOAP? RPC? And if it's SOAP, I'd need the WSDL. XML, JAVA, etc would be the language I use to send something to Avaya, but what is the connection type? Also, how do I find the web services endpoint in Avaya?

I think I'm just missing a step/understanding here before I even write the message I want to send.

Is there a standard format for the endpoint for CM where I can just plug in my endpoint based on our instance name?

Thanks!
MichaelHerman2
Joined: Jan 9, 2014
Messages: 102
Offline
To reiterate what some of what John has said, polling and setting Agent states must be done through one of the Application Enablement Services (AES) APIs that supports third party call control (3PCC). Therefore, your options are to use one of these AES APIs; TSAPI, JTAPI, or DMCC. Your application will send a request (e.g. to change an Agent's state) to the AES server and the AES server send the request to CM.

TSAPI is C++
JTAPI is Java
DMCC has three flavors. C#, Java, and access to the protocol XSDs which can be used by various code generators to produce interface source code.

Information on those interfaces can be found here.

https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/releases/8_1_3/index.gsp#tabs-product-horiz-2

If you choose to use JTAPI, for example, then you will need to download and use JTAPI SDK to develop your application.

Sample JTAPI applications can be found here:

https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/educational_resources/sample_applications/jtapi/index.gsp

The "JTAPI Agent Viewer" sample application would be very useful to you as it demonstrates how to "monitor" and change an agent's state.

https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/educational_resources/sample_applications/jtapi/agent_viewer/index.gsp
calculus_entropy
Joined: Apr 21, 2021
Messages: 6
Offline
Yep, got the flavors. I was looking for where do I hit with said flavors. It was the AES part I was missing. Had no idea about it.

Thanks!
calculus_entropy
Joined: Apr 21, 2021
Messages: 6
Offline
Also looks like you can do SOAP as well which would make it much easier for someone used to SOAP/REST.

https://www.devconnectprogram.com/site/global/products_resources/avaya_aura_application_enablement_services/overview/index2.gsp

Application Enablement Services provides the ability for traditional IT data application developers to interface with Avaya Aura Communication Manager as an evolution server, through standard web services via SOAP/XML methods.
JohnBiggs
Joined: Jun 20, 2005
Messages: 1139
Location: Rural, Virginia
Offline
I will get that clarified. The SOAP functionality is limited to CM provisioning services and a very restricted set of Telephony services provided through the Telephony Web Services. TWS does not include agent monitoring nor state change services.
Go to:   
Mobile view