Genesys Cloud - Main

 View Only

Sign Up

  Thread closed by the administrator, not accepting new replies.
  • 1.  Setting multiple Key/Pair values at once using SetJsonObjectProperty in Architect

    Posted 06-16-2023 02:30
    No replies, thread closed.

    Hi Everyone,

    Is there any way to assign multiple Key/Pair values at once using SetJsonObjectProperty in Architect.

    Currently, in JSON literal we can be able to do it. But, in expression mode only one SetJsonObjectProperty is being allowed.

    Please do share if you've implemented something like this (Looking to add 10-15 Key/Value pairs at once).

    Thanks in advance


    #Implementation
    #Unsure/Other

    ------------------------------
    Sriram L
    ------------------------------


  • 2.  RE: Setting multiple Key/Pair values at once using SetJsonObjectProperty in Architect

    Posted 06-20-2023 18:39
    No replies, thread closed.

    @Melissa Bailey Thoughts?



    ------------------------------
    George Ganahl GCP (Genesys Cloud), CCXP
    Principal PS Consultant
    Genesys
    ------------------------------



  • 3.  RE: Setting multiple Key/Pair values at once using SetJsonObjectProperty in Architect

    Posted 06-21-2023 10:14
    No replies, thread closed.

    SetJsonObjectProperty returns the json object with the added key, so just nest the calls to add multiple key/value pairs.  Remember Architect limits you to 60 nested expressions (see https://help.mypurecloud.com/articles/complex-expression-error/)

    SetJsonObjectProperty(SetJsonObjectProperty(Task.json, "b", 2), "c", 3)





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



  • 4.  RE: Setting multiple Key/Pair values at once using SetJsonObjectProperty in Architect

    Posted 06-21-2023 18:20
    No replies, thread closed.

    Thank you, Melissa!



    ------------------------------
    George Ganahl GCP (Genesys Cloud), CCXP
    Principal PS Consultant
    Genesys
    ------------------------------



  • 5.  RE: Setting multiple Key/Pair values at once using SetJsonObjectProperty in Architect

    Posted 06-22-2023 08:30
    No replies, thread closed.

    Hi Melissa,

    Thanks for the great suggestion. Will try it out !

    Thanks



    ------------------------------
    Sriram L
    ------------------------------