@ocpp-debugkit/cli 0.1.0 → 0.1.1
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/README.md +69 -0
- package/package.json +4 -4
package/README.md
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# @ocpp-debugkit/cli
|
|
2
|
+
|
|
3
|
+
> Command-line interface for OCPP DebugKit — inspect traces, generate reports, run scenarios.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install -g @ocpp-debugkit/cli
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Commands
|
|
12
|
+
|
|
13
|
+
### inspect
|
|
14
|
+
|
|
15
|
+
Parse and analyze an OCPP trace file:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
ocpp-debugkit inspect trace.json
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Outputs event count, sessions, detected failures, and parse warnings.
|
|
22
|
+
|
|
23
|
+
### report
|
|
24
|
+
|
|
25
|
+
Generate a Markdown report:
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
# To stdout
|
|
29
|
+
ocpp-debugkit report trace.json
|
|
30
|
+
|
|
31
|
+
# To a file
|
|
32
|
+
ocpp-debugkit report trace.json --output report.md
|
|
33
|
+
|
|
34
|
+
# Specify format
|
|
35
|
+
ocpp-debugkit report trace.json --format markdown
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
### scenario list
|
|
39
|
+
|
|
40
|
+
List all available built-in scenarios:
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
ocpp-debugkit scenario list
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### scenario run
|
|
47
|
+
|
|
48
|
+
Run a scenario through the analysis engine and compare detected vs expected failures:
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
ocpp-debugkit scenario run failed-auth
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
**Note:** `scenario run` runs static fixtures through the local analysis engine only. It is not active endpoint testing, WebSocket simulation, or live station/CSMS testing.
|
|
55
|
+
|
|
56
|
+
## Accepted Trace Formats
|
|
57
|
+
|
|
58
|
+
- **JSON Object** — `{ "metadata": {...}, "events": [...] }`
|
|
59
|
+
- **JSONL** — one event per line
|
|
60
|
+
- **Bare array** — `[[2, "id", "Action", {}], ...]`
|
|
61
|
+
|
|
62
|
+
## Limits
|
|
63
|
+
|
|
64
|
+
- Maximum input size: 10 MB
|
|
65
|
+
- Maximum event count: 10,000
|
|
66
|
+
|
|
67
|
+
## License
|
|
68
|
+
|
|
69
|
+
Apache 2.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ocpp-debugkit/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "Command-line interface for OCPP DebugKit — inspect traces, generate reports, run scenarios.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -33,9 +33,9 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"commander": "^13.0.0",
|
|
36
|
-
"@ocpp-debugkit/core": "0.1.
|
|
37
|
-
"@ocpp-debugkit/scenarios": "0.1.
|
|
38
|
-
"@ocpp-debugkit/reporter": "0.1.
|
|
36
|
+
"@ocpp-debugkit/core": "0.1.1",
|
|
37
|
+
"@ocpp-debugkit/scenarios": "0.1.1",
|
|
38
|
+
"@ocpp-debugkit/reporter": "0.1.1"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"typescript": "^5.7.0",
|