Legacy Dev Forum Posts

 View Only

Sign Up

Authenticated Web messaging custom atributes

  • 1.  Authenticated Web messaging custom atributes

    Posted 06-05-2025 18:36

    Daisy | 2023-05-08 15:38:07 UTC | #1

    Hi all,

    If we implement authenticated web messaging, and wanted to pass for example accountID to agent, is there a predefined variable that we can use instead of setting the Participant data (Genesys("command", "Database.set") )? https://help.mypurecloud.com/articles/authenticated-web-messaging-attributes/ shows only 4 attributes, but maybe one can be utilized?

    Kind Regards,


    Gurwan_Duplenne | 2023-05-09 06:42:58 UTC | #2

    Hello Daisy,

    You just need to pass your attributes this way Key : "Value"

    For example :

    // dummy Database Genesys("command", "Database.set", { messaging: { customAttributes: { foo1: "myValue", foo2:"Myvalue2", accountID :"1234566789" } } });:

    Hope it helps


    Daisy | 2023-06-07 14:52:40 UTC | #3

    Hi Gurwan,

    When I use Database.set command, and use custom button with Messenger.open command, I have an issue. It looks like sometimes I don't get the values passed to the Inbound message flow, like Database.set action did not finish before messenger flow started.

    Is there a way to make sure Database.set is executed before we call Messenger.open command?

    I am attaching the img as an example (without the sensitive data)

    Thank you!


    Angelo_Cicchitto | 2023-06-07 15:21:07 UTC | #4

    GC can automatically capture the unique ID of customer as provided by your ID provider: that is exposed via the sub claim, and available in the Message.Message.senderAddressInfo.addressDisplayable built-in variable. So, if your AccountID can be provided in the sub claim, that's automatically exposed.

    The other option of using Database.set is also valid, and available regardless of Authentication: if you notice misbehavior, please raise a ticket with Customer Care. In your example, I would simply trigger Database.set prior to Messenger.open command.


    Daisy | 2023-06-09 19:48:59 UTC | #5

    Hi Angelo,

    Thank you, this has solved the issue. I also had another question, although this is not an appropriate thread I wanted to confirm if data session can be removed with localStorage.removeItem("_actmu")? Is there any additional method that we can use?

    Edit: Is it valid to use this command: Genesys("command", "MessagingService.clearSession");

    Thank you!


    system | 2023-07-09 14:59:51 UTC | #6

    This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.


    This post was migrated from the old Developer Forum.

    ref: 19794