Simple Production Order
Simple Production Order Registration
The PostAddSimpleProductionOrder endpoint is responsible for registering a Simple Production Order in the MIMS system and can be consulted through PRO021.
How to register a Simple Production Order
HTTP POST Request
| Request Type | Example URL |
|---|---|
| POST | {{url_base}}/PostAddSimpleProductionOrder |
| Example | http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostAddSimpleProductionOrder" |
Input Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| BranchNo | String(25) | Yes | External branch code |
| SimpleProductionOrderNo | String(25) | Yes | External simple production order code |
| SlaughterStructureNo | String(25) | No | External slaughter structure code |
| StartDate | Date | Yes | Production order start date |
| FinalDate | Date | Yes | Production order end date |
| ItemList | AddSimpleProductionOrderItemList | Yes | List of production order items |
📝 AddSimpleProductionOrderItem Object
The AddSimpleProductionOrderItem object represents a list of items from a simple production order
Input Parameters
Parameter Type Required Description SimpleProductionOrderItemNo String(25) Yes External production order item number code ProductNo String(25) Yes External product code Qty Integer No Quantity to be produced Weight Float No Weight to be produced ControlPanel Boolean Yes Flag indicating whether the item is controlled by the control panel AlertOvermeasureProducts Boolean Yes Flag indicating whether the item alerts overmeasure products StartAlert Integer No Quantity of products to start the alert BlockOvermeasureProducts Boolean Yes Flag indicating whether it blocks overmeasure production
Return
| Parameter | Type | Required | Description |
|---|---|---|---|
| WebServiceReturn | WebServiceReturn | Yes | Standard WebService response information on method execution |
| SimpleProductionOrderCode | Integer | Yes | Internal simple production order code generated in the MIMS system |
Request Example
curl --location 'http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostAddSimpleProductionOrder"' \
--header 'Content-Type: application/json' \
--data '{
"BranchNo": "BR001",
"SimpleProductionOrderNo": "SPO-20251111-001",
"SlaughterStructureNo": "SLG-015",
"StartDate": "2025-11-11",
"FinalDate": "2025-11-12",
"ItemList": [
{
"SimpleProductionOrderItemNo": "ITEM-001",
"ProductNo": "PROD-001",
"Qty": 150,
"Weight": 1250.5,
"ControlPanel": true,
"AlertOvermeasureProducts": true,
"StartAlert": 140,
"BlockOvermeasureProducts": false
}
]
}'
Response Example
{
"WebServiceReturn": {
"Status": "wrsSuccess",
"ErrorCode": "",
"Message": "",
"Actor": "",
"ReturnQuestion": null
},
"SimpleProductionOrderCode": 12345
}
🐞 Possible Errors
| Code | Message |
|---|---|
| APO‑001 | It is necessary to inform a quantity! |
| APO‑002 | It is necessary to inform only one quantity! |
| APO‑003 | The product [value sent in request] informed at index [index code] already exists for production order [production order number], operation not allowed! |
| APO‑004 | The final scheduling date must be greater than or equal to the initial date |
| APO‑005 | The informed scheduling order item code already exists, operation not allowed! |
| APO‑006 | The informed scheduling order code already exists, operation not allowed! |
Simple Production Order Item Deletion
The PostDeleteSimpleProductionOrderItem endpoint is responsible for executing the deletion of a Simple Production Order item in the MIMS system.
How to delete a Simple Production Order item
HTTP POST Request
| Request Type | Example URL |
|---|---|
| POST | {{url_base}}/PostDeleteSimpleProductionOrderItem |
| Example | http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostDeleteSimpleProductionOrderItem" |
Input Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| SimpleProductionOrderItemNo | String(25) | Yes | External production order item number code |
| ErrorIfNotFound | Boolean | Yes | Returns error if the informed item does not exist in the database |
Return
| Parameter | Type | Required | Description |
|---|---|---|---|
| WebServiceReturn | WebServiceReturn | Yes | Standard WebService response information on method execution |
Request Example
curl --location 'http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostDeleteSimpleProductionOrderItem"' \
--header 'Content-Type: application/json' \
--data '{
"SimpleProductionOrderItemNo": "SPI001",
"ErrorIfNotFound": false
}'
Response Example
{
"WebServiceReturn": {
"Status": "wrsSuccess",
"ErrorCode": "",
"Message": "",
"Actor": "",
"ReturnQuestion": null
}
}
🐞 Possible Errors
| Code | Message |
|---|---|
| DSP‑001 | The informed "SimpleProductionOrderItemNo" does not exist! |
| DSP‑002 | The informed "SimpleProductionOrderItemNo" is a fixed record, deletion not allowed! |
| DSP‑003 | There are batches generated for this scheduling "SimpleProductionOrderItemNo". Deletion not allowed! |
| DSP‑004 | Production has already been started for the informed "ProductionOrderItemNo". Deletion not allowed! |