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.
orders:readGrant 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):
lineororder. - type (string):
percentageorfixed_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 —
manualfor 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
- 200
- 401
- 403
- 404
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not found — no record with the given identifier (or the route does not exist). Verify the ID before retrying.
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.