Build
The act of consuming a child item into a parent item.
This endpoint allows for consumptions in a third part system to be mirrored in Eyelit MES-M.
Where inventory is not being managed in Eyelit MES-M, receipt at point of consumption can be enabled which allows for the creation of child items through the endpoint for a streamlined experience.
Figure 1 - Logic within Build/Build API Call
Data Prerequisites
A build transaction in Eyelit MES-M is performed against a Material Item. The Serial No for the parent Material Item must be included in the payload.
This means that a works order must be started before a consumption can be recorded against the Material Item it is producing.
Additionally, the child item must be of a product that is defined with the parent item’s Bill of Materials.
Request
Table 2 shows the method and endpoint required to make the API call to build.
Table 2 - Outbound Message Detail for Build
Method | URL Structure | Endpoint |
PUT | https://[environment].mestec.net | /api/Build/Build |
The body of the payload should follow the format below.
Figure 2 - JSON Structure for Build
See Table 3 for information on which fields are optional, the appropriate data types and the mappings to fields in Eyelit MES-M.
Table 3 - Parameter Information for Build
Parameter Name | Data Mapping | Data Type | Mandatory | Case Sensitive | Match Type |
parentSerialNo | materialitem.visualserialno | VARCHAR2 | Yes | No | Exact |
childSerialNo | materialitem.visualserialno | VARCHAR2(250 BYTE) | Yes | No | Exact |
builtQty | Buildrecord.qty | NUMBER | Yes | N/A | N/A |
receiveAtPointOfConsumption | N/A | BOOL | Yes | N/A | N/A |
itemDetails | N/A | JSON object | No1 | N/A | N/A |
productName | Product.name | VARCHAR2 | Yes | No | Exact |
expiryDate | Materialitem.expirydt | TIMESTAMP | No | N/A | N/A |
batchNo | Materialitem.batchno | VARCHAR2 | No | N/A | N/A |
version | MaterialItem.version | VARCHAR2 | No | N/A | N/A |
costPerUnit | Materialitem.costperunit | NUMBER | No | N/A | N/A |
currency | Currency.name | VARCHAR2 | No2 | No | Exact |
Note: For any fields where the match type is ‘Like’, a percent symbol should be used as a wildcard character to indicate a number of characters within the given string.
Sample Request
See below for sample use cases with examples of the JSON payload format required.
To build an existing child item to a parent item:
Figure 3 - JSON Sample for Build Request A
To receive a new child item and build into a parent item:
Figure 4 - JSON Sample for Build Request B
Response
When a build is successfully completed through the endpoint, a JSON payload will be returned containing data in the following structure:
Sample Response
See below for sample use cases with examples of the JSON payload format returned.
No results were found that matched given parameters:
Remove
This endpoint allows for reversals of consumption in a third part system to be mirrored in Eyelit MES-M.
Figure 5 - Logic within Build/Remove API Call
Data Prerequisites
The Child Material Item must be built into the Parent Material Item with sufficient quantity to be removed.
The reason SUID provided must match an existing Material Reason in Eyelit MES-M which is assigned to the Remove transaction
Request
Table 4 shows the method and endpoint required to make the API call to Remove.
Table 4 - Outbound Message Detail for Remove
Method | URL Structure | Endpoint |
PUT | https://[environment].mestec.net | /api/Build/Remove |
The body of the payload should follow the format below.
See Table 5 for information on which fields are optional, the appropriate data types and the mappings to fields in Eyelit MES-M.
Table 5 - Parameter Information for Remove
Parameter Name | Data Mapping | Data Type | Mandatory | Case Sensitive | Match Type |
parentSerialNo | materialitem.visualserialno | VARCHAR2 | Yes | No | Exact |
childSerialNo | materialitem.visualserialno | VARCHAR2(250 BYTE) | Yes | No | Exact |
removeQty | Buildrecord.qty | NUMBER | Yes | N/A | N/A |
comments | MaterialTransactionLog.Comments | VARCHAR2 | No | N/A | N/A |
reasonSUID | MaterialReason.SUID | VARCHAR2 | Yes | No | Exact |
Note: For any fields where the match type is ‘Like’, a percent symbol should be used as a wildcard character to indicate a number of characters within the given string.
Sample Request
See below for sample use cases with examples of the JSON payload format required.
To remove an existing child item to a parent item:
Response
When a build is successfully completed through the endpoint, a JSON payload will be returned containing data in the following structure:
Sample Response
See below for sample use cases with examples of the JSON payload format returned.