1 import { ChargingProfilePurposeType
, OCPP16ChargingProfile
} from
'./ChargingProfile';
3 import { EmptyObject
} from
'../../EmptyObject';
4 import { JsonType
} from
'../../JsonType';
5 import { OCPP16ChargePointErrorCode
} from
'./ChargePointErrorCode';
6 import { OCPP16ChargePointStatus
} from
'./ChargePointStatus';
7 import { OCPP16DiagnosticsStatus
} from
'./DiagnosticsStatus';
8 import { OCPP16StandardParametersKey
} from
'./Configuration';
10 export enum OCPP16RequestCommand
{
11 BOOT_NOTIFICATION
= 'BootNotification',
12 HEARTBEAT
= 'Heartbeat',
13 STATUS_NOTIFICATION
= 'StatusNotification',
14 CHANGE_CONFIGURATION
= 'ChangeConfiguration',
15 AUTHORIZE
= 'Authorize',
16 START_TRANSACTION
= 'StartTransaction',
17 STOP_TRANSACTION
= 'StopTransaction',
18 METER_VALUES
= 'MeterValues',
19 DIAGNOSTICS_STATUS_NOTIFICATION
= 'DiagnosticsStatusNotification'
22 export enum OCPP16IncomingRequestCommand
{
24 CLEAR_CACHE
= 'ClearCache',
25 CHANGE_AVAILABILITY
= 'ChangeAvailability',
26 UNLOCK_CONNECTOR
= 'UnlockConnector',
27 GET_CONFIGURATION
= 'GetConfiguration',
28 CHANGE_CONFIGURATION
= 'ChangeConfiguration',
29 SET_CHARGING_PROFILE
= 'SetChargingProfile',
30 CLEAR_CHARGING_PROFILE
= 'ClearChargingProfile',
31 REMOTE_START_TRANSACTION
= 'RemoteStartTransaction',
32 REMOTE_STOP_TRANSACTION
= 'RemoteStopTransaction',
33 GET_DIAGNOSTICS
= 'GetDiagnostics',
34 TRIGGER_MESSAGE
= 'TriggerMessage'
37 export type HeartbeatRequest
= EmptyObject
;
39 export interface OCPP16BootNotificationRequest
extends JsonType
{
40 chargeBoxSerialNumber
?: string;
41 chargePointModel
: string;
42 chargePointSerialNumber
?: string;
43 chargePointVendor
: string;
44 firmwareVersion
?: string;
47 meterSerialNumber
?: string;
51 export interface StatusNotificationRequest
extends JsonType
{
53 errorCode
: OCPP16ChargePointErrorCode
;
55 status: OCPP16ChargePointStatus
;
58 vendorErrorCode
?: string;
61 export interface ChangeConfigurationRequest
extends JsonType
{
62 key
: string | OCPP16StandardParametersKey
;
66 export interface RemoteStartTransactionRequest
extends JsonType
{
69 chargingProfile
?: OCPP16ChargingProfile
;
72 export interface RemoteStopTransactionRequest
extends JsonType
{
73 transactionId
: number;
76 export interface UnlockConnectorRequest
extends JsonType
{
80 export interface GetConfigurationRequest
extends JsonType
{
81 key
?: string | OCPP16StandardParametersKey
[];
84 export enum ResetType
{
89 export interface ResetRequest
extends JsonType
{
93 export interface SetChargingProfileRequest
extends JsonType
{
95 csChargingProfiles
: OCPP16ChargingProfile
;
98 export enum OCPP16AvailabilityType
{
99 INOPERATIVE
= 'Inoperative',
100 OPERATIVE
= 'Operative'
103 export interface ChangeAvailabilityRequest
extends JsonType
{
105 type: OCPP16AvailabilityType
;
108 export interface ClearChargingProfileRequest
extends JsonType
{
110 connectorId
?: number;
111 chargingProfilePurpose
?: ChargingProfilePurposeType
;
115 export interface GetDiagnosticsRequest
extends JsonType
{
118 retryInterval
?: number;
123 export interface DiagnosticsStatusNotificationRequest
extends JsonType
{
124 status: OCPP16DiagnosticsStatus
127 export enum MessageTrigger
{
128 BootNotification
= 'BootNotification',
129 DiagnosticsStatusNotification
= 'DiagnosticsStatusNotification',
130 FirmwareStatusNotification
= 'FirmwareStatusNotification',
131 Heartbeat
= 'Heartbeat',
132 MeterValues
= 'MeterValues',
133 StatusNotification
= 'StatusNotification'
136 export interface OCPP16TriggerMessageRequest
extends JsonType
{
137 requestedMessage
: MessageTrigger
;