Add coupon code to order confirmation email for only 1 collection

Topic summary

  • Objective: Add a coupon code or special text to the order confirmation email only when an order includes items from the “Tickets” collection (used for reserving game space).

  • Business rule: The coupon should effectively return the rental fee as store credit, redeemable only on the same day.

  • Proposed approach: A community reply links to guided code that enables conditional messaging in the order confirmation email template, suggesting it’s feasible to display content based on whether a specific collection is present in the order.

  • Key terms: “Order confirmation email template” is the post-purchase email; “conditional messaging” means content appears only when certain criteria (e.g., items from a specific collection) are met; “collection” refers to a grouped set of products.

  • Status: No confirmation of implementation or outcomes yet. An external link with example code is central to proceeding. The discussion remains open, awaiting the requester’s follow-up.

Summarized with AI on February 16. AI used: gpt-5.

I’d like to add a coupon code or even verbiage only to the email confirmation for one collection in our store. Are we able to do that?

For example, my collection is called Tickets. We will add tickets for reserving game space in our store. If someone does this, we want to give them a coupon code redeemable that day (basically giving them back their rental fee in the form of store credit but can only be used that day).

Hey, @RemisAE I’ve come across a similar question in the community before that I would like to refer you to here. It offers some guided code that you can use to create additional, conditional messaging for your order confirmation email template.

Let me know if this helps! If there is anything else I can help you with, please let me know.