Read this yet?
This article is part of a series helping users get started with the Template Workflows we have included in Automation. To use a Template, visit here and select a Workflow to edit and apply to your orders!
The Workflow helps you to automatically send an Email Invoice to your Customer.
Firstly, we check if the Finalized Order has yet to be Invoiced and if so it must also have a positive Order Total value. Then, we can send the email using {{order.email}} to send to the default email address for the Customer Relationship.
We suggest you use the Email Template settings in your account to create a Sales Invoice Template with all the attributes you want to be displayed.
Then, that can be selected in the Workflow creation. In our Template example, we have included some simple parameters that you might wish to show.
Here are the code blocks ready to copy and paste for the example above
To
"{{order.email}}"
Subject
"Your Sales Order Invoice #{{order.order_number}}"
Body
"Hi {{order.contact.first_name | default: 'there' }},\n\nThank you for your recent order.\nSales Order #{{order.order_number}}\nInvoice total: {{order.total}}\n{% if due_at %}Please make your payment by the due date {{due_at | date: '%d %b %Y' }}{% endif %}{% if order.reference_number %} and include this reference number {{order.reference_number}} in any deposits for our records{% endif %}\n\nIf you have any questions, please feel free to reply to this email.\n\nThank you for your business."
Enjoy exploring our Commerce Automation 🤖