B2B Edition allows you to automatically send email notifications to buyers after certain actions, such as Company account approval or the creation of an invoice. Emails settings in the B2B Edition control panel include templates for buyer-facing emails, and allow you to customize the text and code to suit your store and brand.
Do your templates look different? We recently updated B2B Edition’s Emails settings to offer more customization. See Transactional Email Templates in B2B Edition to learn more about using the new experience.
Requirements
Your B2B Edition user account must have the following permissions enabled to edit email templates:
- View Settings
- Update Settings
To edit the New invoice, Invoice reminder, and Invoice past due templates, your user account must also have the following invoice permissions enabled:
- View Settings
- Update Settings
Available Templates
The following email templates can be customized in the B2B Edition control panel:
- New company created — sent to the Company admin user when a new company account is created
- New user created — sent to a new user that has been added to a Company account
- New company rejected — sent to the Company admin user when their Company account application is rejected
- New super admin created — sent to a new user that has been assigned as a Super Admin
- Shopping list approval request — sent to Company users with approval permissions when a buyer submits a Shopping List for approval
- Shopping list status updated — sent to the Shopping List creator when an approver approves or rejects their pending Shopping List
- Quote reminder — sent at preset intervals to the contact email in a quote to inform them of the quote’s expiration date
- New invoice — sent to the buyer who placed an order when an invoice is created for that order
- Invoice reminder — sent at preset intervals to the buyer who placed the original order to inform them of the invoice’s expiration date
- Invoice past due — sent at preset intervals to the buyer who placed the original order after an invoice has expired
- New quote (merchant email) — sent to specified B2B Edition users when a buyer requests a quote from the storefront
Managing Email Templates
B2B email templates are located in Settings › Emails in the B2B Edition control panel. Each template is given a label so that you can confirm at a glance if it is currently enabled or disabled. All email templates are enabled by default.
Using the drop-down list at the top of the page, you can select whether you want to view the default global templates or specific templates for each storefront provisioned in B2B Edition. You can also select the global or storefront-specific version of a template while editing it.
Click a template’s name to edit its phrases or code. You can also Enable or Disable a template from its Action menu in the template list or at the top of the page while editing the template. If you use a third-party email integration, you may want to disable the built-in email templates to prevent your buyers from receiving duplicate emails.
While editing the global version of a template, you can select Reset to system defaults from the Action menu to restore the template’s original phrases and code.
Once a global template has been reset, it is not possible to recover any previous customizations. We recommend copying your template code and saving it in a plain text editor before resetting it to default values.
Storefront-specific templates cannot be reset to their default values. Instead, you can check the box next to Use global to send the global template in its place.
Template-Specific Settings
Some settings are only available in specific email templates, and allow you to make additional configurations to their behavior. These settings are accessed by clicking the template name, or by selecting Edit from the Action menu. Note that template-specific settings apply to all storefronts and cannot be configured on the storefront level.
The Quote reminder and Invoice reminder templates include a Retry Days Before Expiration Date setting, which indicates how many days in advance that a buyer should be notified about the impending expiration of their quote or invoice. Enter a whole number to specify the number of days before the expiration date when the email is triggered. You can enter multiple numbers, separated by commas, to send the email multiple times before the expiration date.
In the Invoice past due template, use the Retry Days After Due Date field to specify when to notify buyers of an overdue invoice. Enter multiple numbers separated by commas to configure multiple sending intervals.
To designate a member of your staff to receive the New quote notification, enter their email address in the Define the email of the recipient field. Click +Add additional email to enter multiple recipient addresses.
Editing Template Phrases
The Phrases tab of the template edit page is where you can add and edit the text used in the email. Each phrase consists of a Phrase name which is used as an internal identifier in the template’s code, and a Phrase value which is the text that appears in the email itself.
Edit an existing phrase’s name or value by entering new text in the corresponding fields, or remove a phrase from the template by selecting Delete from its Action menu. Note that editing or deleting a Phrase name identifier will not change or remove it from the template’s code; you must make corresponding adjustments in the Code tab.
To create a custom phrase in your template, click + Add New and enter the new name and value in the resulting fields. As with editing or deleting an existing phrase, you must enter the Phrase name in the template code for the text to appear in the email.
The Phrase value field supports the use of HTML and template variables. For example, you can create a phrase with a name of "contact" and a value like "Need help? Contact {store}’s Support team at <a href="mailto:support@mystore.com">support@mystore.com</a>." to provide your buyers with a clickable email link. By using the store.name variable, you can add the same phrase to multiple storefronts without having to adjust the text.
Editing Template Code
In the Code tab, you can edit the HTML and CSS content of your email template, as well as create a custom subject line. The Subject field can have a maximum of 255 characters; however, you can use phrase names and variables to include additional content and insert buyer-specific information.
For example, you can personalize the Shopping list status updated template with a subject of "{{submitter.name}}, {{{ lang 'subject' }}}". This includes the name of the Shopping List creator in the subject, and allows you to insert a custom phrase value.
Editing code? We recommend saving a backup copy of your template in a plain text editor such as Notepad or TextEdit. You can also restore the default version of an email's global template if needed.
The body of the template is customized by editing its underlying HTML and Handlebars code. It is divided between CSS styling at the top and HTML content at the bottom. We recommend making edits by copying the template code into a text editor and pasting the edited version back into the Content box.
Following the example in the previous section, you can add your custom phrase name to the bottom of the template. To do this, locate the <!-- prevent Gmail on iOS font size manipulation --> HTML comment and add paragraph tags above it. In the paragraph tags, add the phrase bracket in the format of {{{ lang 'contact' store=store.name }}}. You can then assign a class to the paragraph and style it in the CSS section of the template.
To learn more about how you can customize your email code, see Email Templates Code Examples in the Dev Center. While this covers email templates in BigCommerce and references variables that may not be present in B2B Edition templates, the HTML customizations can be applied to both sets of templates.
Previewing Template Customizations
The Preview tab provides you with an example of how your template customizations will appear before saving your changes. Click the desktop or mobile icon to see how the email is formatted in different devices.
If you want to view how the template will appear in your inbox, click Send test email. The resulting email is delivered to your user account email address.
The template preview and test email use placeholder values to fill in buyer-specific variables, such as their email address or Company name. Similarly, any links in the preview direct to your storefront URL instead of the corresponding area of the Company’s Buyer Portal.
If you need to adjust any of your customizations, return to the Phrases and Code tabs. When you’re ready to apply the updated template to live emails, Save your changes.
Available Template Variables
Each email template has a set of available variables that are used to insert store, Company, and buyer-specific information. Some variables, such as store.name and user.email, can be used in multiple templates. See the table below to learn more about each variable and their supported templates.
Variable | Corresponds to: | Output example | Supported Templates |
---|---|---|---|
store.name | your store's name | “Thank you for creating a business account with My BC Store” | All templates |
store.login_url | the storefront’s login page | “Log into your business account at https://mybcstore.com/login.php” |
|
company.name | the recipient’s Company name | “Marie Curie from Client Corporation would like you to join their My BC Store Business Account.“ |
|
user.email | the recipient’s email address | "Email Address: john.s@example.com" |
|
password.reset_url | a link for the recipient to reset their Company account password | This URL is generated uniquely in each email |
|
newuser.email | the email address associated with the new user account | “Here is your account email address: john.s@example.com” |
|
inviter.name | the name of the Company user that created the new user account | “Marie Curie from Client Corporation would like you to join their My BC Store Business Account.“ |
|
inviter.email | the email address of the Company user that created the new user account | “m.curie@clientcorporation.com from Client Corporation would like you to join their My BC Store Business Account.“ |
|
user.name | the recipient’s first name | “Hi Marie,” |
|
submitter.name | the name of the Junior Buyer user that submitted the Shopping List | “Marie Curie has submitted a new shopping list for Client Corporation” |
|
submitter.email | the email address of the Junior Buyer user that submitted the Shopping List | “m.curie@clientcorporation.com has submitted a new shopping list for Client Corporation” |
|
shopping_list.name | the name of the Shopping List awaiting approval | “This shopping list, called Weekly Inventory, will be on hold until you or another admin has approved it for processing.” |
|
shopping_list.url | the URL of the Shopping List in the Buyer Portal | “https://mybcstore.com/account.php?action=order_status#/shoppingList/12345” |
|
approver.name | the name of the Company user that approved or rejected the Shopping List | “Marie Curie has updated the status of your shopping list at My BC Store” |
|
approver.email | the email address of the Company user that approved or rejected the Shopping List | “For more information on your shopping list’s status, contact m.curie@clientcorporation.com“ |
|
quote.number | the quote’s ID | “Quote QN000001 expires in 7 days” |
|
quote.title | the title given to the quote | “Quote Machining Tool Bulk Purchase expires in 7 days” |
|
quote.amount | the title given to the quote | “Quote QN000001 for $30, issued on 02.15.2024, will expire in 7 days” |
|
quote.expired_at | the quote’s expiration date | “Quote QN000001 will expire in 7 days on 02.22.2024” |
|
quote.created_at | the date the quote was created on | “Quote QN000001 for $30, issued on 02.15.2024, will expire in 7 days” |
|
quote.details_url | the URL of the quote in the Buyer Portal | “https://mybcstore.com/account.php?action=order_status#/quoteDetail/12345” |
|
quote.contact.name | the Contact Name entered in the quote | “Hi Marie Curie,” |
|
quote.contact.email | the Contact Email entered in the quote | "Email Address: john.s@example.com" |
|
quote.reminder_days | the number of days before the quote expires | “Quote QN000001 for $30, issued on 02.15.2024, will expire in 7 days” |
|
order.number | the ID of the order associated with the invoice | “Order number: 123” |
|
invoice.number | the invoice’s ID | “Invoice number: 00000005” |
|
invoice.currency | the currency used for the order associated with the invoice | “You have a new invoice for USD$200” |
|
invoice.total | the total value of the invoice | “You have a new invoice for USD$200” |
|
invoice_amount.due | the outstanding value of the invoice | “Please pay the remaining value of $200 before the invoice expires on 02.22.2024” |
|
invoice.date | the date the invoice was created | “This invoice, issued on 02.15.2024, expires in 7 days.” |
|
invoice.details_url | the invoice’s PDF URL in the Buyer Portal | Each invoice PDF has a unique URL |
|
invoice.contact.email | the email address of the buyer associated with the invoice | Email Address: john.s@example.com" |
|
invoice.due_date | the invoice’s due date | “Please pay the remaining value of $200 before the invoice expires on 02.22.2024” |
|
invoice.reminder_days | the number of days before the invoice is due | “This invoice, issued on 02.15.2024, expires in 7 days.” |
|
invoice.past_days | the number of days that have passed since the invoice’s due date | “This email is to notify you that invoice 00000005 is 5 days past due.” |
|
FAQ
Can I customize the email sent when creating or updating a quote in the B2B Edition control panel?
You can select a preconfigured template and enter a personalized subject line while submitting quotes to buyers, but it is not possible to edit the phrases or code of the quote templates.
Can I specify the sending email address for B2B Edition emails?
By default, emails in B2B Edition are sent from noreply@bundleb2b.com. If you are using a third-party email service, you can assign a different sending email address by connecting an external SMTP server in your General settings. Note that this sending address is only used for emails with customizable templates, not for system-generated emails like the new user invitation.
Why are my emails showing raw HTML instead of the phrases or variables I added to the template?
A custom variable or phrase added to the Code section of your email template can appear as raw HTML if it is contained within two curly brackets instead of three. For example, {{ lang 'yourcustomphrase' }} will display as raw HTML, but {{{ lang 'yourcustomphrase' }}} will properly display your custom phrase.