Promotions
promotions in @open-mercato/core
Rule-based promotions engine: condition-benefit trees, promotional codes, and cart effect resolution.
- Built-in
- Marketing & Loyalty
Ships with Open Mercato 0.10.1
Enable it
yarn mercato module enable @open-mercato/core --module promotions
Then run yarn generate. Core is already installed, so nothing is downloaded.
Anatomy
ADDS 9 TABLES · 8 PERMISSIONS · EMITS 14 EVENTS
Data
promotionspromotion_rule_ groups promotion_rules promotion_benefits promotion_codes promotion_generated_ codes promotion_code_ reservations promotion_code_ usages promotion_usages
API
Routes are not listed for built-in modules.
Security
promotions.
viewcreateupdatedeletecodes.manage evaluatecodes.redeem usage.manage
Events
promotions.
- emits
promotion.created - emits
promotion.updated - emits
promotion.deleted - emits
code.created - emits
code.updated - emits
code.deleted - emits
code.used - emits
code.exhausted - emits
generated_code .created - emits
usage.registered - emits
usage.reverted - emits
promotion.budget_ exhausted - emits
promotion.expiring_ soon - emits
evaluation.completed - subscribes
code.created - subscribes
code.deleted - subscribes
code.updated - subscribes
promotion.created - subscribes
promotion.deleted - subscribes
promotion.updated - subscribes
usage.registered - subscribes
usage.reverted
UI
6 backend pages
Background
2 workers
Not present: AI tools.
Not read: credentials and env, hosts (not in module-facts.v2.json).
From module-facts.v2.json in @open-mercato/cli 0.10.1. Read statically, not executed.