Skip to main content

Raw Material Stock Consumption Information

The GetMaterialConsumption endpoint returns raw material stock consumption information (product technical list) from the MIMS system.


How to query raw material stock consumption

HTTP POST Request

Request TypeExample URL
POST{{url_base}}/GetMaterialConsumption
Examplehttp://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"GetMaterialConsumption"

Input Parameters

ParameterTypeRequiredDescription
BranchNoString(25)YesExternal branch code
MovementBeginDateDataHoraYesStock movement start date/time
MovementEndDateDataHoraNoStock movement end date/time
ProductNoString(25)NoExternal product code

Return

ParameterTypeRequiredDescription
WebServiceReturnWebServiceReturnYesStandard WebService response information on method execution
MaterialConsumptionDataListGetMaterialConsumptionDataListYesList of objects with consumption information

📝 GetMaterialConsumptionDataList Object

The GetMaterialConsumptionDataList object represents a product that had movement.

Return Parameters

ParameterTypeRequiredDescription
BranchNoString(25)YesExternal branch code
ProductNoString(25)YesExternal product code
ProductionStandartDateDataHoraYesMIMS system stock totalization record date/time
CartonQtyIntegerYesQuantity of boxes
NetWeightFloatYesNet weight
StandardWeightFloatYesStandard weight
ItemListGetMaterialConsumptionItemYesList of materials consumed in this product

📝 GetMaterialConsumptionItem Object

The GetMaterialConsumptionItem object represents a raw material consumption of the product.

Return Parameters

ParameterTypeRequiredDescription
MaterialNoString(25)YesExternal material code
ProductNoString(25)YesExternal product code
StandardQtyFloatYesMaterial consumed quantity (net)
RealQtyFloatYesMaterial consumed quantity (real)
MeasurementUnitString(25)YesUnit of measurement
ConsumptionTypeString(2)YesEnumerator with possible values for record Type: ctAnalytics (Analytical Structure - AS) or ctMaterial (Raw Material - RM)
Observation
  • The ProductNo parameter can be a material or a semi-finished product

Request Example

curl --location 'http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"GetMaterialConsumption"' \
--header 'Content-Type: application/json' \
--data '{
"BranchNo": "010101",
"MovementBeginDate": "2022-11-26T00:00:00",
"MovementEndDate": "2022-11-26T23:59:59",
"ProductNo": "PROD001"
}'

Response Example

{
"WebServiceReturn": {
"Status": "wrsSuccess",
"ErrorCode": "",
"Message": "",
"Actor": "",
"ReturnQuestion": null
},
"MaterialConsumptionDataList": [
{
"BranchNo": "BR001",
"ProductNo": "PROD001",
"ProductionStandartDate": "2025-05-15T12:00:00Z",
"CartonQty": 100,
"NetWeight": 1500.0,
"StandardWeight": 1520.0,
"ItemList": [
{
"MaterialNo": "MAT001",
"ProductNo": "PROD001",
"StandardQty": 1520.0,
"RealQty": 1500.0,
"MeasurementUnit": "KG",
"ConsumptionType": "ctMaterial"
}
]
}
]
}