Cart discounts

add discount

Добавление скидки, выбираемой из списка
request
PUT /api/v2/carts/04e7a998-4100-43c4-8d8d-fb148c3fdbbb/discounts/1000000008 HTTP/1.1
Content-Type: application/x-www-form-urlencoded
Table 83. /api/v2/carts/{cartUuid}/discounts/{discountId}
Parameter Description

cartUuid

UUID корзины

discountId

Id скидки

response
HTTP/1.1 200 OK

add extra discount

Добавление доп. скидки (указывается сумма)
request
PUT /api/v2/carts/84640bb4-9bd6-4b4a-bc8f-c506391008fc/discounts/extra HTTP/1.1

{
  "sum" : 750.0
}
Table 84. /api/v2/carts/{cartUuid}/discounts/extra
Parameter Description

cartUuid

UUID корзины

response
HTTP/1.1 200 OK

delete extra discount

Удаление дополнительной скидки с корзины
request
DELETE /api/v2/carts/84640bb4-9bd6-4b4a-bc8f-c506391008fc/discounts/extra HTTP/1.1
Table 85. /api/v2/carts/{cartUuid}/discounts/extra
Parameter Description

cartUuid

UUID корзины

response
HTTP/1.1 200 OK

delete item discount

Удаление скидки на одну(!) позицию
request
DELETE /api/v2/carts/819ae777-171d-4a7a-9798-e5eb41cb4084/discounts/items?cartItemIds=1000012250,1000012252 HTTP/1.1
Table 86. /api/v2/carts/{cartUuid}/discounts/items
Parameter Description

cartUuid

UUID корзины

Parameter Description

cartItemIds

Id элементов корзины

response
HTTP/1.1 200 OK