Skip to main content
Version: V3 (Ignition 8.3)

system.mes.meter.getMeterConfigurationReferences

Description

By ID:

Retrieves a list of entities that reference a Meter Configuration record by its ID, preventing its deletion.

By Equipment and Name:

Retrieves a list of entities that reference a Meter Configuration record by the equipment ID and the configuration name.

Permissions

This method requires the METERING.READ.GET permission.

Syntax

This method accepts either key set: provide id, or provide both equipmentId and name.

# By ID
system.mes.meter.getMeterConfigurationReferences(id=id)

# By equipment and name
system.mes.meter.getMeterConfigurationReferences(equipmentId=equipmentId, name=name)

Parameters

Provide either id, or both equipmentId and name. All parameters are individually nullable because the two key sets are mutually exclusive.

ParameterTypeNullableDescription
idString (ULID)YesThe ID of the Meter Configuration to check references for.
equipmentIdString (ULID)YesThe ID of the equipment. Provide together with name.
nameStringYesThe name of the Meter Configuration. Provide together with equipmentId.

Returns

Returns a JSON object of referencing entities grouped by entity type.

Code Examples

# Get references by ID
references = system.mes.meter.getMeterConfigurationReferences(id='01J9YP3JBR-WQ8GWRR2-8Y879V2F')
print(references)

# Get references by equipment ID and name
references = system.mes.meter.getMeterConfigurationReferences(equipmentId='01J9YP3JBR-WQ8GWRR2-8Y879V2D', name='Main Panel kWh')
print(references)