# XY discounts

Managing X + Y discounts in the e-shop.

## List of X + Y discounts

 - [GET /api/xy-discounts](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/getlistofxydiscounts.md)

## X + Y discount insertion

 - [POST /api/xy-discounts](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/createxydiscount.md)

## Detail of X + Y discounts

 - [GET /api/xy-discounts/{id}](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/getdetailofxydiscounts.md)

## X + Y discount update

 - [PATCH /api/xy-discounts/{id}](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/updatexydiscount.md)

## Delete of X + Y discount

 - [DELETE /api/xy-discounts/{id}](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/deletexydiscount.md)

## X + Y discounts settings

 - [GET /api/xy-discounts/settings](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/getxydiscountssettings.md): Lists & updates settings of X + Y discounts.
Please note, that enableInCashdesk setting is not supported on HU projects.

## X + Y discount settings update

 - [PATCH /api/xy-discounts/settings](https://api.docs.shoptet.com/shoptet-api/openapi/xy-discounts/updatexydiscountsettings.md): Updates settings for X + Y discounts. All settings are optional, but at
least one should be present.

Please note, that updating "enableInCashdesk" setting on HU projects
will throw an exception.


If you're targeting a discount to a specific category, right now, we
only include products that have

that category as their primary one. If you want to include all products
in that category in the discount,

not just the ones in the primary category, please use
categoryTargeting attribute with all-categories value.

