Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Discountify Laravel Package

safemood/discountify

Laravel package for dynamic, condition-based discounts. Define custom conditions, apply percentage discounts, set global discount and tax rate, support coupon and class-based discounts, dynamic item field names, optional condition skipping, and event tracking for e-commerce totals.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Dynamic Pricing & Promotions: Enables flexible discount strategies (e.g., seasonal sales, bulk purchases, loyalty rewards) without hardcoding logic, reducing backend complexity.
  • A/B Testing & Personalization: Supports conditional discounts (e.g., user segments, cart contents) to test pricing strategies or tailor offers (e.g., "10% off for returning users").
  • Coupon System: Builds a scalable coupon engine for marketing campaigns (e.g., time-limited, user-restricted, or usage-limited codes) without reinventing the wheel.
  • Tax & Global Discounts: Simplifies compliance (e.g., VAT, regional taxes) and enterprise-wide discounts (e.g., corporate contracts) via configurable tax rates and global discounts.
  • Event-Driven Analytics: Tracks discount applications (e.g., DiscountAppliedEvent) to power dashboards, fraud detection, or customer insights (e.g., "Top 10% of users redeemed this coupon").
  • Roadmap Prioritization:
    • Short-term: Quick wins like seasonal promotions or loyalty discounts.
    • Long-term: Foundation for a full pricing engine (e.g., tiered pricing, subscription discounts).
  • Build vs. Buy: Avoids custom development for discount logic, reducing technical debt and accelerating feature delivery.

When to Consider This Package

  • Adopt if:

    • Your Laravel app needs flexible, rule-based discounts (e.g., e-commerce, SaaS, marketplaces).
    • You require coupon management (e.g., time-limited, user-specific, or usage-restricted codes).
    • Your team lacks bandwidth to build a scalable discount system from scratch.
    • You need auditability (e.g., tracking which discounts applied to which users).
    • Your pricing logic is dynamic (e.g., depends on cart contents, user attributes, or external conditions like dates).
  • Look elsewhere if:

    • You’re using a non-Laravel stack (e.g., Django, Node.js).
    • Your discounts are static (e.g., fixed percentage off all products) and don’t require conditions.
    • You need advanced features like dynamic pricing algorithms (e.g., surge pricing) or multi-currency support (not natively included).
    • Your team prefers low-code/no-code tools (e.g., Shopify’s native discount system) over PHP-based solutions.
    • You require real-time validation (e.g., discounts applied at checkout must sync with inventory systems).

How to Pitch It (Stakeholders)

For Executives:

"Discountify lets us run targeted promotions—like seasonal sales, bulk discounts, or loyalty rewards—without custom development. It’s like having a plug-and-play coupon engine that integrates seamlessly with our Laravel stack. For example, we could offer a ‘10% off for users with 5+ items’ or a ‘Black Friday 20% off’ coupon with expiry dates, all managed via code. This reduces backend work, speeds up marketing campaigns, and gives us data on which discounts drive the most revenue. The MIT license means no hidden costs, and the package is actively maintained."

For Engineering:

*"This package replaces ad-hoc discount logic scattered across our codebase with a centralized, configurable system. Key benefits:

  • Dynamic conditions: Define discounts based on cart contents, user roles, dates, etc., using closures or class-based conditions.
  • Coupon types: Time-limited, single-use, user-restricted, or usage-limited coupons—all managed via a clean API.
  • Tax & global discounts: Handle VAT or enterprise-wide discounts without manual calculations.
  • Event tracking: Fire events when discounts apply (e.g., trigger analytics or notifications).
  • Performance: Optimized for Laravel, with minimal overhead. Example:
    Discountify::setItems($cart)
        ->applyCoupon('SUMMER20')
        ->total(); // Returns discounted total + breakdown
    

Tradeoff: We’d need to standardize on Laravel, but the payoff is cleaner code, faster iteration, and fewer bugs in discount logic. The package is battle-tested (234 stars, active maintenance) and MIT-licensed."*

For Product/Marketing:

*"This tool lets us test and deploy promotions faster. For example:

  • A/B test discounts: ‘15% off for users who clicked this ad’ vs. ‘10% off for first-time buyers’.
  • Seasonal campaigns: Auto-apply ‘Holiday20%’ coupons between Nov 1–Dec 31.
  • Loyalty tiers: ‘VIP users get 20% off’ without manual checks.
  • Data insights: Track which discounts convert best (via events). No more waiting for dev cycles—just define the rules in code or config."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
jayeshmepani/jpl-moshier-ephemeris-php
elnasnato/laraliveui
labrodev/rest-sdk
sampaui/sampaui
babelqueue/php-sdk
facebook/capi-param-builder-php
babelqueue/symfony
hamzi/corewatch
minionfactory/raw-hydrator
hexters/coinpayment
rjcodes/rjcms
act-training/laravel-permissions-manager
alimarchal/laravel-chart-of-accounts
babenkoivan/elastic-scout-driver
mkwebdesign/filament-watchdog-v5
renatomarinho/laravel-page-speed
zedmagdy/filament-business-hours
renatovdemoura/blade-elements-ui
devgeek/beacon-admin
benjamin-rqt/data-watcher-bundle