Skip to main content

system.mes.oee.getOeeWasteRecord

Description

Retrieves a specific OEE Waste Record by its ID.

Permissions

This method requires the OEE.READ.GET permission.

Syntax

system.mes.oee.getOeeWasteRecord(id)

Parameters

ParameterTypeNullableDescription
idString (ULID)FalseThe ID of the OEE waste record to retrieve.

Returns

Returns a JSON representation of the OeeWasteRecordDTO object. Returns nothing if no record is found.

NameTypeNullableDescriptionDefault Value
idStringTrueThe id of the OEE Waste Recordnull
locationIdStringFalseIdentifier of the associated location where this OEE waste record was capturednull
locationPathStringTruePath of the location where this OEE waste record was capturednull
locationNameStringTrueName of the associated locationnull
startDateInstantFalseStart date and time of the OEE waste recordInstant.now()
endDateInstantTrueEnd date and time of the OEE waste recordnull
totalDurationSecDoubleFalseTotal duration of the OEE waste record in seconds0.0
qualityReasonIdStringTrueIdentifier of the associated quality reason, if applicablenull
qualityReasonNameStringTrueName of the associated quality reason. (Name - Code) For display purposes onlynull
qualityReasonPathStringTruePath to the current quality reasonnull
qualityReasonCodeStringTrueCode of the associated quality reasonnull
wasteCountDoubleFalseTotal number of waste units recorded during this period0.0
wasteCountUnitOfMeasureIdStringTrueIdentifier of the unit of measure for the waste countnull
wasteCountUnitOfMeasureNameStringTrueName of the unit of measure for the waste countnull
wasteCountUnitOfMeasureSymbolStringTrueSymbol of the unit of measure for the waste countnull
notesStringTrueNotes associated with the OEE Waste Recordnull
enabledbooleanTrueIndicates whether the OEE Waste Record is enabledtrue
spare1StringTrueExtra field 1null
spare2StringTrueExtra field 2null
spare3StringTrueExtra field 3null

Code Examples

# Retrieve an OEE waste record by ID
wasteRecord = system.mes.oee.getOeeWasteRecord('01JAP8RJBN-8ZTPXSGY-J9GSDPE1')

# Output the record
print(wasteRecord)