Data Transfer Objects
A customer is a detailed description of a customer, including their associated channels.
| Property | Type | Description |
|---|---|---|
customer_id | String | The customer's unique ID. |
display_name | String | The customer's display name. |
channels | An array of Channel resources, optional | A list of channel addresses, used only on the Customer Details screen. |
links | An array of Link resources, optional | A list of a customer's links, used only on the Customer Details screen. |
details | A Detail resource, optional | Additional information about the customer |
avatar | String, optional | An absolute URL of the customer's avatar image. |
A channel is a customer contact address.
| Property | Type | Description |
|---|---|---|
type | Enum: sms, whatsapp, chat | The channel type. |
value | String | The channel address. |
A link is a URL to additional information about a customer.
| Property | Type | Description |
|---|---|---|
type | String | The website or app name. Examples: Facebook, Salesforce. |
value | String | An actual link, i.e., the site's URL. Note: For the web version of Frontline, only https:// or mailto: protocols are accepted. All other protocols will be ignored. |
display_name | String | The link's display name. |
A detail is a field that can be used to display additional information about a customer.
| Property | Type | Description |
|---|---|---|
title | String | The title of the detail section. |
content | String | The additional information that is to be displayed. Can include multiple lines. |
Example of a Data transfer Object for Customer: Note: A whatsapp number is not required.
1{2"display_name": "Joseph Martin",3"channels": [4{ "type": "sms", "value": "+15558675310" },5{ "type": "whatsapp", "value": "whatsapp:+15558675310" }6],7"links": [8{ "type": "Facebook", "value": "https://www.facebook.com/josephmartin/", "display_name": "Facebook" }9],10"details": {11"title": "Purchase History",12"content": "Product: Unobtanium\n\nDate: 2021-07-07\nQuantity: 1000 units\n\nSales rep: Jessie Robinson"13}14}
The Conversation resource is what binds Twilio Frontline users and customers together. Learn about the Conversation resource and how you can update one here.
| Property | Type | Description |
|---|---|---|
friendlyName | String, optional | The human-readable name of a conversation. |
attributes.avatar | String, optional | An absolute URL to the conversation avatar image. A custom attribute defined by Twilio Frontline. |
The User resource represents a Twilio Frontline user, who can log into the app.
| Property | Type | Description |
|---|---|---|
friendlyName | String, optional | The user's display name. |
identity | String | The app user identity. |
attributes.avatar | String, optional | An absolute URL to the user's avatar image. A custom attribute defined by Twilio Frontline. |
The Participant resource represents a customer in Twilio Frontline who is a non-chat conversation participant, i.e., via WhatsApp or SMS. Learn more about the Participant resource and how to update it here.
| Property | Type | Description |
|---|---|---|
attributes.customer_id | String | An ID used to tie together a conversation participant and a customer in your system. A custom attribute defined by Twilio Frontline. |
attributes.avatar | String, optional | An absolute URL to the participant's avatar image. A custom attribute defined by Twilio Frontline |
attributes.display_name | String, optional | The participant's display name. A custom attribute defined by Twilio Frontline. |
A Template is a predefined message with placeholders for custom variables.
| Property | Type | Description |
|---|---|---|
content | String | The message string. |
whatsAppApproved | Boolean, optional | A flag which shows whether a template has been approved by Facebook. |
A Category is an object that groups together similar templates.
| Property | Type | Description |
|---|---|---|
display_name | String | The Category's title. |
templates | An array of Template resources | The list of templates that are members of the Category. |