2

I've discovered ways to do this with a single email template and lots of logic but I'm considering purchasing Sprout Email cause of all the features we would gain.

Basically: I need to know if/how Sprout Email can help me set up different emails to send to customers based on their purchase. Our store is currently set up so that customers can only purchase 1 item at a time (they are services and not physical products) and want to send very different emails based on which service they purchased. I installed the trial Pro version but I don't see Commerce events in the notifications events dropdown. I see the docs do include commerce events. I'm not sure if I'm missing something, if the solution is to write a custom event plugin, or something else?

2 Answers 2

1

Not a direct answer, but for anyone looking to do this, this can be implemented natively with Craft / Commerce, and with really pretty simple logic, all without a plugin.

For example, you can have a section with the email content for each of your products, plus a commerce products relation field, to choose the product this particular content relates to.

Then your email template logic is really just using the SKU of the product in the order to look up the matching entry in that section, with the relation to the product with the same SKU, and grabbing that content. That would be a couple of lines of logic, so pretty simple really, as far as template logic goes.

Of course a plugin may be easier and have a bunch of other advantages, but the logic for constructing emails based on the products ordered can really end up very simple.

We do this, although often our orders have many products in them, so we have a looped version of this logic. This means we can build really complex emails easily (for example sending product instructions, or warranty notes, or handy links etc) - and still have a great content management experience as all that content lives in a tidy section with the great Craft AX available.

1
  • this is pretty much what I have set up at the moment, minus the email field in the product. If I can't get Sprout Email to do this then I'll definitely take what I have and update it to be closer to what you have. Thanks for the input! Jul 28, 2021 at 16:55
1

For now, for Craft Commerce support you could use Sprout Email's existing features to build and manage emails but you'd need to create a custom Notification Event to use as your trigger for Craft Commerce events.

Our docs have a simple overview of Custom Notification Events and you're welcome to copy our default events as a starting point. If you have specific questions to your scenario, I'm always happy to hop on a call to help you get framed around how the plugin works or arrange a short screen-share/pair-programming if you have any custom development questions.

I do plan to add more Craft Commerce support in Sprout Email at some point but for right now it's a feature request.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.