Skip to main content

Template variables

Variables are placeholder text in messages that are dynamically replaced based on the information you've provided.

When you create a message with variables, UniLink will translate it to the appropriate value.

variable list

If we send a message Hey {{ contact.name }}, how may I help you?, then UniLink will pick the contact name and send a message like Hey John, how may I help you?. This enables you to send personalized messages to the end user.

Note: UniLink supports variables in canned response/macros/automation.

variable demo

To use a variable, type two double curly brackets {{ when composing a new message or creating a canned response. The variables will appear, and you can select the one you'd like to use.

The current list of template variables are:

VariableDescription
conversation.idNumeric version of the conversation id
contact.idNumeric version of the contact id
contact.nameContact full name
contact.first_nameContact first name
contact.last_nameContact last name
contact.phone_numberContact phone number
agent.nameAgent full name
agent.first_nameAgent first name
agent.last_nameAgent last name
agent.phone_numberAgent phone number

What if the variable doesn't exist?

If you try to send an undefined variable, then UniLink will show a warning.

undefined-variable

How to add fallback text?

When defining a fallback text, make sure you surround it with single quotes.

{{ contact.first_name || 'there'}}