Genesys Cloud - Main

 View Only

Sign Up

  Thread closed by the administrator, not accepting new replies.
  • 1.  Append to an AgentPair variable rather than updating it

    Posted 12-04-2023 13:34
    No replies, thread closed.

    Hi,

    I'm looking to work with Preferred Agent routing and I'm having some trouble creating my list of agentpairs.

    I'm running a Data Action which is returning me a list of users IDs. I can then loop through this list of IDs and generate a collection of agentpairs: MakeList(MakeAgentScorePair(FindUserById(Flow.queueMembers[Task.LoopIndex]),(100)))

    To make a pair. However, this doesn't really work - it's overwriting the list each time so I only end up with one agentpair rather than one for each member of the list of IDs.

    How can I "append" to the variable (agentpair collection) I've created rather than replace it each time? 

    I thought about adding each ID to a string and then each priority (coming from a separate array) into a separate string and then using MakeListAgentScorePair() but it won't accept a string collection to the priority values.

    I just wish we had List.Add() (or Collection.Add()) type functions to work with.


    #ArchitectureandDesign
    #Routing(ACD/IVR)

    ------------------------------
    James Dunn
    Pitney Bowes Inc.
    ------------------------------


  • 2.  RE: Append to an AgentPair variable rather than updating it

    Posted 12-04-2023 13:41
    No replies, thread closed.

    Use the AddItem function



    ------------------------------
    Melissa Bailey
    Genesys - Employees
    ------------------------------



  • 3.  RE: Append to an AgentPair variable rather than updating it

    Posted 12-05-2023 08:02
    No replies, thread closed.

    Thanks Melissa, that was far too obvious... But it's given me what I was looking for. 

    The Preferred Agent routing isn't working as I had expected (it still just seems to be alternating between agents on the queue) but I'll keep investigating.



    ------------------------------
    James Dunn
    Pitney Bowes Inc.
    ------------------------------