@itentialopensource/adapter-efficientip_solidserver 0.3.4 → 0.4.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.
package/TAB2.md ADDED
@@ -0,0 +1,319 @@
1
+ # Efficient iP SOLIDserver
2
+
3
+ ## Table of Contents
4
+
5
+ - [Specific Adapter Information](#specific-adapter-information)
6
+ - [Authentication](#authentication)
7
+ - [Sample Properties](#sample-properties)
8
+ - [Swagger](#swagger)
9
+ - [Generic Adapter Information](#generic-adapter-information)
10
+
11
+ ## Specific Adapter Information
12
+ ### Authentication
13
+
14
+ This document will go through the steps for authenticating the Efficient iP SOLIDserver adapter with Basic Authentication. Properly configuring the properties for an adapter in IAP is critical for getting the adapter online. You can read more about adapter authentication <a href="https://docs.itential.com/opensource/docs/authentication" target="_blank">HERE</a>.
15
+
16
+ #### Basic Authentication
17
+ The Efficient iP SOLIDserver adapter requires Basic Authentication. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
18
+
19
+ STEPS
20
+ 1. Ensure you have access to a Efficient iP SOLIDserver server and that it is running
21
+ 2. Follow the steps in the README.md to import the adapter into IAP if you have not already done so
22
+ 3. Use the properties below for the ```properties.authentication``` field
23
+ ```json
24
+ "authentication": {
25
+ "auth_method": "basic user_password",
26
+ "username": "<username>",
27
+ "password": "<password>",
28
+ "token": "",
29
+ "token_timeout": 1800000,
30
+ "token_cache": "local",
31
+ "invalid_token_error": 401,
32
+ "auth_field": "header.headers.Authorization",
33
+ "auth_field_format": "Basic {b64}{username}:{password}{/b64}",
34
+ "auth_logging": false
35
+ }
36
+ ```
37
+ 4. Restart the adapter. If your properties were set correctly, the adapter should go online.
38
+
39
+ #### Troubleshooting
40
+ - Make sure you copied over the correct username and password.
41
+ - Turn on debug level logs for the adapter in IAP Admin Essentials.
42
+ - Turn on auth_logging for the adapter in IAP Admin Essentials (adapter properties).
43
+ - Investigate the logs - in particular:
44
+ - The FULL REQUEST log to make sure the proper headers are being sent with the request.
45
+ - The FULL BODY log to make sure the payload is accurate.
46
+ - The CALL RETURN log to see what the other system is telling us.
47
+ - Credentials should be ** masked ** by the adapter so make sure you verify the username and password - including that there are erroneous spaces at the front or end.
48
+ - Remember when you are done to turn auth_logging off as you do not want to log credentials.
49
+
50
+ ### Sample Properties
51
+
52
+ Sample Properties can be used to help you configure the adapter in the Itential Automation Platform. You will need to update connectivity information such as the host, port, protocol and credentials.
53
+
54
+ ```json
55
+ "properties": {
56
+ "host": "localhost",
57
+ "port": 443,
58
+ "choosepath": "",
59
+ "base_path": "/rest",
60
+ "version": "",
61
+ "cache_location": "none",
62
+ "encode_pathvars": true,
63
+ "encode_queryvars": true,
64
+ "save_metric": false,
65
+ "stub": true,
66
+ "protocol": "https",
67
+ "authentication": {
68
+ "auth_method": "basic user_password",
69
+ "username": "username",
70
+ "password": "password",
71
+ "token": "token",
72
+ "token_timeout": 600000,
73
+ "token_cache": "local",
74
+ "invalid_token_error": 401,
75
+ "auth_field": "header.headers.Authorization",
76
+ "auth_field_format": "Basic {b64}{username}:{password}{/b64}",
77
+ "auth_logging": false,
78
+ "client_id": "",
79
+ "client_secret": "",
80
+ "grant_type": "",
81
+ "sensitive": [],
82
+ "sso": {
83
+ "protocol": "",
84
+ "host": "",
85
+ "port": 0
86
+ },
87
+ "multiStepAuthCalls": [
88
+ {
89
+ "name": "",
90
+ "requestFields": {},
91
+ "responseFields": {},
92
+ "successfullResponseCode": 200
93
+ }
94
+ ]
95
+ },
96
+ "healthcheck": {
97
+ "type": "intermittent",
98
+ "frequency": 600000,
99
+ "query_object": {},
100
+ "addlHeaders": {}
101
+ },
102
+ "throttle": {
103
+ "throttle_enabled": false,
104
+ "number_pronghorns": 1,
105
+ "sync_async": "sync",
106
+ "max_in_queue": 1000,
107
+ "concurrent_max": 1,
108
+ "expire_timeout": 0,
109
+ "avg_runtime": 200,
110
+ "priorities": [
111
+ {
112
+ "value": 0,
113
+ "percent": 100
114
+ }
115
+ ]
116
+ },
117
+ "request": {
118
+ "number_redirects": 0,
119
+ "number_retries": 3,
120
+ "limit_retry_error": [
121
+ 0
122
+ ],
123
+ "failover_codes": [],
124
+ "attempt_timeout": 5000,
125
+ "global_request": {
126
+ "payload": {},
127
+ "uriOptions": {},
128
+ "addlHeaders": {},
129
+ "authData": {}
130
+ },
131
+ "healthcheck_on_timeout": true,
132
+ "return_raw": false,
133
+ "archiving": false,
134
+ "return_request": false
135
+ },
136
+ "proxy": {
137
+ "enabled": false,
138
+ "host": "",
139
+ "port": 1,
140
+ "protocol": "http",
141
+ "username": "",
142
+ "password": ""
143
+ },
144
+ "ssl": {
145
+ "ecdhCurve": "",
146
+ "enabled": false,
147
+ "accept_invalid_cert": false,
148
+ "ca_file": "",
149
+ "key_file": "",
150
+ "cert_file": "",
151
+ "secure_protocol": "",
152
+ "ciphers": ""
153
+ },
154
+ "mongo": {
155
+ "host": "",
156
+ "port": 0,
157
+ "database": "",
158
+ "username": "",
159
+ "password": "",
160
+ "replSet": "",
161
+ "db_ssl": {
162
+ "enabled": false,
163
+ "accept_invalid_cert": false,
164
+ "ca_file": "",
165
+ "key_file": "",
166
+ "cert_file": ""
167
+ }
168
+ },
169
+ "devicebroker": {
170
+ "enabled": false,
171
+ "getDevice": [
172
+ {
173
+ "path": "/not/mapped",
174
+ "method": "GET",
175
+ "query": {},
176
+ "body": {},
177
+ "headers": {},
178
+ "handleFailure": "ignore",
179
+ "requestFields": {
180
+ "insample": "{port}"
181
+ },
182
+ "responseDatakey": "",
183
+ "responseFields": {
184
+ "name": "{this}{||}{that}",
185
+ "ostype": "{osfield}",
186
+ "ostypePrefix": "meraki-",
187
+ "port": "{port}",
188
+ "ipaddress": "{ip_addr}",
189
+ "serial": "{serial}"
190
+ }
191
+ }
192
+ ],
193
+ "getDevicesFiltered": [
194
+ {
195
+ "path": "/not/mapped",
196
+ "method": "GET",
197
+ "pagination": {
198
+ "offsetVar": "",
199
+ "limitVar": "",
200
+ "incrementBy": "limit",
201
+ "requestLocation": "query"
202
+ },
203
+ "query": {},
204
+ "body": {},
205
+ "headers": {},
206
+ "handleFailure": "ignore",
207
+ "requestFields": {},
208
+ "responseDatakey": "",
209
+ "responseFields": {
210
+ "name": "{this}{||}{that}",
211
+ "ostype": "{osfield}",
212
+ "ostypePrefix": "meraki-",
213
+ "port": "{port}",
214
+ "ipaddress": "{ip_addr}",
215
+ "serial": "{serial}",
216
+ "id": "{myid}"
217
+ }
218
+ }
219
+ ],
220
+ "isAlive": [
221
+ {
222
+ "path": "/not/mapped/{devID}",
223
+ "method": "GET",
224
+ "query": {},
225
+ "body": {},
226
+ "headers": {},
227
+ "handleFailure": "ignore",
228
+ "requestFields": {
229
+ "devID": "{id}"
230
+ },
231
+ "responseDatakey": "",
232
+ "responseFields": {
233
+ "status": "return2xx",
234
+ "statusValue": "AD.200"
235
+ }
236
+ }
237
+ ],
238
+ "getConfig": [
239
+ {
240
+ "path": "/not/mapped/{devID}",
241
+ "method": "GET",
242
+ "query": {},
243
+ "body": {},
244
+ "headers": {},
245
+ "handleFailure": "ignore",
246
+ "requestFields": {
247
+ "devID": "{id}"
248
+ },
249
+ "responseDatakey": "",
250
+ "responseFields": {}
251
+ }
252
+ ],
253
+ "getCount": [
254
+ {
255
+ "path": "/not/mapped",
256
+ "method": "GET",
257
+ "query": {},
258
+ "body": {},
259
+ "headers": {},
260
+ "handleFailure": "ignore",
261
+ "requestFields": {},
262
+ "responseDatakey": "",
263
+ "responseFields": {}
264
+ }
265
+ ]
266
+ },
267
+ "cache": {
268
+ "enabled": false,
269
+ "entities": [
270
+ {
271
+ "entityType": "device",
272
+ "frequency": 3600,
273
+ "flushOnFail": false,
274
+ "limit": 10000,
275
+ "retryAttempts": 5,
276
+ "sort": true,
277
+ "populate": [
278
+ {
279
+ "path": "/not/mapped",
280
+ "method": "GET",
281
+ "pagination": {
282
+ "offsetVar": "",
283
+ "limitVar": "",
284
+ "incrementBy": "limit",
285
+ "requestLocation": "query"
286
+ },
287
+ "query": {},
288
+ "body": {},
289
+ "headers": {},
290
+ "handleFailure": "ignore",
291
+ "requestFields": {},
292
+ "responseDatakey": "",
293
+ "responseFields": {
294
+ "name": "{this}{||}{that}",
295
+ "ostype": "{osfield}",
296
+ "ostypePrefix": "meraki-",
297
+ "port": "{port}",
298
+ "ipaddress": "{ip_addr}",
299
+ "serial": "{serial}",
300
+ "id": "{myid}"
301
+ }
302
+ }
303
+ ],
304
+ "cachedTasks": [
305
+ {
306
+ "name": "",
307
+ "filterField": "",
308
+ "filterLoc": ""
309
+ }
310
+ ]
311
+ }
312
+ ]
313
+ }
314
+ }
315
+ ```
316
+ ### [Swagger](https://gitlab.com/itentialopensource/adapters/inventory/adapter-efficientip_solidserver/-/blob/master/report/adapter-openapi.json)
317
+
318
+ ## [Generic Adapter Information](https://gitlab.com/itentialopensource/adapters/inventory/adapter-efficientip_solidserver/-/blob/master/README.md)
319
+
package/metadata.json CHANGED
@@ -34,20 +34,37 @@
34
34
  "isDeprecated": false
35
35
  },
36
36
  "brokerSince": "",
37
+ "authMethods": [
38
+ {
39
+ "type": "Basic Auth",
40
+ "primary": true
41
+ }
42
+ ],
37
43
  "documentation": {
38
44
  "storeLink": "",
39
45
  "npmLink": "https://www.npmjs.com/package/@itentialopensource/adapter-efficientip_solidserver",
40
- "repoLink": "https://gitlab.com/itentialopensource/adapters/inventory/adapter-efficientip_solidserver",
46
+ "repoLink": "https://gitlab.com/itentialopensource/adapters/adapter-efficientip_solidserver",
41
47
  "docLink": "https://docs.itential.com/opensource/docs/efficient-ip-solidserver",
42
48
  "demoLinks": [],
43
- "trainingLinks": [],
49
+ "trainingLinks": [
50
+ {
51
+ "title": "Itential Academy",
52
+ "link": "https://www.itential.com/itential-academy/"
53
+ }
54
+ ],
44
55
  "faqLink": "https://docs.itential.com/opensource/docs/troubleshooting-an-adapter",
45
56
  "contributeLink": "https://gitlab.com/itentialopensource/adapters/contributing-guide",
46
57
  "issueLink": "https://itential.atlassian.net/servicedesk/customer/portals",
47
58
  "webLink": "https://www.itential.com/adapters/efficient-ip-solidserver/",
48
- "vendorLink": "",
49
- "productLink": "",
50
- "apiLinks": []
59
+ "vendorLink": "https://efficientip.com/",
60
+ "productLink": "https://efficientip.com/products/solidserver-ddi/",
61
+ "apiLinks": [
62
+ {
63
+ "title": "API documents for Efficientip Solidserver",
64
+ "link": "https://efficientip.com/blog/getting-started-with-solidserver-rest-apis/",
65
+ "public": true
66
+ }
67
+ ]
51
68
  },
52
69
  "assets": [],
53
70
  "relatedItems": {
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@itentialopensource/adapter-efficientip_solidserver",
3
- "version": "0.3.4",
3
+ "version": "0.4.0",
4
4
  "description": "This adapter integrates with system described as: efficientip solidserver",
5
5
  "main": "adapter.js",
6
6
  "wizardVersion": "2.44.7",
7
- "engineVersion": "1.67.14",
7
+ "engineVersion": "1.67.19",
8
8
  "adapterType": "http",
9
9
  "scripts": {
10
10
  "artifactize": "npm i && node utils/packModificationScript.js",
@@ -15,7 +15,6 @@
15
15
  "test:baseunit": "mocha test/unit/adapterBaseTestUnit.js --LOG=error",
16
16
  "test:unit": "mocha test/unit/adapterTestUnit.js --LOG=error",
17
17
  "test:integration": "mocha test/integration/adapterTestIntegration.js --LOG=error",
18
- "test:cover": "nyc --reporter html --reporter text mocha --reporter dot test/*",
19
18
  "test": "npm run test:baseunit && npm run test:unit && npm run test:integration",
20
19
  "adapter:install": "npm i && node utils/tbScript.js install",
21
20
  "adapter:checkMigrate": "node utils/checkMigrate.js",
@@ -44,20 +43,20 @@
44
43
  ],
45
44
  "license": "Apache-2.0",
46
45
  "engines": {
47
- "node": ">= 8.0.0",
46
+ "node": ">= 14.0.0",
48
47
  "npm": ">= 6.0.0"
49
48
  },
50
49
  "repository": {
51
50
  "type": "git",
52
- "url": "git@gitlab.com:itentialopensource/adapters/inventory/adapter-efficientip_solidserver.git"
51
+ "url": "git@gitlab.com:itentialopensource/adapters/adapter-efficientip_solidserver.git"
53
52
  },
54
53
  "author": "Itential",
55
- "homepage": "https://gitlab.com/itentialopensource/adapters/inventory/adapter-efficientip_solidserver#readme",
54
+ "homepage": "https://gitlab.com/itentialopensource/adapters/adapter-efficientip_solidserver#readme",
56
55
  "dependencies": {
57
- "@itentialopensource/adapter-utils": "^5.3.8",
56
+ "@itentialopensource/adapter-utils": "^5.3.10",
58
57
  "acorn": "^8.10.0",
59
58
  "ajv": "^8.12.0",
60
- "axios": "^1.6.7",
59
+ "axios": "^1.6.8",
61
60
  "commander": "^11.0.0",
62
61
  "dns-lookup-promise": "^1.0.4",
63
62
  "fs-extra": "^11.1.1",
@@ -65,7 +64,6 @@
65
64
  "mocha": "^10.3.0",
66
65
  "mocha-param": "^2.0.1",
67
66
  "mongodb": "^4.16.0",
68
- "nyc": "^15.1.0",
69
67
  "ping": "^0.4.4",
70
68
  "prompts": "^2.4.2",
71
69
  "readline-sync": "^1.4.10",
@@ -945,6 +945,11 @@
945
945
  "devicebroker": {
946
946
  "type": "object",
947
947
  "properties": {
948
+ "enabled": {
949
+ "type": "boolean",
950
+ "description": "Whether or not the device broker calls have been mapped",
951
+ "default": false
952
+ },
948
953
  "getDevice": {
949
954
  "type": "array",
950
955
  "description": "Broker call(s) to getDevice",
Binary file
@@ -1,10 +1,10 @@
1
1
  {
2
- "version": "0.2.0",
3
- "configLines": 41128,
2
+ "version": "0.3.5",
3
+ "configLines": 41133,
4
4
  "scriptLines": 1783,
5
5
  "codeLines": 19147,
6
- "testLines": 12875,
6
+ "testLines": 12874,
7
7
  "testCases": 579,
8
- "totalCodeLines": 33805,
8
+ "totalCodeLines": 33804,
9
9
  "wfTasks": 241
10
10
  }
@@ -0,0 +1,120 @@
1
+ {
2
+ "errors": [],
3
+ "statistics": [
4
+ {
5
+ "owner": "errorJson",
6
+ "description": "New adapter errors available for use",
7
+ "value": 0
8
+ },
9
+ {
10
+ "owner": "errorJson",
11
+ "description": "Adapter errors no longer available for use",
12
+ "value": 0
13
+ },
14
+ {
15
+ "owner": "errorJson",
16
+ "description": "Adapter errors that have been updated (e.g. recommendation changes)",
17
+ "value": 31
18
+ },
19
+ {
20
+ "owner": "packageJson",
21
+ "description": "Number of production dependencies",
22
+ "value": 16
23
+ },
24
+ {
25
+ "owner": "packageJson",
26
+ "description": "Number of development dependencies",
27
+ "value": 6
28
+ },
29
+ {
30
+ "owner": "packageJson",
31
+ "description": "Number of npm scripts",
32
+ "value": 21
33
+ },
34
+ {
35
+ "owner": "packageJson",
36
+ "description": "Runtime Library dependency",
37
+ "value": "^5.3.10"
38
+ },
39
+ {
40
+ "owner": "propertiesSchemaJson",
41
+ "description": "Adapter properties defined in the propertiesSchema file",
42
+ "value": 78
43
+ },
44
+ {
45
+ "owner": "markdown",
46
+ "description": "Number of lines in the README.md",
47
+ "value": 344
48
+ },
49
+ {
50
+ "owner": "markdown",
51
+ "description": "Number of lines in the SUMMARY.md",
52
+ "value": 9
53
+ },
54
+ {
55
+ "owner": "markdown",
56
+ "description": "Number of lines in the PROPERTIES.md",
57
+ "value": 647
58
+ },
59
+ {
60
+ "owner": "markdown",
61
+ "description": "Number of lines in the TROUBLESHOOT.md",
62
+ "value": 48
63
+ },
64
+ {
65
+ "owner": "markdown",
66
+ "description": "Number of lines in the ENHANCE.md",
67
+ "value": 70
68
+ },
69
+ {
70
+ "owner": "markdown",
71
+ "description": "Number of lines in the BROKER.md",
72
+ "value": 70
73
+ },
74
+ {
75
+ "owner": "unitTestJS",
76
+ "description": "Number of lines of code in unit tests",
77
+ "value": 4099
78
+ },
79
+ {
80
+ "owner": "unitTestJS",
81
+ "description": "Number of unit tests",
82
+ "value": 284
83
+ },
84
+ {
85
+ "owner": "integrationTestJS",
86
+ "description": "Number of lines of code in integration tests",
87
+ "value": 7523
88
+ },
89
+ {
90
+ "owner": "integrationTestJS",
91
+ "description": "Number of integration tests",
92
+ "value": 225
93
+ },
94
+ {
95
+ "owner": "staticFile",
96
+ "description": "Number of lines of code in adapterBase.js",
97
+ "value": 1453
98
+ },
99
+ {
100
+ "owner": "staticFile",
101
+ "description": "Number of static files added",
102
+ "value": 36
103
+ },
104
+ {
105
+ "owner": "Overall",
106
+ "description": "Total lines of Code",
107
+ "value": 13075
108
+ },
109
+ {
110
+ "owner": "Overall",
111
+ "description": "Total Tests",
112
+ "value": 509
113
+ },
114
+ {
115
+ "owner": "Overall",
116
+ "description": "Total Files",
117
+ "value": 6
118
+ }
119
+ ]
120
+ }