n8n-nodes-arubaclearpass 1.1.7 → 1.1.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.
@@ -50,6 +50,10 @@ class ArubaClearPass {
50
50
  name: 'Platform Certificates',
51
51
  value: 'PlatformCertificates',
52
52
  },
53
+ {
54
+ name: 'Local Server Configuration',
55
+ value: 'LocalServerConfiguration',
56
+ },
53
57
  ],
54
58
  default: 'Identities',
55
59
  required: true,
@@ -161,6 +165,33 @@ class ArubaClearPass {
161
165
  required: true,
162
166
  description: 'Resource to consume',
163
167
  },
168
+ {
169
+ displayName: 'Resource',
170
+ name: 'resource',
171
+ type: 'options',
172
+ displayOptions: {
173
+ show: {
174
+ domain: ['LocalServerConfiguration'],
175
+ },
176
+ },
177
+ options: [
178
+ {
179
+ name: 'CPPM Version',
180
+ value: 'CppmVersion',
181
+ },
182
+ {
183
+ name: 'Server Configuration',
184
+ value: 'ServerConfiguration',
185
+ },
186
+ {
187
+ name: 'Server Version',
188
+ value: 'ServerVersion',
189
+ },
190
+ ],
191
+ default: 'ServerConfiguration',
192
+ required: true,
193
+ description: 'Resource to consume',
194
+ },
164
195
  // Import the properties from the descriptions
165
196
  ...require('./descriptions/Identities/Device.descriptions').deviceProperties,
166
197
  ...require('./descriptions/Identities/Endpoint.descriptions').endpointProperties,
@@ -178,6 +209,12 @@ class ArubaClearPass {
178
209
  .serverCertProperties,
179
210
  ...require('./descriptions/PlatformCertificates/SelfSignedCert.descriptions')
180
211
  .selfSignedCertProperties,
212
+ ...require('./descriptions/LocalServerConfiguration/CppmVersion.descriptions')
213
+ .cppmVersionProperties,
214
+ ...require('./descriptions/LocalServerConfiguration/ServerVersion.descriptions')
215
+ .serverVersionProperties,
216
+ ...require('./descriptions/LocalServerConfiguration/ServerConfiguration.descriptions')
217
+ .serverConfigurationProperties,
181
218
  ],
182
219
  };
183
220
  }
@@ -0,0 +1,4 @@
1
+ import { INodeProperties } from 'n8n-workflow';
2
+ export declare const cppmVersionOperations: INodeProperties;
3
+ export declare const cppmVersionFields: INodeProperties[];
4
+ export declare const cppmVersionProperties: INodeProperties[];
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.cppmVersionProperties = exports.cppmVersionFields = exports.cppmVersionOperations = void 0;
4
+ exports.cppmVersionOperations = {
5
+ displayName: 'Operation',
6
+ name: 'operation',
7
+ type: 'options',
8
+ displayOptions: {
9
+ show: {
10
+ domain: ['LocalServerConfiguration'],
11
+ resource: ['CppmVersion'],
12
+ },
13
+ },
14
+ options: [
15
+ {
16
+ name: 'Get',
17
+ value: 'get',
18
+ description: 'Get the ClearPass Policy Manager version information',
19
+ action: 'Get CPPM version',
20
+ },
21
+ ],
22
+ default: 'get',
23
+ };
24
+ exports.cppmVersionFields = [];
25
+ exports.cppmVersionProperties = [exports.cppmVersionOperations, ...exports.cppmVersionFields];
@@ -0,0 +1,4 @@
1
+ import { INodeProperties } from 'n8n-workflow';
2
+ export declare const serverConfigurationOperations: INodeProperties;
3
+ export declare const serverConfigurationFields: INodeProperties[];
4
+ export declare const serverConfigurationProperties: INodeProperties[];
@@ -0,0 +1,76 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.serverConfigurationProperties = exports.serverConfigurationFields = exports.serverConfigurationOperations = void 0;
4
+ exports.serverConfigurationOperations = {
5
+ displayName: 'Operation',
6
+ name: 'operation',
7
+ type: 'options',
8
+ displayOptions: {
9
+ show: {
10
+ domain: ['LocalServerConfiguration'],
11
+ resource: ['ServerConfiguration'],
12
+ },
13
+ },
14
+ options: [
15
+ {
16
+ name: 'Get',
17
+ value: 'get',
18
+ description: 'Get configuration for a specific server by UUID, "publisher", or "this"',
19
+ action: 'Get server configuration',
20
+ },
21
+ {
22
+ name: 'List',
23
+ value: 'list',
24
+ description: 'Get a list of all servers in the cluster with their configurations',
25
+ action: 'List server configurations',
26
+ },
27
+ {
28
+ name: 'Update',
29
+ value: 'update',
30
+ description: 'Update configuration of a specific server',
31
+ action: 'Update server configuration',
32
+ },
33
+ ],
34
+ default: 'list',
35
+ };
36
+ exports.serverConfigurationFields = [
37
+ // Server UUID for get and update operations
38
+ {
39
+ displayName: 'Server UUID',
40
+ name: 'serverUuid',
41
+ type: 'string',
42
+ required: true,
43
+ default: 'this',
44
+ displayOptions: {
45
+ show: {
46
+ domain: ['LocalServerConfiguration'],
47
+ resource: ['ServerConfiguration'],
48
+ operation: ['get', 'update'],
49
+ },
50
+ },
51
+ typeOptions: {
52
+ expressionsEnabled: true,
53
+ },
54
+ description: 'Server UUID, "publisher" (for the publisher node), or "this" (for the current node)',
55
+ hint: 'Use "this" for the current node, "publisher" for the publisher, or a full UUID from the List operation',
56
+ },
57
+ // Update fields
58
+ {
59
+ displayName: 'Insight Reporting Enabled',
60
+ name: 'is_insight_enabled',
61
+ type: 'boolean',
62
+ default: false,
63
+ displayOptions: {
64
+ show: {
65
+ domain: ['LocalServerConfiguration'],
66
+ resource: ['ServerConfiguration'],
67
+ operation: ['update'],
68
+ },
69
+ },
70
+ description: 'Whether to enable Insight reporting on this server',
71
+ },
72
+ ];
73
+ exports.serverConfigurationProperties = [
74
+ exports.serverConfigurationOperations,
75
+ ...exports.serverConfigurationFields,
76
+ ];
@@ -0,0 +1,4 @@
1
+ import { INodeProperties } from 'n8n-workflow';
2
+ export declare const serverVersionOperations: INodeProperties;
3
+ export declare const serverVersionFields: INodeProperties[];
4
+ export declare const serverVersionProperties: INodeProperties[];
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.serverVersionProperties = exports.serverVersionFields = exports.serverVersionOperations = void 0;
4
+ exports.serverVersionOperations = {
5
+ displayName: 'Operation',
6
+ name: 'operation',
7
+ type: 'options',
8
+ displayOptions: {
9
+ show: {
10
+ domain: ['LocalServerConfiguration'],
11
+ resource: ['ServerVersion'],
12
+ },
13
+ },
14
+ options: [
15
+ {
16
+ name: 'Get',
17
+ value: 'get',
18
+ description: 'Get version information for the ClearPass server',
19
+ action: 'Get server version',
20
+ },
21
+ ],
22
+ default: 'get',
23
+ };
24
+ exports.serverVersionFields = [];
25
+ exports.serverVersionProperties = [exports.serverVersionOperations, ...exports.serverVersionFields];
@@ -45,6 +45,9 @@ const enforcementProfileMethods = __importStar(require("../methods/EnforcementPr
45
45
  const serviceCertMethods = __importStar(require("../methods/PlatformCertificates/ServiceCert.methods"));
46
46
  const serverCertMethods = __importStar(require("../methods/PlatformCertificates/ServerCert.methods"));
47
47
  const selfSignedCertMethods = __importStar(require("../methods/PlatformCertificates/SelfSignedCert.methods"));
48
+ const cppmVersionMethods = __importStar(require("../methods/LocalServerConfiguration/CppmVersion.methods"));
49
+ const serverVersionMethods = __importStar(require("../methods/LocalServerConfiguration/ServerVersion.methods"));
50
+ const serverConfigurationMethods = __importStar(require("../methods/LocalServerConfiguration/ServerConfiguration.methods"));
48
51
  /**
49
52
  * Execute the appropriate operation based on user selection
50
53
  */
@@ -177,6 +180,19 @@ async function executeOperation() {
177
180
  create: selfSignedCertMethods.createSelfSignedCert,
178
181
  },
179
182
  },
183
+ LocalServerConfiguration: {
184
+ CppmVersion: {
185
+ get: cppmVersionMethods.getCppmVersion,
186
+ },
187
+ ServerVersion: {
188
+ get: serverVersionMethods.getServerVersion,
189
+ },
190
+ ServerConfiguration: {
191
+ list: serverConfigurationMethods.listServerConfigurations,
192
+ get: serverConfigurationMethods.getServerConfiguration,
193
+ update: serverConfigurationMethods.updateServerConfiguration,
194
+ },
195
+ },
180
196
  };
181
197
  if (!handlers[domain] || !handlers[domain][resource] || !handlers[domain][resource][operation]) {
182
198
  throw new Error(`The operation ${domain}.${resource}.${operation} is not supported!`);
@@ -0,0 +1,6 @@
1
+ import { IExecuteFunctions, INodeExecutionData } from 'n8n-workflow';
2
+ /**
3
+ * Get ClearPass Policy Manager version information
4
+ * GET /cppm-version
5
+ */
6
+ export declare function getCppmVersion(this: IExecuteFunctions): Promise<INodeExecutionData[]>;
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getCppmVersion = getCppmVersion;
4
+ // methods/LocalServerConfiguration/CppmVersion.methods.ts
5
+ const n8n_workflow_1 = require("n8n-workflow");
6
+ const apiRequest_1 = require("../../helpers/apiRequest");
7
+ const responseFormatter_1 = require("../../helpers/responseFormatter");
8
+ /**
9
+ * Get ClearPass Policy Manager version information
10
+ * GET /cppm-version
11
+ */
12
+ async function getCppmVersion() {
13
+ try {
14
+ const responseData = await apiRequest_1.apiRequest.call(this, 'GET', '/cppm-version');
15
+ return responseFormatter_1.formatResponse.call(this, responseData);
16
+ }
17
+ catch (error) {
18
+ const errorObject = {};
19
+ if (error instanceof Error) {
20
+ errorObject.message = error.message;
21
+ if (error.stack)
22
+ errorObject.stackTrace = error.stack;
23
+ }
24
+ else {
25
+ errorObject.message = 'Unknown error in getCppmVersion';
26
+ }
27
+ throw new n8n_workflow_1.NodeApiError(this.getNode(), errorObject);
28
+ }
29
+ }
@@ -0,0 +1,18 @@
1
+ import { IExecuteFunctions, INodeExecutionData } from 'n8n-workflow';
2
+ /**
3
+ * Get a list of all servers in the cluster
4
+ * GET /cluster/server
5
+ */
6
+ export declare function listServerConfigurations(this: IExecuteFunctions): Promise<INodeExecutionData[]>;
7
+ /**
8
+ * Get configuration for a specific server
9
+ * GET /cluster/server/{uuid}
10
+ * uuid can be a server UUID, "publisher", or "this"
11
+ */
12
+ export declare function getServerConfiguration(this: IExecuteFunctions): Promise<INodeExecutionData[]>;
13
+ /**
14
+ * Update configuration of a specific server
15
+ * PATCH /cluster/server/{uuid}
16
+ * uuid can be a server UUID, "publisher", or "this"
17
+ */
18
+ export declare function updateServerConfiguration(this: IExecuteFunctions): Promise<INodeExecutionData[]>;
@@ -0,0 +1,83 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.listServerConfigurations = listServerConfigurations;
4
+ exports.getServerConfiguration = getServerConfiguration;
5
+ exports.updateServerConfiguration = updateServerConfiguration;
6
+ // methods/LocalServerConfiguration/ServerConfiguration.methods.ts
7
+ const n8n_workflow_1 = require("n8n-workflow");
8
+ const apiRequest_1 = require("../../helpers/apiRequest");
9
+ const responseFormatter_1 = require("../../helpers/responseFormatter");
10
+ /**
11
+ * Get a list of all servers in the cluster
12
+ * GET /cluster/server
13
+ */
14
+ async function listServerConfigurations() {
15
+ try {
16
+ const responseData = await apiRequest_1.apiRequest.call(this, 'GET', '/cluster/server');
17
+ return responseFormatter_1.formatResponse.call(this, responseData);
18
+ }
19
+ catch (error) {
20
+ const errorObject = {};
21
+ if (error instanceof Error) {
22
+ errorObject.message = error.message;
23
+ if (error.stack)
24
+ errorObject.stackTrace = error.stack;
25
+ }
26
+ else {
27
+ errorObject.message = 'Unknown error in listServerConfigurations';
28
+ }
29
+ throw new n8n_workflow_1.NodeApiError(this.getNode(), errorObject);
30
+ }
31
+ }
32
+ /**
33
+ * Get configuration for a specific server
34
+ * GET /cluster/server/{uuid}
35
+ * uuid can be a server UUID, "publisher", or "this"
36
+ */
37
+ async function getServerConfiguration() {
38
+ try {
39
+ const serverUuid = this.getNodeParameter('serverUuid', 0);
40
+ const responseData = await apiRequest_1.apiRequest.call(this, 'GET', `/cluster/server/${encodeURIComponent(serverUuid)}`);
41
+ return responseFormatter_1.formatResponse.call(this, responseData);
42
+ }
43
+ catch (error) {
44
+ const errorObject = {};
45
+ if (error instanceof Error) {
46
+ errorObject.message = error.message;
47
+ if (error.stack)
48
+ errorObject.stackTrace = error.stack;
49
+ }
50
+ else {
51
+ errorObject.message = 'Unknown error in getServerConfiguration';
52
+ }
53
+ throw new n8n_workflow_1.NodeApiError(this.getNode(), errorObject);
54
+ }
55
+ }
56
+ /**
57
+ * Update configuration of a specific server
58
+ * PATCH /cluster/server/{uuid}
59
+ * uuid can be a server UUID, "publisher", or "this"
60
+ */
61
+ async function updateServerConfiguration() {
62
+ try {
63
+ const serverUuid = this.getNodeParameter('serverUuid', 0);
64
+ const isInsightEnabled = this.getNodeParameter('is_insight_enabled', 0);
65
+ const body = {
66
+ is_insight_enabled: isInsightEnabled,
67
+ };
68
+ const responseData = await apiRequest_1.apiRequest.call(this, 'PATCH', `/cluster/server/${encodeURIComponent(serverUuid)}`, body);
69
+ return responseFormatter_1.formatResponse.call(this, responseData);
70
+ }
71
+ catch (error) {
72
+ const errorObject = {};
73
+ if (error instanceof Error) {
74
+ errorObject.message = error.message;
75
+ if (error.stack)
76
+ errorObject.stackTrace = error.stack;
77
+ }
78
+ else {
79
+ errorObject.message = 'Unknown error in updateServerConfiguration';
80
+ }
81
+ throw new n8n_workflow_1.NodeApiError(this.getNode(), errorObject);
82
+ }
83
+ }
@@ -0,0 +1,6 @@
1
+ import { IExecuteFunctions, INodeExecutionData } from 'n8n-workflow';
2
+ /**
3
+ * Get server version information
4
+ * GET /server/version
5
+ */
6
+ export declare function getServerVersion(this: IExecuteFunctions): Promise<INodeExecutionData[]>;
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getServerVersion = getServerVersion;
4
+ // methods/LocalServerConfiguration/ServerVersion.methods.ts
5
+ const n8n_workflow_1 = require("n8n-workflow");
6
+ const apiRequest_1 = require("../../helpers/apiRequest");
7
+ const responseFormatter_1 = require("../../helpers/responseFormatter");
8
+ /**
9
+ * Get server version information
10
+ * GET /server/version
11
+ */
12
+ async function getServerVersion() {
13
+ try {
14
+ const responseData = await apiRequest_1.apiRequest.call(this, 'GET', '/server/version');
15
+ return responseFormatter_1.formatResponse.call(this, responseData);
16
+ }
17
+ catch (error) {
18
+ const errorObject = {};
19
+ if (error instanceof Error) {
20
+ errorObject.message = error.message;
21
+ if (error.stack)
22
+ errorObject.stackTrace = error.stack;
23
+ }
24
+ else {
25
+ errorObject.message = 'Unknown error in getServerVersion';
26
+ }
27
+ throw new n8n_workflow_1.NodeApiError(this.getNode(), errorObject);
28
+ }
29
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-arubaclearpass",
3
- "version": "1.1.7",
3
+ "version": "1.1.8",
4
4
  "description": "n8n community node for Aruba ClearPass API integration with comprehensive identity, policy, and enforcement profile management",
5
5
  "keywords": [
6
6
  "n8n-community-node-package",