losant_rest 1.9.3 → 1.10.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (110) hide show
  1. checksums.yaml +4 -4
  2. data/docs/_schemas.md +17405 -2766
  3. data/docs/application.md +85 -0
  4. data/docs/applicationApiTokens.md +1 -1
  5. data/docs/applicationTemplate.md +46 -0
  6. data/docs/applicationTemplates.md +76 -1
  7. data/docs/device.md +7 -3
  8. data/docs/devices.md +92 -4
  9. data/docs/experienceEndpoints.md +1 -0
  10. data/docs/file.md +4 -4
  11. data/docs/flow.md +94 -1
  12. data/docs/flowVersion.md +96 -1
  13. data/docs/me.md +0 -36
  14. data/lib/losant_rest.rb +1 -0
  15. data/lib/losant_rest/application.rb +48 -0
  16. data/lib/losant_rest/application_api_tokens.rb +1 -1
  17. data/lib/losant_rest/application_template.rb +79 -0
  18. data/lib/losant_rest/application_templates.rb +89 -1
  19. data/lib/losant_rest/client.rb +6 -2
  20. data/lib/losant_rest/device.rb +11 -3
  21. data/lib/losant_rest/devices.rb +103 -3
  22. data/lib/losant_rest/experience_endpoints.rb +2 -0
  23. data/lib/losant_rest/file.rb +3 -3
  24. data/lib/losant_rest/flow.rb +115 -1
  25. data/lib/losant_rest/flow_version.rb +115 -1
  26. data/lib/losant_rest/me.rb +0 -41
  27. data/lib/losant_rest/version.rb +1 -1
  28. data/schemas/advancedDeviceQuery.json +117 -0
  29. data/schemas/advancedEventQuery.json +205 -0
  30. data/schemas/advancedQuery.json +34 -3
  31. data/schemas/application.json +13 -0
  32. data/schemas/applicationApiTokenPost.json +9 -1
  33. data/schemas/applicationApplyTemplatePatch.json +19 -0
  34. data/schemas/applicationCreationByTemplateResult.json +13 -0
  35. data/schemas/applicationPatch.json +5 -0
  36. data/schemas/applicationPost.json +13 -0
  37. data/schemas/applicationTemplate.json +32 -0
  38. data/schemas/applicationTemplateCategories.json +43 -0
  39. data/schemas/applicationTemplateCategory.json +23 -0
  40. data/schemas/applicationTemplates.json +44 -0
  41. data/schemas/applications.json +13 -0
  42. data/schemas/changePassword.json +2 -2
  43. data/schemas/dashboard.json +1285 -145
  44. data/schemas/dashboardPatch.json +1285 -145
  45. data/schemas/dashboardPost.json +1285 -145
  46. data/schemas/dashboards.json +1285 -145
  47. data/schemas/dataExport.json +142 -0
  48. data/schemas/dataTableRowsExport.json +34 -3
  49. data/schemas/device.json +16 -3
  50. data/schemas/devicePatch.json +16 -3
  51. data/schemas/devicePost.json +16 -3
  52. data/schemas/deviceRecipe.json +16 -3
  53. data/schemas/deviceRecipePatch.json +16 -3
  54. data/schemas/deviceRecipePost.json +16 -3
  55. data/schemas/deviceRecipes.json +16 -3
  56. data/schemas/devices.json +16 -3
  57. data/schemas/devicesDataRemoved.json +12 -0
  58. data/schemas/devicesDeletePost.json +1034 -0
  59. data/schemas/devicesDeleted.json +12 -0
  60. data/schemas/devicesExportPost.json +1035 -0
  61. data/schemas/devicesPatch.json +1773 -7
  62. data/schemas/devicesRemoveDataPost.json +1056 -0
  63. data/schemas/devicesUpdated.json +18 -0
  64. data/schemas/eventPost.json +22 -0
  65. data/schemas/eventsExport.json +205 -0
  66. data/schemas/experienceDomain.json +1 -1
  67. data/schemas/experienceDomainPatch.json +1 -1
  68. data/schemas/experienceDomainPost.json +1 -1
  69. data/schemas/experienceDomains.json +1 -1
  70. data/schemas/experienceGroup.json +7 -0
  71. data/schemas/experienceGroupPatch.json +7 -0
  72. data/schemas/experienceGroupPost.json +7 -0
  73. data/schemas/experienceGroups.json +7 -0
  74. data/schemas/experienceLinkedResources.json +348 -3
  75. data/schemas/experienceVersion.json +1 -1
  76. data/schemas/experienceVersions.json +1 -1
  77. data/schemas/flow.json +116 -1
  78. data/schemas/flowErrors.json +87 -0
  79. data/schemas/flowPatch.json +116 -1
  80. data/schemas/flowPost.json +116 -1
  81. data/schemas/flowStats.json +54 -0
  82. data/schemas/flowVersion.json +232 -2
  83. data/schemas/flowVersionPost.json +116 -1
  84. data/schemas/flowVersions.json +232 -2
  85. data/schemas/flows.json +116 -1
  86. data/schemas/flowsImportPost.json +232 -2
  87. data/schemas/flowsImportResult.json +348 -3
  88. data/schemas/githubLogin.json +15 -4
  89. data/schemas/me.json +0 -3
  90. data/schemas/mePatch.json +2 -2
  91. data/schemas/multiDeviceCommand.json +1019 -0
  92. data/schemas/notebook.json +99 -2
  93. data/schemas/notebookPatch.json +99 -2
  94. data/schemas/notebookPost.json +99 -2
  95. data/schemas/notebooks.json +99 -2
  96. data/schemas/org.json +1 -1
  97. data/schemas/orgInviteInfo.json +3 -0
  98. data/schemas/orgInvitePost.json +3 -0
  99. data/schemas/orgInvites.json +3 -0
  100. data/schemas/orgPatch.json +1 -1
  101. data/schemas/orgPost.json +0 -9
  102. data/schemas/orgs.json +1 -1
  103. data/schemas/passwordResetFinish.json +2 -2
  104. data/schemas/samlResponse.json +1 -1
  105. data/schemas/templateKeywords.json +14 -0
  106. data/schemas/timeSeriesData.json +101 -12
  107. data/schemas/timeSeriesQuery.json +101 -12
  108. data/schemas/userCredentials.json +13 -3
  109. data/schemas/userPost.json +21 -7
  110. metadata +19 -5
@@ -0,0 +1,54 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-04/schema#",
3
+ "type": "object",
4
+ "properties": {
5
+ "flowVersion": {
6
+ "type": "string",
7
+ "minLength": 1,
8
+ "maxLength": 255
9
+ },
10
+ "flowVersionId": {
11
+ "type": "string",
12
+ "pattern": "^[A-Fa-f\\d]{24}$"
13
+ },
14
+ "deviceId": {
15
+ "type": "string",
16
+ "pattern": "^[A-Fa-f\\d]{24}$"
17
+ },
18
+ "start": {
19
+ "type": "string",
20
+ "format": "date-time"
21
+ },
22
+ "end": {
23
+ "type": "string",
24
+ "format": "date-time"
25
+ },
26
+ "resolution": {
27
+ "type": "number"
28
+ },
29
+ "metrics": {
30
+ "type": "array",
31
+ "items": {
32
+ "type": "object",
33
+ "properties": {
34
+ "time": {
35
+ "type": "string",
36
+ "format": "date-time"
37
+ },
38
+ "pathsFailed": {
39
+ "type": "number"
40
+ },
41
+ "pathsCompleted": {
42
+ "type": "number"
43
+ },
44
+ "runCount": {
45
+ "type": "number"
46
+ },
47
+ "wallTime": {
48
+ "type": "number"
49
+ }
50
+ }
51
+ }
52
+ }
53
+ }
54
+ }
@@ -62,7 +62,6 @@
62
62
  "deviceIdDisconnect",
63
63
  "deviceTagDisconnect",
64
64
  "integration",
65
- "mqttTopic",
66
65
  "notebook",
67
66
  "onBoot",
68
67
  "onConnect",
@@ -1008,6 +1007,109 @@
1008
1007
  ],
1009
1008
  "additionalProperties": false
1010
1009
  },
1010
+ {
1011
+ "type": "object",
1012
+ "properties": {
1013
+ "key": {
1014
+ "type": "string",
1015
+ "maxLength": 1024
1016
+ },
1017
+ "type": {
1018
+ "type": "string",
1019
+ "enum": [
1020
+ "mqttTopic"
1021
+ ]
1022
+ },
1023
+ "config": {
1024
+ "type": "object",
1025
+ "properties": {
1026
+ "integrationId": {
1027
+ "type": "string",
1028
+ "enum": [
1029
+ "losant",
1030
+ "local"
1031
+ ]
1032
+ }
1033
+ },
1034
+ "additionalProperties": false
1035
+ },
1036
+ "meta": {
1037
+ "type": "object",
1038
+ "properties": {
1039
+ "category": {
1040
+ "type": "string",
1041
+ "enum": [
1042
+ "trigger"
1043
+ ]
1044
+ },
1045
+ "name": {
1046
+ "type": "string",
1047
+ "enum": [
1048
+ "mqtt"
1049
+ ]
1050
+ },
1051
+ "label": {
1052
+ "type": "string",
1053
+ "minLength": 1,
1054
+ "maxLength": 255
1055
+ },
1056
+ "x": {
1057
+ "type": "number"
1058
+ },
1059
+ "y": {
1060
+ "type": "number"
1061
+ },
1062
+ "uiId": {
1063
+ "type": "string",
1064
+ "maxLength": 48
1065
+ },
1066
+ "description": {
1067
+ "type": "string",
1068
+ "maxLength": 32767
1069
+ },
1070
+ "icon": {
1071
+ "type": "string",
1072
+ "maxLength": 1024
1073
+ },
1074
+ "color": {
1075
+ "type": "string",
1076
+ "maxLength": 1024
1077
+ },
1078
+ "inputCount": {
1079
+ "type": "number"
1080
+ },
1081
+ "outputCount": {
1082
+ "type": "number"
1083
+ },
1084
+ "triggerId": {
1085
+ "type": "string",
1086
+ "maxLength": 48
1087
+ },
1088
+ "id": {
1089
+ "type": "string",
1090
+ "maxLength": 48
1091
+ }
1092
+ },
1093
+ "additionalProperties": false
1094
+ },
1095
+ "outputIds": {
1096
+ "type": "array",
1097
+ "items": {
1098
+ "type": "array",
1099
+ "items": {
1100
+ "type": "string",
1101
+ "maxLength": 255
1102
+ },
1103
+ "maxItems": 100
1104
+ },
1105
+ "maxItems": 100
1106
+ }
1107
+ },
1108
+ "required": [
1109
+ "type"
1110
+ ],
1111
+ "additionalProperties": false
1112
+ },
1011
1113
  {
1012
1114
  "type": "object",
1013
1115
  "properties": {
@@ -1294,6 +1396,19 @@
1294
1396
  "baudRate": {
1295
1397
  "type": "number"
1296
1398
  },
1399
+ "dataBits": {
1400
+ "type": "number"
1401
+ },
1402
+ "stopBits": {
1403
+ "type": "number"
1404
+ },
1405
+ "parity": {
1406
+ "type": "string",
1407
+ "maxLength": 8
1408
+ },
1409
+ "rtscts": {
1410
+ "type": "boolean"
1411
+ },
1297
1412
  "encoding": {
1298
1413
  "type": "string",
1299
1414
  "maxLength": 48
@@ -2126,7 +2241,6 @@
2126
2241
  "deviceIdDisconnect",
2127
2242
  "deviceTagDisconnect",
2128
2243
  "integration",
2129
- "mqttTopic",
2130
2244
  "notebook",
2131
2245
  "onBoot",
2132
2246
  "onConnect",
@@ -3072,6 +3186,109 @@
3072
3186
  ],
3073
3187
  "additionalProperties": false
3074
3188
  },
3189
+ {
3190
+ "type": "object",
3191
+ "properties": {
3192
+ "key": {
3193
+ "type": "string",
3194
+ "maxLength": 1024
3195
+ },
3196
+ "type": {
3197
+ "type": "string",
3198
+ "enum": [
3199
+ "mqttTopic"
3200
+ ]
3201
+ },
3202
+ "config": {
3203
+ "type": "object",
3204
+ "properties": {
3205
+ "integrationId": {
3206
+ "type": "string",
3207
+ "enum": [
3208
+ "losant",
3209
+ "local"
3210
+ ]
3211
+ }
3212
+ },
3213
+ "additionalProperties": false
3214
+ },
3215
+ "meta": {
3216
+ "type": "object",
3217
+ "properties": {
3218
+ "category": {
3219
+ "type": "string",
3220
+ "enum": [
3221
+ "trigger"
3222
+ ]
3223
+ },
3224
+ "name": {
3225
+ "type": "string",
3226
+ "enum": [
3227
+ "mqtt"
3228
+ ]
3229
+ },
3230
+ "label": {
3231
+ "type": "string",
3232
+ "minLength": 1,
3233
+ "maxLength": 255
3234
+ },
3235
+ "x": {
3236
+ "type": "number"
3237
+ },
3238
+ "y": {
3239
+ "type": "number"
3240
+ },
3241
+ "uiId": {
3242
+ "type": "string",
3243
+ "maxLength": 48
3244
+ },
3245
+ "description": {
3246
+ "type": "string",
3247
+ "maxLength": 32767
3248
+ },
3249
+ "icon": {
3250
+ "type": "string",
3251
+ "maxLength": 1024
3252
+ },
3253
+ "color": {
3254
+ "type": "string",
3255
+ "maxLength": 1024
3256
+ },
3257
+ "inputCount": {
3258
+ "type": "number"
3259
+ },
3260
+ "outputCount": {
3261
+ "type": "number"
3262
+ },
3263
+ "triggerId": {
3264
+ "type": "string",
3265
+ "maxLength": 48
3266
+ },
3267
+ "id": {
3268
+ "type": "string",
3269
+ "maxLength": 48
3270
+ }
3271
+ },
3272
+ "additionalProperties": false
3273
+ },
3274
+ "outputIds": {
3275
+ "type": "array",
3276
+ "items": {
3277
+ "type": "array",
3278
+ "items": {
3279
+ "type": "string",
3280
+ "maxLength": 255
3281
+ },
3282
+ "maxItems": 100
3283
+ },
3284
+ "maxItems": 100
3285
+ }
3286
+ },
3287
+ "required": [
3288
+ "type"
3289
+ ],
3290
+ "additionalProperties": false
3291
+ },
3075
3292
  {
3076
3293
  "type": "object",
3077
3294
  "properties": {
@@ -3358,6 +3575,19 @@
3358
3575
  "baudRate": {
3359
3576
  "type": "number"
3360
3577
  },
3578
+ "dataBits": {
3579
+ "type": "number"
3580
+ },
3581
+ "stopBits": {
3582
+ "type": "number"
3583
+ },
3584
+ "parity": {
3585
+ "type": "string",
3586
+ "maxLength": 8
3587
+ },
3588
+ "rtscts": {
3589
+ "type": "boolean"
3590
+ },
3361
3591
  "encoding": {
3362
3592
  "type": "string",
3363
3593
  "maxLength": 48
@@ -35,7 +35,6 @@
35
35
  "deviceIdDisconnect",
36
36
  "deviceTagDisconnect",
37
37
  "integration",
38
- "mqttTopic",
39
38
  "notebook",
40
39
  "onBoot",
41
40
  "onConnect",
@@ -981,6 +980,109 @@
981
980
  ],
982
981
  "additionalProperties": false
983
982
  },
983
+ {
984
+ "type": "object",
985
+ "properties": {
986
+ "key": {
987
+ "type": "string",
988
+ "maxLength": 1024
989
+ },
990
+ "type": {
991
+ "type": "string",
992
+ "enum": [
993
+ "mqttTopic"
994
+ ]
995
+ },
996
+ "config": {
997
+ "type": "object",
998
+ "properties": {
999
+ "integrationId": {
1000
+ "type": "string",
1001
+ "enum": [
1002
+ "losant",
1003
+ "local"
1004
+ ]
1005
+ }
1006
+ },
1007
+ "additionalProperties": false
1008
+ },
1009
+ "meta": {
1010
+ "type": "object",
1011
+ "properties": {
1012
+ "category": {
1013
+ "type": "string",
1014
+ "enum": [
1015
+ "trigger"
1016
+ ]
1017
+ },
1018
+ "name": {
1019
+ "type": "string",
1020
+ "enum": [
1021
+ "mqtt"
1022
+ ]
1023
+ },
1024
+ "label": {
1025
+ "type": "string",
1026
+ "minLength": 1,
1027
+ "maxLength": 255
1028
+ },
1029
+ "x": {
1030
+ "type": "number"
1031
+ },
1032
+ "y": {
1033
+ "type": "number"
1034
+ },
1035
+ "uiId": {
1036
+ "type": "string",
1037
+ "maxLength": 48
1038
+ },
1039
+ "description": {
1040
+ "type": "string",
1041
+ "maxLength": 32767
1042
+ },
1043
+ "icon": {
1044
+ "type": "string",
1045
+ "maxLength": 1024
1046
+ },
1047
+ "color": {
1048
+ "type": "string",
1049
+ "maxLength": 1024
1050
+ },
1051
+ "inputCount": {
1052
+ "type": "number"
1053
+ },
1054
+ "outputCount": {
1055
+ "type": "number"
1056
+ },
1057
+ "triggerId": {
1058
+ "type": "string",
1059
+ "maxLength": 48
1060
+ },
1061
+ "id": {
1062
+ "type": "string",
1063
+ "maxLength": 48
1064
+ }
1065
+ },
1066
+ "additionalProperties": false
1067
+ },
1068
+ "outputIds": {
1069
+ "type": "array",
1070
+ "items": {
1071
+ "type": "array",
1072
+ "items": {
1073
+ "type": "string",
1074
+ "maxLength": 255
1075
+ },
1076
+ "maxItems": 100
1077
+ },
1078
+ "maxItems": 100
1079
+ }
1080
+ },
1081
+ "required": [
1082
+ "type"
1083
+ ],
1084
+ "additionalProperties": false
1085
+ },
984
1086
  {
985
1087
  "type": "object",
986
1088
  "properties": {
@@ -1267,6 +1369,19 @@
1267
1369
  "baudRate": {
1268
1370
  "type": "number"
1269
1371
  },
1372
+ "dataBits": {
1373
+ "type": "number"
1374
+ },
1375
+ "stopBits": {
1376
+ "type": "number"
1377
+ },
1378
+ "parity": {
1379
+ "type": "string",
1380
+ "maxLength": 8
1381
+ },
1382
+ "rtscts": {
1383
+ "type": "boolean"
1384
+ },
1270
1385
  "encoding": {
1271
1386
  "type": "string",
1272
1387
  "maxLength": 48