@itentialopensource/adapter-easypost 0.1.1 → 0.3.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/AUTH.md +9 -14
- package/CALLS.md +60 -24
- package/CHANGELOG.md +16 -1
- package/CONTRIBUTING.md +1 -160
- package/ENHANCE.md +2 -2
- package/README.md +31 -22
- package/SYSTEMINFO.md +19 -6
- package/adapter.js +159 -330
- package/adapterBase.js +538 -873
- package/changelogs/CHANGELOG.md +9 -0
- package/metadata.json +55 -0
- package/package.json +22 -25
- package/pronghorn.json +484 -155
- package/propertiesSchema.json +453 -40
- package/refs?service=git-upload-pack +0 -0
- package/report/adapter-openapi.json +424 -0
- package/report/adapter-openapi.yaml +373 -0
- package/report/adapterInfo.json +8 -8
- package/report/updateReport1691508403162.json +120 -0
- package/report/updateReport1692202885261.json +120 -0
- package/report/updateReport1694464805959.json +120 -0
- package/report/updateReport1698421757641.json +120 -0
- package/sampleProperties.json +63 -2
- package/test/integration/adapterTestBasicGet.js +1 -1
- package/test/integration/adapterTestConnectivity.js +91 -42
- package/test/integration/adapterTestIntegration.js +130 -2
- package/test/unit/adapterBaseTestUnit.js +388 -313
- package/test/unit/adapterTestUnit.js +306 -109
- package/utils/adapterInfo.js +1 -1
- package/utils/addAuth.js +1 -1
- package/utils/artifactize.js +1 -1
- package/utils/checkMigrate.js +1 -1
- package/utils/entitiesToDB.js +1 -0
- package/utils/findPath.js +1 -1
- package/utils/methodDocumentor.js +71 -23
- package/utils/modify.js +13 -15
- package/utils/packModificationScript.js +1 -1
- package/utils/taskMover.js +309 -0
- package/utils/tbScript.js +3 -10
- package/utils/tbUtils.js +2 -3
- package/utils/testRunner.js +1 -1
- package/utils/troubleshootingAdapter.js +1 -3
- package/workflows/README.md +0 -3
package/propertiesSchema.json
CHANGED
|
@@ -18,6 +18,11 @@
|
|
|
18
18
|
"minimum": 1,
|
|
19
19
|
"maximum": 65535
|
|
20
20
|
},
|
|
21
|
+
"choosepath": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"description": "choose the path to use -- requires entityPath choices",
|
|
24
|
+
"default": ""
|
|
25
|
+
},
|
|
21
26
|
"base_path": {
|
|
22
27
|
"type": "string",
|
|
23
28
|
"description": "a base path that is consistent across api calls",
|
|
@@ -101,6 +106,17 @@
|
|
|
101
106
|
},
|
|
102
107
|
"devicebroker": {
|
|
103
108
|
"$ref": "#/definitions/devicebroker"
|
|
109
|
+
},
|
|
110
|
+
"cache": {
|
|
111
|
+
"$ref": "#/definitions/cache"
|
|
112
|
+
},
|
|
113
|
+
"service": {
|
|
114
|
+
"type": "string",
|
|
115
|
+
"description": "Service we are integrating with -- used with AWS Authentication",
|
|
116
|
+
"examples": [
|
|
117
|
+
"ec2",
|
|
118
|
+
"route53"
|
|
119
|
+
]
|
|
104
120
|
}
|
|
105
121
|
},
|
|
106
122
|
"required": [
|
|
@@ -122,7 +138,9 @@
|
|
|
122
138
|
"static_token",
|
|
123
139
|
"jwt_token",
|
|
124
140
|
"request_token",
|
|
125
|
-
"no_authentication"
|
|
141
|
+
"no_authentication",
|
|
142
|
+
"multi_step_authentication",
|
|
143
|
+
"aws_authentication"
|
|
126
144
|
]
|
|
127
145
|
},
|
|
128
146
|
"username": {
|
|
@@ -255,6 +273,74 @@
|
|
|
255
273
|
"type": "string",
|
|
256
274
|
"description": "The grant type for OAuth requests - can also provide in schema",
|
|
257
275
|
"default": ""
|
|
276
|
+
},
|
|
277
|
+
"sensitive": {
|
|
278
|
+
"type": "array",
|
|
279
|
+
"description": "List of sensitive keys to search and hide values from being logged",
|
|
280
|
+
"default": [],
|
|
281
|
+
"items": {
|
|
282
|
+
"type": "string"
|
|
283
|
+
}
|
|
284
|
+
},
|
|
285
|
+
"sso": {
|
|
286
|
+
"type": "object",
|
|
287
|
+
"properties": {
|
|
288
|
+
"protocol": {
|
|
289
|
+
"type": "string",
|
|
290
|
+
"description": "the protocol to request token from system",
|
|
291
|
+
"default": "",
|
|
292
|
+
"enum": [
|
|
293
|
+
"http",
|
|
294
|
+
"https",
|
|
295
|
+
""
|
|
296
|
+
]
|
|
297
|
+
},
|
|
298
|
+
"host": {
|
|
299
|
+
"type": "string",
|
|
300
|
+
"description": "hostname of the authentication system",
|
|
301
|
+
"default": "",
|
|
302
|
+
"examples": [
|
|
303
|
+
"systemx.customer.com"
|
|
304
|
+
]
|
|
305
|
+
},
|
|
306
|
+
"port": {
|
|
307
|
+
"type": "integer",
|
|
308
|
+
"description": "port on which to connect to the authentication system",
|
|
309
|
+
"default": 0,
|
|
310
|
+
"minimum": 0,
|
|
311
|
+
"maximum": 65535
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
"multiStepAuthCalls": {
|
|
316
|
+
"type": "array",
|
|
317
|
+
"items": {
|
|
318
|
+
"type": "object",
|
|
319
|
+
"properties": {
|
|
320
|
+
"name": {
|
|
321
|
+
"type": "string",
|
|
322
|
+
"description": "Id of the step call",
|
|
323
|
+
"examples": [
|
|
324
|
+
"getAccessToken"
|
|
325
|
+
]
|
|
326
|
+
},
|
|
327
|
+
"requestFields": {
|
|
328
|
+
"type": "object",
|
|
329
|
+
"description": "The fields set in step request"
|
|
330
|
+
},
|
|
331
|
+
"responseFields": {
|
|
332
|
+
"type": "object",
|
|
333
|
+
"description": "The fields from the step result"
|
|
334
|
+
},
|
|
335
|
+
"successfullResponseCode": {
|
|
336
|
+
"type": "integer",
|
|
337
|
+
"description": "Expected response code for given step, if not set any successfull http response is accepted",
|
|
338
|
+
"examples": [
|
|
339
|
+
200
|
|
340
|
+
]
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
}
|
|
258
344
|
}
|
|
259
345
|
},
|
|
260
346
|
"required": [
|
|
@@ -356,7 +442,13 @@
|
|
|
356
442
|
},
|
|
357
443
|
"query_object": {
|
|
358
444
|
"type": "object",
|
|
359
|
-
"description": "Query object { device: xxxxx } to be placed into the healthcheck, will be converted to query string by the adapter"
|
|
445
|
+
"description": "Query object { device: xxxxx } to be placed into the healthcheck, will be converted to query string by the adapter",
|
|
446
|
+
"default": {}
|
|
447
|
+
},
|
|
448
|
+
"addlHeaders": {
|
|
449
|
+
"type": "object",
|
|
450
|
+
"description": "headers that will be appended to the headers for the call",
|
|
451
|
+
"default": {}
|
|
360
452
|
}
|
|
361
453
|
},
|
|
362
454
|
"required": [
|
|
@@ -436,6 +528,7 @@
|
|
|
436
528
|
"priorities": {
|
|
437
529
|
"type": "array",
|
|
438
530
|
"description": "define your priorities here",
|
|
531
|
+
"default": [],
|
|
439
532
|
"items": {
|
|
440
533
|
"type": "object",
|
|
441
534
|
"properties": {
|
|
@@ -506,6 +599,7 @@
|
|
|
506
599
|
"failover_codes": {
|
|
507
600
|
"type": "array",
|
|
508
601
|
"description": "An array of codes where it is ok to try another method",
|
|
602
|
+
"default": [],
|
|
509
603
|
"items": {
|
|
510
604
|
"type": "integer"
|
|
511
605
|
}
|
|
@@ -523,19 +617,23 @@
|
|
|
523
617
|
"properties": {
|
|
524
618
|
"payload": {
|
|
525
619
|
"type": "object",
|
|
526
|
-
"description": "payload fields that will be appended to the provided payload (excluding GET calls)"
|
|
620
|
+
"description": "payload fields that will be appended to the provided payload (excluding GET calls)",
|
|
621
|
+
"default": {}
|
|
527
622
|
},
|
|
528
623
|
"uriOptions": {
|
|
529
624
|
"type": "object",
|
|
530
|
-
"description": "options that will be appended to all GET calls"
|
|
625
|
+
"description": "options that will be appended to all GET calls",
|
|
626
|
+
"default": {}
|
|
531
627
|
},
|
|
532
628
|
"addlHeaders": {
|
|
533
629
|
"type": "object",
|
|
534
|
-
"description": "headers that will be appended to the headers for the call"
|
|
630
|
+
"description": "headers that will be appended to the headers for the call",
|
|
631
|
+
"default": {}
|
|
535
632
|
},
|
|
536
633
|
"authData": {
|
|
537
634
|
"type": "object",
|
|
538
|
-
"description": "authentication data that will be appended to the payload for authentication calls"
|
|
635
|
+
"description": "authentication data that will be appended to the payload for authentication calls",
|
|
636
|
+
"default": {}
|
|
539
637
|
}
|
|
540
638
|
}
|
|
541
639
|
},
|
|
@@ -850,6 +948,7 @@
|
|
|
850
948
|
"type": "array",
|
|
851
949
|
"description": "Broker call(s) to getDevice",
|
|
852
950
|
"items": {
|
|
951
|
+
"type": "object",
|
|
853
952
|
"properties": {
|
|
854
953
|
"path": {
|
|
855
954
|
"type": "string",
|
|
@@ -865,26 +964,38 @@
|
|
|
865
964
|
"type": "object",
|
|
866
965
|
"description": "The json object with query parameters of the call to getDevice",
|
|
867
966
|
"additionalProperties": {
|
|
868
|
-
"type":
|
|
967
|
+
"type": [
|
|
968
|
+
"string",
|
|
969
|
+
"number"
|
|
970
|
+
]
|
|
869
971
|
}
|
|
870
972
|
},
|
|
871
973
|
"body": {
|
|
872
974
|
"type": "object",
|
|
873
975
|
"description": "The json object with body of the call to getDevice",
|
|
874
976
|
"additionalProperties": {
|
|
875
|
-
"type":
|
|
977
|
+
"type": [
|
|
978
|
+
"string",
|
|
979
|
+
"number"
|
|
980
|
+
]
|
|
876
981
|
}
|
|
877
982
|
},
|
|
878
983
|
"headers": {
|
|
879
984
|
"type": "object",
|
|
880
985
|
"description": "The json object with headers of the call to getDevice",
|
|
881
986
|
"additionalProperties": {
|
|
882
|
-
"type":
|
|
987
|
+
"type": [
|
|
988
|
+
"string",
|
|
989
|
+
"number"
|
|
990
|
+
]
|
|
883
991
|
}
|
|
884
992
|
},
|
|
885
993
|
"handleFailure": {
|
|
886
994
|
"type": "string",
|
|
887
|
-
"enum": [
|
|
995
|
+
"enum": [
|
|
996
|
+
"ignore",
|
|
997
|
+
"fail"
|
|
998
|
+
],
|
|
888
999
|
"description": "return failure or ignore failure",
|
|
889
1000
|
"default": "ignore"
|
|
890
1001
|
},
|
|
@@ -892,7 +1003,10 @@
|
|
|
892
1003
|
"type": "object",
|
|
893
1004
|
"description": "The json object with response fields of the call to getDevice",
|
|
894
1005
|
"additionalProperties": {
|
|
895
|
-
"type":
|
|
1006
|
+
"type": [
|
|
1007
|
+
"string",
|
|
1008
|
+
"number"
|
|
1009
|
+
]
|
|
896
1010
|
},
|
|
897
1011
|
"properties": {}
|
|
898
1012
|
},
|
|
@@ -905,7 +1019,10 @@
|
|
|
905
1019
|
"type": "object",
|
|
906
1020
|
"description": "The json object with response fields of the call to getDevice",
|
|
907
1021
|
"additionalProperties": {
|
|
908
|
-
"type":
|
|
1022
|
+
"type": [
|
|
1023
|
+
"string",
|
|
1024
|
+
"number"
|
|
1025
|
+
]
|
|
909
1026
|
},
|
|
910
1027
|
"properties": {
|
|
911
1028
|
"name": {
|
|
@@ -942,6 +1059,7 @@
|
|
|
942
1059
|
"type": "array",
|
|
943
1060
|
"description": "Broker call(s) to getDevicesFiltered",
|
|
944
1061
|
"items": {
|
|
1062
|
+
"type": "object",
|
|
945
1063
|
"properties": {
|
|
946
1064
|
"path": {
|
|
947
1065
|
"type": "string",
|
|
@@ -953,30 +1071,74 @@
|
|
|
953
1071
|
"description": "The method of the call to getDevicesFiltered",
|
|
954
1072
|
"default": "GET"
|
|
955
1073
|
},
|
|
1074
|
+
"pagination": {
|
|
1075
|
+
"type": "object",
|
|
1076
|
+
"description": "todo",
|
|
1077
|
+
"properties": {
|
|
1078
|
+
"offsetVar": {
|
|
1079
|
+
"type": "string",
|
|
1080
|
+
"description": "Name of variable that defines how to go to next set of results"
|
|
1081
|
+
},
|
|
1082
|
+
"limitVar": {
|
|
1083
|
+
"type": "string",
|
|
1084
|
+
"description": "Name of variable that defines the max results returned in a request"
|
|
1085
|
+
},
|
|
1086
|
+
"incrementBy": {
|
|
1087
|
+
"type": "string",
|
|
1088
|
+
"enum": [
|
|
1089
|
+
"limit",
|
|
1090
|
+
"page"
|
|
1091
|
+
],
|
|
1092
|
+
"description": "How to incremenet offset. Default limit",
|
|
1093
|
+
"default": "limit"
|
|
1094
|
+
},
|
|
1095
|
+
"requestLocation": {
|
|
1096
|
+
"type": "string",
|
|
1097
|
+
"enum": [
|
|
1098
|
+
"query",
|
|
1099
|
+
"body"
|
|
1100
|
+
],
|
|
1101
|
+
"description": "Where in request the pagination data goes",
|
|
1102
|
+
"default": "query"
|
|
1103
|
+
}
|
|
1104
|
+
}
|
|
1105
|
+
},
|
|
956
1106
|
"query": {
|
|
957
1107
|
"type": "object",
|
|
958
1108
|
"description": "The json object with query parameters of the call to getDevicesFiltered",
|
|
959
1109
|
"additionalProperties": {
|
|
960
|
-
"type":
|
|
1110
|
+
"type": [
|
|
1111
|
+
"string",
|
|
1112
|
+
"number"
|
|
1113
|
+
]
|
|
961
1114
|
}
|
|
962
1115
|
},
|
|
963
1116
|
"body": {
|
|
964
1117
|
"type": "object",
|
|
965
1118
|
"description": "The json object with body of the call to getDevicesFiltered",
|
|
966
1119
|
"additionalProperties": {
|
|
967
|
-
"type":
|
|
1120
|
+
"type": [
|
|
1121
|
+
"string",
|
|
1122
|
+
"number"
|
|
1123
|
+
]
|
|
968
1124
|
}
|
|
969
1125
|
},
|
|
970
1126
|
"headers": {
|
|
971
1127
|
"type": "object",
|
|
972
1128
|
"description": "The json object with headers of the call to getDevicesFiltered",
|
|
973
1129
|
"additionalProperties": {
|
|
974
|
-
"type":
|
|
1130
|
+
"type": [
|
|
1131
|
+
"string",
|
|
1132
|
+
"number"
|
|
1133
|
+
]
|
|
975
1134
|
}
|
|
976
1135
|
},
|
|
977
1136
|
"handleFailure": {
|
|
978
1137
|
"type": "string",
|
|
979
|
-
"enum": [
|
|
1138
|
+
"enum": [
|
|
1139
|
+
"ignore",
|
|
1140
|
+
"fail"
|
|
1141
|
+
],
|
|
980
1142
|
"description": "return failure or ignore failure",
|
|
981
1143
|
"default": "ignore"
|
|
982
1144
|
},
|
|
@@ -984,7 +1146,10 @@
|
|
|
984
1146
|
"type": "object",
|
|
985
1147
|
"description": "The json object with response fields of the call to getDevice",
|
|
986
1148
|
"additionalProperties": {
|
|
987
|
-
"type":
|
|
1149
|
+
"type": [
|
|
1150
|
+
"string",
|
|
1151
|
+
"number"
|
|
1152
|
+
]
|
|
988
1153
|
},
|
|
989
1154
|
"properties": {}
|
|
990
1155
|
},
|
|
@@ -997,7 +1162,10 @@
|
|
|
997
1162
|
"type": "object",
|
|
998
1163
|
"description": "The json object with response fields of the call to getDevicesFiltered",
|
|
999
1164
|
"additionalProperties": {
|
|
1000
|
-
"type":
|
|
1165
|
+
"type": [
|
|
1166
|
+
"string",
|
|
1167
|
+
"number"
|
|
1168
|
+
]
|
|
1001
1169
|
},
|
|
1002
1170
|
"properties": {
|
|
1003
1171
|
"name": {
|
|
@@ -1034,6 +1202,7 @@
|
|
|
1034
1202
|
"type": "array",
|
|
1035
1203
|
"description": "Broker call(s) to determine if the device isAlive",
|
|
1036
1204
|
"items": {
|
|
1205
|
+
"type": "object",
|
|
1037
1206
|
"properties": {
|
|
1038
1207
|
"path": {
|
|
1039
1208
|
"type": "string",
|
|
@@ -1049,26 +1218,38 @@
|
|
|
1049
1218
|
"type": "object",
|
|
1050
1219
|
"description": "The json object with query parameters of the call to isAlive",
|
|
1051
1220
|
"additionalProperties": {
|
|
1052
|
-
"type":
|
|
1221
|
+
"type": [
|
|
1222
|
+
"string",
|
|
1223
|
+
"number"
|
|
1224
|
+
]
|
|
1053
1225
|
}
|
|
1054
1226
|
},
|
|
1055
1227
|
"body": {
|
|
1056
1228
|
"type": "object",
|
|
1057
1229
|
"description": "The json object with body of the call to isAlive",
|
|
1058
1230
|
"additionalProperties": {
|
|
1059
|
-
"type":
|
|
1231
|
+
"type": [
|
|
1232
|
+
"string",
|
|
1233
|
+
"number"
|
|
1234
|
+
]
|
|
1060
1235
|
}
|
|
1061
1236
|
},
|
|
1062
1237
|
"headers": {
|
|
1063
1238
|
"type": "object",
|
|
1064
1239
|
"description": "The json object with headers of the call to isAlive",
|
|
1065
1240
|
"additionalProperties": {
|
|
1066
|
-
"type":
|
|
1241
|
+
"type": [
|
|
1242
|
+
"string",
|
|
1243
|
+
"number"
|
|
1244
|
+
]
|
|
1067
1245
|
}
|
|
1068
1246
|
},
|
|
1069
1247
|
"handleFailure": {
|
|
1070
1248
|
"type": "string",
|
|
1071
|
-
"enum": [
|
|
1249
|
+
"enum": [
|
|
1250
|
+
"ignore",
|
|
1251
|
+
"fail"
|
|
1252
|
+
],
|
|
1072
1253
|
"description": "return failure or ignore isAlive",
|
|
1073
1254
|
"default": "ignore"
|
|
1074
1255
|
},
|
|
@@ -1076,7 +1257,10 @@
|
|
|
1076
1257
|
"type": "object",
|
|
1077
1258
|
"description": "The json object with response fields of the call to getDevice",
|
|
1078
1259
|
"additionalProperties": {
|
|
1079
|
-
"type":
|
|
1260
|
+
"type": [
|
|
1261
|
+
"string",
|
|
1262
|
+
"number"
|
|
1263
|
+
]
|
|
1080
1264
|
},
|
|
1081
1265
|
"properties": {}
|
|
1082
1266
|
},
|
|
@@ -1089,7 +1273,10 @@
|
|
|
1089
1273
|
"type": "object",
|
|
1090
1274
|
"description": "The json object with response fields of the call to isAlive",
|
|
1091
1275
|
"additionalProperties": {
|
|
1092
|
-
"type":
|
|
1276
|
+
"type": [
|
|
1277
|
+
"string",
|
|
1278
|
+
"number"
|
|
1279
|
+
]
|
|
1093
1280
|
},
|
|
1094
1281
|
"properties": {
|
|
1095
1282
|
"status": {
|
|
@@ -1111,6 +1298,7 @@
|
|
|
1111
1298
|
"type": "array",
|
|
1112
1299
|
"description": "Broker call(s) to getConfig",
|
|
1113
1300
|
"items": {
|
|
1301
|
+
"type": "object",
|
|
1114
1302
|
"properties": {
|
|
1115
1303
|
"path": {
|
|
1116
1304
|
"type": "string",
|
|
@@ -1126,26 +1314,38 @@
|
|
|
1126
1314
|
"type": "object",
|
|
1127
1315
|
"description": "The json object with query parameters of the call to getConfig",
|
|
1128
1316
|
"additionalProperties": {
|
|
1129
|
-
"type":
|
|
1317
|
+
"type": [
|
|
1318
|
+
"string",
|
|
1319
|
+
"number"
|
|
1320
|
+
]
|
|
1130
1321
|
}
|
|
1131
1322
|
},
|
|
1132
1323
|
"body": {
|
|
1133
1324
|
"type": "object",
|
|
1134
1325
|
"description": "The json object with body of the call to getConfig",
|
|
1135
1326
|
"additionalProperties": {
|
|
1136
|
-
"type":
|
|
1327
|
+
"type": [
|
|
1328
|
+
"string",
|
|
1329
|
+
"number"
|
|
1330
|
+
]
|
|
1137
1331
|
}
|
|
1138
1332
|
},
|
|
1139
1333
|
"headers": {
|
|
1140
1334
|
"type": "object",
|
|
1141
1335
|
"description": "The json object with headers of the call to getConfig",
|
|
1142
1336
|
"additionalProperties": {
|
|
1143
|
-
"type":
|
|
1337
|
+
"type": [
|
|
1338
|
+
"string",
|
|
1339
|
+
"number"
|
|
1340
|
+
]
|
|
1144
1341
|
}
|
|
1145
1342
|
},
|
|
1146
1343
|
"handleFailure": {
|
|
1147
1344
|
"type": "string",
|
|
1148
|
-
"enum": [
|
|
1345
|
+
"enum": [
|
|
1346
|
+
"ignore",
|
|
1347
|
+
"fail"
|
|
1348
|
+
],
|
|
1149
1349
|
"description": "return failure or ignore getConfig",
|
|
1150
1350
|
"default": "ignore"
|
|
1151
1351
|
},
|
|
@@ -1153,7 +1353,10 @@
|
|
|
1153
1353
|
"type": "object",
|
|
1154
1354
|
"description": "The json object with response fields of the call to getDevice",
|
|
1155
1355
|
"additionalProperties": {
|
|
1156
|
-
"type":
|
|
1356
|
+
"type": [
|
|
1357
|
+
"string",
|
|
1358
|
+
"number"
|
|
1359
|
+
]
|
|
1157
1360
|
},
|
|
1158
1361
|
"properties": {}
|
|
1159
1362
|
},
|
|
@@ -1166,10 +1369,12 @@
|
|
|
1166
1369
|
"type": "object",
|
|
1167
1370
|
"description": "The json object with response fields of the call to getConfig",
|
|
1168
1371
|
"additionalProperties": {
|
|
1169
|
-
"type":
|
|
1372
|
+
"type": [
|
|
1373
|
+
"string",
|
|
1374
|
+
"number"
|
|
1375
|
+
]
|
|
1170
1376
|
},
|
|
1171
|
-
"properties": {
|
|
1172
|
-
}
|
|
1377
|
+
"properties": {}
|
|
1173
1378
|
}
|
|
1174
1379
|
}
|
|
1175
1380
|
}
|
|
@@ -1178,6 +1383,7 @@
|
|
|
1178
1383
|
"type": "array",
|
|
1179
1384
|
"description": "Broker call(s) to getCount",
|
|
1180
1385
|
"items": {
|
|
1386
|
+
"type": "object",
|
|
1181
1387
|
"properties": {
|
|
1182
1388
|
"path": {
|
|
1183
1389
|
"type": "string",
|
|
@@ -1193,26 +1399,38 @@
|
|
|
1193
1399
|
"type": "object",
|
|
1194
1400
|
"description": "The json object with query parameters of the call to getCount",
|
|
1195
1401
|
"additionalProperties": {
|
|
1196
|
-
"type":
|
|
1402
|
+
"type": [
|
|
1403
|
+
"string",
|
|
1404
|
+
"number"
|
|
1405
|
+
]
|
|
1197
1406
|
}
|
|
1198
1407
|
},
|
|
1199
1408
|
"body": {
|
|
1200
1409
|
"type": "object",
|
|
1201
1410
|
"description": "The json object with body of the call to getCount",
|
|
1202
1411
|
"additionalProperties": {
|
|
1203
|
-
"type":
|
|
1412
|
+
"type": [
|
|
1413
|
+
"string",
|
|
1414
|
+
"number"
|
|
1415
|
+
]
|
|
1204
1416
|
}
|
|
1205
1417
|
},
|
|
1206
1418
|
"headers": {
|
|
1207
1419
|
"type": "object",
|
|
1208
1420
|
"description": "The json object with headers of the call to getCount",
|
|
1209
1421
|
"additionalProperties": {
|
|
1210
|
-
"type":
|
|
1422
|
+
"type": [
|
|
1423
|
+
"string",
|
|
1424
|
+
"number"
|
|
1425
|
+
]
|
|
1211
1426
|
}
|
|
1212
1427
|
},
|
|
1213
1428
|
"handleFailure": {
|
|
1214
1429
|
"type": "string",
|
|
1215
|
-
"enum": [
|
|
1430
|
+
"enum": [
|
|
1431
|
+
"ignore",
|
|
1432
|
+
"fail"
|
|
1433
|
+
],
|
|
1216
1434
|
"description": "return failure or ignore getCount",
|
|
1217
1435
|
"default": "ignore"
|
|
1218
1436
|
},
|
|
@@ -1220,7 +1438,10 @@
|
|
|
1220
1438
|
"type": "object",
|
|
1221
1439
|
"description": "The json object with response fields of the call to getDevice",
|
|
1222
1440
|
"additionalProperties": {
|
|
1223
|
-
"type":
|
|
1441
|
+
"type": [
|
|
1442
|
+
"string",
|
|
1443
|
+
"number"
|
|
1444
|
+
]
|
|
1224
1445
|
},
|
|
1225
1446
|
"properties": {}
|
|
1226
1447
|
},
|
|
@@ -1233,9 +1454,201 @@
|
|
|
1233
1454
|
"type": "object",
|
|
1234
1455
|
"description": "The json object with response fields of the call to getConfig",
|
|
1235
1456
|
"additionalProperties": {
|
|
1236
|
-
"type":
|
|
1457
|
+
"type": [
|
|
1458
|
+
"string",
|
|
1459
|
+
"number"
|
|
1460
|
+
]
|
|
1237
1461
|
},
|
|
1238
|
-
"properties": {
|
|
1462
|
+
"properties": {}
|
|
1463
|
+
}
|
|
1464
|
+
}
|
|
1465
|
+
}
|
|
1466
|
+
}
|
|
1467
|
+
}
|
|
1468
|
+
},
|
|
1469
|
+
"cache": {
|
|
1470
|
+
"type": "object",
|
|
1471
|
+
"properties": {
|
|
1472
|
+
"enabled": {
|
|
1473
|
+
"type": "boolean",
|
|
1474
|
+
"description": "Whether or not cache is enabled for adapter",
|
|
1475
|
+
"default": false
|
|
1476
|
+
},
|
|
1477
|
+
"entities": {
|
|
1478
|
+
"type": "array",
|
|
1479
|
+
"description": "Information for the cached entities",
|
|
1480
|
+
"items": {
|
|
1481
|
+
"type": "object",
|
|
1482
|
+
"properties": {
|
|
1483
|
+
"entityType": {
|
|
1484
|
+
"type": "string",
|
|
1485
|
+
"description": "The name of the entity - should match adapter entity configuration or a broker (e.g. Device)",
|
|
1486
|
+
"default": ""
|
|
1487
|
+
},
|
|
1488
|
+
"frequency": {
|
|
1489
|
+
"type": "integer",
|
|
1490
|
+
"description": "how long (in minutes) we wait to re-populate the cache",
|
|
1491
|
+
"default": 1440,
|
|
1492
|
+
"maximum": 10080
|
|
1493
|
+
},
|
|
1494
|
+
"flushOnFail": {
|
|
1495
|
+
"type": "boolean",
|
|
1496
|
+
"description": "Whether to clear the cache we have if the populate failed",
|
|
1497
|
+
"default": false
|
|
1498
|
+
},
|
|
1499
|
+
"limit": {
|
|
1500
|
+
"type": "integer",
|
|
1501
|
+
"description": "maximum number of items to keep in cache",
|
|
1502
|
+
"default": 1000
|
|
1503
|
+
},
|
|
1504
|
+
"retryAttempts": {
|
|
1505
|
+
"type": "integer",
|
|
1506
|
+
"description": "number of times to retry the populate call before failure",
|
|
1507
|
+
"default": 5
|
|
1508
|
+
},
|
|
1509
|
+
"sort": {
|
|
1510
|
+
"type": "boolean",
|
|
1511
|
+
"description": "whether to sort the data or not",
|
|
1512
|
+
"default": true
|
|
1513
|
+
},
|
|
1514
|
+
"populate": {
|
|
1515
|
+
"type": "array",
|
|
1516
|
+
"description": "Information for the call(s) used to populate the cache",
|
|
1517
|
+
"items": {
|
|
1518
|
+
"type": "object",
|
|
1519
|
+
"properties": {
|
|
1520
|
+
"path": {
|
|
1521
|
+
"type": "string",
|
|
1522
|
+
"description": "The fully qualified path of the call to getDevice (e.g. /rest/api/device/{deviceid})",
|
|
1523
|
+
"default": ""
|
|
1524
|
+
},
|
|
1525
|
+
"method": {
|
|
1526
|
+
"type": "string",
|
|
1527
|
+
"description": "The method of the call to getDevice",
|
|
1528
|
+
"default": "GET"
|
|
1529
|
+
},
|
|
1530
|
+
"pagination": {
|
|
1531
|
+
"type": "object",
|
|
1532
|
+
"description": "todo",
|
|
1533
|
+
"properties": {
|
|
1534
|
+
"offsetVar": {
|
|
1535
|
+
"type": "string",
|
|
1536
|
+
"description": "Name of variable that defines how to go to next set of results"
|
|
1537
|
+
},
|
|
1538
|
+
"limitVar": {
|
|
1539
|
+
"type": "string",
|
|
1540
|
+
"description": "Name of variable that defines the max results returned in a request"
|
|
1541
|
+
},
|
|
1542
|
+
"incrementBy": {
|
|
1543
|
+
"type": "string",
|
|
1544
|
+
"enum": [
|
|
1545
|
+
"limit",
|
|
1546
|
+
"page"
|
|
1547
|
+
],
|
|
1548
|
+
"description": "How to incremenet offset. Default limit",
|
|
1549
|
+
"default": "limit"
|
|
1550
|
+
},
|
|
1551
|
+
"requestLocation": {
|
|
1552
|
+
"type": "string",
|
|
1553
|
+
"enum": [
|
|
1554
|
+
"query",
|
|
1555
|
+
"body"
|
|
1556
|
+
],
|
|
1557
|
+
"description": "Where in request the pagination data goes",
|
|
1558
|
+
"default": "query"
|
|
1559
|
+
}
|
|
1560
|
+
}
|
|
1561
|
+
},
|
|
1562
|
+
"query": {
|
|
1563
|
+
"type": "object",
|
|
1564
|
+
"description": "The json object with query parameters of the call to getDevice",
|
|
1565
|
+
"additionalProperties": {
|
|
1566
|
+
"type": [
|
|
1567
|
+
"string",
|
|
1568
|
+
"number"
|
|
1569
|
+
]
|
|
1570
|
+
}
|
|
1571
|
+
},
|
|
1572
|
+
"body": {
|
|
1573
|
+
"type": "object",
|
|
1574
|
+
"description": "The json object with body of the call to getDevice",
|
|
1575
|
+
"additionalProperties": {
|
|
1576
|
+
"type": [
|
|
1577
|
+
"string",
|
|
1578
|
+
"number"
|
|
1579
|
+
]
|
|
1580
|
+
}
|
|
1581
|
+
},
|
|
1582
|
+
"headers": {
|
|
1583
|
+
"type": "object",
|
|
1584
|
+
"description": "The json object with headers of the call to getDevice",
|
|
1585
|
+
"additionalProperties": {
|
|
1586
|
+
"type": [
|
|
1587
|
+
"string",
|
|
1588
|
+
"number"
|
|
1589
|
+
]
|
|
1590
|
+
}
|
|
1591
|
+
},
|
|
1592
|
+
"handleFailure": {
|
|
1593
|
+
"type": "string",
|
|
1594
|
+
"enum": [
|
|
1595
|
+
"ignore",
|
|
1596
|
+
"fail"
|
|
1597
|
+
],
|
|
1598
|
+
"description": "return failure or ignore failure",
|
|
1599
|
+
"default": "ignore"
|
|
1600
|
+
},
|
|
1601
|
+
"requestFields": {
|
|
1602
|
+
"type": "object",
|
|
1603
|
+
"description": "The json object with response fields of the call to getDevice",
|
|
1604
|
+
"additionalProperties": {
|
|
1605
|
+
"type": [
|
|
1606
|
+
"string",
|
|
1607
|
+
"number"
|
|
1608
|
+
]
|
|
1609
|
+
},
|
|
1610
|
+
"properties": {}
|
|
1611
|
+
},
|
|
1612
|
+
"responseDatakey": {
|
|
1613
|
+
"type": "string",
|
|
1614
|
+
"description": "place in the response where the data is - supports jsonquery",
|
|
1615
|
+
"default": ""
|
|
1616
|
+
},
|
|
1617
|
+
"responseFields": {
|
|
1618
|
+
"type": "object",
|
|
1619
|
+
"description": "The json object with response fields of the call to getDevice",
|
|
1620
|
+
"additionalProperties": {
|
|
1621
|
+
"type": [
|
|
1622
|
+
"string",
|
|
1623
|
+
"number"
|
|
1624
|
+
]
|
|
1625
|
+
}
|
|
1626
|
+
}
|
|
1627
|
+
}
|
|
1628
|
+
}
|
|
1629
|
+
},
|
|
1630
|
+
"cachedTasks": {
|
|
1631
|
+
"type": "array",
|
|
1632
|
+
"description": "Information for the call(s) used to populate the cache",
|
|
1633
|
+
"items": {
|
|
1634
|
+
"type": "object",
|
|
1635
|
+
"properties": {
|
|
1636
|
+
"name": {
|
|
1637
|
+
"type": "string",
|
|
1638
|
+
"description": "the name of the task/action that should utilize cached information",
|
|
1639
|
+
"default": ""
|
|
1640
|
+
},
|
|
1641
|
+
"filterField": {
|
|
1642
|
+
"type": "string",
|
|
1643
|
+
"description": "the field that contains filter information for this call",
|
|
1644
|
+
"default": ""
|
|
1645
|
+
},
|
|
1646
|
+
"filterLoc": {
|
|
1647
|
+
"type": "string",
|
|
1648
|
+
"description": "the field that contains the location of the filter field",
|
|
1649
|
+
"default": ""
|
|
1650
|
+
}
|
|
1651
|
+
}
|
|
1239
1652
|
}
|
|
1240
1653
|
}
|
|
1241
1654
|
}
|
|
@@ -1244,4 +1657,4 @@
|
|
|
1244
1657
|
}
|
|
1245
1658
|
}
|
|
1246
1659
|
}
|
|
1247
|
-
}
|
|
1660
|
+
}
|