Meter API
Welcome to the Meter API documentation. This API provides a comprehensive set of functions for managing and interacting with metering data within the system. Below is a list of available functions, each with a brief description and a link to its detailed documentation.
Meter Type Functions
newMeterType
Generates an empty non-persisted Meter Type object to provide the structure required by the API to save a new record into the database. This method must be combined with the saveMeterType method in order to persist the record. Returns a JSON representation of the newly created Meter Type object.
getMeterType
Retrieves a Meter Type record by its ID or name. Returns a JSON representation of the Meter Type. Returns nothing if no Meter Type is found.
getAllMeterTypes
Retrieves a list of all Meter Type records in the system. Returns a list of JSON objects representing all Meter Types.
findMeterTypes
Retrieves Meter Type records based on the specified pagination, sort, and column constraint parameters. Returns a Query Result object.
saveMeterType
Creates or updates a Meter Type record in the system based on the provided parameters. Returns a JSON representation of the saved Meter Type.
validateMeterType
Validates the specified parameters for a Meter Type record and returns any validation errors. Returns a JSON object where keys are field names and values are lists of validation violation messages.
deleteMeterType
Deletes a Meter Type record by its ID or name. This cannot delete a Meter Type that is referenced by a Meter Configuration. If successful, an ApiResponse object is returned with the success bool set to True.
deleteMeterTypes
Deletes multiple Meter Type records by the given IDs or names. This cannot delete any Meter Types with references to them. If successful, an ApiResponse object is returned with the success bool set to True.
getMeterTypeReferences
Retrieves a list of entities that reference a Meter Type record, preventing deletion. Returns a JSON object of referencing entities.
importMeterTypesFromCsv
Imports Meter Type records from a CSV file. Returns a JSON representation of the import response.
importMeterTypesFromJson
Imports Meter Type records from a JSON file. Returns a JSON representation of the import response.
exportMeterTypesAsJson
Exports all Meter Types as JSON, or specific ones by IDs or names. Returns the JSON export as bytes.
exportMeterTypesAsCsv
Exports all Meter Types as CSV, or specific ones by IDs or names. Returns the CSV export as bytes.
getMeterTypeImportQueueSize
Gets the current size of the Meter Type import queue. Returns an integer indicating the number of items pending import.
cancelMeterTypeImportQueue
Cancels all pending Meter Type imports. No response is returned.
Meter Configuration Functions
newMeterConfiguration
Generates an empty non-persisted Meter Configuration object to provide the structure required by the API to save a new record into the database. This method must be combined with the saveMeterConfiguration method in order to persist the record. Returns a JSON representation of the newly created Meter Configuration object.
getMeterConfiguration
Retrieves a Meter Configuration record by its ID, or by its equipment ID/path and name. Returns a JSON representation of the Meter Configuration. Returns nothing if no Meter Configuration is found.
getMeterConfigurationsForEquipment
Retrieves all Meter Configuration records for a specific piece of equipment. Returns a list of JSON objects representing the Meter Configurations.
getMeterConfigurationsForEquipmentPath
Retrieves all Meter Configuration records for the equipment at a path and every equipment beneath it (a path-prefix/subtree match). Returns a list of JSON objects representing the Meter Configurations.
getAllMeterConfigurations
Retrieves a list of all Meter Configuration records in the system. Returns a list of JSON objects representing all Meter Configurations.
findMeterConfigurations
Retrieves Meter Configuration records based on the specified pagination, sort, and column constraint parameters. Returns a Query Result object.
saveMeterConfiguration
Creates or updates a Meter Configuration record in the system based on the provided parameters. Returns a JSON representation of the saved Meter Configuration.
validateMeterConfiguration
Validates the specified parameters for a Meter Configuration record and returns any validation errors. Returns a JSON object where keys are field names and values are lists of validation violation messages.