Skip to content
Last updated

Editing Communicator Templates

Communications sent out via Communicator can be edited (content or styling) by changing the appropriate template.

Making Changes via API

Templates can be directly editing using the API see the Update Template Version endpoint in the API docs.

Making Changes via the Template Editor

You can also use the Peach Admin dashboard UI to edit templates. Visit your Admin Dashboard and click the "Templates" menu option. Check with Peach Support if you don't already have access to the Peach Admin dashboard.

Template Syntax

Peach templates are Jinja templates and so their syntax and semantics are the same. See the Jinja Documentation.

Available Variables

Different template variables are available depending on type of message being sent. For instance, almost all messages sent via Communicator are related to a borrower, so the variable {{person}} is available for use. Other variables, like {{loan}} only make sense for messages being sent regarding a specific loan. For instance, a message with subject paymentMethodAdded has no loan associated with it, and thus no {{loan}} variable available for use. Whereas, loanPaidOff does have a loan associated with it, and so does have {{loan}} variable available.

Variable {{company}}

This variable is always available. It references the Company object of the company which is sending the message.

Note the important subfield: {{company.config}} which is the Company Config object which contains important configurations.

Examples

...

Thanks you,
- {{company.brandName}}
<img alt="logo" src="{{company.config.brandAssets.logos.small}}">

Variable {{person}}

This variable is available for messages sent which are related to a borrower (most messages).

The borrower referenced is the borrower to whom the message is being sent. Note that for historical reasons even borrowers of type "Business" are referenced by {{person}}.

Examples

Dearest {{person.name.firstName}},

Variable {{case}}

This variable is available for messages sent which are related to a case.

The case referenced is the case about which the message is being sent.

Variable {{loanTypeCompanyConfig}}

This variable is available for messages sent which are related to a loan. It provides access to company configuration values with support for loan type-specific overrides.

Resolution Order

When you access an attribute on loanTypeCompanyConfig, the value is resolved in this order:

  1. Loan Type Company Config Override - If the loan has an associated loan type with a company config override, that value is used first.
  2. Company Object Attributes - Standard company fields like legalName, brandName, name, domainName, shortDomainName, slug.
  3. Company Config - Values from the company's config object (e.g., brandAssets, support, timezone).
  4. Empty String - If the attribute is not found anywhere, returns an empty string.

Supported Attributes

AttributeDescription
legalNameThe company's legal name
brandNameThe company's brand name
nameThe company's name
domainNameThe company's domain name
shortDomainNameThe company's short domain name
slugThe company's slug
brandAssets.*Brand assets from company config (logos, colors, etc.)
support.*Support contact information from company config
timezoneThe company's timezone
(other config keys)Any other keys from the company config

Examples

Using brand name with loan type override support:

Thank you for choosing {{loanTypeCompanyConfig.brandName}}!

Using support contact information:

Questions? Contact us at {{loanTypeCompanyConfig.support.email}} 
or call {{loanTypeCompanyConfig.support.phone}}.

Using brand assets:

<img alt="logo" src="{{loanTypeCompanyConfig.brandAssets.logos.primary}}">

Note: If no loan type override is configured, {{loanTypeCompanyConfig}} will return the same values as accessing the equivalent fields on {{company}} or {{company.config}}.

Next steps