UNPKG

@citrineos/reporting

Version:

The reporting module for OCPP v2.0.1. This module is not intended to be used directly, but rather as a dependency for other modules.

35 lines (34 loc) 2.08 kB
import type { ILogObj } from 'tslog'; import { Logger } from 'tslog'; import type { CallAction, IMessageConfirmation } from '@citrineos/base'; import { AbstractModuleApi, OCPP2_0_1 } from '@citrineos/base'; import type { FastifyInstance } from 'fastify'; import type { IReportingModuleApi } from '../interface.js'; import { ReportingModule } from '../module.js'; /** * Server API for the Reporting module. */ export declare class ReportingOcpp201Api extends AbstractModuleApi<ReportingModule> implements IReportingModuleApi { private readonly _componentDeviceDataCtrlr; /** * Constructs a new instance of the class. * * @param {ReportingModule} reportingModule - The Reporting module. * @param {FastifyInstance} server - The Fastify server instance. * @param {Logger<ILogObj>} [logger] - The logger instance. */ constructor(reportingModule: ReportingModule, server: FastifyInstance, logger?: Logger<ILogObj>); getBaseReport(identifier: string[], request: OCPP2_0_1.GetBaseReportRequest, callbackUrl?: string, tenantId?: number): Promise<IMessageConfirmation[]>; getCustomReport(identifier: string, request: OCPP2_0_1.GetReportRequest, callbackUrl?: string, tenantId?: number): Promise<IMessageConfirmation>; getMonitoringReport(identifier: string, request: OCPP2_0_1.GetMonitoringReportRequest, callbackUrl?: string, tenantId?: number): Promise<IMessageConfirmation>; getLog(identifier: string[], request: OCPP2_0_1.GetLogRequest, callbackUrl?: string, tenantId?: number): Promise<IMessageConfirmation[]>; customerInformation(identifier: string[], request: OCPP2_0_1.CustomerInformationRequest, callbackUrl?: string, tenantId?: number): Promise<IMessageConfirmation[]>; /** * Overrides superclass method to generate the URL path based on the input {@link CallAction} * and the module's endpoint prefix configuration. * * @param {CallAction} input - The input {@link CallAction}. * @return {string} - The generated URL path. */ protected _toMessagePath(input: CallAction): string; }