SmartLETTERS: Merge fields

SmartLETTERS: Merge fields

Within your document you can use a wide range of merge fields. These will be taken from the output of Step 1 of your SmartSYNC flow. A non-exhaustive list is below.

Merge fields for CONSTITUENT letters

The standard fields are listed below. You can though include other information by using different options within your SmartSYNC flow to fetch addressee, salutation, giving summaries and other details. Please consult your SmartTHING team to find out more about this.
  1. {id}
  2. {import_id}
  3. {address|id}
  4. {address|address_lines}
  5. {address|city}
  6. {address|constituent_id}
  7. {address|country}
  8. {address|county}
  9. {address|do_not_mail}
  10. {address|formatted_address}
  11. {address|inactive}
  12. {address|postal_code}
  13. {address|preferred}
  14. {address|type}
  15. {address|address_lines_1}
  16. {age}
  17. {birthdate|d}
  18. {birthdate|m}
  19. {birthdate|y}
  20. {birthdateISO}
  21. {date_added}
  22. {date_modified}
  23. {deceased}
  24. {email|id}
  25. {email|address}
  26. {email|constituent_id}
  27. {email|do_not_email}
  28. {email|inactive}
  29. {email|primary}
  30. {email|type}
  31. {first}
  32. {fundraiser_status}
  33. {gender}
  34. {gives_anonymously}
  35. {inactive}
  36. {last}
  37. {lookup_id}
  38. {income}
  39. {religion}
  40. {industry}
  41. {matches_gifts}
  42. {matching_gift_per_gift_min}
  43. {matching_gift_per_gift_max}
  44. {matching_gift_total_min}
  45. {matching_gift_total_max}
  46. {matching_gift_factor}
  47. {matching_gift_notes}
  48. {name}
  49. {num_employees}
  50. {is_memorial}
  51. {is_solicitor}
  52. {no_valid_address}
  53. {receipt_type}
  54. {target}
  55. {requests_no_email}
  56. {former_name}
  57. {online_presence|id}
  58. {online_presence|address}
  59. {online_presence|constituent_id}
  60. {online_presence|inactive}
  61. {online_presence|primary}
  62. {online_presence|type}
  63. {phone|id}
  64. {phone|do_not_call}
  65. {phone|inactive}
  66. {phone|number}
  67. {phone|primary}
  68. {phone|type}
  69. {preferred_name}
  70. {primary_addressee}
  71. {primary_salutation}
  72. {name_other_name_type}
  73. {spouse|first}
  74. {spouse|last}
  75. {spouse|is_head_of_household}
  76. {custom_category} - This field will have the value of custom field if 'Enable gift and constituent custom fields?' option has been selected in settings.
  77. {custom_category_comment}
Note: Category in the above is a sanitised version of the custom field category. The category is lowercased and all non alpha fields are replaced with underline i.e. Letter-Name would become letter_name and the merge field {custom_letter_name}, similarly Last updated would have the merge field {category_last_updated}.

Details on these fields are available here,

If you have enabled membership fields in settings. If multiple memberships exist the fields to access these will be {membership_2|...} etc. We also output 'Active' memberships with merge fields prefixed by the program i.e. for a program of 'Annual members' you would have {membership_annual_members|category} etc.
  1. {membership_1|id}
  2. {membership_1|category}
  3. {membership_1|constituent_id}
  4. {membership_1|dues|value}
  5. {membership_1|expires}
  6. {membership_1|joined}
  7. {membership_1|members_1|id}
  8. {membership_1|members_1|constituent_id}
  9. {membership_1|members_1|primary}
  10. {membership_1|program}
  11. {membership_1|standing}

Merge fields for GIFT letters

Fields available as standard are:
  1. {id}
  2. {acknowledgements}
  3. {acknowledgements|0|status}
  4. {amount|value}
  5. {balance|value}
  6. {batch_number}
  7. {constituent_id}
  8. {constituent|id}
  9. {constituent|address|id}
  10. {constituent|address|address_lines}
  11. {constituent|address|city}
  12. {constituent|address|constituent_id}
  13. {constituent|address|country}
  14. {constituent|address|county}
  15. {constituent|address|do_not_mail}
  16. {constituent|address|formatted_address}
  17. {constituent|address|postal_code}
  18. {constituent|address|preferred}
  19. {constituent|address|state}
  20. {constituent|address|type}
  21. {constituent|age}
  22. {constituent|birthdate|d}
  23. {constituent|birthdate|m}
  24. {constituent|birthdate|y}
  25. {constituent|birthdate|full}
  26. {constituent|date_added}
  27. {constituent|date_modified}
  28. {constituent|deceased}
  29. {constituent|email|id}
  30. {constituent|email|address}
  31. {constituent|email|do_not_email}
  32. {constituent|email|inactive}
  33. {constituent|email|primary}
  34. {constituent|email|type}
  35. {constituent|first}
  36. {constituent|fundraiser_status}
  37. {constituent|gender}
  38. {constituent|gives_anonymously}
  39. {constituent|inactive}
  40. {constituent|is_constituent}
  41. {constituent|last}
  42. {constituent|lookup_id}
  43. {constituent|middle}
  44. {constituent|name}
  45. {constituent|online_presence|id}
  46. {constituent|online_presence|address}
  47. {constituent|online_presence|inactive}
  48. {constituent|online_presence|primary}
  49. {constituent|online_presence|type}
  50. {constituent|phone|id}
  51. {constituent|phone|do_not_call}
  52. {constituent|phone|inactive}
  53. {constituent|phone|number}
  54. {constituent|phone|primary}
  55. {constituent|phone|type}
  56. {constituent|preferred_name}
  57. {constituent|primary_addressee}
  58. {constituent|primary_salutation}
  59. {constituent|name_other_name_type}
  60. {constituent|spouse|id}
  61. {constituent|spouse|first}
  62. {constituent|spouse|last}
  63. {constituent|spouse|is_head_of_household}
  64. {constituent|title}
  65. {constituent|type}
  66. {constituent|import_id}
  67. {date}
  68. {date_added}
  69. {date_modified}
  70. {fundraisers}
  71. {fundraisers|0|amount|value}
  72. {fundraisers|0|constituent_id}
  73. {gift_aid_amount|value}
  74. {gift_aid_qualification_status} i.e. Qualified, Partly qualified and Not qualified etc.
  75. {gift_code}
  76. {gift_splits}
  77. {gift_splits|0|id}
  78. {gift_splits|0|amount|value}
  79. {gift_splits|0|appeal_id}
  80. {gift_splits|0|appeal|id}
  81. {gift_splits|0|appeal|category}
  82. {gift_splits|0|appeal|description}
  83. {gift_splits|0|appeal|end_date}
  84. {gift_splits|0|appeal|goal|value}
  85. {gift_splits|0|appeal|lookup_id}
  86. {gift_splits|0|appeal|start_date}
  87. {gift_splits|0|campaign_id}
  88. {gift_splits|0|campaign|id}
  89. {gift_splits|0|campaign|category}
  90. {gift_splits|0|campaign|description}
  91. {gift_splits|0|campaign|end_date}
  92. {gift_splits|0|campaign|goal|value}
  93. {gift_splits|0|campaign|lookup_id}
  94. {gift_splits|0|campaign|start_date}
  95. {gift_splits|0|fund_id}
  96. {gift_splits|0|fund|id}
  97. {gift_splits|0|fund|category}
  98. {gift_splits|0|fund|description}
  99. {gift_splits|0|fund|end_date}
  100. {gift_splits|0|fund|goal|value}
  101. {gift_splits|0|fund|lookup_id}
  102. {gift_splits|0|fund|start_date}
  103. {gift_splits|0|fund|type}
  104. {gift_splits|0|gift_aid_amount|value}
  105. {gift_splits|0|gift_aid_qualification_status} i.e. Qualified, Partly qualified and Not qualified etc.
  106. {recurring_gift_schedule|start_date} Date the recurring gift should start. 
  107. {recurring_gift_schedule|frequency} Installment frequency of the recurring gift to view. Values are Weekly, Every two weeks, Every four weeks, Monthly, Quarterly, Annually.
  108. {recurring_gift_schedule|end_date} Date the recurring gift should end.
  109. {reference}
  110. {split_summary} A summary of the gift splits
  111. {split_summary_html} A summary of the gift splits in HTML list format
  112. {gift_status}
  113. {is_anonymous}
  114. {constituency}
  115. {lookup_id}
  116. {payments}
  117. {payments|0|payment_method}
  118. {post_date}
  119. {post_status}
  120. {receipts}
  121. {receipts|0|amount|value}
  122. {receipts|0|date}
  123. {receipts|0|status}
  124. {subtype}
  125. {type}
  126. {constituent|custom_category} - value of custom field if 'Enable gift and constituent custom fields?' option has been selected in settings.
  127. {constituent|custom_category_comment}
Note: Category in the above is a sanitised version of the custom field category. The category is lowercased and all non alpha fields are replaced with underline i.e. Letter-Name would become letter_name and the merge field {custom_letter_name}, similarly Last updated would have the merge field {category_last_updated}.

For pledge and recurring gift payments you will also have a link to the parent gift's information with all the gift fields i.e.
  1. {linked_gift_1|amount|value}
  2. {linked_gift_1|balance|value}
  3. etc.
If you have enabled soft credits in settings the gift will also have available soft credit fields starting with {soft_credits|0|... and {soft_credit|1|...} etc. as an example:
  1. {soft_credits|0|id}
  2. {soft_credits|0|import_id}
  3. {soft_credits|0|address|id}
  4. {soft_credits|0|address|address_lines}
  5. {soft_credits|0|address|city}
  6. {soft_credits|0|address|constituent_id}
  7. {soft_credits|0|address|country}
  8. {soft_credits|0|address|county}
  9. {soft_credits|0|address|do_not_mail}
  10. {soft_credits|0|address|formatted_address}
  11. {soft_credits|0|address|inactive}
  12. {soft_credits|0|address|postal_code}
  13. {soft_credits|0|address|preferred}
  14. {soft_credits|0|address|type}
  15. {soft_credits|0|address|address_lines_1}
  16. {soft_credits|0|age}
  17. {soft_credits|0|birthdate|d}
  18. {soft_credits|0|birthdate|m}
  19. {soft_credits|0|birthdate|y}
  20. {soft_credits|0|birthdateISO}
  21. {soft_credits|0|date_added}
  22. {soft_credits|0|date_modified}
  23. {soft_credits|0|deceased}
  24. {soft_credits|0|email|id}
  25. {soft_credits|0|email|address}
  26. {soft_credits|0|email|constituent_id}
  27. {soft_credits|0|email|do_not_email}
  28. {soft_credits|0|email|inactive}
  29. {soft_credits|0|email|primary}
  30. {soft_credits|0|email|type}
  31. {soft_credits|0|first}
  32. {soft_credits|0|fundraiser_status}
  33. {soft_credits|0|gender}
  34. {soft_credits|0|gives_anonymously}
  35. {soft_credits|0|inactive}
  36. {soft_credits|0|last}
  37. {soft_credits|0|lookup_id}
  38. {soft_credits|0|income}
  39. {soft_credits|0|religion}
  40. {soft_credits|0|industry}
  41. {soft_credits|0|matches_gifts}
  42. {soft_credits|0|matching_gift_per_gift_min}
  43. {soft_credits|0|matching_gift_per_gift_max}
  44. {soft_credits|0|matching_gift_total_min}
  45. {soft_credits|0|matching_gift_total_max}
  46. {soft_credits|0|matching_gift_factor}
  47. {soft_credits|0|matching_gift_notes}
  48. {soft_credits|0|name}
  49. {soft_credits|0|num_employees}
  50. {soft_credits|0|is_memorial}
  51. {soft_credits|0|is_solicitor}
  52. {soft_credits|0|no_valid_address}
  53. {soft_credits|0|receipt_type}
  54. {soft_credits|0|target}
  55. {soft_credits|0|requests_no_email}
  56. {soft_credits|0|former_name}
  57. {soft_credits|0|online_presence|id}
  58. {soft_credits|0|online_presence|address}
  59. {soft_credits|0|online_presence|constituent_id}
  60. {soft_credits|0|online_presence|inactive}
  61. {soft_credits|0|online_presence|primary}
  62. {soft_credits|0|online_presence|type}
  63. {soft_credits|0|phone|id}
  64. {soft_credits|0|phone|do_not_call}
  65. {soft_credits|0|phone|inactive}
  66. {soft_credits|0|phone|number}
  67. {soft_credits|0|phone|primary}
  68. {soft_credits|0|phone|type}
  69. {soft_credits|0|preferred_name}
  70. {soft_credits|0|primary_addressee}
  71. {soft_credits|0|primary_salutation}
  72. {soft_credits|0|name_other_name_type}
  73. {soft_credits|0|spouse|first}
  74. {soft_credits|0|spouse|last}
  75. {soft_credits|0|spouse|is_head_of_household}
If you have enabled tribute fields in settings AND NXT is connected as an environment admin (note if multiple tributes exist the fields to access these will be {tribute_2|...} etc.):
  1. {tribute_1|id}
  2. {tribute_1|gift_id}
  3. {tribute_1|tribute_id}
  4. {tribute_1|tribute_type}
  5. {tribute_1|import_id}
  6. {tribute_1|acknowledge}
  7. {tribute_1|sequence}
  8. {tribute_1|tribute_local_type} - if the local tribute type has been overridden this may be different to the tribute_type_name
  9. {tribute_1|tribute_type_id}
  10. {tribute_1|tribute_type_name} i.e. "In Special Recognition of"
  11. {tribute_1|description} i.e. "Francis and Derrick's 25th Anniversary"
  12. {tribute_1|notes} i.e. "Francis and Derrick would like for all donations to be given to Disaster Relief"
  13. {tribute_1|is_active}
  14. {tribute_1|tribute_sequence}
  15. {tribute_1|constituent_record_id}
  16. {tribute_1|constituent_name} i.e. "Sam Smith"
  17. {tribute_1|last_changed_by_id}
  18. {tribute_1|date_added}
  19. {tribute_1|date_changed}
  20. {tribute_1|tribute_import_id}
  21. {tribute_1|added_by_id}
  22. {tribute_1|start_date_iso}
  23. {tribute_1|end_date_iso}
Details on these fields are available here (constituent fields) and here (gift fields),

Primary salutation and addressee

We dynamically calculate these for you so if the record does not have a 'primary salutation' the first name is used as long as it is more than an initial, otherwise the full record name from Raiser's Edge is used. Similarly for 'primary addressee' where, if it is not set, we use the record name from Raiser's Edge. The record name is usually '<Title> <First> <Last>' or '<Org Name>' in Raiser's Edge but a fuller definition is 'If the constituent's type is Individual, this computed field indicates the full name of the constituent based on your organization’s display name settings. If the type is Organization, this is the organization's name.'

Using custom fields in merge fields

For custom fields the category is a 'safe' version of the 'Custom field' category from Raiser's Edge i.e. 'Further Information' would be {custom_further_information}. To create the safe version the category is changed to all lower case and spaces are replaced with underlines.

Conditional merge sections

You can specify sections of a document to only appear based upon conditions. You can use any of the fields in the above list using the format {[field][comparator]"[value]"}...the content...{/[field]} i.e. 
  1. {age>="25"}You are at least 25 years old{/age}.
You can also provide default content for the case where the age sections where not matched
  1. {age="OTHERWISE"}You are under 25 years old{/age}
Operators you can use for these checks are:
  1. Equals: {age="20"} or {first="Fred"} (case insensitive i.e. freD and FrEd are also matches)
  2. Less than: {age<"10"} 
  3. Less than or equal to: {age<="10"}
  4. Greater than: {age>"10"}
  5. Greater than or equal to: {age>="10"} 
  6. Like/Contains: {first~"Fre"} would check for any first values containing  fre (case insensitive)
  7. Blank: {first="BLANK"}
  8. Not blank: {first!="BLANK"}
  9. Otherwise: If none of the previous checks for this field were matched this section will be displayed: {age="OTHERWISE"}
  10. Range: {age<"[40,50]"} would check for age between 40 and 50 inclusive
All sections must end with a marker {/[field]} i.e. {/first} or {/age}.

NOTE: IMPORTANT We strongly suggest that when adding conditional content you first highlight the text involved and click the 'Clear formatting' icon (the T with a small x bottom right). Then apply your tags. From that point when applying formatting to this section of text ensure you don't include any {...} tag. You can change the format within the {...} ... {/...} tags but do not include the {...} in the format change.

Modifiers to reformat fields as they are output

Any merge field value can have it's value modified before it is output. This is achieved by adding ::[format] to the merge field i.e. {amount|value::currency}. The options are:
  1. titlecase
  2. uppercase
  3. lowercase
  4. name: Surname format i.e. McKinsey, Trust etc.
  5. phone: Only allow valid phone numbers
  6. email: Only allow valid email addresses
  7. nospaces: Remove spaces
  8. plaintext: Convert HTML to plain text format
  9. url: Convert entry to an HTML link
  10. dateuk: Format a date in UK format i.e. {today::dateuk} 30/09/2022
  11. dateus: Format a date in US format i.e. {today::dateus} 09/30/2022
  12. datey: Extract the year from the date
  13. dateymd: Format a date format Y-m-d i.e. 2022-09-30
  14. datemd: Output month and date m/d i.e. 09/30
  15. datedm: Output month and date m/d i.e. 30/09
  16. datelong: Format a date in long format i.e. {today::datelong} 30 September 2022
  17. datelongus: Format a date in US long format i.e. {today::datelongus} September 30, 2022
  18. currency: Formats a value as a two digit currency string i.e. {amount|value::currency} 12.34
  19. dollar: Replaces [CURRENCY] with $ (useful for gift summaries i.e. {split_summary::dollar])
  20. pound: Replaces [CURRENCY] with £ (useful for gift summaries i.e. {split_summary::pound])

Gift Aid features (UK only)

Gift aid fields are now supported natively so see above merge fields for details

Special merge fields

  1. {today}: The current date, usually used with a modifier i.e. {today::dateuk} or {today::dateus}
  2. {unique_id}: A unique ID for this letter i.e. 67873458787384787
  3. {random}: A random (unique) ID for this letter (10 characters) i.e. 23jh23dsHJ
  4. {random_long}: A random (unique) ID for this letter (25 characters) i.e. 23jh23dsHJ23jh23dsHJ234d2

    • Related Articles

    • SmartLETTERS: FAQS

      Where can we see a live demonstration of SmartLETTERS and sign up for the Early Access Program? https://www.smartthing.org/smartletters/ How much does SmartLETTERS cost? £600 | $800 US | $1000 CAN per year. When SmartLETTERS goes live, will we be ...
    • SmartLETTERS: Add Gift Aid support

      SmartLETTERS natively supports gift aid now so please refer to the merge field guide for relevant fields.
    • SmartLETTERS set up instructions

      Connect to your Raiser's Edge NXT (ref image below) Optionally connect your Google or Microsoft Account (Connect Office) if you want to import templates from OneDrive or Google Drive and send email via your own account Email ...
    • SmartLETTERS: Demo video and connecting a trial to RENXT

      Demo Video We have produced a comprehensive demo video for SmartLETTERS 2 which you can access via the below link: https://youtu.be/2-I8Fmoujp8 Connecting SmartLETTERS for your trial To activate your trial of SmartLETTERS please: Go to the Blackbaud ...
    • SmartLETTERS: Advanced template editing (headers, footers and page breaks)

      Once a template is in SmartLETTERS it is actually a pure HTML/CSS template with locally stored images. If you have the requisite skills you can edit the raw HTML by editing the template and clicking the 'View' > 'Source code' menu item. There are ...