@chkp/policy-insights-mcp 0.3.5 → 0.3.8

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/index.js CHANGED
@@ -1,8 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  var __defProp = Object.defineProperty;
3
3
  var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __esm = (fn, res) => function __init() {
5
- return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
4
+ var __esm = (fn, res, err) => function __init() {
5
+ if (err) throw err[0];
6
+ try {
7
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
8
+ } catch (e) {
9
+ throw err = [e], e;
10
+ }
6
11
  };
7
12
  var __export = (target, all) => {
8
13
  for (var name in all)
@@ -2476,10 +2481,17 @@ var APIManagerBase = class {
2476
2481
  * Call an API endpoint
2477
2482
  */
2478
2483
  async callApi(method, uri, data, domain) {
2484
+ return (await this.callApiWithStatus(method, uri, data, domain)).response;
2485
+ }
2486
+ /**
2487
+ * Call an API endpoint and return both the HTTP status code and the response body.
2488
+ * Used by callers that need to track the underlying HTTP status (e.g. management-write).
2489
+ */
2490
+ async callApiWithStatus(method, uri, data, domain) {
2479
2491
  const sanitizedData = sanitizeData(data);
2480
2492
  const apiClient = domain && !data["domains-to-process"] ? await this.getDomainApiClientByDomain(domain) : this.client;
2481
2493
  const clientResponse = await apiClient.callApi(method, uri, sanitizedData, void 0);
2482
- return clientResponse.response;
2494
+ return { status: clientResponse.status, response: clientResponse.response };
2483
2495
  }
2484
2496
  /**
2485
2497
  * Get the result of a management API task (similar to getTaskResult but for management tasks)
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chkp/policy-insights-mcp",
3
- "version": "0.3.5",
3
+ "version": "0.3.8",
4
4
  "bin": {
5
5
  "policy-insights-mcp": "dist/index.js"
6
6
  },
@@ -27,14 +27,14 @@
27
27
  "dependencies": {
28
28
  "@chkp/mcp-utils": "*",
29
29
  "@chkp/quantum-infra": "*",
30
- "@modelcontextprotocol/sdk": "^1.26.0",
31
- "axios": "^1.13.5",
32
- "commander": "^13.1.0",
30
+ "@modelcontextprotocol/sdk": "^1.29.0",
31
+ "axios": "^1.16.0",
32
+ "commander": "^14.0.3",
33
33
  "node-machine-id": "^1.1.12",
34
34
  "zod": "^3.22.4"
35
35
  },
36
36
  "devDependencies": {
37
- "@types/node": "^22.15.2",
37
+ "@types/node": "^26.0.0",
38
38
  "@typescript-eslint/eslint-plugin": "^8.38.0",
39
39
  "@typescript-eslint/parser": "^8.38.0",
40
40
  "eslint": "^8.57.0",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chkp/policy-insights-mcp",
3
- "version": "0.3.5",
3
+ "version": "0.3.8",
4
4
  "bin": {
5
5
  "policy-insights-mcp": "dist/index.js"
6
6
  },
@@ -25,14 +25,14 @@
25
25
  "postpack": "node ../../scripts/strip-bundled-deps.js restore"
26
26
  },
27
27
  "dependencies": {
28
- "@modelcontextprotocol/sdk": "^1.26.0",
29
- "commander": "^13.1.0",
30
- "axios": "^1.13.5",
28
+ "@modelcontextprotocol/sdk": "^1.29.0",
29
+ "commander": "^14.0.3",
30
+ "axios": "^1.16.0",
31
31
  "node-machine-id": "^1.1.12",
32
32
  "zod": "^3.24.4"
33
33
  },
34
34
  "devDependencies": {
35
- "@types/node": "^22.15.2",
35
+ "@types/node": "^26.0.0",
36
36
  "@typescript-eslint/eslint-plugin": "^8.38.0",
37
37
  "@typescript-eslint/parser": "^8.38.0",
38
38
  "eslint": "^8.57.0",
package/package.json.bak CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chkp/policy-insights-mcp",
3
- "version": "0.3.5",
3
+ "version": "0.3.8",
4
4
  "bin": {
5
5
  "policy-insights-mcp": "dist/index.js"
6
6
  },
@@ -27,14 +27,14 @@
27
27
  "dependencies": {
28
28
  "@chkp/mcp-utils": "*",
29
29
  "@chkp/quantum-infra": "*",
30
- "@modelcontextprotocol/sdk": "^1.26.0",
31
- "commander": "^13.1.0",
32
- "axios": "^1.13.5",
30
+ "@modelcontextprotocol/sdk": "^1.29.0",
31
+ "commander": "^14.0.3",
32
+ "axios": "^1.16.0",
33
33
  "node-machine-id": "^1.1.12",
34
34
  "zod": "^3.24.4"
35
35
  },
36
36
  "devDependencies": {
37
- "@types/node": "^22.15.2",
37
+ "@types/node": "^26.0.0",
38
38
  "@typescript-eslint/eslint-plugin": "^8.38.0",
39
39
  "@typescript-eslint/parser": "^8.38.0",
40
40
  "eslint": "^8.57.0",