GET api/inventory/{id1}/{id2}/{option}

Returns inventory base on the following option values: "bycodes" - WarehouseCode (id1), PartCode (id2), this is also the default if option is left out "bywarehouse" - WarehouseCode (id1), id2 will be ignored but needs a place holder (use zero), "bypart" = id1 will be ignored but needs a place holder (use zero), PartCode (id2)

Request Information

URI Parameters

NameDescriptionTypeAdditional information
id1

WarehouseCode from the IN_Warehouse table

string

Required

id2

PartCode from the IN_Part table

string

Required

option

bycodes, bywarehouse or bypart

string

Default value is bycodes

Body Parameters

None.

Response Information

Resource Description

Collection of Inventory
NameDescriptionTypeAdditional information
InventoryId

Key from IN_Inventory

integer

None.

WarehouseCode

Abbreviated Warehouse code; defaults to N/A if not supplied

string

String length: inclusive between 0 and 25

PartCode

Abbreviated Part_Code, from IN_Part table

string

String length: inclusive between 0 and 25

OnHandNew

Number of now onhand

integer

None.

OnHandUsed

Number of used onhand

integer

None.

Response Formats

application/json, text/json

Sample:
[
  {
    "InventoryId": 1,
    "WarehouseCode": "sample string 2",
    "PartCode": "sample string 3",
    "OnHandNew": 1,
    "OnHandUsed": 1
  },
  {
    "InventoryId": 1,
    "WarehouseCode": "sample string 2",
    "PartCode": "sample string 3",
    "OnHandNew": 1,
    "OnHandUsed": 1
  }
]

application/xml, text/xml

Sample:
<ArrayOfInventory xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SedonaServices.Models">
  <Inventory>
    <InventoryId>1</InventoryId>
    <OnHandNew>1</OnHandNew>
    <OnHandUsed>1</OnHandUsed>
    <PartCode>sample string 3</PartCode>
    <WarehouseCode>sample string 2</WarehouseCode>
  </Inventory>
  <Inventory>
    <InventoryId>1</InventoryId>
    <OnHandNew>1</OnHandNew>
    <OnHandUsed>1</OnHandUsed>
    <PartCode>sample string 3</PartCode>
    <WarehouseCode>sample string 2</WarehouseCode>
  </Inventory>
</ArrayOfInventory>