You are not logged in.
ListOrderDiscounts
A customer can query available discounts when paying an order on the partner sales platform.
NOTE:
No discount is available to reseller customers.
This API can be invoked only by the customer AK/SK or token.
Name | Type | IN | Mandatory | Description |
---|---|---|---|---|
X-Auth-Token | string | header | Yes | Call with customer token |
order_id | string | query | Yes | Order ID. |
ListOrderDiscounts Responses
Name | Type | Description |
---|---|---|
discounts | Array of DiscountInfoV3 objects | List of available discounts. For details, see Table 2. |
Name | Type | Description |
---|---|---|
discount_id | string | ID of the available order discount. To use a discount, enter the value of this parameter when paying an order. |
discount_value | string | Discount percentage or reduction. Leave this parameter empty if the discount model is set to 1. |
discount_type | integer | Discount type. The options are as follows: 0: promotion discount1: contract discount2: commercial discount3: discount granted by a partner609: discount for adjusting an order price |
orders | Array of OrderV3 objects | List of the orders that can use discounts. For details, see Table 3. |
Name | Type | Description |
---|---|---|
order_id | string | ID of the order that can use discounts. |
order_line_items | Array of OrderLineItemV3 objects | List of the order items that can use the same discount. For details, see Table 4. |
Name | Type | Description |
---|---|---|
order_line_item_ids | Array of strings | List of the IDs of the combined order items that can use the same discount. Order items with the same product, same specifications (for linear products), and same final price (for example, price adjustment for a featured product) will be combined. |
discount_mode | integer | Available discount model of an order. 0: discount1: buy-it-now price2: reduction for specific amount |
discount_amount | number | Discount amount of an order, that is, the deducted amount. |
discount_ratio | number | Discount ratio of an order. |
CBC.0100:parameter error
"GET https://bss-intl.myhuaweicloud.com/v2/orders/customer-orders/order-discounts?order_id=CS2011091132EMKL9"
ListOrderDiscounts Responses
{
"discounts": [
{
"discount_id": "PDP2011260815047721TYT48G0BA02EI",
"discount_value": "0.9",
"discount_type": 0,
"orders": [
{
"order_id": "CS2011091132EMKL9",
"order_line_items": [
{
"order_line_item_ids": [
"CS2011091132EMKL9-000002"
],
"discount_mode": 0,
"discount_amount": null,
"discount_ratio": 0.9
},
{
"order_line_item_ids": [
"CS2011091132EMKL9-000001"
],
"discount_mode": 0,
"discount_amount": null,
"discount_ratio": 0.9
}
]
}
]
}
]
}