I configured an endpoint that returns this response:
{
"foo": 10,
"bar": 7
}
And then setup a working response like this:
{
"translationMap": {
"foo": "foo",
"bar": "bar"
},
"translationMapDefaults": {},
"successTemplate": "#set( $Integer = 0 ) #if (!$foo) #set ($foo = \"0\") #end #if (!$bar) #set ($bar = \"0\") #end #set( $total = $!Integer.parseInt($foo) + $!Integer.parseInt($bar)) {\"total\" : $total}"
}
The $Integer variable is a hack to get an instance of an Integer object.
I had to add the code like this to set default values due to some sort of validation weirdness. I opened an internal ticket for us to investigate.
#if (!$foo) #set ($foo = \"0\") #end #if (!$bar) #set ($bar = \"0\") #end
After that it does math on the two variables and returns it.
------------------------------
--Jason
------------------------------
Original Message:
Sent: 08-06-2025 12:49
From: Jason Mathison
Subject: Queue Observations - oActiveUsers
Are you getting everything you need from a single API response? If so, can you give me an example of it with anything sensitive redacted?
------------------------------
--Jason
------------------------------
Original Message:
Sent: 08-05-2025 01:26
From: Stijn Serry
Subject: Queue Observations - oActiveUsers
Hello Jason,
I need to get the total of Logged In Users. I'm getting this back from the REST call and returning both active members and logged out users towards architect where i can deduct active members - logged out users to find out the number of logged in users.
Stijn
------------------------------
Stijn Serry
Technical Coordinator CRM
Original Message:
Sent: 08-04-2025 13:17
From: Jason Mathison
Subject: Queue Observations - oActiveUsers
So while I agree that you can't do math in the translation map, you might be able to do it in the response template. What exactly is the math that you are doing?
------------------------------
--Jason
Original Message:
Sent: 07-31-2025 06:28
From: Stijn Serry
Subject: Queue Observations - oActiveUsers
Hello,
Yes, I'm using the same solution as you. Great that this solution is confirmed then.
For others: I uploaded the data action json file as txt file (uses integration: "Genesys Cloud Contact Data Actions" ) and do the calculation within architect in-queue flow to have the active members - logged out users to verify if there or users logged in into the system which take part of the queue.
You cannot make the calculation within the data action as Genesys doesn't support this in the translationmap.
------------------------------
Stijn Serry
Technical Coordinator CRM
Original Message:
Sent: 07-31-2025 06:10
From: Brian Jones
Subject: Queue Observations - oActiveUsers
Greetings @Stijn Serry - We agree a simple "oLoggedInUsers" dimension would be ideal. If passionate enough about the idea, you can create an enhancement request here. In the meantime, in case you haven't figured out a workaround...
We ended up calculating the "No Agents Logged In" value in our flow using the same API you're using above (grabbed the Offline user presence count) coupled with the Queue Members API. After running both data actions in Architect, we did a count of the Queue Members and then subtracted the count of Offline Users to get our total users logged in.
------------------------------
Brian T. Jones | Ascension | Senior Specialist - Technology
Original Message:
Sent: 07-29-2025 06:34
From: Stijn Serry
Subject: Queue Observations - oActiveUsers
Ok, it was apparently misinterpretation.
oActiveUsers is the number of agents which are member of the queue and have the queue really active for them (functionality exist in Genesys to be member but deactivate the queue) via user preferences.
I need to realize my query via another means then.
It would have been great to have an oLoggedInUsers counter in observations to avoid a lot of extra manipulations within the data action or architect.
Stijn
------------------------------
Stijn Serry
Technical Coordinator CRM