Webchat: Unable to deliver Custom Attributes via Agent Script View

Hello,

We have deployed chat using Widget - Version 2. The below custom attributes have been configured within the script and the script variables so they can display on the Agents screen. However, these custom variables are not showing up in architect so I am posting here to see if someone can provide clarity as to why they are not working.

Capture2

{
id: 'cx_webchat_form_firstname',
name: 'firstname',
maxlength: '100',
placeholder: 'Required',
label: 'First Name'
},
{
id: 'cx_webchat_form_lastname',
name: 'lastname',
maxlength: '100',
placeholder: 'Required',
label: 'Last Name'
},
{
id: 'cx_webchat_form_accountnumber',
name: 'accountnumber',
maxlength: '100',
placeholder: 'Required',
label: 'Account Number',
value: '<%=repId%>'
},
{
id: 'cx_webchat_form_district',
name: 'district',
maxlength: '100',
placeholder: 'Required',
label: 'District',
value: '<%=district%>'
},
{
id: 'cx_webchat_form_email',
name: 'email',
maxlength: '100',
placeholder: 'Required',
label: 'Email'
},
{
id: 'cx_webchat_form_reason',
name: 'subject',
maxlength: '100',
placeholder: 'Required',
label: 'Reason for chatting'
}

Architect Error:
Capture3

I do see them come through on the conversation ID API.
"attributes": {

  •    "context.email": "EMAIL ADDRESS HERE",*
    
  •    "firstname": "FIRSTNAME HERE",*
    
  •    "Email": "state.email",*
    
  •    "displayName": "state.firstName + \" \" + state.lastName",*
    
  •    "subject": "",*
    
  •    "context.accountnumber": "ACCOUNT NUMBER HERE",*
    
  •    "Language": "en-us",*
    
  •    "email": "",*
    
  •    "context.district": "DISTRICT NUMBER HERE",*
    
  •    "context._genesys_OS": "Windows",*
    
  •    "customerLanguage": "state.customerLanguage",*
    
  •    "accountnumber": "",*
    
  •    "context._genesys_browser": "Chrome",*
    
  •    "context._genesys_referrer": "REFERRER PAGE HERE",*
    
  •    "context.reason": "REASON HERE",*
    
  •    "context._genesys_source": "web",*
    
  •    "accountNumber": "state.accountNumber",*
    
  •    "context.genesys.legacyRoutingTargetQueueAddress": "",*
    
  •    "lastname": "LAST NAME HERE",*
    
  •    "context.firstName": "FIRST NAME HERE",*
    
  •    "scriptId": "SCRIPT ID HERE",*
    
  •    "context.lastName": "LAST NAME HERE",*
    
  •    "context._genesys_url": "URL HERE",*
    
  •    "district": "",*
    
  •    "context._genesys_pageTitle": "PAGE TITLE HERE",*
    
  •    "Chat Language": "en-us"*

I made a small change in my architect configuration. I will test to see if it works.

Capture4

Also, is there a way to display attributes in the "Interactions Details"?

Picture1

The variables you collect in chat result in participant attributes; custom variables in architect are only variables in the flow. You'll need to use the architect action to get participant data.

See the three custom field properties documented here: https://developer.mypurecloud.com/api/digital/webchat/index.html#chat_variables. There's a usage example for a custom field in v2 here: https://developer.mypurecloud.com/api/digital/webchat/widget-version2.html#code_sample_for_web_page_with_genesys_webchat_widget.

Hi @tim.smith,

Thanks for the additional information. After further exploring, I was able to get additional custom attributes and show them via the script. Are there any plans to have a UI admin tool in the near future versus having to configure everything via the script code?

Thank you.

No, you get the 3 attributes you can display without any extra config. Beyond that, you have to use a script; the script is the admin tool to configure the agent interface.

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