Use transaction list object data in composer workflow ECMAScript

Function: _genesys.session.getListItemValue(Transaction_List, Section) returns an OBJECT of key/value pairs: {Key1:value1, Key2:Value2, ..}

I am getting a string by using valueOf() function but not able to print in log from ECMAScript to check the string format.

If anyone has any idea how to store the each KVP info in a string array in ECMAScript… Please help.

Thanks in advance.

The object you are seeing is a JSON object.
To log the object as text __Log( JSON.stringify( ))
If there is a kv pair with the key of MyKey you can access it by .MyKey

var obj = _genesys.session.getListItemValue(Transaction_List, Section) ;
__Log( JSON.stringify( obj ));

var myVar = obj.MyKey;

Thanks a lot Mike :slight_smile: