--- title: "Discount Coupons & Promo Vouchers Documentation" description: "Documentation for Discount Coupons, Promotional Vouchers, and Wallet Credit Grants in Ring2All BSS" --- ## 🎯 User Roles & Key Capabilities | Role | Primary Use Case | Key Capabilities | | :--- | :--- | :--- | | **Customer Account Manager** | Enterprise onboarding & lifecycle management. | Provision customer profiles, assign billing wallets, and configure payment methods. | | **Subscription Specialist** | Tier assignment & plan contracts. | Apply customer tier rules, attach recurring subscriptions, and grant discount coupons. | | **Hardware Inventory Clerk** | Customer CPE & VoIP device logistics. | Allocate SIP hardware to customer accounts and track inventory serial numbers. | --- ## Table of Contents 1. [Module Overview (Technical)](#1-module-overview-technical) 2. [Module Overview (Commercial & Business Value)](#2-module-overview-commercial--business-value) 3. [Visual Interface & Form Structure](#3-visual-interface--form-structure) 4. [Coupon Types & Redemption Mechanics](#4-coupon-types--redemption-mechanics) 5. [Customer Portal Self-Service Redemption](#5-customer-portal-self-service-redemption) 6. [Common Scenarios & Promotional Campaigns](#6-common-scenarios--promotional-campaigns) 7. [Settings Reference](#7-settings-reference) 8. [Model Context Protocol (MCP) AI Integration](#8-model-context-protocol-mcp-ai-integration) 9. [Troubleshooting & FAQs](#9-troubleshooting--faqs) 10. [Glossary](#10-glossary) --- ## 1. Module Overview (Technical) The **Discount Coupons & Promo Vouchers** module (promotional coupons and coupon redemptions store) manages marketing promotional codes, prepaid wallet credit grants, and recurring plan discount vouchers within **Ring2All BSS**. It enforces cryptographic uniqueness, expiration windows, maximum fleet redemption limits, and customer-level isolation to prevent promotional abuse. ### Data Model & Lifecycle Flow ``` β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Discount Coupon Entity (promotional coupons) β”‚ β”‚ β€’ id: bigint (Canonical Invariant Numeric ID) β”‚ β”‚ β€’ code: VARCHAR(50) (e.g. "WELCOME2026", "VOIP-TRIAL-50") β”‚ β”‚ β€’ coupon_type: 'wallet_credit' | 'percentage_discount' | 'fixed_plan' β”‚ β”‚ β€’ credit_amount: NUMERIC(14,4) | discount_pct: NUMERIC(5,2) β”‚ β”‚ β€’ max_redemptions: INTEGER | current_redemptions: INTEGER β”‚ β”‚ β€’ max_per_customer: INTEGER (Enforces single-use per tenant) β”‚ β”‚ β€’ valid_from: TIMESTAMP | valid_until: TIMESTAMP β”‚ β”‚ β€’ is_active: BOOLEAN β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ β–Ό (Self-Service or Admin Apply) β–Ό (Immutable Ledger Record) β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Customer Portal Client β”‚ β”‚ Coupon Redemptions β”‚ β”‚ β€’ User clicks "Redeem Coupon" β”‚ β”‚ β€’ redemption_id: bigint β”‚ β”‚ β€’ Submits code: "WELCOME2026" β”‚ β”‚ β€’ customer_id: 104 β”‚ β”‚ β€’ Instant feedback & confirmationβ”‚ β”‚ β€’ wallet_transaction_id: 8941 β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` * **Atomic Ledger Credit:** When a `wallet_credit` coupon is redeemed, the transaction immediately registers a credited ledger record in transactions store and updates the customer's prepaid balance in wallets store within a single atomic database transaction. * **Anti-Abuse Protections:** Every redemption checks coupon redemptions store against `customer_id` and IP metadata to ensure promotional limits (`max_per_customer`) cannot be bypassed. --- ## 2. Module Overview (Commercial & Business Value) * **Accelerate Customer Acquisition:** Offer instant `$25` or `$50` free trial credit codes that enable prospects to spin up cloud PBX extensions and test carrier voice quality without entering credit card information upfront. * **Customer Retention & Win-Back Campaigns:** Reward long-standing clients or re-engage dormant accounts with targeted percentage discounts on upcoming plan renewals or bulk DID orders. * **Affiliate & Partner Tracking:** Generate unique coupon codes for commercial channel partners, measuring traffic acquisition effectiveness and referral volume directly from the redemption history. --- ## 3. Visual Interface & Form Structure ### Discount Coupons Registry Comprehensive overview of all active, scheduled, and expired promotional campaigns, displaying coupon codes, benefit types, redemption progress bars, and validity dates. ![Discount Coupons Registry](/screenshots/billing/customer-accounts/discount-coupons/discount-coupons-list.png) ### Create / Edit Discount Coupon Form Administrative configuration suite for defining code identifiers, coupon value (wallet credit or percentage discount), redemption limits, allowed service scopes, and validity periods. ![Discount Coupon Configuration Form](/screenshots/billing/customer-accounts/discount-coupons/discount-coupons-form.png) --- ## 4. Coupon Types & Redemption Mechanics Ring2All BSS supports three distinct coupon archetypes: ### 1. Direct Wallet Credit Grant (`wallet_credit`) * **Mechanism:** Injects a fixed monetary sum (e.g. `$25.00`) directly into the customer's prepaid wallet ledger. * **Usage:** Ideal for onboarding vouchers, customer goodwill concessions, and trial top-ups. The funds can be spent across any metered service (calls, DIDs, SMS, or AI tokens). ### 2. Percentage Discount Voucher (`percentage_discount`) * **Mechanism:** Applies a percentage reduction (e.g. `20% off`) to catalog plan purchases or invoice settlements. * **Usage:** Commonly deployed during holiday promotions, annual plan upgrades, or new service launches. ### 3. Product Access Voucher (`fixed_plan`) * **Mechanism:** Grants complimentary or discounted access to a specific subscription plan tier (e.g. 1 month of "Cloud PBX Pro" free). --- ## 5. Customer Portal Self-Service Redemption End users can redeem valid promotional codes independently from the **Ring2All BSS Customer Portal**: 1. Log in to the Customer Portal (`https:///portal` or `/client`). 2. Navigate to the **Wallet & Balances** or **Billing** overview. 3. Click the **Redeem Coupon** button to open the redemption modal. 4. Enter the case-insensitive promo code (e.g., `START2026`) and click **Verify & Apply**. 5. The system validates availability in real time, applies the credit atomically, and displays an animated confirmation showing the updated wallet balance. --- ## 6. Common Scenarios & Promotional Campaigns ### Scenario 1: New Year Telecom Onboarding Campaign * **Code:** `NEWYEAR26` * **Type:** `Wallet Credit ($20.00)` * **Max Fleet Redemptions:** `500` * **Max Per Customer:** `1` * **Validity:** `Jan 1, 2026 - Jan 31, 2026` * **Result:** The first 500 new accounts receive an instant $20 credit upon sign-up. ### Scenario 2: High-Volume DID Migration Concession * **Code:** `MIGRATE-DIDS-50` * **Type:** `Percentage Discount (50% off DID Setup Fees)` * **Target Services:** `Inbound DID Numbers` * **Usage:** Enables sales agents to close large carrier migrations without manual billing invoice overrides. --- ## 7. Settings Reference | Field | Type | Description | Default | | :--- | :--- | :--- | :--- | | **Coupon Code** | String | Alphanumeric promotional code entered by the user (uppercase recommended). | Required | | **Campaign Name** | String | Internal descriptive name for campaign tracking and reporting. | Required | | **Coupon Type** | Enum | Type of benefit: `wallet_credit`, `percentage_discount`, or `fixed_plan`. | `wallet_credit` | | **Credit Amount ($)** | Currency | Monetary sum credited to the wallet when type is `wallet_credit`. | `$0.00` | | **Discount Percentage (%)** | Percentage | Percentage deducted from purchases when type is `percentage_discount`. | `0.00%` | | **Total Redemption Limit** | Number | Maximum total times this coupon can be redeemed platform-wide. | `100` | | **Per-Customer Limit** | Number | Maximum times a single customer account can redeem this coupon. | `1` | | **Valid From** | Datetime | Start timestamp when the coupon becomes active for redemption. | Immediate | | **Valid Until** | Datetime | Expiration timestamp after which redemption attempts are rejected. | Optional | | **Status / Active** | Toggle | Master switch to pause or re-enable the coupon campaign. | `true` | --- ## 8. Model Context Protocol (MCP) AI Integration The **Discount Coupons** module connects directly to the **Ring2All BSS MCP Server**, allowing support agents and automated retention chatbots to evaluate and issue coupons: | MCP Tool Name | Description | Sample Arguments | | :--- | :--- | :--- | | `list_discount_coupons` | Retrieves active promotional campaigns, codes, and remaining redemption quotas. | `{ "status": "active" }` | | `validate_coupon_code` | Checks whether a coupon code is valid, unexpired, and eligible for a specific customer. | `{ "code": "WELCOME26", "customerId": 104 }` | | `redeem_coupon_for_customer` | Executes atomic redemption of a voucher on behalf of an authenticated customer. | `{ "code": "GOODWILL10", "customerId": 104 }` | --- ## 9. Troubleshooting & FAQs * **Why does the portal report "Coupon code is invalid or expired"?** Check that the coupon's `is_active` toggle is enabled, that current system time falls between `valid_from` and `valid_until`, and that `current_redemptions` has not exceeded `max_redemptions`. * **Can a customer redeem the same coupon multiple times?** Only if `max_per_customer` is explicitly set higher than `1`. By default, all promotional coupons restrict redemptions to once per customer. --- ## 10. Glossary * **Wallet Credit:** Real monetary funds added to a customer's prepaid balance that can be spent on telecom services. * **Promo Voucher:** A promotional instrument offering percentage or fixed fee concessions on catalog items. * **Atomic Redemption:** A transactional database operation guaranteeing that credit disbursement and usage logging occur together or fail completely.