Skip to main content
Discounts are managed at one of two scopes:
  • A location discount belongs to one restaurant.
  • An organization discount is a template assigned to one or more locations.
A location list returns both kinds so you can inspect the offers that are effective for that restaurant. Organization-managed entries are read-only on location mutation endpoints; update their template or location mapping through the organization routes.

Endpoints

Location discounts
Organization templates
Organization location mappings
Writes require discounts.write; reads require discounts.read. Organization API keys may act on child locations. A location-scoped key cannot act on organization routes.

Create a location discount

Use public product and bundle IDs from the location’s active Catalog API resource. Chataigne never accepts or returns private SKU or database IDs here.
Date boundaries are inclusive calendar dates evaluated in the location timezone. minimum_order.amount uses whole major currency units; fixed discount amounts support two decimals. PATCH uses merge semantics: omitted fields stay unchanged; explicit null clears nullable fields such as description, image_url, dates, and minimum_order. The benefit type is immutable. To change from a percentage to a free product, create a new discount and deactivate the old one with PATCH { "enabled": false }.

Benefit types

required_items are eligibility conditions; they do not limit a percentage or fixed amount to those line items.

Organization mappings

Product IDs may differ between restaurant catalogs. Product-based organization discounts therefore carry reward and eligibility item mappings on each location assignment.
PUT replaces both mapping arrays for that location. The response reports mapping_status:
  • ready: every required binding resolves against the active catalog;
  • unresolved: at least one item is missing or belongs to another catalog;
  • ambiguous: a stable reference matches more than one catalog item.
Non-ready discounts remain visible to management clients but fail closed during ordering. Organization fixed amounts and minimum-order thresholds require all active target locations to use one currency. A mixed-currency target set returns discount_target_currency_mismatch; per-location monetary overrides are not part of V1.

Deactivation and history

Public API V1 does not expose destructive discount deletion. Deactivate a location discount or organization template with PATCH { "enabled": false }; it remains available for history and can be re-enabled with PATCH { "enabled": true } unless an internal lifecycle operation has already retired it after completed-order use. Existing retired location mappings remain readable with status=retired.