Apply discountPercent

in Development
Hi,
So I read in another ticket here that discountPercent has been deprecated on Sale level and that you now need to apply discount on sale line level.
How do I apply the discountPercent? Cause i have been unable to get it to work.
I have tried multiple payloads, including this one:
So I read in another ticket here that discountPercent has been deprecated on Sale level and that you now need to apply discount on sale line level.
How do I apply the discountPercent? Cause i have been unable to get it to work.
I have tried multiple payloads, including this one:
{ "completed": false, "referenceNumber": "Test", "referenceNumberSource": "Test API", "taxCategoryID": 0, "employeeID": 1, "shopID": 1, "registerID": 1, "customerID": 10, "SaleLines": { "SaleLine": [ { "itemID": 17, "unitQuantity": 1, "Note": { "note": "Note" }, "Discount": { "discountPercent": "100" } } ] } }
2 comments
You can't apply percentage discounts to line items in exactly the way you are trying to. The discount must already be created and you will then need to reference its ID like this:
Lightspeed HQ