Skip to main content

system.mes.inventory.getLot

Description

Retrieves an Inventory Lots record by its ID.

Syntax

system.mes.inventory.getLot(id)

Parameters

ParameterTypeDescription
idString (ULID)The ID of the inventory lots to retrieve.

Returns

Returns a JSON representation of the inventory lot. Returns nothing if no inventory lot is found.

NameTypeDescription
nameStringThe name of the inventory lot.
materialIdString (ULID)The ULID of the material associated with this inventory lot.
statusStringThe status of the inventory lot.
totalQuantityDoubleThe total quantity of material in the inventory lot.
unitOfMeasureIdString (ULID)The ULID of the unit of measure for the quantity of the inventory lot.
expirationDateInstantThe expected expiration date of the inventory lot.
closedDateInstantThe date that the inventory lot was closed.
supplierIdString (ULID)The ULID of the supplier for the inventory lot.
idString (ULID)The ULID of the inventory lot.
notesStringNotes related to the inventory lot.
enabledBooleanIndicates if the inventory lot is active and enabled.
spare1StringAdditional field for user-defined context.
spare2StringAdditional field for user-defined context.
spare3StringAdditional field for user-defined context.

Code Examples

# Retrieve a inventory lot by ID
lot = system.mes.inventory.getLot('01JE6F0CE9-T94PZD8R-TH9J01TJ')

# Output the inventory lot
print(lot)