Skip to main content

Apply Discount Rate to Lines

POST 

/api/purchase-orders/:purchaseOrder/apply-discount-rate

Apply one discount rate to every line of a purchase order.

Required scope: purchase-orders:write

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

Authentication: Requires Bearer token.

Body:

  • discount (required, numeric, min:0, max:100): Discount percentage (e.g. 2 = 2%)

Lines already at the given rate are left untouched. When the order has already been received, the change is costed the same way editing a single line's price is: one cost change is raised for the whole order and your cost-change policy for PO price edits decides whether it applies immediately or is held as a pending cost change for review. An applied change re-costs every FIFO layer received against the changed lines and trues up the cost of goods sold for units already shipped; under a restate resolution each layer's revaluation is dated at its own receipt, under a going-forward resolution at the day the discount was entered.

Requires permission: purchase_orders.update

Request​

Responses​

OK

Response Headers
    Content-Type