Genesys Multicloud

 View Only

Discussion Thread View
  • 1.  GWS 9 Subscriptions

    GENESYS
    Posted 10-26-2020 00:52
    We have a requirement to monitor Call States using GWS 9 cometd subscription. We need to build a custom application to monitor the states and pass them on to a few 3rd party application, Looking at the API documentation and from past experience, GWS appears to really be used for building agent desktop type functionality. I have written application connecting to SIP Server directly to monitor events, but it is against Cloud Policy to directly connect to SIP Server.

    It could be possible to log an agent in twice, once at the desktop and then this custom app could also log in each agent and so it could see the events. The problem with this approach is we would need all the agent passwords and that is not possible. This approach seems a bit of a kludge. Also talked about having a desktop customization send the events to custom application which could forward them on, but they do not want to do this either.

    Does anyone know a good way to use GWS 9 to subscribe for all the events for all the agents in a Tenant?

    #ArchitectureandDesign

    ------------------------------
    Arnold Lipton
    Genesys - Employees
    ------------------------------


  • 2.  RE: GWS 9 Subscriptions

    GENESYS
    Posted 10-27-2020 11:44
    Arnold,

    You can absolutely accomplish your goal using GWS 9 Statistics API.  Several Genesys Engage Cloud customers have used that API to obtain statistics for BI tools and dashboards.  To use the GWS 9 Statistics API from a non-agent service you'll need to authenticate against a Client Credentials Grant OAuth client using the Authentication API.  That OAuth client can be created by contacting Genesys Customer Care and requesting that is be setup for that Genesys Engage Cloud tenant.  They'll return your the Client ID and Client Secret to use in the authentication request.

    There is a tutorial on the Genesys Engage Cloud developer center that specifically authenticates using Client Credentials Grant and then subscribes to statistics: https://github.com/GenesysPureEngage/console-statistics-app-csharp.  It's in C#, but it's a good reference for whatever language you are developing in.

    To subscribe to all agents you'll need to use the GWS 9 Provisioning API to request a list of all configured agents.  Then you'll need to spin through that list and subscribe to the statistics that you need for each agent.

    Reach out to me directly if you have any questions during your development.

    Cheers.

    ------------------------------
    Jim Crespino
    Senior Director, Developer Evangelism
    Genesys
    https://developer.genesys.com
    ------------------------------



Need Help finding something?

Check out the Genesys Knowledge Network - your all-in-one access point for Genesys resources