kirby-ocpp 0.1.2 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +192 -88
- package/THIRD_PARTY_NOTICES.md +6 -2
- package/bin/kirby-ocpp.js +77 -0
- package/package.json +23 -44
- package/dist/cli.d.ts +0 -2
- package/dist/cli.js +0 -72
- package/dist/config.d.ts +0 -2
- package/dist/config.js +0 -53
- package/dist/ocpp/client.d.ts +0 -59
- package/dist/ocpp/client.js +0 -299
- package/dist/ocpp/schema-validator.d.ts +0 -15
- package/dist/ocpp/schema-validator.js +0 -75
- package/dist/ocpp/schemas/json/Authorize.json +0 -16
- package/dist/ocpp/schemas/json/AuthorizeResponse.json +0 -40
- package/dist/ocpp/schemas/json/BootNotification.json +0 -49
- package/dist/ocpp/schemas/json/BootNotificationResponse.json +0 -30
- package/dist/ocpp/schemas/json/CancelReservation.json +0 -15
- package/dist/ocpp/schemas/json/CancelReservationResponse.json +0 -20
- package/dist/ocpp/schemas/json/ChangeAvailability.json +0 -24
- package/dist/ocpp/schemas/json/ChangeAvailabilityResponse.json +0 -21
- package/dist/ocpp/schemas/json/ChangeConfiguration.json +0 -21
- package/dist/ocpp/schemas/json/ChangeConfigurationResponse.json +0 -22
- package/dist/ocpp/schemas/json/ClearCache.json +0 -8
- package/dist/ocpp/schemas/json/ClearCacheResponse.json +0 -20
- package/dist/ocpp/schemas/json/ClearChargingProfile.json +0 -27
- package/dist/ocpp/schemas/json/ClearChargingProfileResponse.json +0 -20
- package/dist/ocpp/schemas/json/DataTransfer.json +0 -23
- package/dist/ocpp/schemas/json/DataTransferResponse.json +0 -25
- package/dist/ocpp/schemas/json/DiagnosticsStatusNotification.json +0 -22
- package/dist/ocpp/schemas/json/DiagnosticsStatusNotificationResponse.json +0 -8
- package/dist/ocpp/schemas/json/FirmwareStatusNotification.json +0 -25
- package/dist/ocpp/schemas/json/FirmwareStatusNotificationResponse.json +0 -8
- package/dist/ocpp/schemas/json/GetCompositeSchedule.json +0 -27
- package/dist/ocpp/schemas/json/GetCompositeScheduleResponse.json +0 -79
- package/dist/ocpp/schemas/json/GetConfiguration.json +0 -16
- package/dist/ocpp/schemas/json/GetConfigurationResponse.json +0 -40
- package/dist/ocpp/schemas/json/GetDiagnostics.json +0 -30
- package/dist/ocpp/schemas/json/GetDiagnosticsResponse.json +0 -13
- package/dist/ocpp/schemas/json/GetLocalListVersion.json +0 -8
- package/dist/ocpp/schemas/json/GetLocalListVersionResponse.json +0 -15
- package/dist/ocpp/schemas/json/Heartbeat.json +0 -8
- package/dist/ocpp/schemas/json/HeartbeatResponse.json +0 -16
- package/dist/ocpp/schemas/json/MeterValues.json +0 -151
- package/dist/ocpp/schemas/json/MeterValuesResponse.json +0 -8
- package/dist/ocpp/schemas/json/RemoteStartTransaction.json +0 -127
- package/dist/ocpp/schemas/json/RemoteStartTransactionResponse.json +0 -20
- package/dist/ocpp/schemas/json/RemoteStopTransaction.json +0 -15
- package/dist/ocpp/schemas/json/RemoteStopTransactionResponse.json +0 -20
- package/dist/ocpp/schemas/json/ReserveNow.json +0 -33
- package/dist/ocpp/schemas/json/ReserveNowResponse.json +0 -23
- package/dist/ocpp/schemas/json/Reset.json +0 -20
- package/dist/ocpp/schemas/json/ResetResponse.json +0 -20
- package/dist/ocpp/schemas/json/SendLocalList.json +0 -68
- package/dist/ocpp/schemas/json/SendLocalListResponse.json +0 -22
- package/dist/ocpp/schemas/json/SetChargingProfile.json +0 -124
- package/dist/ocpp/schemas/json/SetChargingProfileResponse.json +0 -21
- package/dist/ocpp/schemas/json/StartTransaction.json +0 -32
- package/dist/ocpp/schemas/json/StartTransactionResponse.json +0 -44
- package/dist/ocpp/schemas/json/StatusNotification.json +0 -70
- package/dist/ocpp/schemas/json/StatusNotificationResponse.json +0 -8
- package/dist/ocpp/schemas/json/StopTransaction.json +0 -177
- package/dist/ocpp/schemas/json/StopTransactionResponse.json +0 -37
- package/dist/ocpp/schemas/json/TriggerMessage.json +0 -27
- package/dist/ocpp/schemas/json/TriggerMessageResponse.json +0 -21
- package/dist/ocpp/schemas/json/UnlockConnector.json +0 -15
- package/dist/ocpp/schemas/json/UnlockConnectorResponse.json +0 -21
- package/dist/ocpp/schemas/json/UpdateFirmware.json +0 -27
- package/dist/ocpp/schemas/json/UpdateFirmwareResponse.json +0 -8
- package/dist/ocpp/types.d.ts +0 -106
- package/dist/ocpp/types.js +0 -1
- package/dist/station/authorization.d.ts +0 -20
- package/dist/station/authorization.js +0 -78
- package/dist/station/charging-profile-registry.d.ts +0 -18
- package/dist/station/charging-profile-registry.js +0 -125
- package/dist/station/configuration-commands.d.ts +0 -11
- package/dist/station/configuration-commands.js +0 -29
- package/dist/station/configuration-registry.d.ts +0 -13
- package/dist/station/configuration-registry.js +0 -39
- package/dist/station/configuration.d.ts +0 -7
- package/dist/station/configuration.js +0 -88
- package/dist/station/connector-registry.d.ts +0 -25
- package/dist/station/connector-registry.js +0 -89
- package/dist/station/connector-status.d.ts +0 -7
- package/dist/station/connector-status.js +0 -66
- package/dist/station/local-auth-list.d.ts +0 -8
- package/dist/station/local-auth-list.js +0 -31
- package/dist/station/maintenance-lifecycle.d.ts +0 -25
- package/dist/station/maintenance-lifecycle.js +0 -110
- package/dist/station/meter-value-scheduler.d.ts +0 -21
- package/dist/station/meter-value-scheduler.js +0 -78
- package/dist/station/metering.d.ts +0 -15
- package/dist/station/metering.js +0 -138
- package/dist/station/ocpp-message.d.ts +0 -2
- package/dist/station/ocpp-message.js +0 -9
- package/dist/station/offline-transaction-sync.d.ts +0 -29
- package/dist/station/offline-transaction-sync.js +0 -99
- package/dist/station/payload.d.ts +0 -4
- package/dist/station/payload.js +0 -12
- package/dist/station/persistence.d.ts +0 -28
- package/dist/station/persistence.js +0 -206
- package/dist/station/reservation-rules.d.ts +0 -3
- package/dist/station/reservation-rules.js +0 -18
- package/dist/station/reservation-scheduler.d.ts +0 -11
- package/dist/station/reservation-scheduler.js +0 -33
- package/dist/station/smart-charging.d.ts +0 -45
- package/dist/station/smart-charging.js +0 -251
- package/dist/station/status-scheduler.d.ts +0 -16
- package/dist/station/status-scheduler.js +0 -58
- package/dist/station/transaction-message-retry.d.ts +0 -3
- package/dist/station/transaction-message-retry.js +0 -7
- package/dist/station/transaction-rules.d.ts +0 -7
- package/dist/station/transaction-rules.js +0 -34
- package/dist/station/trigger-message.d.ts +0 -2
- package/dist/station/trigger-message.js +0 -11
- package/dist/station-store.d.ts +0 -41
- package/dist/station-store.js +0 -104
- package/dist/station.d.ts +0 -113
- package/dist/station.js +0 -1204
- package/dist/tui.d.ts +0 -96
- package/dist/tui.js +0 -1656
- package/docs/OCPP_1.6J_CONFORMANCE.md +0 -61
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
# OCPP 1.6J conformance matrix
|
|
2
|
-
|
|
3
|
-
This matrix tracks emulator coverage against the OCPP 1.6J JSON schemas bundled in `src/ocpp/schemas/json`.
|
|
4
|
-
The bundled JSON schemas are sourced from the official OCPP 1.6J archive and are treated as the conformance baseline for schema validation.
|
|
5
|
-
|
|
6
|
-
Legend:
|
|
7
|
-
|
|
8
|
-
- `schema`: request and response payloads are validated against the official JSON schema.
|
|
9
|
-
- `handler`: the emulator has behavior for the action.
|
|
10
|
-
- `smoke`: covered by `npm run smoke`.
|
|
11
|
-
- `manual`: exposed through the TUI or public `Station` API for interactive testing.
|
|
12
|
-
- `partial`: implemented for common testing scenarios, but not yet exhaustive against the prose specification.
|
|
13
|
-
|
|
14
|
-
`npm run smoke` also covers representative edge/negative CSMS command responses, including unknown connectors, readonly/unknown configuration keys, unknown charging profiles, stale local auth list versions, local auth differential delete/restore/duplicate handling, SendLocalList `NotSupported`/`Failed` behavior, malformed local auth list schema errors, disabled local auth list/cache behavior, parent/expired/concurrent idTagInfo handling, remote-start authorization rejection, remote-start TxProfile handling, unknown reservations/transactions, unknown vendors, reservation Occupied/Unavailable/Faulted statuses, TriggerMessage connector-specific routing/rejection, schema-level CALLERROR responses for malformed/unknown commands, transaction-message retry for StartTransaction/StopTransaction/MeterValues on CALLERROR and timeout, disconnect during pending StartTransaction without creating a phantom transaction, offline StartTransaction/StopTransaction synchronization after reconnect, automatic reconnect/reboot after disconnect, active-transaction reconnect continuity, BootNotification Pending retry, MaxEnergyOnInvalidId delayed stop, and Reset with active transaction/reservation cleanup plus ResetRetries reboot retry.
|
|
15
|
-
`npm test` covers WebSocket protocol validation, pending-call timeout/disconnect rejection, ping/pong watchdog behavior, local `wss://` TLS success/failure behavior, CA/server-name validation, mTLS client certificate options, station reconnect after unexpected WebSocket close, and max reconnect attempt limiting.
|
|
16
|
-
|
|
17
|
-
## Charge Point to Central System
|
|
18
|
-
|
|
19
|
-
| Action | Schema | Handler | Smoke | Manual | Notes |
|
|
20
|
-
| --- | --- | --- | --- | --- | --- |
|
|
21
|
-
| Authorize | yes | yes | yes | yes | Online + local list/cache/offline behavior, offline transaction start/stop synchronization, cache disable behavior, LocalAuthListEnabled, LocalPreAuthorize blocking, parentIdTag preservation, expired/blocked/concurrent idTagInfo rejection, immediate invalid-id transaction stop, and MaxEnergyOnInvalidId delayed stop. |
|
|
22
|
-
| BootNotification | yes | yes | yes | yes | Accepted handling, Pending retry by response interval, and reset-specific rejected retry coverage. |
|
|
23
|
-
| DataTransfer | yes | yes | yes | yes | Vendor-specific payloads are free-form. |
|
|
24
|
-
| DiagnosticsStatusNotification | yes | yes | yes | yes | Simulates upload lifecycle with success, UploadFailed, and retry attempts. |
|
|
25
|
-
| FirmwareStatusNotification | yes | yes | yes | yes | Simulates download/install lifecycle with success, DownloadFailed, InstallationFailed, and retry attempts. |
|
|
26
|
-
| Heartbeat | yes | yes | yes | yes | Updates last heartbeat timestamp. |
|
|
27
|
-
| MeterValues | yes | yes | yes | yes | Supports configurable sampled measurands, periodic/clock-aligned sampling, and transaction-message retry settings with CALLERROR/timeout smoke coverage. |
|
|
28
|
-
| StartTransaction | yes | yes | yes | yes | Handles reservation consumption, rejected idTagInfo statuses, and transaction-message retry settings with CALLERROR/timeout smoke coverage. |
|
|
29
|
-
| StatusNotification | yes | yes | yes | yes | Includes fault metadata, honors MinimumStatusDuration for rapid status changes, and suppresses duplicate status spam. |
|
|
30
|
-
| StopTransaction | yes | yes | yes | yes | Uses configurable StopTxnSampledData/StopTxnAlignedData, honors StopTransactionOnEVSideDisconnect, uses transaction-message retry settings with CALLERROR/timeout smoke coverage, and restores active transaction state after final delivery failure. |
|
|
31
|
-
|
|
32
|
-
## Central System to Charge Point
|
|
33
|
-
|
|
34
|
-
| Action | Schema | Handler | Smoke | Notes |
|
|
35
|
-
| --- | --- | --- | --- | --- |
|
|
36
|
-
| CancelReservation | yes | yes | yes | Accepts known reservation, rejects unknown. |
|
|
37
|
-
| ChangeAvailability | yes | yes | yes | Supports connector `0`, mixed immediate/scheduled changes, and applies scheduled `Inoperative` after transaction end. |
|
|
38
|
-
| ChangeConfiguration | yes | yes | yes | Core keys seeded with type validation for common boolean/integer/list values. |
|
|
39
|
-
| ClearCache | yes | yes | yes | Clears authorization cache. |
|
|
40
|
-
| ClearChargingProfile | yes | partial | yes | Supports id, connectorId, purpose, and stackLevel filters, including unknown-profile response coverage. |
|
|
41
|
-
| DataTransfer | yes | yes | yes | Accepts emulator vendor, rejects unknown vendor. |
|
|
42
|
-
| GetCompositeSchedule | yes | partial | yes | Applies purpose/stack priority, same-stack latest-profile tie behavior, ChargePointMaxProfile limiting, TxProfile lifecycle, expired/future validity windows including activation inside requested duration, multi-period schedules, daily/weekly and long recurring schedules, unit-specific profile selection without A/W conversion, `numberPhases`, `minChargingRate`, and relative TxProfile timing for common cases. |
|
|
43
|
-
| GetConfiguration | yes | yes | yes | Returns known/unknown keys. |
|
|
44
|
-
| GetDiagnostics | yes | partial | yes | Simulates upload lifecycle, retries, and failure outcome; no real file upload. |
|
|
45
|
-
| GetLocalListVersion | yes | yes | yes | Persistent local list version. |
|
|
46
|
-
| RemoteStartTransaction | yes | yes | yes | Supports connector selection, optional authorization, rejected Authorize response, and remote-start TxProfile application. |
|
|
47
|
-
| RemoteStopTransaction | yes | yes | yes | Stops known transaction. |
|
|
48
|
-
| ReserveNow | yes | yes | yes | Handles expiry, occupied/unavailable/faulted statuses with smoke coverage. |
|
|
49
|
-
| Reset | yes | partial | yes | Stops active transactions with SoftReset/HardReset reason, clears reservations, cancels maintenance timers, reboots with BootNotification, and honors ResetRetries for rejected reboot registration. |
|
|
50
|
-
| SendLocalList | yes | yes | yes | Full/differential list persistence, version mismatch, differential delete, duplicate idTag overwrite, parent/expiry idTagInfo behavior, malformed-list CALLERROR, `NotSupported` when LocalAuthListEnabled=false, and `Failed` over SendLocalListMaxLength. |
|
|
51
|
-
| SetChargingProfile | yes | partial | yes | Stores profiles, replaces duplicate profile ids, rejects invalid connector, inactive TxProfile, and wrong-transaction TxProfile cases, supports common absolute/recurring/relative multi-period schedule fields, unit-specific profiles, `numberPhases`, and `minChargingRate`. |
|
|
52
|
-
| TriggerMessage | yes | yes | yes | Supports Boot, Diagnostics, Firmware, Heartbeat, MeterValues, Status; connector-specific MeterValues/StatusNotification and unknown connector rejection are smoke-covered. |
|
|
53
|
-
| UnlockConnector | yes | yes | yes | Stops active transaction with `UnlockCommand`. |
|
|
54
|
-
| UpdateFirmware | yes | partial | yes | Simulates download/install lifecycle, retries, and failure outcomes; no real firmware download. |
|
|
55
|
-
|
|
56
|
-
## Next gaps
|
|
57
|
-
|
|
58
|
-
- More station-level resume tests for non-transaction command behavior during reconnect windows.
|
|
59
|
-
- More Smart Charging edge cases around ambiguous vendor-specific tie policies and long recurring schedules.
|
|
60
|
-
- Expand edge/negative conformance tests toward full per-command response-status matrices.
|
|
61
|
-
- More WebSocket failure-mode tests around handshake errors mixed with reconnect/backoff.
|