**版本：202607**

# 折扣

配置自动折扣与折扣码形式的促销活动，支持灵活的顾客范围设置

折扣功能让商家配置自动应用或折扣码形式的促销活动，支持灵活的触发条件、优惠类型和 顾客范围设置。

提供自动折扣与非自动折扣的创建和更新、折扣叠加设置管理、折扣列表查询与详情获取， 以及批量取消、重启、删除等操作接口。

- [创建自动折扣](/zh-CN/api/discount-automatic-create) `POST /openapi/2026-07/discounts/automatic`: 创建一个自动应用的折扣活动。

- [创建非自动折扣](/zh-CN/api/discount-non-automatic-create) `POST /openapi/2026-07/discounts/non-automatic`: 创建一个需要使用折扣码的非自动折扣活动。

- [更新自动折扣](/zh-CN/api/discount-automatic-update) `PUT /openapi/2026-07/discounts/automatic/:id`: 通过 ID 更新指定的自动折扣活动。

- [更新非自动折扣](/zh-CN/api/discount-non-automatic-update) `PUT /openapi/2026-07/discounts/non-automatic/:id`: 通过 ID 更新指定的非自动折扣活动。

- [取消折扣](/zh-CN/api/discount-cancel) `POST /openapi/2026-07/discounts/cancel`: 取消一个或多个折扣活动（提前结束）。

- [重启折扣](/zh-CN/api/discount-restart) `POST /openapi/2026-07/discounts/restart`: 重新启动一个已暂停的折扣活动。

- [查询折扣列表](/zh-CN/api/discounts) `GET /openapi/2026-07/discounts`: 根据查询参数返回折扣活动列表。

- [查询折扣详情](/zh-CN/api/discount-detail) `GET /openapi/2026-07/discounts/:id`: 通过 ID 获取折扣活动详情。

- [删除折扣](/zh-CN/api/discount-delete) `DELETE /openapi/2026-07/discounts/:id`: 通过 ID 删除折扣活动，仅进度状态为已完成的折扣可删除。

- [根据折扣码获取折扣](/zh-CN/api/discount-by-code) `GET /openapi/2026-07/discounts/by-code/:discount_code`: 通过折扣码查询对应的折扣活动。

- [更新折扣叠加设置](/zh-CN/api/discount-combine-update) `PUT /openapi/2026-07/discounts/combine`: 更新多个折扣活动的叠加使用配置。

- [批量删除折扣](/zh-CN/api/discount-batch-delete) `POST /openapi/2026-07/discounts/batch-delete`: 通过 ID 批量删除折扣活动，仅进度状态为已完成的折扣可删除。
