This API retrieves the material status of the given Tag number or Drawing number from Smart Materials.
-
API retrieves all the Bill of Materials (BOM) Positions (LpId) of the given Drawing number or Tag number on which a Forecast is already run.
-
If both Drawing number and Tag number is passed, then the status of the Tag number associated with the given Drawing number is retrieved.
Required Privilege: API_GET_FORECAST_RESULTS
Headers
Header Name |
Description |
Required |
Values |
---|---|---|---|
Authorization |
Access token |
Required |
Bearer <access_token> |
Content-Type |
Request type format |
Required |
application/JSON |
Body
URL Format: POST http://localhost:53215/smat/v1/Projects(':project')/Com.Ingr.Smat.V1.MaterialStatus/
Specify value for the project in the URL. In the body, provide the TimePeriod and BOMNodes details.
Element |
Description |
Type |
Required |
Notes |
---|---|---|---|---|
TimePeriod |
Represents the time that the application considers Time is in days. |
Integer |
Optional |
Maximum allowed time Default value is 180 days. |
BOMNodes |
Collection of three parameters; DrawingNumber, TagNumber, and FahCode |
Collection |
Required |
|
DrawingNumber |
Name of the BOM node If given DrawingNumber is root node, then all the BOM |
String |
Required |
Either DrawingNumber |
TagNumber |
Tag number of the material |
String |
Required |
Either DrawingNumber |
FahCode |
Refers to Forecast/Reservation code in Smart Material |
String |
Optional |
If FahCode is passed, then the material |
Sample Code
POST http://localhost:53215/smat/v1/Projects('M06_1188')/Com.Ingr.Smat.V1.MaterialStatus/
{
"filterMatStatus":
{
"TimePeriod": 60,
"BOMNodes": [
{
"DrawingNumber": "MS_LEV2",
"TagNumber": "TAG-REC-F390511"
}
]
}
}
Success Response
Status: 200 OK
{
"@odata.context": "http://localhost:53215/SMAT/V1/$metadata#Collection(Com.Ingr.Smat.Core.V1.MaterialStatus)",
"value": [
{
"LpId": 157773993,
"DrawingNumber": "MS_LEV2",
"FahId": 65633,
"FahType": "Forecast Run",
"ListPosition": "10",
"StatId": 5602,
"CommodityCode": "TAG-REC-F390511",
"CommodityCodeShortDesc": "TAG-REC-F390511",
"Size1": "0",
"Size2": "0",
"Size3": "0",
"Size4": "0",
"ShortCode": null,
"IdentCode": "TAG-REC-F390511",
"TagNumber": "TAG-REC-F390511",
"BOMPath": "/MS_STATUS/MS_LEV2",
"SplitTagIndicator": "N",
"DetailTagsBOMPath": null,
"BOMQty": 100,
"TotalIssuedQty": 30,
"ReservedvQty": 0,
"TotalOnHandQty": 40,
"TotalAllocatedQty": 40,
"ForecastShortQty": 30,
"UnitId": 5181,
"UnitCode": "PC",
"ForecastResults": [
{
"WhId": 12028,
"WhCode": "PB_WH1",
"LocId": 6478,
"LocCode": "A-A",
"RecvStatus": "CHECKING",
"OnHandQty": 40,
"AllocatedQty": 40,
"AllocationType": "Inventory",
"ETADate": null,
"PromOnSiteDate": null,
"ROSDate": null
}
],
"MIRDetails": [
{
"MIRNumber": "MIR-PB-00004",
"MIRType": "MIR By BOM Ident",
"IssuedQty": 10
},
{
"MIRNumber": "MIR-PB-00004",
"MIRType": "MIR By BOM Ident",
"IssuedQty": 20
}
]
}
]
}
Element |
Description |
Type |
---|---|---|
FahId |
Unique ID of the given Forecast header |
Integer |
LpId |
Unique ID of the list position Represents BOM positions. |
Integer |
ListPosition |
Unique position of the structure-element |
String |
CommodityCode |
Name or code of the commodity |
String |
CommodityCodeShortDesc |
Short description of the commodity code |
String |
Size (1-4) |
Commodity size Four different values are allowed. |
String |
IdentCode |
Code or name of the ident |
String |
BOMQty |
Quantity of the BOM position |
Integer |
BOMPath |
Path description starting from the root node till the selected list node |
String |
TotalIssuedQty |
Total issued quantity of the BOM position |
Decimal |
UnitId |
Unique ID of the unit |
Integer |
UnitCode |
Name of the unit |
String |
ForecastShortQty |
Represents the difference between the outstanding quantity and the |
Decimal |
TotalAllocatedQty |
Represents the sum of actual and manual reserved quantity and In Smart Materials, this refers to Total Reserved Qty. |
Decimal |
TotalOnHandQty |
Total on hand quantity for this BOM position |
Decimal |
ReservedQty |
Represents the sum of the reserved quantity of all the Reservation Runs for this position. In Smart Materials, this refers to List Pos Resv Qty. |
Decimal |
SplitTagIndicator |
Indicates whether the tag item is split or not |
String |
DetailTagsBOMPath |
BOM path of the detail tags If SplitTagIndicator is N, then DetailTagsBOMPath will be null. |
String |
FahType |
Specifies type of Run. Run can be a Forecast Run or Reservation Run. |
String |
StatId |
Unique ID of the associated issue status |
Integer |
ShortCode |
Specifies the short code |
String |
-
Forecast Results (ForecastResults)
Element |
Description |
Type |
---|---|---|
ETADate |
Expected time of arrival of the material and also refers to PredOnSite Date is Smart Materials. |
Date time offset |
ROSDate |
Date and time when the material is Required on Site |
Date time offset |
OnHandQty |
On-hand quantity of the associated BOM position available in the displayed warehouse location. |
Decimal |
AllocatedQty |
Quantity that is forecasted by this job. This quantity is reserved for a Reservation job. In Smart Materials, this refers to the sum of Actual ResvQty and Manual Resv Qty. |
Decimal |
WhId |
Unique ID of the associated warehouse |
Integer |
WhCode |
Name of the associated warehouse |
String |
LocId |
Unique ID of the location |
Integer |
LocCode |
Name of the location |
String |
AllocationType |
Defines the level where the material is allocated.Allowed values are:
|
String |
PromOnSiteDate |
Promised on Site date |
Date Time Offset |
RecvStatus |
Status of the received material in site |
String |
-
Material Issuing Report (MIR) details
MIR details is a collection and consist of all the MIRs of the corresponding BOM position.
Element |
Description |
Type |
---|---|---|
MIRNumber |
Name of the MIR |
String |
MIRType |
Type of MIR. Available options are:
|
String |
IssuedQty |
Issued quantity of the list position associated with the given MIR |
Decimal |