@usex/mikrotik-mcp 5.18.0 → 5.20.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.
Files changed (76) hide show
  1. package/README.md +213 -5
  2. package/dist/cli.js +3242 -835
  3. package/dist/index.js +169 -28
  4. package/dist/shared/{cli-97csvm6f.js → cli-426pkqe9.js} +8 -0
  5. package/dist/shared/{library-552hdvw2.js → library-73y8qdjr.js} +2619 -537
  6. package/dist/shared/{library-xbg1d52n.js → library-76naf20r.js} +1 -1
  7. package/dist/shared/{library-w5tyng4c.js → library-81amv3az.js} +1 -1
  8. package/dist/shared/{library-08g0pwc9.js → library-krajvnj9.js} +1 -1
  9. package/dist/shared/{library-gmx9pzx3.js → library-y9tt30y1.js} +11 -1
  10. package/dist/ui/aaa.html +8 -8
  11. package/dist/ui/connected-devices.html +8 -8
  12. package/dist/ui/dashboard.html +16 -16
  13. package/dist/ui/fabric.html +11 -11
  14. package/dist/ui/firewall-audit.html +8 -8
  15. package/dist/ui/firewall.html +9 -9
  16. package/dist/ui/interfaces.html +8 -8
  17. package/dist/ui/investigations.html +11 -11
  18. package/dist/ui/observability.html +77 -75
  19. package/dist/ui/operations.html +11 -11
  20. package/dist/ui/records.html +12 -12
  21. package/dist/ui/reports.html +11 -11
  22. package/dist/ui/round-trip.html +11 -11
  23. package/dist/ui/service-health.html +11 -11
  24. package/package.json +22 -22
  25. package/prompts/audit-routeros-containers.md +27 -0
  26. package/prompts/audit-vlan-segmentation.md +31 -0
  27. package/prompts/setup-guest-wifi.md +23 -24
  28. package/prompts/setup-routeros-container.md +36 -0
  29. package/prompts/setup-v2ray-container-proxy.md +68 -194
  30. package/prompts/setup-vlan-network.md +27 -33
  31. package/schemas/README.md +1 -1
  32. package/schemas/devtools-manifest.json +358 -16
  33. package/schemas/tool-catalog.json +1133 -144
  34. package/schemas/tools/add_container.json +42 -30
  35. package/schemas/tools/add_container_env.json +3 -4
  36. package/schemas/tools/add_container_mount.json +10 -4
  37. package/schemas/tools/apply_service_routing.json +23 -0
  38. package/schemas/tools/arm_service_routing.json +23 -0
  39. package/schemas/tools/configure_flight_recorder.json +30 -0
  40. package/schemas/tools/confirm_mcp_settings.json +19 -0
  41. package/schemas/tools/create_service_routing.json +78 -0
  42. package/schemas/tools/design_network_segment.json +22 -6
  43. package/schemas/tools/destroy_recovery_lab.json +18 -0
  44. package/schemas/tools/export_network_incident.json +14 -0
  45. package/schemas/tools/freeze_network_incident.json +14 -0
  46. package/schemas/tools/get_container.json +11 -4
  47. package/schemas/tools/get_flight_recorder.json +7 -0
  48. package/schemas/tools/get_mcp_settings.json +7 -0
  49. package/schemas/tools/get_mcp_settings_schema.json +7 -0
  50. package/schemas/tools/get_recovery_lab.json +7 -0
  51. package/schemas/tools/get_routeros_container_guide.json +22 -0
  52. package/schemas/tools/get_vlan_segmentation_guide.json +14 -0
  53. package/schemas/tools/list_container_envs.json +1 -1
  54. package/schemas/tools/list_container_mounts.json +7 -2
  55. package/schemas/tools/list_containers.json +2 -4
  56. package/schemas/tools/list_service_routing.json +7 -0
  57. package/schemas/tools/poll_recovery_lab.json +14 -0
  58. package/schemas/tools/prepare_recovery_lab.json +23 -0
  59. package/schemas/tools/preview_mcp_settings.json +94 -0
  60. package/schemas/tools/preview_service_routing.json +23 -0
  61. package/schemas/tools/probe_service_routing.json +14 -0
  62. package/schemas/tools/recovery_lab_inventory.json +7 -0
  63. package/schemas/tools/remove_container.json +11 -4
  64. package/schemas/tools/remove_container_env.json +7 -3
  65. package/schemas/tools/remove_container_mount.json +18 -2
  66. package/schemas/tools/rollback_mcp_settings.json +19 -0
  67. package/schemas/tools/service_routing_inventory.json +7 -0
  68. package/schemas/tools/set_container_config.json +4 -6
  69. package/schemas/tools/start_container.json +11 -4
  70. package/schemas/tools/start_recovery_lab.json +18 -0
  71. package/schemas/tools/stop_container.json +11 -4
  72. package/schemas/tools/update_container.json +46 -6
  73. package/schemas/tools/update_mcp_settings.json +110 -0
  74. /package/dist/shared/{cli-3zrj182m.js → cli-6wdstvdq.js} +0 -0
  75. /package/dist/shared/{cli-s423xk9v.js → cli-cvt06346.js} +0 -0
  76. /package/dist/shared/{cli-ff6yww2e.js → cli-z1kavk0z.js} +0 -0
@@ -0,0 +1,23 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "prepare_recovery_lab",
4
+ "type": "object",
5
+ "properties": {
6
+ "snapshotId": {
7
+ "type": "string",
8
+ "minLength": 1,
9
+ "maxLength": 100
10
+ },
11
+ "version": {
12
+ "type": "string",
13
+ "pattern": "^7\\.\\d+(?:\\.\\d+)?(?:beta\\d+|rc\\d+)?$"
14
+ },
15
+ "mode": {
16
+ "default": "restore",
17
+ "type": "string",
18
+ "enum": ["restore", "upgrade"]
19
+ }
20
+ },
21
+ "required": ["snapshotId", "version", "mode"],
22
+ "additionalProperties": false
23
+ }
@@ -0,0 +1,94 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "preview_mcp_settings",
4
+ "type": "object",
5
+ "properties": {
6
+ "changes": {
7
+ "type": "object",
8
+ "properties": {
9
+ "mcp": {
10
+ "type": "object",
11
+ "properties": {
12
+ "toolPageSize": {
13
+ "type": "integer",
14
+ "minimum": 0,
15
+ "maximum": 9007199254740991
16
+ },
17
+ "appViews": {
18
+ "type": "boolean"
19
+ },
20
+ "capabilityGating": {
21
+ "type": "string",
22
+ "enum": ["off", "annotate", "filter"]
23
+ }
24
+ },
25
+ "additionalProperties": false
26
+ },
27
+ "ssh": {
28
+ "type": "object",
29
+ "properties": {
30
+ "keepAlive": {
31
+ "type": "boolean"
32
+ },
33
+ "keepAliveInterval": {
34
+ "type": "integer",
35
+ "minimum": 0,
36
+ "maximum": 9007199254740991
37
+ },
38
+ "idleTimeout": {
39
+ "type": "integer",
40
+ "exclusiveMinimum": 0,
41
+ "maximum": 9007199254740991
42
+ }
43
+ },
44
+ "additionalProperties": false
45
+ },
46
+ "dashboard": {
47
+ "type": "object",
48
+ "properties": {
49
+ "maxEvents": {
50
+ "type": "integer",
51
+ "exclusiveMinimum": 0,
52
+ "maximum": 9007199254740991
53
+ },
54
+ "captureBody": {
55
+ "type": "boolean"
56
+ },
57
+ "redactInput": {
58
+ "description": "May enable redaction, never disable it.",
59
+ "type": "boolean",
60
+ "const": true
61
+ },
62
+ "maxBodyBytes": {
63
+ "type": "integer",
64
+ "minimum": 0,
65
+ "maximum": 9007199254740991
66
+ },
67
+ "feedLimit": {
68
+ "type": "integer",
69
+ "exclusiveMinimum": 0,
70
+ "maximum": 10000
71
+ }
72
+ },
73
+ "additionalProperties": false
74
+ },
75
+ "memory": {
76
+ "type": "object",
77
+ "properties": {
78
+ "enabled": {
79
+ "type": "boolean"
80
+ }
81
+ },
82
+ "additionalProperties": false
83
+ },
84
+ "disableUpdateCheck": {
85
+ "type": "boolean"
86
+ }
87
+ },
88
+ "additionalProperties": false,
89
+ "description": "Only the fields to change; omitted values are preserved."
90
+ }
91
+ },
92
+ "required": ["changes"],
93
+ "additionalProperties": false
94
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "preview_service_routing",
4
+ "type": "object",
5
+ "properties": {
6
+ "id": {
7
+ "type": "string",
8
+ "format": "uuid",
9
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
10
+ },
11
+ "table": {
12
+ "type": "string",
13
+ "minLength": 1,
14
+ "maxLength": 64
15
+ },
16
+ "remove": {
17
+ "default": false,
18
+ "type": "boolean"
19
+ }
20
+ },
21
+ "required": ["id", "table", "remove"],
22
+ "additionalProperties": false
23
+ }
@@ -0,0 +1,14 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "probe_service_routing",
4
+ "type": "object",
5
+ "properties": {
6
+ "id": {
7
+ "type": "string",
8
+ "format": "uuid",
9
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
10
+ }
11
+ },
12
+ "required": ["id"],
13
+ "additionalProperties": false
14
+ }
@@ -0,0 +1,7 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "recovery_lab_inventory",
4
+ "type": "object",
5
+ "properties": {},
6
+ "additionalProperties": false
7
+ }
@@ -3,13 +3,20 @@
3
3
  "title": "remove_container",
4
4
  "type": "object",
5
5
  "properties": {
6
+ "id": {
7
+ "description": "Stable .id from fresh discovery; never a row number",
8
+ "type": "string",
9
+ "pattern": "^\\*[\\da-fA-F]+$"
10
+ },
6
11
  "name": {
7
- "description": "Container name (set via add_container)",
8
- "type": "string"
12
+ "description": "Exact unique container name",
13
+ "type": "string",
14
+ "minLength": 1
9
15
  },
10
16
  "tag": {
11
- "description": "Image tag to match (e.g. 'pihole') if no name",
12
- "type": "string"
17
+ "description": "Exact unique image tag, not a regex; prefer id when images are shared",
18
+ "type": "string",
19
+ "minLength": 1
13
20
  }
14
21
  },
15
22
  "additionalProperties": false
@@ -3,15 +3,19 @@
3
3
  "title": "remove_container_env",
4
4
  "type": "object",
5
5
  "properties": {
6
+ "id": {
7
+ "description": "Stable .id from fresh discovery; never a row number",
8
+ "type": "string",
9
+ "pattern": "^\\*[\\da-fA-F]+$"
10
+ },
6
11
  "list": {
7
12
  "type": "string",
8
- "description": "Env-list (group) name"
13
+ "minLength": 1
9
14
  },
10
15
  "key": {
11
16
  "type": "string",
12
- "description": "Variable name to remove"
17
+ "minLength": 1
13
18
  }
14
19
  },
15
- "required": ["list", "key"],
16
20
  "additionalProperties": false
17
21
  }
@@ -3,11 +3,27 @@
3
3
  "title": "remove_container_mount",
4
4
  "type": "object",
5
5
  "properties": {
6
+ "id": {
7
+ "description": "Stable .id from fresh discovery; never a row number",
8
+ "type": "string",
9
+ "pattern": "^\\*[\\da-fA-F]+$"
10
+ },
11
+ "list": {
12
+ "type": "string",
13
+ "minLength": 1
14
+ },
6
15
  "name": {
7
16
  "type": "string",
8
- "description": "Mount name to remove"
17
+ "minLength": 1
18
+ },
19
+ "src": {
20
+ "type": "string",
21
+ "minLength": 1
22
+ },
23
+ "dst": {
24
+ "type": "string",
25
+ "minLength": 1
9
26
  }
10
27
  },
11
- "required": ["name"],
12
28
  "additionalProperties": false
13
29
  }
@@ -0,0 +1,19 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "rollback_mcp_settings",
4
+ "type": "object",
5
+ "properties": {
6
+ "pending_id": {
7
+ "type": "string",
8
+ "minLength": 1
9
+ },
10
+ "revision": {
11
+ "type": "string",
12
+ "minLength": 64,
13
+ "maxLength": 64,
14
+ "description": "Revision returned by update_mcp_settings or get_mcp_settings."
15
+ }
16
+ },
17
+ "required": ["pending_id", "revision"],
18
+ "additionalProperties": false
19
+ }
@@ -0,0 +1,7 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "service_routing_inventory",
4
+ "type": "object",
5
+ "properties": {},
6
+ "additionalProperties": false
7
+ }
@@ -4,27 +4,25 @@
4
4
  "type": "object",
5
5
  "properties": {
6
6
  "registry_url": {
7
- "description": "Image registry URL",
8
7
  "type": "string"
9
8
  },
10
9
  "tmpdir": {
11
- "description": "Pull/extract temp dir, e.g. 'disk1/pull'",
12
10
  "type": "string"
13
11
  },
14
12
  "layer_dir": {
15
- "description": "Directory for extracted image layers",
13
+ "type": "string"
14
+ },
15
+ "memory_high": {
16
16
  "type": "string"
17
17
  },
18
18
  "ram_high": {
19
- "description": "RAM-high limit, e.g. '256M'",
19
+ "description": "Deprecated alias of memory_high; never sent as ram-high",
20
20
  "type": "string"
21
21
  },
22
22
  "username": {
23
- "description": "Registry username (private registries)",
24
23
  "type": "string"
25
24
  },
26
25
  "password": {
27
- "description": "Registry password (private registries)",
28
26
  "type": "string"
29
27
  }
30
28
  },
@@ -3,13 +3,20 @@
3
3
  "title": "start_container",
4
4
  "type": "object",
5
5
  "properties": {
6
+ "id": {
7
+ "description": "Stable .id from fresh discovery; never a row number",
8
+ "type": "string",
9
+ "pattern": "^\\*[\\da-fA-F]+$"
10
+ },
6
11
  "name": {
7
- "description": "Container name (set via add_container)",
8
- "type": "string"
12
+ "description": "Exact unique container name",
13
+ "type": "string",
14
+ "minLength": 1
9
15
  },
10
16
  "tag": {
11
- "description": "Image tag to match (e.g. 'pihole') if no name",
12
- "type": "string"
17
+ "description": "Exact unique image tag, not a regex; prefer id when images are shared",
18
+ "type": "string",
19
+ "minLength": 1
13
20
  }
14
21
  },
15
22
  "additionalProperties": false
@@ -0,0 +1,18 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "start_recovery_lab",
4
+ "type": "object",
5
+ "properties": {
6
+ "id": {
7
+ "type": "string",
8
+ "format": "uuid",
9
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
10
+ },
11
+ "confirm": {
12
+ "default": false,
13
+ "type": "boolean"
14
+ }
15
+ },
16
+ "required": ["id", "confirm"],
17
+ "additionalProperties": false
18
+ }
@@ -3,13 +3,20 @@
3
3
  "title": "stop_container",
4
4
  "type": "object",
5
5
  "properties": {
6
+ "id": {
7
+ "description": "Stable .id from fresh discovery; never a row number",
8
+ "type": "string",
9
+ "pattern": "^\\*[\\da-fA-F]+$"
10
+ },
6
11
  "name": {
7
- "description": "Container name (set via add_container)",
8
- "type": "string"
12
+ "description": "Exact unique container name",
13
+ "type": "string",
14
+ "minLength": 1
9
15
  },
10
16
  "tag": {
11
- "description": "Image tag to match (e.g. 'pihole') if no name",
12
- "type": "string"
17
+ "description": "Exact unique image tag, not a regex; prefer id when images are shared",
18
+ "type": "string",
19
+ "minLength": 1
13
20
  }
14
21
  },
15
22
  "additionalProperties": false
@@ -3,36 +3,61 @@
3
3
  "title": "update_container",
4
4
  "type": "object",
5
5
  "properties": {
6
+ "id": {
7
+ "description": "Stable .id from fresh discovery; never a row number",
8
+ "type": "string",
9
+ "pattern": "^\\*[\\da-fA-F]+$"
10
+ },
6
11
  "name": {
7
- "description": "Container name (set via add_container)",
8
- "type": "string"
12
+ "description": "Exact unique container name",
13
+ "type": "string",
14
+ "minLength": 1
9
15
  },
10
16
  "tag": {
11
- "description": "Image tag to match (e.g. 'pihole') if no name",
12
- "type": "string"
17
+ "description": "Exact unique image tag, not a regex; prefer id when images are shared",
18
+ "type": "string",
19
+ "minLength": 1
13
20
  },
14
21
  "interface": {
15
- "type": "string"
22
+ "description": "VETH interface(s); verify target syntax and image interface names",
23
+ "type": "string",
24
+ "minLength": 1
16
25
  },
17
26
  "root_dir": {
18
- "type": "string"
27
+ "description": "Dedicated root path on appropriate storage, not internal flash",
28
+ "type": "string",
29
+ "minLength": 1
19
30
  },
20
31
  "env": {
32
+ "description": "Sensitive inline environment; verify support on the target",
21
33
  "type": "string"
22
34
  },
23
35
  "envlists": {
36
+ "description": "Current CLI named environment lists",
37
+ "type": "string"
38
+ },
39
+ "envlist": {
40
+ "description": "Legacy singular envlist; exclusive with envlists",
24
41
  "type": "string"
25
42
  },
26
43
  "mount": {
44
+ "description": "Inline mount expression supported by the target; not Docker syntax",
27
45
  "type": "string"
28
46
  },
29
47
  "mountlists": {
48
+ "description": "Current CLI named mount lists",
49
+ "type": "string"
50
+ },
51
+ "mounts": {
52
+ "description": "Legacy mounts reference; exclusive with mountlists",
30
53
  "type": "string"
31
54
  },
32
55
  "cmd": {
56
+ "description": "Command override; may contain secrets",
33
57
  "type": "string"
34
58
  },
35
59
  "entrypoint": {
60
+ "description": "Entrypoint override; may contain secrets",
36
61
  "type": "string"
37
62
  },
38
63
  "workdir": {
@@ -44,10 +69,25 @@
44
69
  "dns": {
45
70
  "type": "string"
46
71
  },
72
+ "user": {
73
+ "type": "string"
74
+ },
75
+ "stop_signal": {
76
+ "type": "string"
77
+ },
78
+ "devices": {
79
+ "description": "Device passthrough; extra privilege requires explicit review",
80
+ "type": "string"
81
+ },
47
82
  "cpu_list": {
48
83
  "type": "string"
49
84
  },
50
85
  "memory_high": {
86
+ "description": "Soft memory pressure threshold, not a hard cap",
87
+ "type": "string"
88
+ },
89
+ "memory_max": {
90
+ "description": "Hard memory limit only where supported; can terminate processes",
51
91
  "type": "string"
52
92
  },
53
93
  "logging": {
@@ -0,0 +1,110 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "update_mcp_settings",
4
+ "type": "object",
5
+ "properties": {
6
+ "changes": {
7
+ "type": "object",
8
+ "properties": {
9
+ "mcp": {
10
+ "type": "object",
11
+ "properties": {
12
+ "toolPageSize": {
13
+ "type": "integer",
14
+ "minimum": 0,
15
+ "maximum": 9007199254740991
16
+ },
17
+ "appViews": {
18
+ "type": "boolean"
19
+ },
20
+ "capabilityGating": {
21
+ "type": "string",
22
+ "enum": ["off", "annotate", "filter"]
23
+ }
24
+ },
25
+ "additionalProperties": false
26
+ },
27
+ "ssh": {
28
+ "type": "object",
29
+ "properties": {
30
+ "keepAlive": {
31
+ "type": "boolean"
32
+ },
33
+ "keepAliveInterval": {
34
+ "type": "integer",
35
+ "minimum": 0,
36
+ "maximum": 9007199254740991
37
+ },
38
+ "idleTimeout": {
39
+ "type": "integer",
40
+ "exclusiveMinimum": 0,
41
+ "maximum": 9007199254740991
42
+ }
43
+ },
44
+ "additionalProperties": false
45
+ },
46
+ "dashboard": {
47
+ "type": "object",
48
+ "properties": {
49
+ "maxEvents": {
50
+ "type": "integer",
51
+ "exclusiveMinimum": 0,
52
+ "maximum": 9007199254740991
53
+ },
54
+ "captureBody": {
55
+ "type": "boolean"
56
+ },
57
+ "redactInput": {
58
+ "description": "May enable redaction, never disable it.",
59
+ "type": "boolean",
60
+ "const": true
61
+ },
62
+ "maxBodyBytes": {
63
+ "type": "integer",
64
+ "minimum": 0,
65
+ "maximum": 9007199254740991
66
+ },
67
+ "feedLimit": {
68
+ "type": "integer",
69
+ "exclusiveMinimum": 0,
70
+ "maximum": 10000
71
+ }
72
+ },
73
+ "additionalProperties": false
74
+ },
75
+ "memory": {
76
+ "type": "object",
77
+ "properties": {
78
+ "enabled": {
79
+ "type": "boolean"
80
+ }
81
+ },
82
+ "additionalProperties": false
83
+ },
84
+ "disableUpdateCheck": {
85
+ "type": "boolean"
86
+ }
87
+ },
88
+ "additionalProperties": false
89
+ },
90
+ "revision": {
91
+ "type": "string",
92
+ "minLength": 64,
93
+ "maxLength": 64,
94
+ "description": "Current revision from get_mcp_settings or preview_mcp_settings."
95
+ },
96
+ "confirm": {
97
+ "type": "boolean",
98
+ "const": true,
99
+ "description": "Only set after the user authorizes these exact changes."
100
+ },
101
+ "rollback_seconds": {
102
+ "default": 60,
103
+ "type": "integer",
104
+ "minimum": 30,
105
+ "maximum": 600
106
+ }
107
+ },
108
+ "required": ["changes", "revision", "confirm", "rollback_seconds"],
109
+ "additionalProperties": false
110
+ }