Sell a prepaid pack of yoga sessions with Smart Coupons, then let customers choose their class dates through WooCommerce Bookings. Each generated coupon pays for one class; buying the pack does not reserve any class times.
Scenario
↑ Back to topRiverbend Yoga Class costs $20 per one-hour session. A customer buys ten session coupons at $18 each, paying $180 instead of $200: a 10% discount. They redeem a separate coupon when booking each session. These example prices are in US dollars before tax; use your own currency, class price, schedule, and capacity.
Before you begin
↑ Back to topInstall and activate WooCommerce, WooCommerce Bookings, Smart Coupons, and Min/Max Quantities. In WooCommerce > Settings > General, enable coupon codes. Set your store currency, taxes, and WordPress time zone before testing. Use a test store and your payment gateway’s test mode for the purchase checks below.
Set up the class and coupon pack
↑ Back to topCreate the bookable yoga class
↑ Back to top- Go to Products > Add new product and name the product Riverbend Yoga Class. In Product data, choose Bookable product and select Virtual.
- In General, set Booking duration to Fixed blocks of, 1, Hour(s). Leave Requires confirmation? unchecked so customers can redeem a coupon during the normal checkout. Leave Has persons and Has resources unchecked for this example.
- In Costs, set Base cost to 0 and Block cost to 20, with no extra cost rules.
- In Availability, set Max bookings per block to your class capacity, such as 12. Set All dates are… to not-available by default. Add an Every day (Set time) range from 9 am to 12 pm, Bookable set to Yes, and Priority set to 10. Set First block starts at… to 9 am.
- Select Publish. Open the product and confirm it offers one-hour sessions at 9 am, 10 am, and 11 am on an available future date, each costing $20. Adapt the availability rules to your actual class timetable.
For a different class setup, follow Creating a Bookable Product, then return here to connect the coupons.

Create the coupon template
↑ Back to top- Go to Marketing > Coupons > Add coupon. Enter a template code such as riverbend-yoga-session. Customers will receive generated codes rather than this template code.
- In General, set Discount type to Percentage discount and Coupon amount to 100. Select Auto generate?. Leave Auto apply? unchecked.
- Optionally set Optional coupon code format to a prefix such as yoga-. To expire codes one year after issue, set Expire to 1 and Years; leave the fixed Coupon expiry date empty. Choose and communicate an expiry policy that suits your business.
- In Usage restriction, select only Riverbend Yoga Class under Products. Leave Disable email restriction? unchecked to restrict generated codes to the buyer or chosen recipient’s email. Leave Individual use only unchecked if customers should be able to redeem separate codes for separate sessions in one order.
- In Usage limits, set Usage limit per coupon to 1 and Limit usage to X items to 1. The first makes each code single-use; the second prevents one 100% code from discounting every eligible class in the cart.
- Select Publish.

A coupon discounts an order item, not a person within that item. If you add persons or let customers buy several seats in one booking, retest the discount before selling passes; this example uses one seat per booking item.
Create the ten-session pass product
↑ Back to top- Go to Products > Add new product. Name it Riverbend Yoga Class Pass – 10 Sessions, choose Simple product, and select Virtual.
- In General, set Regular price to 20 and Sale price to 18. These are prices for one coupon, not the whole pack. Ten units cost $180.
- In the same tab, find Quantity rules and set Group of to 10. This allows quantities 10, 20, 30, and so on. To limit each purchase to exactly ten, also set Minimum quantity and Maximum quantity to 10.
- In Coupons, search for and select riverbend-yoga-session. Select Publish. Explain on the product page that customers must purchase ten units for one pass and still need to book their class times.
Min/Max Quantities controls how many coupon units customers buy. It does not count their future bookings or maintain a session balance. The ten generated, single-use codes provide the ten redemptions.
Customer experience
↑ Back to topPurchase the coupons
↑ Back to topCustomers open the pass product, set the quantity to 10, and select Add to cart. Some product layouts start at quantity 1; customers must change it to a valid quantity. Confirm the cart shows ten units at $18 each, totaling $180 before tax, then complete checkout.
Smart Coupons normally generates the ten codes when the purchase order reaches Processing or Completed, rather than merely when checkout starts. Customers receive the codes by email and can find them in their account’s available coupons and the purchase order details. A guest should keep the purchase email. Codes may also appear in supported cart and checkout coupon displays. The recipient should use the same billing email when redeeming them.
Book a class with one coupon
↑ Back to top- Open Riverbend Yoga Class, choose an available date and time, and select Book now. The class initially has its normal $20 price.
- In the cart or checkout, open the coupon entry area, enter one generated code, and select Apply coupon. Confirm a $20 class discount and a $0 class total. Other products, fees, or taxes can still affect the order total.
- Complete checkout using the recipient’s billing email, even when the payable total is zero. Check the order confirmation and booking details for the correct date and time.
- Use a different unused code for the next session. Adding a class to the cart or applying a code alone does not complete a reservation.
Handle cancellations and refunds
↑ Back to topDo not promise that every cancellation or refund automatically returns a coupon. WooCommerce restores a percentage coupon’s recorded usage when its order is cancelled or failed. Refunding an order does not, by itself, reset that usage. Cancelling one booking in a multi-booking order may leave the order active, so the code may remain used.
Check both the booking and its related order, then check the code’s usage under Marketing > Coupons. If your cancellation policy grants another session and the code is still used, issue a replacement single-use code restricted to the class and the same recipient. Confirm any refund separately; a coupon replacement does not refund a payment.
Test before selling passes
↑ Back to top- Try quantity 1 and 11: they should be rejected. Quantity 10 should total $180 before tax. If you set both minimum and maximum to 10, confirm 20 is rejected too.
- Complete a test pass order. Confirm exactly ten different codes are generated, each with a 100% discount, the class restriction, the recipient email, and both limits set to 1.
- Book one class with one code and complete checkout. Confirm the $0 class total, the booking date and time, and that the used code cannot pay for another order.
- Put two separate class bookings in a test cart and apply one unused code: only one class should be discounted. Apply a second code if both classes should be prepaid.
- Test a cancellation and a refund separately, then inspect the order status and coupon usage. Remove test reservations from your schedule when finished.
If the result differs
↑ Back to top- No codes arrive: check that the pass product has the correct coupon selected, Auto generate? is enabled on the template, and the purchase order has reached a qualifying status. Check the generated coupons on the order before issuing replacements to avoid duplicates.
- A code discounts too many classes: confirm Limit usage to X items is 1, as well as the single-use limit. Existing generated coupons need their own correction; changing the template does not rewrite codes already issued.
- The code is rejected: check the class product restriction, billing email, expiry, and recorded usage. Do not apply a session code to the pass product itself.
- The pack total is wrong: check the unit price, cart quantity, tax, and other discounts. Entering 180 as the unit price would charge $1,800 for ten units.
- No class times appear: check the product’s opening rule, advance-booking window, capacity, and store availability. Coupon ownership does not guarantee a seat.
Questions and support
↑ Back to topSomething missing from this documentation? Still have questions and need assistance?
- If you have a question about a specific extension or theme you’d like to purchase, contact us to get answers.
- If you already purchased this product and need some assistance, get in touch with a Happiness Engineer via our support page and select this product’s name from the Product dropdown.