AdjustLocationNumberOfItems

This function allows you to adjust the number of items in stock for an article on a certain location.

Tags: AdjustLocationNumberOfItems, AdjustLocationNumberOfItemsOperation, InventoryAdjustmentCause_AdjustLocation, ByUser, AdjustLocationNumberOfItemsHandling, ArticleItemStatus_AdjustLocationNumberOfItems, AdjustLocationNumberOfItemsResponse, AdjustLocationNumberOfItemsResult, AdjustLocationNumberOfItemsError

Request XML

POST /xxx/Automation.asmx HTTP/1.1
Host: api.ongoingsystems.se
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://ongoingsystems.se/Automation/AdjustLocationNumberOfItems"

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <AdjustLocationNumberOfItems xmlns="http://ongoingsystems.se/Automation">
      <UserName>string</UserName>
      <Password>string</Password>
      <Operation>
        <InventoryNumber>string</InventoryNumber>
        <ArticleDefId>int</ArticleDefId>
        <Location>string</Location>
        <TransactionNumberOfItems>decimal</TransactionNumberOfItems>
        <Batch>string</Batch>
        <ExpiryDate>dateTime</ExpiryDate>
        <InventoryAdjustmentCause>
          <Code>string</Code>
        </InventoryAdjustmentCause>
        <Comment>string</Comment>
        <OriginalArticleItemId>int</OriginalArticleItemId>
        <AdjustedByUser>
          <UserName>string</UserName>
        </AdjustedByUser>
        <Handling>
          <AllowDeAllocationOfOrders>boolean</AllowDeAllocationOfOrders>
        </Handling>
        <ArticleItemStatus>
          <ArticleItemStatusId>int</ArticleItemStatusId>
        </ArticleItemStatus>
      </Operation>
    </AdjustLocationNumberOfItems>
  </soap:Body>
</soap:Envelope>

Request specification

AdjustLocationNumberOfItems
UserName string(50) Req. Your username
Password string(50) Req. Your password
Operation AdjustLocationNumberOfItemsOperation Req. The operation object
AdjustLocationNumberOfItemsOperation
InventoryNumber string(50) Custom identifier for this adjustment.
ArticleDefId int Req. The article id of the article for which to adjust stock balance.
Location string(50) Req. The location to adjust stock balance on.
TransactionNumberOfItems decimal Req. How much to adjust the stock balance. A negative value will decrease the stock balance and a positive value will increase it.
Batch string(50) Filter by batch. The adjustment will be made for this batch.
ExpiryDate dateTime Filter by expiry date. The adjustment will be made for this expiry date.
InventoryAdjustmentCause InventoryAdjustmentCause_AdjustLocation Adjustment cause.
Comment string Transaction comment.
OriginalArticleItemId int Filter by OriginalArticleItemId.
AdjustedByUser ByUser An element of type ByUser. Designates which user did the adjustment.
Handling AdjustLocationNumberOfItemsHandling An object of type AdjustLocationNumberOfItemsHandling. Allows you to customize how you want to Ongoing WMS to handle your request.
ArticleItemStatus ArticleItemStatus_AdjustLocationNumberOfItems Filter by article item status. The adjustment will be made for this article item status.
InventoryAdjustmentCause_AdjustLocation
Code string Adjustment cause code.
ByUser
UserName string(50) Req. The name of the user. Must be an actual user in Ongoing WMS. Will be set as the user that performed the packing.
AdjustLocationNumberOfItemsHandling
AllowDeAllocationOfOrders boolean If the location contains items which are allocated, is Ongoing WMS allowed to deallocate them? This may be necessary in order to fulfil the API call. Default: false
ArticleItemStatus_AdjustLocationNumberOfItems
ArticleItemStatusId int The id of the article item status that you want to filter for

Response XML

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <AdjustLocationNumberOfItemsResponse xmlns="http://ongoingsystems.se/Automation">
      <AdjustLocationNumberOfItemsResult>
        <AdjustLocationNumberOfItemsErrors>
          <AdjustLocationNumberOfItemsError>
            <Message>string</Message>
            <ErrorType>UnknownError or LogonError or LocationNotFound or InventoryNumberAlreadyExists or BelowZeroTransaction or ArticleNotFound or ErrorSavingInventory or ActiveCountInventoryExists or LockedGoods or TransactionRowAlreadyExists or GoodsOwnerIsDeleted or InventoryAdjustmentCauseNotFound</ErrorType>
          </AdjustLocationNumberOfItemsError>
          <AdjustLocationNumberOfItemsError>
            <Message>string</Message>
            <ErrorType>UnknownError or LogonError or LocationNotFound or InventoryNumberAlreadyExists or BelowZeroTransaction or ArticleNotFound or ErrorSavingInventory or ActiveCountInventoryExists or LockedGoods or TransactionRowAlreadyExists or GoodsOwnerIsDeleted or InventoryAdjustmentCauseNotFound</ErrorType>
          </AdjustLocationNumberOfItemsError>
        </AdjustLocationNumberOfItemsErrors>
        <Success>boolean</Success>
      </AdjustLocationNumberOfItemsResult>
    </AdjustLocationNumberOfItemsResponse>
  </soap:Body>
</soap:Envelope>

Response specification

AdjustLocationNumberOfItemsResponse
AdjustLocationNumberOfItemsResult AdjustLocationNumberOfItemsResult
AdjustLocationNumberOfItemsResult
AdjustLocationNumberOfItemsErrors AdjustLocationNumberOfItemsError[] A list of AdjustLocationNumberOfItemsError objects
Success boolean True if successful, false otherwise.
AdjustLocationNumberOfItemsError
Message string Message explaining the error.
ErrorType enum The type of error:
- UnknownError
- LogonError
- LocationNotFound
- InventoryNumberAlreadyExists
- BelowZeroTransaction
- ArticleNotFound
- ErrorSavingInventory
- ActiveCountInventoryExists
- LockedGoods
- TransactionRowAlreadyExists
- GoodsOwnerIsDeleted
- InventoryAdjustmentCauseNotFound