Skip to main content

List Sales Order Discounts

GET 

/api/sales-orders/:salesOrder/discounts

Lists every discount applied to a sales order, ordered by sequence (the order in which discounts are applied). Includes line-level discounts — tied to a product line via sales_order_line_id, or to a charge line such as shipping via financial_line_id — and order-level discounts.

Required scope: orders:read

Grant this scope to your token under Settings → Developer → Personal Access Tokens.

Authentication: Requires Bearer token.

Response fields (per discount):

  • id (integer): Discount ID.
  • sales_order_id (integer): Owning sales order.
  • sales_order_line_id (integer|null): Product line the discount applies to (line scope).
  • financial_line_id (integer|null): Charge line (e.g. shipping) the discount applies to (line scope).
  • scope (string): line or order.
  • type (string): percentage or fixed_amount.
  • rate (number|null): Percentage rate (0-100) for percentage discounts; null for fixed amounts.
  • amount (number): Discount total in the order currency. For percentage discounts this is the computed amount.
  • name (string): Display label.
  • source_type (string): Where the discount came from — manual for user-entered discounts, or a sales-channel identifier for imported ones.
  • source_id (integer|null), source_reference (string|null): External identifiers, e.g. a coupon code.
  • channel_discount_type (string|null), allocation_method (string|null), target_type (string|null): Raw sales-channel discount metadata, set only on imported discounts.
  • apply_before_tax (boolean): Whether the discount is applied before tax is calculated.
  • sequence (integer): Application order — lower values apply first.

Path parameters:

  • salesOrder (required): Sales order ID.

Request

Responses

OK

Response Headers
    Content-Type