Skip to main content

system.mes.material.getMaterialClass

Description

Retrieves a Material Classes record by its ID or path.

Syntax

system.mes.material.getMaterialClass(idOrPath)

Parameters

ParameterTypeDescription
idOrPathStringThe ID or path of the material class to retrieve.

Returns

Returns a JSON representation of the material class. Returns nothing if no material class is found.

NameTypeDescription
nameStringThe name of the material class.
descriptionStringThe description of the material class.
pathStringThe path to the material class.
parentIdString (ULID)The ULID of the parent material class to this material class.
idString (ULID)The ULID of the material class.
notesStringNotes related to the material class.
enabledBooleanIndicates if the material class 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 material class by ID or path
material_class = system.mes.material.getMaterialClass('RAW')

# Output the material class
print(material_class)