v1

latestOpenAPI 3.0.12026-07-24501176.6 MB

Update a Loyalty Promotion

Endpoint for PUT /api_gateway/v1/promotions/%7Bpromotion_id%7D

put/v3/promotions/{promotion_id}

Path parameters

promotion_idstring required

Headers

X-CAP-API-AUTH-ORG-IDstring
Example:100232
user-agentstring
Example:pyapps_auto_Promotion_Engine_Eucrm_Smoke
Authorizationstring
Example:Basic bmFtYW5fZGgyMzA3MWJmYjM5OGM5ZmM2YjZlY2I2MmEy

Request body

namestring
orgIdinteger
priorityinteger
activeboolean
messageLabelstring
typestring
createdByinteger
createdOninteger
lastUpdatedByinteger
startDateinteger
endDateinteger
campaignIdinteger
modestring
isStackableboolean

Example request

{
  "name": "CODE_Promotion_Test_17573886",
  "orgId": 100027,
  "active": true,
  "messageLabel": "test!!",
  "type": "CODE",
  "condition": {
    "type": "CART",
    "cartCondition": {
      "kpi": "SUBTOTAL",
      "operator": "EQUALS",
      "value": 250
    }
  },
  "action": {
    "type": "CART_BASED",
    "cartBasedAction": {
      "type": "ABSOLUTE",
      "value": 25
    }
  },
  "createdBy": 70707,
  "lastUpdatedBy": 70707,
  "campaignId": 39077,
  "mode": "DISCOUNT",
  "promotionRestrictions": {
    "Code": [
      {
        "kpi": "REDEMPTION",
        "limit": 1
      }
    ]
  }
}

Response

Created

object required