List Promotions

Service Url: POST /promotions/list

Parameters:

None

Request Body:

IPromotionCalculationRequest:

items – List<IPromotionCalculationRequestItem> – a list of items to be requested.

Response Body:

IListPromotionsResponse:

promotions – List<IPromotionDescriptionResponse> – The promotions relevant to the request

IPromotionDescriptionResponse:

promotionKey –

description –

Remarks:

Lists the possible promotions given the list of items and basket details. If the request is empty then all promotions will be returned.

Example Request:

POST: http://localhost:8080/WebRestApi/rest/promotions/list
Content-Type: application/json

{
  "creationDate" : {
    "calendar" : 1521129992000
  },
  "honourDate" : { },
  "currency" : {
    "id" : "GBP"
  },
  "employeeSale" : false,
  "employeeStartingBalance" : 0,
  "fascia" : {
    "id" : ""
  },
  "items" : [ {
    "promotionCalculationRequestProductItem" : {
      "product" : {
        "id" : "DF517XM-1"
      },
      "parentProduct" : {
        "id" : "DF517XM"
      },
      "mmGroup" : {
        "groupHierarchyId" : "FASHION",
        "groupTypeId" : "mmGroup",
        "id" : "MENS_SHIRTS",
        "variantGroupHierarchyId" : "All",
        "variantGroupId" : "UK",
        "variantGroupTypeId" : "region"
      },
      "brand" : {
        "groupHierarchyId" : "FASHION",
        "groupTypeId" : "brand",
        "id" : "INTERNAL",
        "variantGroupHierarchyId" : "All",
        "variantGroupId" : "UK",
        "variantGroupTypeId" : "region"
      },
      "priceType" : {
        "id" : "R"
      },
      "loyaltyPoints" : 0,
      "lineNumber" : 1,
      "quantity" : 1.0,
      "unitValue" : 2595,
      "lineNetValue" : 2595,
      "isReturn" : false,
      "honourPromotionItem" : false,
      "manuallyTargetedPromotionId" : [ ],
      "offerPrice" : 0
    }
  } ],
  "itemQuantity" : 1.0,
  "merchandiseItemQuantity" : 1.0,
  "merchandiseItemValue" : 2595,
  "enableReturns" : false,
  "location" : {
    "id" : "0001"
  },
  "loyaltyPointsBalance" : 0,
  "loyaltyPointsTotal" : 0,
  "loyaltyPointsRate" : 0,
  "loyaltyTransaction" : false,
  "priceGroup" : {
    "@entity" : "core:groupKey",
    "groupHierarchyId" : "ALL",
    "groupTypeId" : "priceGroup",
    "id" : "UK",
    "variantGroupHierarchyId" : "All",
    "variantGroupId" : "All",
    "variantGroupTypeId" : "region"
  },
  "region" : {
    "groupHierarchyId" : "All",
    "groupTypeId" : "region",
    "id" : "UK"
  },
  "total" : 2595,
  "ignoreCrossTransactionLimits" : false
}

Example Response

{
    "promotions": [
        {
            "promotionKey": {
                "promotionId": "C543210",
                "groupKey": {
                    "id": "UK",
                    "groupTypeId": "region",
                    "groupHierarchyId": "All"
                }
            }
        },
        {
            "promotionKey": {
                "promotionId": "Gift Card001",
                "groupKey": {
                    "id": "UK",
                    "groupTypeId": "region",
                    "groupHierarchyId": "All"
                }
            }
        },
        {
            "promotionKey": {
                "promotionId": "VoucherPromo",
                "groupKey": {
                    "id": "All",
                    "groupTypeId": "region",
                    "groupHierarchyId": "All"
                }
            }
        },
        {
            "promotionKey": {
                "promotionId": "GiftVUK Promo",
                "groupKey": {
                    "id": "All",
                    "groupTypeId": "region",
                    "groupHierarchyId": "All"
                }
            }
        },
        {
            "promotionKey": {
                "promotionId": "3",
                "groupKey": {
                    "id": "All",
                    "groupTypeId": "region",
                    "groupHierarchyId": "All"
                }
            }
        },
        {
            "promotionKey": {
                "promotionId": "1",
                "groupKey": {
                    "id": "All",
                    "groupTypeId": "region",
                    "groupHierarchyId": "All"
                }
            }
        }
    ]
}

Go to Top