First create your coupon and code. Second go to your woocommerce setting > emails > and choose either the 'Processing Order' (its sent before the item has shipped while processing payment) or the "Completed Order' (lets customers know the order has been completed and has started shipping) or customer invoice (manually sent <-- probably the one I would use since it can provide tracking information as well) > click manage >'Email Heading' you can add a line after the default (<-- I would change that to also include available placeholders) > Click save.
Your coupon code will be sent to anyone who has completed payment processing and receive the code along with shipment information and order completion confirmation. That being said, make sure your coupon doesn't have an expire date, or use limit other than on 'user per user'.
That's about the only way I would know how to do it. But in reality its going to depend on really how you have things set up. Are you using SMTP service (ex: pepipost, sendinblue, mailchimp, ect)? If so you will most likely have to edit the templates on those services as well / instead.