SquidSupport
Product reference / Settings

Outbound Templates

In the app: Settings → Outbound

Needs the 'Edit Outbound Templates' permission.

Outbound templates are the emails you send to a list of customers from the Outbound page, for example a notice that an order is ready for pick-up. A template is written once for the organization, with one version per language, and its blanks are filled in per customer from Shopify and from the file you upload. This page is where the templates are made; the sending itself happens on the Outbound page.

Template list

Each template shows its name and a small label for every language it has, or "No variants". Click a template to unfold it: you see its description and its language versions with their subject lines. Clicking a language opens the editor on that language.

The buttons on a template:

  • Activate / Deactivate (the switch): takes effect at once. An inactive template stays in this list but is not offered on the Outbound page. Emails from it that are already waiting to leave are still sent. New templates are active.
  • Edit (pencil): opens the template.
  • Copy template: makes a copy named after the original with "- Copy" added, with its description, default language, all its language versions, required columns, reference sheet lookup, on-success actions, tags and per-store senders. A per-store sender that is no longer a verified address of its store is left out. The copy is active, also when the original is not.
  • Delete (bin): asks for confirmation, then deletes the template with all its language versions and per-store senders. This cannot be undone. Emails that were already sent stay in the Outbound history.

"Create Template" opens an empty template. When there are no templates, the page shows "No templates yet" with "Create a template". A template with no language version says "No language variants yet" and offers "Add the first language"; it cannot be sent until it has at least one.

Opening this page and changing templates needs the 'Edit Outbound Templates' permission. Loading the template list also needs 'View Outbound Templates'. Templates are shared by every store, so a teammate whose account is limited to certain stores cannot create, change, copy or delete a template; they can still set "Sender address per store" for their own stores.

Create or edit a template

"Create Template" opens the "Create Template" dialog; the pencil opens "Edit" followed by the template's name. Nothing is saved until you click "Create Template" or "Save Changes" at the bottom; the one exception is "Sender address per store", which saves each choice at once. Closing with unsaved changes asks "Discard unsaved changes?".

"Name" is required, up to 255 characters. It is what you pick on the Outbound page.

"Description (optional)" is a note for your team on what the template is for, up to 2,000 characters.

"Default Language" is the language version used when a store has no version in its own language. The menu offers the languages the template has a tab for; a new template starts with English. For each customer, Squid uses the version in the main language of the customer's store; if the template has none, it uses the default language. A row for a store with neither is refused.

"Advanced" holds the required columns, the reference sheet lookup, the actions after a send and the tags; "Sender address per store" is a separate fold. Both are described below.

Whatever a template says, emails sent from it follow the sending rules of the Outbound page. Templates whose reference sheet is the organization’s out-of-stock sheet also block repeat notices when an out-of-stock offer exists or an earlier notice is pending or sent outside the current batch. That check has no 60-minute expiry. Rows within one batch still reach the normal duplicate check.

Other sending rules:

  • a single email is scheduled 5 minutes ahead. A bulk batch shares one scheduled time, initially 5 minutes after you start it. A late-starting worker moves an expired time forward, but later rows can have less than 5 minutes left. Cancellation is available before the scheduled time while delivery has not started;
  • within the same store, the same template and uploaded row are blocked for the same order number for 60 minutes after the earlier send was created. Pending and sent emails count; failed and cancelled ones do not;
  • an address with a recorded permanent recipient bounce in this organization during the last 180 days is refused. A policy or content refusal does not count as a bad recipient address;
  • outbound template mail leaves the email provider’s account-level unsubscribe tracking in effect. Whether it adds an unsubscribe link or suppresses an address depends on the provider’s settings and suppression lists; this page does not override them.

Languages and message content

A template has one tab per language. The "+" button ("Add language") adds one: pick a language code from the list or type a code under "Custom..." and click "Add". A code is 2 to 10 characters and can be added once. The cross on a tab removes that language; a language that was saved before or has text asks you to confirm first. The cross refuses to remove the default language until you choose another default. However, clearing that language’s subject or body and saving another complete language can still delete the default version. Choose a complete default before saving, or stores relying on that fallback will be refused. At least one complete language must remain when you save. A warning mark on a tab means that language is missing its subject or its body.

For each language:

  • "Subject": the email's subject line, up to 1,000 characters. It can contain variables.
  • Body: the email itself, written in the editor.
  • "Edit" / "Preview": "Preview" shows the subject and body with example values in place of the built-in variables. The examples are fixed sample text, not data from a store or an order. A reference sheet variable, or a variable Squid does not know, is shown as its name between square brackets. The preview also shows a sample phone number for brand.phone, although Squid never fills that variable in from store data; see "Variables".

At least one language needs both a subject and a body before the template can be saved. A language with only one of the two counts as empty. On saving, a new language you left empty is not saved, and an existing language you emptied is deleted; Squid asks you to confirm both.

Variables

A variable is a placeholder written between double curly brackets that is replaced per customer when the email is sent. Click a variable in the toolbar to insert it into the subject or the body, whichever you last clicked in; the toolbar says which.

Variables filled in from Shopify, looked up by the store code and order number in your upload:

  • Customer: customer.name, customer.email, customer.first_name.
  • Order: order.number, order.status, order.total, order.created_at.
  • Tracking: tracking.number, tracking.carrier, tracking.url.

Variables about the store, under "Store" in the toolbar:

  • brand.name is the store's name in Squid. It is always filled in.
  • brand.website is worked out from the store's own settings: the website address entered in the store's setup, otherwise the store's own email domain (not a free mail domain such as gmail.com), otherwise the store's website address in its AI settings. When the store has none of these, it is not filled in.
  • brand.phone is not filled in automatically, although the toolbar offers it and the list under the editor shows it with a tick. Squid has no phone number for a store, so the variable only has a value when someone supplies one for it by hand. Leave it out of a template, or type the phone number as normal text.

A variable with no value supplied shows its name between square brackets, such as [brand.phone]. A supplied empty value renders as a blank instead. Check the review step on the Outbound page before sending.

Under the editor, "Variables:" lists every variable the subject and body of that language use. A tick means the name is one Squid knows: a built-in variable or a column of the reference sheet. A warning sign means Squid does not know the name, so it is not filled in automatically. The tick only says the name is known, not that every email will have a value for it.

The columns of the reference sheet appear in the toolbar under "Sheet" as extra variables once the lookup is on, a sheet is picked and at least one match rule is complete; until then the toolbar says what is missing. See "Reference sheet lookup". When the same variable gets a value from more than one place, a value typed on the Outbound page wins, then any saved per-store template value, then the reference sheet, then Shopify. For brand.website, a blank final value falls back to the store’s derived website when one is available.

Required columns

"Required columns" lists the columns the uploaded CSV file must have for this template. Two are fixed for every template and cannot be removed: the store code, which decides which store a row belongs to, and the order number, which Squid uses to find the recipient in Shopify.

"Add column" adds your own column: type a name and press Enter. The pencil on a column renames it and the cross removes it. A template can have up to 30 custom required columns, in addition to the two fixed columns. "See an example upload" shows what a matching file looks like.

The Outbound page refuses a file that lacks one of these columns; upper and lower case in the column names do not matter, and extra columns are allowed. Only the store code and the order number must also hold a value in every row: an empty cell in one of your own columns does not by itself refuse the row. It can still prevent a reference-sheet match when that column is used in a match rule.

One optional column is recognised without being listed: sender_email, the address that row is sent from.

  • It overrides every other sender choice for that row: the sender picked on the Outbound page and the template's "Sender address per store".
  • It must be one of the store's verified sending addresses. Upper and lower case do not matter. A row whose value matches none is refused with an error in the review table; it is not sent from another address instead.
  • A row where the column is empty follows the normal sender choice.
  • The column name may be written in any case. It cannot be added as a required column, because it is optional by design.

Reference sheet lookup

"Enable reference sheet lookup" is off by default. When it is on, each uploaded row is looked up in a Google spreadsheet, and the matching sheet row's cells become variables you can use in the message.

It needs Google Sheets to be connected and at least one spreadsheet in Settings → Google Sheets; the section says so when that is missing.

  • "Reference sheet": the spreadsheet and worksheet to look in.
  • "Headers index": the row of the worksheet that holds the column headers, from 1 to 1,000. The default is 1.
  • "Match rules": pairs of an uploaded column and a sheet column that must hold the same value. A sheet row matches when every pair matches. Up to 20 rules. Changing the reference sheet clears these match rules, so set them again for the new sheet. Without a complete match rule, no lookup runs.
  • "Add a matching rule" (optional): send rows to a different sheet depending on a value in the upload, for example one sheet per carrier. Each rule reads "Column … is … then use …". Rows that match no rule use the sheet under "Otherwise use". The match rules are applied by column name, so they work on whichever sheet a row is sent to.

The sheet's columns appear in the variable toolbar under "Sheet". Add "_link" to the end of such a variable to insert the hyperlink behind the cell instead of its text.

How a row is matched when you send:

  • The sheet is read when the upload is reviewed on the Outbound page. It is read again by the background worker after you start the send, once per sheet for that run. Each email is written as the worker processes its row. Sheet edits after that run’s read do not change its messages, but a resumed run reads the sheets again for rows it has not already created.
  • Values are compared as text, ignoring upper and lower case and spaces at the start and end. "DHL " in the upload matches "dhl" in the sheet.
  • An empty value in the upload never matches, not even an empty cell.
  • When several sheet rows match, the first one from the top is used. The search reads a limited number of rows below the headers, 100,000 by default; matches farther down than that limit are missed.
  • With "Add a matching rule", the rules are tried from the top and the first one whose value equals the uploaded value decides the sheet.
  • A row that finds no match, or whose sheet cannot be read, is refused with "No reference sheet match for this row" when the message in that store's language uses a sheet variable. When the message uses no sheet variable, the row is sent without sheet values.

On successful outbound email

"Enable on-success actions" is off by default. When it is on, Squid writes values into a Google spreadsheet each time an email from this template is sent successfully.

When and how the actions run:

  • They are queued after the email provider accepts the email, not when the email is scheduled. An email that fails before that point triggers no actions. This does not confirm arrival in the customer’s inbox; a later bounce does not undo sheet writes. The actions use the template settings saved when this follow-up work runs, so edits after scheduling can affect pending emails. Deleting the template prevents its remaining follow-up work.
  • They run for bulk sends from an uploaded file only. Choosing a different action sheet resets that action’s conditions and values. A named target has its own "Headers index", from 1 to 1,000, defaulting to 1. "Selected reference sheet" uses the reference sheet’s header row and selects the target again from the settings saved when the actions run. A single email sent from the Outbound page has no uploaded row, so its actions are skipped.
  • An action only changes an existing row. It finds the first sheet row, from the top, where every condition matches, and writes the values into that row. The same search limit as reference sheet lookup applies. It never adds a row. When no row matches, the action is skipped.
  • Matching works as in "Reference sheet lookup": case and surrounding spaces are ignored, and an empty uploaded value never matches.
  • When a column to write to does not exist on the sheet, or the sheet cannot be read, that action fails and nothing is written for it. Other actions still run.
  • Once the follow-up result is recorded, later deliveries of the same follow-up job skip it. A failed sheet action is recorded and is not retried automatically; a failure to get the initial database connection can be retried before any changes begin. A failed action does not change the email or its status.

There is one action type, "Update rows on existing sheet". For each action, up to 5:

  • "Sheet": the spreadsheet to write to, or "Selected reference sheet" to write back to the sheet the row was looked up in. If the reference sheet lookup is off or has no sheet, such an action is skipped, and the section warns you.
  • Conditions: pairs of a sheet column and an uploaded column that must match, to find the row to update. Up to 10. An action with no complete condition or no complete value writes nothing.
  • "For the matching line, add": the values to write, each into a sheet column. A value can come from a column of the upload, be text you type ("Enter your own value…"), or be the "Ticket number", the "Ticket URL" or the "Current date (mm/dd/yyyy hh:mm)". Up to 20 values. The ticket number and URL are those of the ticket the email created, and the URL opens that ticket in the Inbox; the date is the moment the action runs, in UTC. An existing value in the cell is overwritten, also when the uploaded column is empty for that row.

Identification tags

"Identification tags" are tags put on the conversation after the outbound email is sent successfully. Squid attempts to add them for single and bulk emails, whether or not on-success actions are enabled. The follow-up uses the tags saved when it runs; deleting the template before then prevents tagging. A tagging failure does not change the email’s sent status. Tags are stored in lower case on the conversation. A new template starts with one tag, "outbound". Use them to find or report on the conversations a template started. Type a tag name to add it, use its pencil to rename it and use the cross to remove it. A template can have up to 20.

Sender address per store

"Sender address per store" decides which address this template sends from, for stores that have more than one sending address. The template has to be saved before you can set it.

Pick a "Store", then choose under "Default sender":

  • "Store primary (default)": the template sends from the store's main address.
  • One of the store's verified addresses: the template sends from that address for this store, unless a row or the person sending picks another; see below.

A store with one sending address has nothing to choose, and a store with no verified address says so. The choice is saved as soon as you make it. Stores with a saved sender choice are listed below the picker, each with "Reset to primary". If a saved address is no longer verified, Squid uses the store’s primary verified address, or its first verified address if there is no primary one. With no usable sending address, the send fails.

This is a default, not a lock. For each email Squid takes the first of these that is set: the row's sender_email column in the upload, the sender picked on the Outbound page for that send, this template's sender for the store, and last the store’s primary verified address or its first verified address when no primary one is available.