# Trigger order confirmation email with Mautic

**URL:** <https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742>\
**Category:** General Discussion\
**Created:** [January 12, 2021, 5:42am UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742 "2021-01-12T05:42:11Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![mailshark](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mailshark/32/433_2.png) [@mailshark](https://forum.mautic.org/u/mailshark)\
**Post date:** [January 12, 2021, 5:42am UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/1 "2021-01-12T05:42:12Z")

</div>

I’m running an ecommerce store on Wordpress with Woocommerce and recently started using Mautic to handle email automation. I want to use Mautic to send order confirmation emails instead of the standard Woocommerce ones.

I find that Mautic email builder allows for more customisation. However, I am not able to find any resources on the Internet to do this.

Is it possible to use Mautic for sending order confirmation emails and if so, how?

Thanks for your help.

---

<div class="post-metadata">

**Author:** ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)\
**Post date:** [January 13, 2021, 12:29pm UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/2 "2021-01-13T12:29:03Z")

</div>

Hi, before I can answer, could you plz let me know what is the level of your knowledge of PHP, HTML, can you save php files on your server for example?  
OR  
You are looking for an UI where you just fill out 1-2 infos and you are done?  
Thx,  
Joey

---

<div class="post-metadata">

**Author:** ![mikew](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mikew/32/5156_2.png) [@mikew](https://forum.mautic.org/u/mikew)\
**Post date:** [January 13, 2021, 1:42pm UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/3 "2021-01-13T13:42:32Z")

</div>

🙂 Joey - your article on the integration is excellent. You will see I have made some more comments there and I am very keen on getting it working.

To answer @mailshark if you have that knowledge Joey has a great article on his [blog](https://joeykeller.com/process-any-webhook-with-mautic-without-zapier/).

If this is too much for you makewebbetter has paid plugin that will take care of all of it.

---

<div class="post-metadata">

**Author:** ![mailshark](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mailshark/32/433_2.png) [@mailshark](https://forum.mautic.org/u/mailshark)\
**Post date:** [January 14, 2021, 4:01am UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/4 "2021-01-14T04:01:23Z")

</div>

Thanks all for your responses.

@joeyk my level of knowledge for coding is at the basic level whereby I can paste code snippets. I’m open to any solutions you have to present 🙂

@mikew Thanks for the article recommendation. Not sure if the article fits my requirement but I’ll have to process it a bit more. Do you by any chance know the name of the plugin that you mentioned?

---

<div class="post-metadata">

**Author:** ![alderson59](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/alderson59/32/637_2.png) [@alderson59](https://forum.mautic.org/u/alderson59)\
**Post date:** [January 14, 2021, 4:11am UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/5 "2021-01-14T04:11:08Z")

</div>

+1 for this topic! I, too, like OP @mailshark can only administer code, but not really comfortable with touching the actual code itself.

@joeyk, nice blog, I’ll definitely be having a look at it over the weekend.

I have the Woocommerce + Mautic plugin by Makewebbetter, and it’s working well for me with integrating the two pieces of tech together. However, I’m still looking for a way to send order confirmation emails with Mautic.

I’m not sure if there’s a way to get the plugin to trigger an email on a new order, and more importantly, how to get that order info into the new email (such as shipping address, name, order items and qty’s).

Will look at it more soon. Great topic here! Strange this isn’t more common, didn’t see many topics posted before this.

Any more ideas to expand on this?

---

<div class="post-metadata">

**Author:** ![mikew](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mikew/32/5156_2.png) [@mikew](https://forum.mautic.org/u/mikew)\
**Post date:** [January 14, 2021, 3:17pm UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/6 "2021-01-14T15:17:43Z")

</div>

Hi @alderson59

There definetly is a way to do this, a few things to keep in mind:

1. How you are synching the plugin (check your settings)  
and you can get so much information from the plugin fields it creates in Mautic.

Check out this [blog post](https://surge.media/trigger-email-on-new-woocommerce-order/) for the full run down on configuring the order campaign.

---

<div class="post-metadata">

**Author:** ![mailshark](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mailshark/32/433_2.png) [@mailshark](https://forum.mautic.org/u/mailshark)\
**Post date:** [January 15, 2021, 10:39am UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/7 "2021-01-15T10:39:31Z")

</div>

This post is kinda what I was looking for as well. Have tried it but it does not work if there is no condition set right after the contact source as well as if the same customer buys twice.

---

<div class="post-metadata">

**Author:** ![mikew](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mikew/32/5156_2.png) [@mikew](https://forum.mautic.org/u/mikew)\
**Post date:** [January 15, 2021, 11:32am UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/8 "2021-01-15T11:32:47Z")

</div>

Ahh I understand, if someone makes two purchases in the same day ?

So what you could do then is add a tag activity from the plugin to add a tag “purchased-now” for example

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/1/160e5776b9a6c662d9eb769c2eea8c8bee9c65a4.png)

Then at the end of the campaign add an action to remove this tag. Then allow for contacts to re-enter the campaign.

Adjust the segment instead of purchase data to tag equals.

---

<div class="post-metadata">

**Author:** ![alderson59](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/alderson59/32/637_2.png) [@alderson59](https://forum.mautic.org/u/alderson59)\
**Post date:** [January 15, 2021, 12:04pm UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/9 "2021-01-15T12:04:35Z")

</div>

Ah interesting, I am also experimenting with this exact method with the tags, @mikew. Segment that is based on tags, and tags are applied by the plugin for each new order changed to processing status.

So each new purchase will cause the plugin to set a tag on the customer, and send that to Mautic.

Now, this will work as long as the orders are within the same day but ONLY after each cron interval.

So, by default, mautic is set to launch emails every 15 minutes of the hour i.e. 0,15,30,45.

So, if say, a customer makes a repeat purchase after the first one, but before cron completes the Mautic campaign, then you’ll still only get one order confirmation email despite having two orders. This is because you can’t quite add a second tag of the same name and have it run twice for the same customer.

Having too many cron intervals is obviously going to hog resources, and mautic isn’t the snappiest of apps. Even with cron running each quarter hr, I have tested and verified that it will still take up to 10 minutes after the cron trigger to finally receive the email (tested with a local mail server, even - so no long-distance SMTP requests)

This is as far as I have gone. Any further thoughts on this?

---

<div class="post-metadata">

**Author:** ![mikew](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mikew/32/5156_2.png) [@mikew](https://forum.mautic.org/u/mikew)\
**Post date:** [January 15, 2021, 1:42pm UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/10 "2021-01-15T13:42:36Z")

</div>

I hear you. Trickey situation. I am sure there is a way to do this, best would be by using the API but this would require coding on the Wordpress side and triggering a certain mailer once an order is completed. Maybe the guys from MakeWebBetter can better assist here.

Alternative to set a specific segment:update -I [segment id] to run every minute. This would be your purchase now segment and would generally run pretty quick as it will never hold to many contacts, then to have campaign:update -I [campaign id]

However still in extereme cases you are going to miss sales if someone does a purchase one after the other

---

<div class="post-metadata">

**Author:** ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)\
**Post date:** [January 16, 2021, 9:27pm UTC](https://forum.mautic.org/t/trigger-order-confirmation-email-with-mautic/17742/11 "2021-01-16T21:27:10Z")

</div>

Some people do this with Wootic. It is free - wootic works with posting to a form. Since Forms can have immediate send email action, maybe it works out.
