Skip to main content
Solved

Get items of shipment via REST-API

  • Nov 12, 2025 3:07 PM UTC
  • 7 replies
  • 163 views
  • Translate All

Forum|alt.badge.img

Hi,

I’m trying to retrieve more detailed information about the items in a shipment.

The REST API endpoint /entity/Default/23.200.001/Shipment/<shipmentNbr> returns the InventoryID.

This InventoryID can then be used to fetch item data through either /entity/Default/23.200.001/NonStockItem/<InventoryID> or /entity/Default/23.200.001/StockItem/<InventoryID>.

However, I’m not sure which endpoint should be used in this case. Could you provide some advice?

 

Thanks in advance

 

 

Best answer by aleksejslusar19

Another thought:

I just found the value “StockItem” in the ItemClass (IN201000).

StockItem=true → Use StockItem-Endpoint

StockItem=false → Use NonStockItem-Endpoint

 

Do you know if the items can be distinguished by this value as well? Would be a bit easier to implement.

 

Yes, I think this could work.

View original

7 replies

Forum|alt.badge.img+1

Hi ​@BEXJens 

Below are the Postman commands to retrieve the required information. 
Retrieve InventoryIDs for Shopment with ShipmentNbr = 000021:

GET  http://localhost/25.101.0153/entity/DefaultExt/24.200.001/Shipment?$expand=Details&$filter=ShipmentNbr eq '000021'&$select=ShipmentNbr,Details/InventoryID 

 

Retrieve StockItem data:

GET http://localhost/25.101.0153/entity/DefaultExt/24.200.001/StockItem/FOODHOTDOG
GET http://localhost/25.101.0153/entity/DefaultExt/24.200.001/StockItem/FOODCHIP36

Hope this helps!

 

Translate

Forum|alt.badge.img
  • Author
  • Freshman II
  • Nov 13, 2025 8:14 AM UTC

 ​@aleksejslusar19 Thanks for your response.

However, calling the NonStockItem-Endpoint with the InventoryID of an stock item returns an error (500):

“/entity//{{endpoint}}/NonStockItem/<InventoryIDOfStockItem>”

So I wonder how to retrieve the information if the item is either a StockItem or a NonStockItem.

 

Translate

Forum|alt.badge.img+1

Hi ​@BEXJens 

StockItems and NonStockItems entities are stored in the InventoryItem table and are distinguished by the value of the ItemType field. The following values ​​can be stored in the ItemType field:

Possible values are: 

"F" - Finished Good (Stock Items only), 
"M" - Component Part (Stock Items only), 
"A" - Subassembly (Stock Items only), 

"N" - Non-Stock Item (a general type of Non-Stock Item), 
"L" - Labor (Non-Stock Items only),
"S" - Service (Non-Stock Items only), 
"C" - Charge (Non-Stock Items only), 
"E" - Expense (Non-Stock Items only). 

Defaults to the Type associated with the Item Class of the item if it's specified, or to Finished Good ("F") otherwise.

Getting InventoryID and ItemType from the Shipment endpoint is not possible with the standard endpoint. To get the ItemType, you must first extend the Shipment screen with the ItemType field and after - extend endpoint.

 

 

Translate

Forum|alt.badge.img
  • Author
  • Freshman II
  • Nov 13, 2025 9:23 AM UTC

Hi ​@aleksejslusar19,

Thanks for the hint! But the ItemType aren’t part of the default endpoint, right? So it would be still necessary to extend the endpoint.

 

Another thought:

I just found the value “StockItem” in the ItemClass (IN201000).

StockItem=true → Use StockItem-Endpoint

StockItem=false → Use NonStockItem-Endpoint

 

Do you know if the items can be distinguished by this value as well? Would be a bit easier to implement.

And can you tell me, whether the item types can be extended? 

Thank you!

Translate

Forum|alt.badge.img+1
  • Jr Varsity III
  • Answer
  • Nov 13, 2025 10:18 AM UTC

Another thought:

I just found the value “StockItem” in the ItemClass (IN201000).

StockItem=true → Use StockItem-Endpoint

StockItem=false → Use NonStockItem-Endpoint

 

Do you know if the items can be distinguished by this value as well? Would be a bit easier to implement.

 

Yes, I think this could work.

Translate

Forum|alt.badge.img+1

And can you tell me, whether the item types can be extended?  
 

 

I'm not quite following—which item types do you need to extend? 

Translate

Forum|alt.badge.img
  • Author
  • Freshman II
  • Nov 13, 2025 12:55 PM UTC

There is no need to extend the item types you mentioned above (F, M, A ...).

I just wondered if the values you mentioned can be modified in any way by the accumatica user or if the item types are fixed values .

Translate