import { ErrorType } from '../../../types/ocpp/ErrorType';
import type { IncomingRequestHandler } from '../../../types/ocpp/Requests';
import type { DefaultResponse } from '../../../types/ocpp/Responses';
-import { StopTransactionReason } from '../../../types/ocpp/Transaction';
import Constants from '../../../utils/Constants';
import logger from '../../../utils/Logger';
import Utils from '../../../utils/Utils';
chargingStation.getConnectorStatus(connectorId).status = OCPP16ChargePointStatus.FINISHING;
const stopResponse = await chargingStation.stopTransactionOnConnector(
connectorId,
- StopTransactionReason.REMOTE
+ OCPP16StopTransactionReason.REMOTE
);
if (stopResponse.idTagInfo?.status === OCPP16AuthorizationStatus.ACCEPTED) {
return Constants.OCPP_RESPONSE_ACCEPTED;
-import type { ChargingStationData } from './ChargingStationType';
import type { JsonObject } from './JsonType';
export enum Protocol {
START_AUTOMATIC_TRANSACTION_GENERATOR = 'startAutomaticTransactionGenerator',
STOP_AUTOMATIC_TRANSACTION_GENERATOR = 'stopAutomaticTransactionGenerator',
}
+
export interface RequestPayload extends JsonObject {
hashIds?: string[];
connectorId?: number;