1 import { EmptyObject
} from
'../../EmptyObject';
2 import { JsonObject
} from
'../../JsonType';
3 import { OCPP16ChargePointErrorCode
} from
'./ChargePointErrorCode';
4 import { OCPP16ChargePointStatus
} from
'./ChargePointStatus';
5 import { ChargingProfilePurposeType
, OCPP16ChargingProfile
} from
'./ChargingProfile';
6 import { OCPP16StandardParametersKey
} from
'./Configuration';
7 import { OCPP16DiagnosticsStatus
} from
'./DiagnosticsStatus';
9 export enum OCPP16RequestCommand
{
10 BOOT_NOTIFICATION
= 'BootNotification',
11 HEARTBEAT
= 'Heartbeat',
12 STATUS_NOTIFICATION
= 'StatusNotification',
13 AUTHORIZE
= 'Authorize',
14 START_TRANSACTION
= 'StartTransaction',
15 STOP_TRANSACTION
= 'StopTransaction',
16 METER_VALUES
= 'MeterValues',
17 DIAGNOSTICS_STATUS_NOTIFICATION
= 'DiagnosticsStatusNotification',
20 export enum OCPP16IncomingRequestCommand
{
22 CLEAR_CACHE
= 'ClearCache',
23 CHANGE_AVAILABILITY
= 'ChangeAvailability',
24 UNLOCK_CONNECTOR
= 'UnlockConnector',
25 GET_CONFIGURATION
= 'GetConfiguration',
26 CHANGE_CONFIGURATION
= 'ChangeConfiguration',
27 SET_CHARGING_PROFILE
= 'SetChargingProfile',
28 CLEAR_CHARGING_PROFILE
= 'ClearChargingProfile',
29 REMOTE_START_TRANSACTION
= 'RemoteStartTransaction',
30 REMOTE_STOP_TRANSACTION
= 'RemoteStopTransaction',
31 GET_DIAGNOSTICS
= 'GetDiagnostics',
32 TRIGGER_MESSAGE
= 'TriggerMessage',
35 export type OCPP16HeartbeatRequest
= EmptyObject
;
37 export interface OCPP16BootNotificationRequest
extends JsonObject
{
38 chargePointVendor
: string;
39 chargePointModel
: string;
40 chargePointSerialNumber
?: string;
41 chargeBoxSerialNumber
?: string;
42 firmwareVersion
?: string;
46 meterSerialNumber
?: string;
49 export interface OCPP16StatusNotificationRequest
extends JsonObject
{
51 errorCode
: OCPP16ChargePointErrorCode
;
53 status: OCPP16ChargePointStatus
;
56 vendorErrorCode
?: string;
59 export interface ChangeConfigurationRequest
extends JsonObject
{
60 key
: string | OCPP16StandardParametersKey
;
64 export interface RemoteStartTransactionRequest
extends JsonObject
{
67 chargingProfile
?: OCPP16ChargingProfile
;
70 export interface RemoteStopTransactionRequest
extends JsonObject
{
71 transactionId
: number;
74 export interface UnlockConnectorRequest
extends JsonObject
{
78 export interface GetConfigurationRequest
extends JsonObject
{
79 key
?: string | OCPP16StandardParametersKey
[];
82 export enum ResetType
{
87 export interface ResetRequest
extends JsonObject
{
91 export interface SetChargingProfileRequest
extends JsonObject
{
93 csChargingProfiles
: OCPP16ChargingProfile
;
96 export enum OCPP16AvailabilityType
{
97 INOPERATIVE
= 'Inoperative',
98 OPERATIVE
= 'Operative',
101 export interface ChangeAvailabilityRequest
extends JsonObject
{
103 type: OCPP16AvailabilityType
;
106 export interface ClearChargingProfileRequest
extends JsonObject
{
108 connectorId
?: number;
109 chargingProfilePurpose
?: ChargingProfilePurposeType
;
113 export interface GetDiagnosticsRequest
extends JsonObject
{
116 retryInterval
?: number;
121 export interface DiagnosticsStatusNotificationRequest
extends JsonObject
{
122 status: OCPP16DiagnosticsStatus
;
125 export enum MessageTrigger
{
126 BootNotification
= 'BootNotification',
127 DiagnosticsStatusNotification
= 'DiagnosticsStatusNotification',
128 FirmwareStatusNotification
= 'FirmwareStatusNotification',
129 Heartbeat
= 'Heartbeat',
130 MeterValues
= 'MeterValues',
131 StatusNotification
= 'StatusNotification',
134 export interface OCPP16TriggerMessageRequest
extends JsonObject
{
135 requestedMessage
: MessageTrigger
;
136 connectorId
?: number;