Item API
Overview
The WMS Items API is a Business Central API page designed to expose item-related data for integration with external systems. This API provides access to item details and related units of measure, enabling seamless communication between Business Central and external warehouse management systems.
API Details
- Publisher: smart
- API Group: wms
- API Version: v2.0
- Entity Name: item
- Entity Set Name: items
- Source Table: Item
Fields
The following fields are exposed in the API:
| Field Name | Source Field | Description | Required |
|---|---|---|---|
No | Item."No." | Unique identifier for the item. | Yes |
Description | Item.Description | Description of the item. | Yes |
Type | Item.Type | Type of the item (e.g., Inventory, Service). | Yes |
BaseUnitOfMeasure | Item."Base Unit of Measure" | The base unit of measure for the item. | Yes |
PurchaseUnitOfMeasure | Item."Purch. Unit of Measure" | The unit of measure used for purchasing the item. | No |
SalesUnitOfMeasure | Item."Sales Unit of Measure" | The unit of measure used for selling the item. | No |
PutAwayUnitOfMeasure | Item."Put-away Unit of Measure Code" | The unit of measure used for put-away operations. | No |
GenProductPostingGroup | Item."Gen. Prod. Posting Group" | General product posting group for the item. | No |
VatProdPostingGroup | Item."VAT Prod. Posting Group" | VAT product posting group for the item. | No |
InventoryPostingGroup | Item."Inventory Posting Group" | Inventory posting group for the item. | No |
CountryOfOrigin | Item."Country/Region of Origin Code" | Country or region of origin for the item. | No |
ItemTrackingCode | Item."Item Tracking Code" | Item tracking code for the item. | No |
LotNos | Item."Lot Nos." | Lot numbers associated with the item. | No |
WarehouseClassCode | Item."Warehouse Class Code" | Warehouse class code for the item. | No |
ManufacturerCode | Manufacturer.Code | Code representing the item's manufacturer. | No |
SalesABCAnalysisCode | Item."SMA Sales ABC-analysis Code" | Sales ABC analysis code for the item. | No |
ItemCategoryCode | Item."Item Category Code" | Item category code for the item. | No |
gTIN | Item.GTIN | Global Trade Item Number (GTIN) for the item. | No |
Subpages
Item Units of Measure API
- Entity Name: itemUnitOfMeasure
- Entity Set Name: itemUnitsOfMeasure
- Subpage Link: Links to units of measure for the item using the
Item No.field.
Notes
- The WMS Connector Setup record must exist; otherwise, an item cannot be updated through the API.
- The item template from the Item Template field of the WMS Connector Setup page is applied when an item is updated (PATCH), not when it is created. The template is applied only if the item has no Gen. Prod. Posting Group yet, and it does not overwrite values that are already set.
- When an item is updated, blank Purch. Unit of Measure, Sales Unit of Measure, and Put-away Unit of Measure Code are set to the base unit of measure. If the specified
ManufacturerCodedoes not exist, the manufacturer is created.
Example Usage
Create a New Item
POST host/instance/api/smart/wms/v2.0/companies(companyId)/items
Content-Type: application/json
{
"No": "ITEM001",
"Description": "Sample Item",
"Type": "Inventory",
"BaseUnitOfMeasure": "pcs"
}
Retrieve an Item
GET host/instance/api/smart/wms/v2.0/companies(companyId)/items('ITEM001')
Update a Item
PATCH /host/instance/api/smart/wms/v2.0/companies(companyId)/items('ITEM001')
Content-Type: application/json
{
"Description": "Updated Item Description"
}