@usex/mikrotik-mcp 3.50.0 → 3.50.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/dist/cli.js CHANGED
@@ -89,7 +89,7 @@ import {
89
89
  toggleAaaEntity,
90
90
  updateAaaEntity,
91
91
  writeBackup
92
- } from "./shared/cli-z6dyvbeb.js";
92
+ } from "./shared/cli-peg82een.js";
93
93
 
94
94
  // src/cli.ts
95
95
  import { existsSync as existsSync2 } from "fs";
@@ -1143,7 +1143,7 @@ function computeStats(events, opts) {
1143
1143
  // package.json
1144
1144
  var package_default = {
1145
1145
  name: "@usex/mikrotik-mcp",
1146
- version: "3.50.0",
1146
+ version: "3.50.1",
1147
1147
  description: "MCP server for MikroTik RouterOS \u2014 660+ tools over SSH for firewall, NAT, routing, DHCP, DNS, WireGuard, wireless, QoS and more.",
1148
1148
  keywords: [
1149
1149
  "ai",
package/dist/index.js CHANGED
@@ -21,7 +21,7 @@ import {
21
21
  resolveDeviceName,
22
22
  selectToolModules,
23
23
  setConfig
24
- } from "./shared/library-bpa5fz2e.js";
24
+ } from "./shared/library-08y4g75d.js";
25
25
  // src/server.ts
26
26
  import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
27
27
  import { ListToolsRequestSchema } from "@modelcontextprotocol/sdk/types.js";
@@ -131,7 +131,7 @@ function registerPrompts(server) {
131
131
  // package.json
132
132
  var package_default = {
133
133
  name: "@usex/mikrotik-mcp",
134
- version: "3.50.0",
134
+ version: "3.50.1",
135
135
  description: "MCP server for MikroTik RouterOS \u2014 660+ tools over SSH for firewall, NAT, routing, DHCP, DNS, WireGuard, wireless, QoS and more.",
136
136
  keywords: [
137
137
  "ai",
@@ -6321,7 +6321,7 @@ var cache = null;
6321
6321
  async function gateway() {
6322
6322
  if (cache)
6323
6323
  return cache;
6324
- const { moduleCatalog } = await import("./cli-p080cnxa.js");
6324
+ const { moduleCatalog } = await import("./cli-qw5z207n.js");
6325
6325
  const forIndex = [];
6326
6326
  const byName = new Map;
6327
6327
  for (const mod of moduleCatalog) {
@@ -25029,18 +25029,24 @@ ${details}`;
25029
25029
  },
25030
25030
  async handler(a, ctx) {
25031
25031
  ctx.info("Listing Wi-Fi regulatory countries");
25032
- const interfaceType = await detectWirelessInterfaceType(ctx);
25033
- if (!interfaceType)
25034
- return "Error: No wireless interface support detected on this device.";
25035
- const cmd = a.search ? `${interfaceType} country print where name~${quoteValue(a.search)}` : `${interfaceType} country print`;
25036
- const result = await executeMikrotikCommand(cmd, ctx);
25037
- if (looksLikeError(result))
25038
- return `Failed to list Wi-Fi countries: ${result}`;
25039
- if (isEmpty(result))
25040
- return `No countries found${a.search ? ` matching "${a.search}".` : "."}`;
25041
- return `WI-FI REGULATORY COUNTRIES:
25032
+ const countryPaths = [
25033
+ "/interface wireless",
25034
+ "/interface wifi",
25035
+ "/interface wifiwave2",
25036
+ "/interface wlan"
25037
+ ];
25038
+ const filter = a.search ? ` where name~${quoteValue(a.search)}` : "";
25039
+ for (const path of countryPaths) {
25040
+ const result = await executeMikrotikCommand(`${path} country print${filter}`, ctx);
25041
+ if (result && !commandUnsupported2(result) && !looksLikeError(result)) {
25042
+ if (isEmpty(result))
25043
+ continue;
25044
+ return `WI-FI REGULATORY COUNTRIES:
25042
25045
 
25043
25046
  ${result}`;
25047
+ }
25048
+ }
25049
+ return `No countries found${a.search ? ` matching "${a.search}"` : ""} \u2014 ` + "the device may not expose a country list under any known wireless path.";
25044
25050
  }
25045
25051
  })
25046
25052
  ];
@@ -4,7 +4,7 @@ import {
4
4
  allToolModules,
5
5
  moduleCatalog,
6
6
  selectToolModules
7
- } from "./cli-z6dyvbeb.js";
7
+ } from "./cli-peg82een.js";
8
8
  export {
9
9
  selectToolModules,
10
10
  moduleCatalog,
@@ -6262,7 +6262,7 @@ var cache = null;
6262
6262
  async function gateway() {
6263
6263
  if (cache)
6264
6264
  return cache;
6265
- const { moduleCatalog } = await import("./library-5yx3nvtf.js");
6265
+ const { moduleCatalog } = await import("./library-8nc9j4aa.js");
6266
6266
  const forIndex = [];
6267
6267
  const byName = new Map;
6268
6268
  for (const mod of moduleCatalog) {
@@ -24970,18 +24970,24 @@ ${details}`;
24970
24970
  },
24971
24971
  async handler(a, ctx) {
24972
24972
  ctx.info("Listing Wi-Fi regulatory countries");
24973
- const interfaceType = await detectWirelessInterfaceType(ctx);
24974
- if (!interfaceType)
24975
- return "Error: No wireless interface support detected on this device.";
24976
- const cmd = a.search ? `${interfaceType} country print where name~${quoteValue(a.search)}` : `${interfaceType} country print`;
24977
- const result = await executeMikrotikCommand(cmd, ctx);
24978
- if (looksLikeError(result))
24979
- return `Failed to list Wi-Fi countries: ${result}`;
24980
- if (isEmpty(result))
24981
- return `No countries found${a.search ? ` matching "${a.search}".` : "."}`;
24982
- return `WI-FI REGULATORY COUNTRIES:
24973
+ const countryPaths = [
24974
+ "/interface wireless",
24975
+ "/interface wifi",
24976
+ "/interface wifiwave2",
24977
+ "/interface wlan"
24978
+ ];
24979
+ const filter = a.search ? ` where name~${quoteValue(a.search)}` : "";
24980
+ for (const path of countryPaths) {
24981
+ const result = await executeMikrotikCommand(`${path} country print${filter}`, ctx);
24982
+ if (result && !commandUnsupported2(result) && !looksLikeError(result)) {
24983
+ if (isEmpty(result))
24984
+ continue;
24985
+ return `WI-FI REGULATORY COUNTRIES:
24983
24986
 
24984
24987
  ${result}`;
24988
+ }
24989
+ }
24990
+ return `No countries found${a.search ? ` matching "${a.search}"` : ""} \u2014 ` + "the device may not expose a country list under any known wireless path.";
24985
24991
  }
24986
24992
  })
24987
24993
  ];
@@ -4,7 +4,7 @@ import {
4
4
  allToolModules,
5
5
  moduleCatalog,
6
6
  selectToolModules
7
- } from "./library-bpa5fz2e.js";
7
+ } from "./library-08y4g75d.js";
8
8
  export {
9
9
  selectToolModules,
10
10
  moduleCatalog,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@usex/mikrotik-mcp",
3
- "version": "3.50.0",
3
+ "version": "3.50.1",
4
4
  "description": "MCP server for MikroTik RouterOS — 660+ tools over SSH for firewall, NAT, routing, DHCP, DNS, WireGuard, wireless, QoS and more.",
5
5
  "keywords": [
6
6
  "ai",