Data Behavior
  • 29 Sep 2022
  • 3 Minutes To Read
  • PDF

Data Behavior

  • PDF

The following notes on data behavior are integral when developing a Lookup Adaptor.

Overwrite Existing Fields

In the Lookup Adaptor configuration within Gladly, you can enable the Detailed Lookup results to replace values currently in Gladly.

This can be used for name, address, and editable custom Attributes in the Gladly Customer Profile. If enabled and an Agent updates a Customer’s address in your Customer system of record, you can use this feature to update the address field in Gladly.

This is an organization-wide setting and will impact all Customer Profiles in your Gladly instance.

Editable vs. Visible Fields

Display Options
Certain fields can be locked so they are un-editable by agents (or hidden). They include:​

  • name​
  • address​
  • customAttributes​

Email address and phone fields cannot be locked and transactions are always read-only​ unless an Action is configured (this feature is currently available for Order type transactions).

Tip - Changing field editability settings

By default, Gladly will configure

  • All customAttributes to be visible, but not editable
  • Name field to be editable
  • Address field to be editable

If you'd like to make certain customAttributes editable, or lock down edits on the name and / or address fields, please let the Gladly Support team know.


Display Behavior
The Customer Profile always displays all EDITABLE custom attributes.

All VISIBLE custom attributes only display if a value is saved. All HIDDEN custom attributes will always hide regardless if a value is saved.

Detailed Lookup Behavior
When a Detailed Lookup occurs, the data the Lookup Adaptor returns overwrites all VISIBLE and HIDDEN fields (except for email and phone). EDITABLE fields retain the current value in Gladly unless they are blank​ or overwrite existing fields is enabled.

Removing custom attribute values during a DETAILED lookup

To remove the value of a custom attribute completely, your lookup adaptor will need to pass in an empty string as the customAttribute value. Removing the key-value pair from the payload will not remove it from the profile as Gladly will retain the previous value.

Unlinking Behavior
When a Profile is unlinked, transactions and customAttributes will be removed from the Profile with the exception of EDITABLE customAttributes.

Email and Phone Handling

The email and phone Arrays are additive and will add the data returned by the Lookup Adaptor to the data already in Gladly.

If the Lookup Adaptor returns a duplicate mobile or email that already exists in another Profile within Gladly, it will drop the duplicate​ and store the rest of the Detailed Lookup resuls.

Overwrite Existing Fields cannot be used to modify email and phone data already in Gladly (e.g. changing a phone type from HOME to MOBILE). If the email address or phone numbers already exist in Gladly, that type will remain as is in the Customer Profile regardless of what the Lookup Adaptor sends back (i.e.: you cannot change a phone number of type OTHER to MOBILE using a Lookup Adaptor response).

Multiple Lookup Adaptors

If you have multiple Lookup Adaptors, please ensure the keys in your customAttributes are unique across all Lookup Adaptors so one does not overwrite the other​.

If you do have customAttributes that are not unique across multiple Lookup Adaptors, the field is read-only, blank, and you've allowed the setting for Overwrite Existing Values in your App settings, Gladly will randomly choose which Lookup Adaptor the attribute comes from at the time that lookup happens.

Please note that if one Customer Lookup integration times out / responds with an error that Gladly will consider this an error for all Customer Lookup integration(s).

Transactions

For the time being, Gladly can only support one transaction type across all Lookup Adaptors (e.g.: they must all be of type ORDER)​.


Was this article helpful?

What's Next