Skip to content

Voucher Performance & Popular Voucher Serializers Documentation


1. VoucherPerformanceSerializer

This serializer provides an overview of a voucher’s performance, including redemptions, sales, and discounts.

Fields

  • total_redemptions (Integer): Total number of times the voucher has been redeemed.
  • total_sales (Decimal): Total sales generated from the voucher.
  • total_discount (Decimal): Total discount amount applied using the voucher.
  • net_sales (Decimal): Net sales after applying discounts.
  • unique_customers (Integer): Number of unique customers who have used the voucher.

2. PopularVoucherSerializer

This serializer provides data on the most popular vouchers based on usage and sales.

Fields

  • code (String): The unique voucher code.
  • usage_count (Integer): Total number of times the voucher has been used.
  • total_sales (Decimal): Total sales amount generated using the voucher.
  • discount_amount (Decimal): Total discount value applied through the voucher.

3. MonthlyPerformanceSerializer

This serializer tracks voucher performance metrics on a monthly basis.

Fields

  • month (DateTime): The month for which the data is being reported.
  • redemptions (Integer): Total number of redemptions during the month.
  • total_sales (Decimal): Total sales amount during the month.
  • total_discount (Decimal): Total discount amount applied during the month.
  • net_sales (Decimal): Net sales after deducting discounts.

This document provides an overview of three serializers used to track voucher performance, popular vouchers, and monthly performance insights.