Back to Aligni.com

Update an inventory unit.

Examples

# request
curl -X PUT -H 'Accept: application/xml' -H 'Content-Type: application/xml' -d "
<inventory_unit>
  <cost_per_unit>100</cost_per_unit>
  <serial_number>IU-42</serial_number>
  <lot_code>LC-223</lot_code>
  <datecode>DC-002</datecode>
</inventory_unit>" \
https://demo.aligni.com/api/v2/oid3vLgynoy_Yl1gZkrgkLEq3J/parts/728/inventory_units/52

# response
<inventory_unit>
  <id>52</id>
  <quantity>100</quantity>
  <quantity_available>100</quantity_available>
  <unit>each</unit>
  <cost_per_unit>0.009</cost_per_unit>
  <currency>USD</currency>
  <inventory_location>CDHQ - General Storage</inventory_location>
  <sublocation_bin/>
  <asset_id>A0000000</asset_id>
  <serial_number></serial_number>
  <lot_code>XKG982MAL</lot_code>
  <datecode>201019</datecode>
  <details/>
  <purchase_order_number/>
  <purchase_quantity/>
  <purchase_price/>
  <vendor/>
  <created_at>2013-11-14T10:34:00+00:00</created_at>
  <updated_at>2014-03-13T06:39:00+00:00</updated_at>
</inventory_unit>

Params

Param name Description
api_token
required

Your API token.


Value: Must be a String
id
required

Inventory unit ID.


Value: Must be a Integer
part_id
required

ID of the part to which the inventory unit belongs.


Value: Must be a Integer
inventory_unit
required

Value: Must be a Hash
inventory_unit[cost_per_unit]
optional

Cost per unit.


Value: Must be a number.
inventory_unit[serial_number]
optional

Serial number.


Value: Must be a String
inventory_unit[lot_code]
optional

Lot code.


Value: Must be a String
inventory_unit[datecode]
optional

Datecode.


Value: Must be a String
inventory_unit[details]
optional

Details


Value: Must be a String
inventory_unit[purchase_order_number]
optional

PO #


Value: Must be a String