Overview


This method allows you to obtain a list of dates when a product will be available on e-commerce for a given customer.

Request

https://api.kometsales.com/api/ecommerce/inventory-available-dates.list

  • Method: GET
  • Content-Type: URL Params.

Headers

  • X-SALES-CHANNEL (optional) (string: 20): Valid values: "WEB_APP", "MOBILE_APP", "K2K", "ECOMMERCE_LITE". 
  • X-ACCOUNT (required)(integer:20): Company ID that is using the API. Please ask Komet Sales team to have this ID. 
  • authenticationToken (required)(string:50): Komet Sales security token.

Input parameters:

  • customerId (required)(integer:20): customer ID, used to search orders from only one customer. You can obtain this value from the customer.list API method.
  • inventoryLineIds (required)(string): the IDs of the inventory lines.
  • inventoryOrigin (required)(integer:1):  the inventory type. 1=OM (Open Market), 2=FS (Future Sales), 3=VA (Vendor Availability), 4=K2K (Komet to Komet).
  • companyLocationId (integer:20): Required if the company is in Multi Location mode. You can obtain this value from the location.list API method.

 

Sample
https://api.kometsales.com/api/ecommerce/inventory-available-dates.list?customerId=7349&inventoryLineIds=428720&inventoryOrigin=4&companyLocationId=13 -H authenticationToken=token_info_goes_here
 

Response

Output:

    • message (String): description of the transaction status.
    • status (integer:1): transaction status. 1 for success or 0 for failure.
    • availableDates (Array): array of dates when the product will be available.
    • availableDateFrom (date) (date format YYYY-MM-DD).
    • availableDateTo (date) (date format YYYY-MM-DD).

Sample
{  
   "message":"OK",
   "availableDateFrom":"2017-06-29",
   "availableDateTo":"2017-07-09",
   "status":1,
   "availableDates":[  
      "2017-06-29",
      "2017-06-30",
      "2017-07-01",
      "2017-07-02",
      "2017-07-03",
      "2017-07-04",
      "2017-07-06",
      "2017-07-07",
      "2017-07-09"
   ]
}