This documents the v1 product. It is kept for integrations already running
on it. If you are building something new, start with the
Quickstart.
Overview
During a customer call, the voice agent works with two types of discounts: applied discounts, which are already in the cart, and additional discounts, which the agent offers during the conversation. The agent watches how interested the customer is and offers an additional incentive when it needs one to close the sale.Discount Types
Applied Discount
An applied discount is one that’s already active in the customer’s cart when the voice agent call begins. This could be:- A first-time user discount
- A discount from a previous interaction
Additional Discount
An additional discount is one the voice agent offers during the call as an incentive. The agent offers it when:- The customer shows less interest in purchasing
- The customer mentions the price is too high
- The customer has concerns about the product
- The customer explicitly asks for more discount
How It Works
During each call, discounts follow this flow:- Customer Asks About Discounts: When a customer asks about available discounts, the voice agent first mentions any applied discount already in their cart.
- Customer Shows Hesitation: If the customer says they’re not ready to buy (because of the price, concerns about the product, or wanting a better deal), the agent offers the additional discount.
-
Discount Application Logic: The system applies the additional discount based on the
applyAssetting:- additional: The new discount stacks on top of the existing one
- override: The new discount replaces the existing one
-
Webhook Event: After the call ends, the
create-orderwebhook event includes only the additional discount’s details (code and reason). The applied discount is already reflected in the cart.
Discount Configuration
You configure discounts by including adiscount object in your initiate-call API request:
Field Descriptions
code(string): The discount code that will be applied (e.g., “NEW_USER”, “SAVE25”, “FLASH50”)amount(string): The discount value- For percentage discounts (
%tage): A number between 0-100 - For fixed discounts (
fixed): A static amount in your currency
- For percentage discounts (
type(string): The discount type"%tage": Percentage-based discount (e.g., 25% off)"fixed": Fixed amount discount (e.g., ₹500 off)
applyAs(string): How the discount should be applied"additional": Stack this discount on top of any existing applied discount"override": Replace any existing applied discount with this one
The applyAs Logic
TheapplyAs field controls how the two discounts combine.
Additional Mode (applyAs: "additional")
In additional mode, the new discount applies on top of the existing applied discount, so the customer gets both.
Example:
- Product price: ₹1,000
- Applied discount: 10% (₹100 off), so the cart shows ₹900
- Additional discount offered: 25% (₹250 off the original price)
- Final price: ₹650 (both discounts apply: ₹1,000 - ₹100 - ₹250)
Override Mode (applyAs: "override")
In override mode, the new discount replaces the existing applied discount. Only the additional discount applies.
Example:
- Product price: ₹1,000
- Applied discount: 10% (₹100 off), so the cart shows ₹900
- Additional discount offered: 25% (₹250 off the original price)
- Final price: ₹750 (only the 25% discount applies: ₹1,000 - ₹250)
Real-World Scenarios
The voice agent handles each possible discount scenario as follows.Scenario 1: Both Discounts Available (Additional Mode)
Conversation Flow:Customer: “Do you have any discounts?”Result: Both discounts apply. Cart total reflects 10% + 25% = 35% total savings.
Agent: “Yes! You already have a 10% welcome discount applied to your cart with code WELCOME10.” Customer: “Hmm, the price is still a bit high for me.”
Agent: “I understand! Let me offer you an additional 25% discount with code EXTRA25. This will be applied on top of your current 10% discount, giving you even more savings!”
Scenario 2: Both Discounts Available (Override Mode)
Conversation Flow:Customer: “Is there any discount on this?”Result: The 25% discount replaces the 10% discount. Cart updates to reflect only the 25% saving.
Agent: “Absolutely! You currently have a 10% discount applied with code WELCOME10.” Customer: “Can I get a better deal?”
Agent: “I can offer you a special 25% discount with code SPECIAL25. This will replace your current 10% discount, giving you a better overall saving!”
Scenario 3: Only Applied Discount Available
Conversation Flow:Customer: “Are there any discounts?”Result: Only the applied discount is active. No additional discount to offer.
Agent: “Yes! You have a 15% discount already applied to your cart with code SAVE15.” Customer: “Can I get more discount?”
Agent: “I’m sorry, but the 15% discount with code SAVE15 is the best offer available for this product right now. It’s already a great deal!”
Scenario 4: Only Additional Discount Available
Conversation Flow:Customer: “Do you have any offers right now?”Result: The 50% additional discount is applied during the call.
Agent: “Currently, there’s no discount applied to your cart.” Customer: “That’s too expensive. I’m not sure about this.”
Agent: “I completely understand! Let me help you with that. I can offer you an exclusive 50% discount with code FIRST50 to make this purchase more affordable!”
Scenario 5: No Discounts Available
Conversation Flow:Customer: “Is there any discount on this item?”Result: No discounts are available, so the agent talks about the product’s value instead.
Agent: “I’m sorry, but there are no discounts available for this product at the moment. However, it’s a premium quality item that offers great value!” Customer: “Can you give me any discount?”
Agent: “Unfortunately, I don’t have any discount codes to offer right now. But this product is worth the investment for its quality and features!”
Webhook Event Details
After a call, when an order is created, thecreate-order webhook event fires. Its discount information has this structure:
Webhook Payload Structure
Important Notes
Only Additional Discount ReturnedThe webhook payload includes only the additional discount that the voice agent offered during the call. It leaves out the applied discount, which is already reflected in the cart total.
code: The discount code that was offered during the call (only if an additional discount was provided)reason: An optional explanation of why the discount was offered (e.g., “Customer showed hesitation”, “Customer requested better deal”)
Best Practices
Choosing Additional vs Override
-
Use
additionalwhen:- Running promotional campaigns where stacking is expected
- Rewarding loyal customers with extra benefits
- You want the combined savings to stand out to the customer
- Your margins can support stacked discounts
-
Use
overridewhen:- You want to cap the maximum discount
- Protecting profit margins is a priority
- Offering a better single discount is more attractive than stacking
- You want the customer to see one clear discount