Allocation Upload

Functional Area

Allocations

Business Overview

This service provides the ability to create and delete allocations within Allocation Cloud Service.

Service Type

POST

REST URL

/MerchIntegrations/services/alloc/allocations/manage

Roles Allowed

ALLOCATION_APPLICATION_ADMINISTRATOR_JOB, rgbu:merch:system

Request Headers

Accept:  <application/json or application/xml>
Accept-Language: <locale>
Content-Type: <application/json or application/xml>

For Example:

Accept:  application/json
Accept-Language: en-US
Content-Type: application/json

URL Query Parameters

N/A

Input Payload Details

Table 5-2 Create - Object. See list of elements for detail

Entity Element Name Required Data Type Description
collectionSize Yes Integer Collection of allocations.
items action Yes String

Contains the intended action for the allocations. Valid

values are CREATE and DELETE.

items allocationId No Integer Unique identifier related to the allocation to be created/deleted
items allocationRefNo No String External Reference number associated with the allocation being created/deleted
items allocationName No String Name associated with the allocation being created/deleted
items status No String

Valid values (0, 1, 2 and 6) - as per ALC_ALLOC.STATUS.

0 = Worksheet

1 = Submitted

2 = Approved

6 = Reserved

items processStatus No String

Valid values - 1, 4 & 13 (as per ALC_ALLOC.PROCESS_STATUS)

1 = Not Calculated

4 = Calculated

13 = Status Processed

items releaseDate No Date Needs to be specified at the header or at an item/source level; Specified date needs to be either the current date or a future date;
items context No String Context associated with the allocation being created/deleted; Needs to be set up as ‘CNTX’ in CODE_HEAD/CODE_DETAIL in MFCS;
items promotion No Integer Required if the Context is set to 'Promotion', should be an active or future promotion;
items comments No String Comments associated with the allocation being created/deleted
items enforceWhStoreRelInd No String Indicates if WH-Store relationship needs to be enforced; Valid values: "Y", "N"
items updateLocationGroupsInd No String Indicates if location groups present in the allocation need to be updated based on external changes; Valid values: "Y", "N"
items defaultAutoQtyLimitsInd No String Indicates if Auto Quantity Limits need to be defaulted; Valid values: "Y", "N"
items/ itemSources item Yes String Item identifier
items/ itemSources diff1 No String Diff 1 identifier
items/ itemSources diff2 No String Diff 2 identifier
items/ itemSources releaseDate No Date Needs to be specified at the header or at an item/source level; Specified date needs to be either the current date or a future date;
items/ itemSources sourceType Yes Integer

Valid values:

1 = PO

2 = ASN

3 = OH

5 = BOL

6 = TSF

7 = ALLOC

items/ itemSources sourceId No String Identifier related to the specified source type; Not required for WH stock driven allocations;
items/ itemSources wh Yes String Identifier associated with the source warehouse
items/ itemSources holdbackQuantity No Number Holdback Quantity specific to the item-location combination
items/ itemSources calculationMultiple No String Calculation Multiple specific to the item-location combination; Valid values: “IN”, “CA”, “PA”, “EA”
items/ itemSources packRoundingLevel No Number Pack rounding level to be used for the calculation process; Valid values: "0.25", "0.5", "0.75", "1.0"
items/locations groupType Yes String

Needs to be a valid group type

(Reference - ALC_LOC_GROUP_ DETAIL.GROUP_TYPE)

items/locations groupId No String Required for all location groups other than 'All Stores' and 'All Warehouses'
items/locations inLocationDate No Date Needs to be at least one day after the release date, if specified
items/ itemLocations item Yes String Item identifier
items/ itemLocations diff1 No String Diff 1 identifier
items/ itemLocations diff2 No String Diff 2 identifier
items/ itemLocations wh Yes String Needs to match a WH specified in 'Item Sources'
items/ itemLocations sourceType Yes Integer

Valid values:

1 = PO

2 = ASN

3 = OH

5 = BOL

6 = TSF

7 = ALLOC

items/ itemLocations sourceId No String Identifier related to the specified source type; Not required for WH stock driven allocations;
items/ itemLocations location Yes String Needs to be a valid store or WH ID
items/ itemLocations grossNeedQty Yes Number Needs to be a positive value
items/ itemLocations netNeedQty Yes Number Needs to be a positive value
items/ itemLocations allocatedQty Yes Number Needs to be a positive value less than or equal to the available quantity for the specified source ID; must be greater than zero for reserved/approved allocations
items/ itemLocations freezeInd No String Valid values: "Y", "N"
items/rule type Yes String

Valid values -

1 = History

2 = Forecast

3 = Plan

4 = History and Plan

5 = Plan Reproject

6 = Corporate

7 = Manual

8 = Receipt Plan

items/rule level Yes String

Valid values -

1 = Department

2 = Class

3 = Subclass

4 = Style

5 = SKU

6 = Style/Color

7 = UDA

8 = UDA Value

9 = Item List

items/rule regularSalesInd No String Indicates if regular sales need to be considered for History/History and Plan; Valid values: "Y", "N"
items/rule promoSalesInd No String Indicates if promotional sales need to be considered for History/History and Plan; Valid values: "Y", "N"
items/rule clearanceSalesInd No String Indicates if clearance sales need to be considered for History/History and Plan; Valid values: "Y", "N"
items/rule corporateRuleId No Number Required only for allocations using the corporate rule; Needs to be present in the Corporate rules table and will error out if no matching rules found;
items/rule weeksThisYear No Number Number of weeks in the current year
items/rule weeksLastYear No Number Number of weeks in the past year
items/rule startDate1 No Date First ‘Start Date’ for the date range option
items/rule endDate1 No Date First ‘End Date’ for the date range option
items/rule startDate2 No Date Second ‘Start Date’ for the date range option
items/rule endDate2 No Date Second ‘End Date’ for the date range option
items/rule idealWeeksofSupply No Number Needs to be a positive number, must be specified for Rule Type = ‘5’;
items/rule useRuleLevelOnHandInd No String Indicates whether rule level on hand (ROLH) is to be used or not; Valid values: "Y", "N"
items/rule exactInd No String Indicates whether the ‘exact’ mode needs to be used in the allocation or not; Valid values: "Y", "N"
items/rule mode No String

Valid values -

1 = Simple

3 = Pack Distribution (valid only for pack allocations)

4 = Spread Demand (valid only for rule levels 1, 2 and 3)

items/rule netNeedInd No String

Indicates whether ‘net need’ is to be used for the allocation being created

Valid values: "Y", "N", defaulted to “Y” if not specified.

items/rule includeInvInMinInd No String Indicates whether destination inventory needs to be considered for Min NN calculations; Valid values: "Y", "N", defaulted to “N” if not specified.
items/rule includeInvInMaxInd No String Indicates whether destination inventory needs to be considered for Min NN calculations; Valid values: "Y", "N", defaulted to “N” if not specified.
items/rule includeOnHandInd No String Indicates whether destination ‘on hand’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “Y” if not specified.
items/rule includeOnOrderInd No String Indicates whether destination ‘on order’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “Y” if not specified.
items/rule includeInTransitInd No String Indicates whether destination ‘in transit’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “Y” if not specified.
items/rule includeInboundAllocationInd No String Indicates whether destination ‘inbound allocations’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “Y” if not specified.
items/rule includeOutboundAllocationInd No String Indicates whether destination ‘outbound allocations’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “Y” if not specified.
items/rule includeBackorderInd No String Indicates whether destination ‘backorder’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “N” if not specified.
items/rule includeClearanceStockInd No String Indicates whether destination ‘clearance stock’ needs to be considered for inventory calculations; Valid values: "Y", "N", defaulted to “N” if not specified.
items/rule onOrderCommitStartDate No Date Start Date for considering ‘on order’ quantity
items/rule onOrderCommitEndDate No Date End Date for considering ‘on order’ quantity
items/rule onOrderCommitWeeksFromToday No Number WOS value for considering ‘on order’ quantity
items/rule onOrderCommitDate No Date Specific date for considering ‘on order’ quantity
items/rule sizeProfileType No String

Valid values -

PR - Profile Ratio Logic;

PO - Profile Ratio Optimal Logic;

SO - Selling Curve Optimal Logic;

items/rule limitSkuOverage No String Limit SKU overage value
items/rule sizeProfileWhAvailPctInd No String

Specific to Fashion Allocations;

Defaulted to 'N' if not specified

items/rule sizeProfileDefaultHierInd No String

Specific to Fashion Allocations;

Defaulted to 'N' if not specified

items/ quantityLimits location Yes String Location identifier
items/ quantityLimits dept No String Department identifier; Required if the values are to be setup at Department, Class or Subclass levels
items/ quantityLimits class No String Class identifier; Required if the values are to be setup at Class or Subclass levels
items/ quantityLimits subclass No String Required if the values are to be setup at the Subclass level
items/ quantityLimits item No String Item identifier
items/ quantityLimits diff1 No String Diff 1 identifier
items/ quantityLimits minNetNeed No Number Minimum Net Need QL value; Needs to be a positive value
items/ quantityLimits maxNetNeed No Number Maximum Net Need QL value; Needs to be a positive value
items/ quantityLimits threshold No Number Threshold QL value; Needs to be a positive value
items/ quantityLimits trend No Number Trend QL value; Can be a positive or negative value
items/ quantityLimits weeksOfSupply No Number Weeks of Supply (WOS) QL value; Needs to be a positive value
items/ quantityLimits minGrossNeed No Number Minimum Gross Need QL value; Needs to be a positive value
items/ quantityLimits minPack No Number Represents Minimum Pack QL value; Needs to be a positive value; Applicable only to packs;
items/ quantityLimits maxPack No Number Represents Maximum Pack QL value; Needs to be a positive value greater than the Minimum Pack QL value; Applicable only to packs;
{
  "collectionSize": 1,
  "items": [
    {
      "action": "CREATE",
      "allocationId": 1000,
      "allocationRefNo": "REF-01",
      "allocationName": "Spring Season Allocation",
      "status": "0",
      "processStatus": "4",
      "releaseDate": "2025-10-28",
      "context": "String",
      "promotion": 799212,
      "comments": "Allocation for Spring Season",
      "enforceWhStoreRelInd": "N",
      "updateLocationGroupsInd": "N",
      "defaultAutoQtyLimitsInd": "N",
      "itemSources": [
        {
          "item": "YT-STYLE2",
          "diff1": "YTYEL",
          "diff2": "String",
          "releaseDate": "2025-10-28",
          "sourceType": "3",
          "sourceId": "String",
          "wh": "1812",
          "holdbackQuantity": 0,
          "calculationMultiple": "EA",
          "packRoundingLevel": 0.5
        }
      ],
      "locations": [
        {
          "groupType": "7",
          "groupId": "676767",
          "inLocationDate": "2025-10-28"
        }
      ],
      "itemLocations": [
        {
          "item": "YT-STYLE2",
          "diff1": "YTYEL",
          "diff2": "String",
          "wh": "1812",
          "sourceType": 3,
          "sourceId": "String",
          "location": "676767",
          "grossNeedQty": 100,
          "netNeedQty": 10,
          "allocatedQty": 15,
          "freezeInd": "N"
        }
      ],
      "rule": {
        "type": "1",
        "level": "5",
        "regularSalesInd": "N",
        "promoSalesInd": "N",
        "clearanceSalesInd": "N",
        "corporateRuleId": 128032,
        "weeksThisYear": -1,
        "weeksLastYear": -1,
        "startDate1": "2025-10-28",
        "endDate1": "2025-10-28",
        "startDate2": "2025-10-28",
        "endDate2": "2025-10-28",
        "idealWeeksofSupply": 75,
        "useRuleLevelOnHandInd": "N",
        "exactInd": "Y",
        "mode": "1",
        "netNeedInd": "N",
        "includeInvInMinInd": "N",
        "includeInvInMaxInd": "N",
        "includeOnHandInd": "Y",
        "includeOnOrderInd": "N",
        "includeInTransitInd": "N",
        "includeInboundAllocationInd": "N",
        "includeOutboundAllocationInd": "N",
        "includeBackorderInd": "N",
        "includeClearanceStockInd": "N",
        "onOrderCommitStartDate": "2025-10-28",
        "onOrderCommitEndDate": "2025-10-28",
        "onOrderCommitWeeksFromToday": 41,
        "onOrderCommitDate": "2025-10-28",
        "sizeProfileType": "PR",
        "limitSkuOverage": 100,
        "sizeProfileWhAvailPctInd": "N",
        "sizeProfileDefaultHierInd": "N"
      },
      "quantityLimits": [
        {
          "location": "676767",
          "dept": "5144",
          "class": "5212",
          "subclass": "5237",
          "item": "YT-STYLE2",
          "diff1": "YT-YEL",
          "minNetNeed": 10,
          "maxNetNeed": 20,
          "threshold": 15,
          "trend": 11,
          "weeksOfSupply": 11,
          "minGrossNeed": 10,
          "minPack": 10,
          "maxPack": 84
        }
      ]
    }
  ]
}

Response Code: 200 (Success)

Sample Response Message

{
  "items": [
    {
      "allocationId": 1000,
      "allocationRefNo": "REF-01",
      "allocationName": "Spring Season Allocation"
    }
  ]
}

Response Code: 400 (Error)

In case of error, the following standard error response will be returned. The element validationErrors will be present when input payload or input parameters do not match the schema definition for this service.

Sample Error Message

{
  "status": "ERROR",
  "message": "Error found in validation of input payload",
  "validationErrors": [
    {
      "error": "must be one of 'Y', 'N'",
      "field": "createRecord.arg0.approveInd",
      "inputValue": "X"
    }
  ],
  "businessError": [
    {
      "allocationRefNo": "String",
      "allocationName": "String",
      "errors": [
        {
          "error": "String",
          "field": "String",
          "inputValue": "String"
        }
      ]
    }
  ]
}