Discounts (1.0)
Download OpenAPI specification:Download
License: Nexway License Version 1.0
Api to manage discounts
Response samples
- 200
- 201
- 401
- 403
- 404
- 500
Content type
application/json
Example
{- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "startDate": "2019-08-24T14:15:22Z",
- "endDate": "2019-08-24T14:15:22Z",
- "catalogId": "string",
- "storeIds": [
- "string"
], - "productIds": [
- "string"
], - "parentProductIds": [
- "string"
], - "publisherRefIds": [
- "string"
], - "sources": [
- "PURCHASE"
], - "subscriptionId": "string",
- "dynamicVariables": {
- "property1": { },
- "property2": { }
}, - "discountRate": 0,
- "amountByCurrency": {
- "property1": 0.1,
- "property2": 0.1
}, - "applyOnNetPrice": false,
- "externalContext": "string",
- "name": "string",
- "localizedLabels": {
- "property1": "string",
- "property2": "string"
}, - "model": "COUPON",
- "countries": [
- "string"
], - "status": "ENABLED",
- "maxUsages": 0,
- "level": "PRODUCT",
- "thresholds": {
- "property1": 0.1,
- "property2": 0.1
}, - "endUserEmails": [
- "string"
], - "endUserTypes": [
- "string"
], - "endUserGroupIds": [
- "string"
], - "buyerBehaviorTriggers": [
- "RETAIN_BUYER"
], - "used": 0,
- "generated": 0,
- "cumulative": true,
- "weight": 100,
- "maxUsePerStore": 1,
- "maxUsePerEndUser": 1,
- "codes": {
- "property1": { },
- "property2": { }
}
}
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
{- "id": "string",
- "storeId": "string",
- "customerId": "string",
- "locale": "string",
- "products": [
- {
- "id": "string",
- "customerId": "string",
- "fullPrice": {
- "vatAmount": 0.1,
- "netPrice": 0.1,
- "vatRate": 0.1,
- "grossPrice": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "discounted": true
}, - "unitPrice": {
- "vatAmount": 0.1,
- "netPrice": 0.1,
- "vatRate": 0.1,
- "grossPrice": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "discounted": true
}, - "price": {
- "vatAmount": 0.1,
- "netPrice": 0.1,
- "vatRate": 0.1,
- "grossPrice": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "discounted": true
}, - "variantOf": "string",
- "publisherRefId": "string",
- "quantity": 0.1,
- "discountsStatus": [
- {
- "discount": "string",
- "status": "APPLIED",
- "discountLabel": "string"
}
], - "forcedBy": "string",
- "crossSellBy": "string",
- "upSellBy": "string",
- "priceFunctionParametersValues": {
- "property1": { },
- "property2": { }
}
}
], - "endUser": {
- "id": "string",
- "locale": "string",
- "country": "string",
- "type": "string",
- "groupId": "string",
- "email": "string"
}, - "totalAmount": 0.1,
- "vouchersTotalAmount": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discounts": [
- "string"
], - "discountsStatus": [
- {
- "discount": "string",
- "status": "APPLIED",
- "discountLabel": "string"
}
], - "buyerBehavior": {
- "retainBuyer": true,
- "abandonedCart": true,
- "renewal": true
}, - "catalogId": "string",
- "source": "PURCHASE",
- "price": {
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "netPrice": 0.1,
- "grossPrice": 0.1,
- "vatIncluded": true,
- "vatRate": 0.1,
- "vatAmount": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "initialGrossPrice": 0.1,
- "initialNetPrice": 0.1,
- "initialVatAmount": 0.1
}, - "vouchers": [
- {
- "id": "string",
- "code": "string",
- "amount": 0.1,
- "localizedLabel": "string",
- "status": "APPLIED",
- "discountExternalContext": "string"
}
], - "subscriptionId": "string"
}
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
{- "id": "string",
- "storeId": "string",
- "customerId": "string",
- "locale": "string",
- "products": [
- {
- "id": "string",
- "customerId": "string",
- "fullPrice": {
- "vatAmount": 0.1,
- "netPrice": 0.1,
- "vatRate": 0.1,
- "grossPrice": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "discounted": true
}, - "unitPrice": {
- "vatAmount": 0.1,
- "netPrice": 0.1,
- "vatRate": 0.1,
- "grossPrice": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "discounted": true
}, - "price": {
- "vatAmount": 0.1,
- "netPrice": 0.1,
- "vatRate": 0.1,
- "grossPrice": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "discounted": true
}, - "variantOf": "string",
- "publisherRefId": "string",
- "quantity": 0.1,
- "discountsStatus": [
- {
- "discount": "string",
- "status": "APPLIED",
- "discountLabel": "string"
}
], - "forcedBy": "string",
- "crossSellBy": "string",
- "upSellBy": "string",
- "priceFunctionParametersValues": {
- "property1": { },
- "property2": { }
}
}
], - "endUser": {
- "id": "string",
- "locale": "string",
- "country": "string",
- "type": "string",
- "groupId": "string",
- "email": "string"
}, - "totalAmount": 0.1,
- "vouchersTotalAmount": 0.1,
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "discounts": [
- "string"
], - "discountsStatus": [
- {
- "discount": "string",
- "status": "APPLIED",
- "discountLabel": "string"
}
], - "buyerBehavior": {
- "retainBuyer": true,
- "abandonedCart": true,
- "renewal": true
}, - "catalogId": "string",
- "source": "PURCHASE",
- "price": {
- "currency": {
- "currencyCode": "string",
- "defaultFractionDigits": 0,
- "numericCode": 0,
- "displayName": "string",
- "symbol": "string",
- "numericCodeAsString": "string"
}, - "netPrice": 0.1,
- "grossPrice": 0.1,
- "vatIncluded": true,
- "vatRate": 0.1,
- "vatAmount": 0.1,
- "vatAmountMsrp": 0.1,
- "netMsrp": 0.1,
- "grossMsrp": 0.1,
- "discountedPrice": {
- "discountedNetPrice": 0.1,
- "discountedGrossPrice": 0.1,
- "discountRate": 0.1,
- "netPriceDiscountAmount": 0.1,
- "grossPriceDiscountAmount": 0.1,
- "vatDiscountAmount": 0.1,
- "signedDiscount": "string",
- "discountCode": "string",
- "discountId": "string",
- "discountLabel": "string",
- "discountExternalContext": "string"
}, - "initialGrossPrice": 0.1,
- "initialNetPrice": 0.1,
- "initialVatAmount": 0.1
}, - "vouchers": [
- {
- "id": "string",
- "code": "string",
- "amount": 0.1,
- "localizedLabel": "string",
- "status": "APPLIED",
- "discountExternalContext": "string"
}
], - "subscriptionId": "string"
}
Get items
Authorizations:
Bearer
query Parameters
target required | string Return selected fields only (multiple occurrences allowed for selecting multiple fields) |
customerId | string Customer Id |
storeIds | string Stores discount can be applied to |
productIds | string Products to which discount is restricted |
parentProductIds | string Products to which discount is restricted |
name | string Name of discount |
startDate | string Discount start date |
endDate | string Discount end date |
level | string Enum: "PRODUCT" "FORCED_CROSS_SELL" "CROSS_SELL" "UP_SELL" "CART" Level of product discount applies |
model | string Enum: "CAMPAIGN" "COUPON" "SINGLE_USE_CODE" Model type of discount |
Responses
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
{- "items": [
- {
- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "startDate": "2019-08-24T14:15:22Z",
- "endDate": "2019-08-24T14:15:22Z",
- "catalogId": "string",
- "storeIds": [
- "string"
], - "productIds": [
- "string"
], - "parentProductIds": [
- "string"
], - "publisherRefIds": [
- "string"
], - "sources": [
- "PURCHASE"
], - "subscriptionId": "string",
- "dynamicVariables": {
- "property1": { },
- "property2": { }
}, - "discountRate": 0,
- "amountByCurrency": {
- "property1": 0.1,
- "property2": 0.1
}, - "applyOnNetPrice": false,
- "externalContext": "string",
- "name": "string",
- "localizedLabels": {
- "property1": "string",
- "property2": "string"
}, - "model": "CAMPAIGN",
- "countries": [
- "string"
], - "status": "ENABLED",
- "maxUsages": 0,
- "level": "PRODUCT",
- "thresholds": {
- "property1": 0.1,
- "property2": 0.1
}, - "endUserEmails": [
- "string"
], - "endUserTypes": [
- "string"
], - "endUserGroupIds": [
- "string"
], - "buyerBehaviorTriggers": [
- "RETAIN_BUYER"
], - "used": 0,
- "generated": 0,
- "cumulative": true,
- "weight": 100,
- "maxUsePerStore": 1,
- "maxUsePerEndUser": 1,
- "codes": {
- "property1": { },
- "property2": { }
}
}
], - "last": true,
- "totalItems": 0,
- "totalPages": 0,
- "size": 0,
- "number": 0
}
Response samples
- 201
- 401
- 403
- 404
- 500
Content type
application/json
Example
{- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "startDate": "2019-08-24T14:15:22Z",
- "endDate": "2019-08-24T14:15:22Z",
- "catalogId": "string",
- "storeIds": [
- "string"
], - "productIds": [
- "string"
], - "parentProductIds": [
- "string"
], - "publisherRefIds": [
- "string"
], - "sources": [
- "PURCHASE"
], - "subscriptionId": "string",
- "dynamicVariables": {
- "property1": { },
- "property2": { }
}, - "discountRate": 0,
- "amountByCurrency": {
- "property1": 0.1,
- "property2": 0.1
}, - "applyOnNetPrice": false,
- "externalContext": "string",
- "name": "string",
- "localizedLabels": {
- "property1": "string",
- "property2": "string"
}, - "model": "COUPON",
- "countries": [
- "string"
], - "status": "ENABLED",
- "maxUsages": 0,
- "level": "PRODUCT",
- "thresholds": {
- "property1": 0.1,
- "property2": 0.1
}, - "endUserEmails": [
- "string"
], - "endUserTypes": [
- "string"
], - "endUserGroupIds": [
- "string"
], - "buyerBehaviorTriggers": [
- "RETAIN_BUYER"
], - "used": 0,
- "generated": 0,
- "cumulative": true,
- "weight": 100,
- "maxUsePerStore": 1,
- "maxUsePerEndUser": 1,
- "codes": {
- "property1": { },
- "property2": { }
}
}
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
Example
{- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "startDate": "2019-08-24T14:15:22Z",
- "endDate": "2019-08-24T14:15:22Z",
- "catalogId": "string",
- "storeIds": [
- "string"
], - "productIds": [
- "string"
], - "parentProductIds": [
- "string"
], - "publisherRefIds": [
- "string"
], - "sources": [
- "PURCHASE"
], - "subscriptionId": "string",
- "dynamicVariables": {
- "property1": { },
- "property2": { }
}, - "discountRate": 0,
- "amountByCurrency": {
- "property1": 0.1,
- "property2": 0.1
}, - "applyOnNetPrice": false,
- "externalContext": "string",
- "name": "string",
- "localizedLabels": {
- "property1": "string",
- "property2": "string"
}, - "model": "COUPON",
- "countries": [
- "string"
], - "status": "ENABLED",
- "maxUsages": 0,
- "level": "PRODUCT",
- "thresholds": {
- "property1": 0.1,
- "property2": 0.1
}, - "endUserEmails": [
- "string"
], - "endUserTypes": [
- "string"
], - "endUserGroupIds": [
- "string"
], - "buyerBehaviorTriggers": [
- "RETAIN_BUYER"
], - "used": 0,
- "generated": 0,
- "cumulative": true,
- "weight": 100,
- "maxUsePerStore": 1,
- "maxUsePerEndUser": 1,
- "codes": {
- "property1": { },
- "property2": { }
}
}
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
Example
{- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "startDate": "2019-08-24T14:15:22Z",
- "endDate": "2019-08-24T14:15:22Z",
- "catalogId": "string",
- "storeIds": [
- "string"
], - "productIds": [
- "string"
], - "parentProductIds": [
- "string"
], - "publisherRefIds": [
- "string"
], - "sources": [
- "PURCHASE"
], - "subscriptionId": "string",
- "dynamicVariables": {
- "property1": { },
- "property2": { }
}, - "discountRate": 0,
- "amountByCurrency": {
- "property1": 0.1,
- "property2": 0.1
}, - "applyOnNetPrice": false,
- "externalContext": "string",
- "name": "string",
- "localizedLabels": {
- "property1": "string",
- "property2": "string"
}, - "model": "COUPON",
- "countries": [
- "string"
], - "status": "ENABLED",
- "maxUsages": 0,
- "level": "PRODUCT",
- "thresholds": {
- "property1": 0.1,
- "property2": 0.1
}, - "endUserEmails": [
- "string"
], - "endUserTypes": [
- "string"
], - "endUserGroupIds": [
- "string"
], - "buyerBehaviorTriggers": [
- "RETAIN_BUYER"
], - "used": 0,
- "generated": 0,
- "cumulative": true,
- "weight": 100,
- "maxUsePerStore": 1,
- "maxUsePerEndUser": 1,
- "codes": {
- "property1": { },
- "property2": { }
}
}
Get items
Authorizations:
Bearer
query Parameters
orderId | string Order Id discount applied to |
customerId | string Customer Id discount applied to |
storeId | string Store Id discount applied to |
discountId | string Discount Id |
discountCode | string Discount Code |
endUserEmail | string Email used |
endUserId | string EndUser Id |
catalogId | string Catalog Id |
target | string Return selected fields only (multiple occurrences allowed for selecting multiple fields) |
Responses
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
{- "items": [
- {
- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "discountId": "string",
- "discountCode": "string",
- "orderId": "string",
- "storeId": "string",
- "endUserEmail": "string",
- "useDate": "2019-08-24T14:15:22Z",
- "used": true
}
], - "last": true,
- "totalItems": 0,
- "totalPages": 0,
- "size": 0,
- "number": 0
}
Response samples
- 200
- 401
- 403
- 404
- 500
Content type
application/json
{- "id": "string",
- "customerId": "string",
- "enduserId": "string",
- "createDate": "2019-08-24T14:15:22Z",
- "updateDate": "2019-08-24T14:15:22Z",
- "modelVersion": "string",
- "dbVersion": 0,
- "lastUpdateReason": "string",
- "discountId": "string",
- "discountCode": "string",
- "orderId": "string",
- "storeId": "string",
- "endUserEmail": "string",
- "useDate": "2019-08-24T14:15:22Z",
- "used": true
}