Discount code refunds are a great way to retain your customers by incentivising them to continue shopping for your products. When a customer requests credit for their return you have the option to automatically create a discount code for the order amount and email it to the customer.
Note: You will need the Gold plan for this feature.
To activate this feature you will need to have 'Refund within the app' setting ticked in the Setup section.
Customer requests credit for their refund via the return portal.
You will then Mark as received when the item has been received back
If you now click 'Refund' - the green button below
Select the items or quantity to refund
Select credit amount
Popup requests you confirm
Discount code for the value set is automatically created and emailed to your customer
See discounts in the discount area of Shopify Admin