The app is displayed in the apps tray on the right side of the user profile page in the agent interface.

Example manifest

"location": {  "support": {    "user_sidebar": "assets/iframe.html"  }},

See Setting the app location.

In addition to the objects available in all locations, including the User object, the following objects are available in this location:

Events

In addition to the core events, you can use the following events to listen for changes to the user's data:

  • user.alias.changed
  • user.avatarUrl.changed
  • user.details.changed
  • user.email.changed
  • user.externalId.changed
  • user.groups.changed
  • user.name.changed
  • user.notes.changed
  • user.role.changed
  • user.signature.changed
  • user.tags.changed
  • user.timeZone.changed
  • user.[custom_field_key].changed
  • user.organizations.changed

The user.name.changed event fires when the user's name in the user's page changes.

For custom fields, replace [custom_field_key] with the custom field's key attribute. Use the User Fields REST API to get a list of possible key values.

Note: Currently, if another user changes a property in a separate window, the event will not be picked up.

To add event listeners to your app, see Working with framework events.

User Profile Page Field object

userFields

Returns either the named user field as an User Profile Page Field object, or all available user fields if you don't specify a name.

Here are the names of the user fields available:

  • access
  • alias
  • details
  • groups
  • locales
  • notes
  • organization
  • organizations
  • role
  • signature
  • tags
  • timezone
  • user_type
  • {user_field_key}

For field definitions, see Default user fields in Zendesk help.

For custom fields, replace {user_field_key} with the custom field's key attribute. Use the User Fields REST API to get a list of possible key values.

get
client.get('userFields')
returns
{  "userFields": [{    // User Profile Page Field object properties  }]}

or

get
client.get('userFields:fieldName') // e.g. client.get('userFields:my_text_field')
returns
{  "userFields:fieldName": {    // User Profile Page Field object properties  }}

You can also access individual fields by their zero-indexed order.

get
client.get('userFields.0')
returns
{  "userFields.0": {    // User Profile Field object properties  }}

Properties

Actions

userField.name

get
client.get('userFields:fieldName.name')
returns
{  "userFields:fieldName.name": string}

userField.isVisible

get
client.get('userFields:fieldName.isVisible')
returns
{  "userFields:fieldName.isVisible": boolean}

userField.options

get
client.get('userFields:fieldName.options')
returns
{  "userFields:fieldName.options": [{    // User Profile Page Field Option properties  }]}

See User Profile Page Field Option object for the properties.

userField.hide

invoke
client.invoke('userFields:fieldName.hide')

userField.show

invoke
client.invoke('userFields:fieldName.show')

userField.toggle

invoke
client.invoke('userFields:fieldName.toggle')

User Profile Page Field Option object

fieldName.options

Returns all the options of a dropdown field in the profile page. Only applicable to dropdown fields.

See User Profile Page Field object.

get
client.get('userFields:fieldName.options') // e.g. client.get('userFields:role.options')
returns
{  "userFields:fieldName.options": [{    // User Profile Page Field Option properties  }]}

You can access individual options by their zero-indexed order.

get
client.get('userFields:fieldName.options.0')  // e.g. client.get('userFields:role.options.0')
returns
{  "userFields:fieldName.options.0": {    // User Profile Page Field Option properties  }}

Properties

userFieldOption.label

get
client.get('userFields:fieldName.options.0.label')
returns
{  "userFields:fieldName.options.0.label": string}

userFieldOption.value

get
client.get('userFields:fieldName.options.0.value')
returns
{  "userFields:fieldName.options.0.value": string}