Skip to main content

Create Supplier Pricing Tier

POST 

/api/supplier-pricing-tiers

Creates a new supplier pricing tier.

Authentication: Requires Bearer token.

Validation:

  • name (required, max:255, unique in supplier_pricing_tiers)
  • currency_code (required, exists:currencies,code)
  • pricing_type (required, in:absolute,relative; defaults to 'absolute' if omitted)
  • base_pricing_tier_id (required_if:pricing_type,relative; nullable, integer, exists:supplier_pricing_tiers)
  • adjustment_percentage (required_if:pricing_type,relative; nullable, numeric, between:-99.9999,999.9999)
  • adjustment_fixed_amount (nullable, numeric, between:-999999.9999,999999.9999)
  • rounding_value (nullable, numeric, gt:0, max:999999.9999)

Business rules:

  • Relative tiers inherit the currency of their root absolute tier
  • Circular references are rejected
  • A tier cannot reference itself as the base tier

Request

Responses

Successful response