losant_rest 1.8.6 → 1.8.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. checksums.yaml +4 -4
  2. data/docs/_schemas.md +2143 -330
  3. data/docs/applicationCertificate.md +133 -0
  4. data/docs/applicationCertificateAuthorities.md +93 -0
  5. data/docs/applicationCertificateAuthority.md +133 -0
  6. data/docs/applicationCertificates.md +93 -0
  7. data/docs/auth.md +1 -1
  8. data/docs/dataTableRows.md +2 -0
  9. data/docs/events.md +1 -1
  10. data/docs/experienceUsers.md +2 -1
  11. data/lib/losant_rest.rb +4 -0
  12. data/lib/losant_rest/application_certificate.rb +174 -0
  13. data/lib/losant_rest/application_certificate_authorities.rb +136 -0
  14. data/lib/losant_rest/application_certificate_authority.rb +174 -0
  15. data/lib/losant_rest/application_certificates.rb +136 -0
  16. data/lib/losant_rest/auth.rb +1 -1
  17. data/lib/losant_rest/client.rb +18 -2
  18. data/lib/losant_rest/data_table_rows.rb +4 -0
  19. data/lib/losant_rest/events.rb +1 -1
  20. data/lib/losant_rest/experience_users.rb +3 -1
  21. data/lib/losant_rest/version.rb +1 -1
  22. data/schemas/applicationApiTokenPost.json +14 -0
  23. data/schemas/applicationCertificate.json +67 -0
  24. data/schemas/applicationCertificateAuthorities.json +93 -0
  25. data/schemas/applicationCertificateAuthority.json +51 -0
  26. data/schemas/applicationCertificateAuthorityPatch.json +26 -0
  27. data/schemas/applicationCertificateAuthorityPost.json +30 -0
  28. data/schemas/applicationCertificatePatch.json +21 -0
  29. data/schemas/applicationCertificatePost.json +51 -0
  30. data/schemas/applicationCertificates.json +109 -0
  31. data/schemas/dashboard.json +274 -72
  32. data/schemas/dashboardPatch.json +274 -72
  33. data/schemas/dashboardPost.json +274 -72
  34. data/schemas/dashboards.json +274 -72
  35. data/schemas/dataTableQuery.json +12 -0
  36. data/schemas/dataTableRowsExport.json +12 -0
  37. data/schemas/deviceCredentials.json +1 -3
  38. data/schemas/event.json +15 -0
  39. data/schemas/eventPatch.json +12 -1
  40. data/schemas/eventPost.json +16 -1
  41. data/schemas/events.json +15 -0
  42. data/schemas/experienceDomain.json +2 -6
  43. data/schemas/experienceDomainPatch.json +2 -6
  44. data/schemas/experienceDomainPost.json +2 -6
  45. data/schemas/experienceDomains.json +2 -6
  46. data/schemas/experienceGroup.json +38 -0
  47. data/schemas/experienceGroupPatch.json +38 -0
  48. data/schemas/experienceGroupPost.json +38 -0
  49. data/schemas/experienceGroups.json +38 -0
  50. data/schemas/flow.json +1 -0
  51. data/schemas/flowPatch.json +3 -2
  52. data/schemas/flowPost.json +1 -0
  53. data/schemas/flowVersion.json +2 -0
  54. data/schemas/flowVersionPost.json +1 -0
  55. data/schemas/flowVersions.json +2 -0
  56. data/schemas/flows.json +1 -0
  57. data/schemas/flowsImportPost.json +4 -2
  58. data/schemas/flowsImportResult.json +3 -0
  59. data/schemas/githubLogin.json +14 -0
  60. data/schemas/userCredentials.json +14 -0
  61. data/schemas/userPost.json +14 -0
  62. metadata +18 -2
@@ -208,36 +208,137 @@
208
208
  "contextConfiguration": {
209
209
  "type": "array",
210
210
  "items": {
211
- "type": "object",
212
- "properties": {
213
- "name": {
214
- "type": "string",
215
- "pattern": "^[0-9a-zA-Z_-]{1,255}$"
216
- },
217
- "type": {
218
- "type": "string",
219
- "enum": [
220
- "deviceAttribute",
221
- "deviceId",
222
- "deviceTag",
223
- "number",
224
- "string"
211
+ "oneOf": [
212
+ {
213
+ "type": "object",
214
+ "properties": {
215
+ "name": {
216
+ "type": "string",
217
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
218
+ },
219
+ "type": {
220
+ "type": "string",
221
+ "enum": [
222
+ "deviceAttribute"
223
+ ]
224
+ },
225
+ "applicationId": {
226
+ "type": "string",
227
+ "pattern": "^[A-Fa-f\\d]{24}$"
228
+ },
229
+ "defaultValue": {
230
+ "type": "string",
231
+ "maxLength": 32767
232
+ },
233
+ "validationEnabled": {
234
+ "type": "boolean"
235
+ },
236
+ "validationConfig": {
237
+ "type": "object",
238
+ "properties": {
239
+ "attributes": {
240
+ "type": "array",
241
+ "items": {
242
+ "type": "string",
243
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
244
+ },
245
+ "maxItems": 100
246
+ }
247
+ },
248
+ "additionalProperties": false
249
+ }
250
+ },
251
+ "required": [
252
+ "name",
253
+ "type",
254
+ "defaultValue"
225
255
  ]
226
256
  },
227
- "applicationId": {
228
- "type": "string",
229
- "pattern": "^[A-Fa-f\\d]{24}$"
230
- },
231
- "defaultValue": {
232
- "oneOf": [
233
- {
257
+ {
258
+ "type": "object",
259
+ "properties": {
260
+ "name": {
261
+ "type": "string",
262
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
263
+ },
264
+ "type": {
265
+ "type": "string",
266
+ "enum": [
267
+ "deviceId"
268
+ ]
269
+ },
270
+ "applicationId": {
271
+ "type": "string",
272
+ "pattern": "^[A-Fa-f\\d]{24}$"
273
+ },
274
+ "defaultValue": {
234
275
  "type": "string",
235
276
  "maxLength": 32767
236
277
  },
237
- {
238
- "type": "number"
278
+ "validationEnabled": {
279
+ "type": "boolean"
280
+ },
281
+ "validationConfig": {
282
+ "type": "object",
283
+ "properties": {
284
+ "deviceIds": {
285
+ "type": "array",
286
+ "items": {
287
+ "type": "string",
288
+ "pattern": "^[A-Fa-f\\d]{24}$"
289
+ },
290
+ "maxItems": 1000
291
+ },
292
+ "deviceTags": {
293
+ "type": "array",
294
+ "items": {
295
+ "type": "object",
296
+ "properties": {
297
+ "key": {
298
+ "type": "string",
299
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
300
+ },
301
+ "value": {
302
+ "type": "string",
303
+ "minLength": 1,
304
+ "maxLength": 255
305
+ }
306
+ },
307
+ "additionalProperties": false
308
+ },
309
+ "maxItems": 100
310
+ },
311
+ "includeFullDevice": {
312
+ "type": "boolean"
313
+ }
314
+ },
315
+ "additionalProperties": false
316
+ }
317
+ },
318
+ "required": [
319
+ "name",
320
+ "type",
321
+ "defaultValue"
322
+ ]
323
+ },
324
+ {
325
+ "type": "object",
326
+ "properties": {
327
+ "name": {
328
+ "type": "string",
329
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
330
+ },
331
+ "type": {
332
+ "type": "string",
333
+ "enum": [
334
+ "deviceTag"
335
+ ]
336
+ },
337
+ "applicationId": {
338
+ "type": "string",
339
+ "pattern": "^[A-Fa-f\\d]{24}$"
239
340
  },
240
- {
341
+ "defaultValue": {
241
342
  "type": "object",
242
343
  "properties": {
243
344
  "key": {
@@ -251,73 +352,174 @@
251
352
  }
252
353
  },
253
354
  "additionalProperties": false
355
+ },
356
+ "validationEnabled": {
357
+ "type": "boolean"
358
+ },
359
+ "validationConfig": {
360
+ "type": "object",
361
+ "properties": {
362
+ "deviceTags": {
363
+ "type": "array",
364
+ "items": {
365
+ "type": "object",
366
+ "properties": {
367
+ "key": {
368
+ "type": "string",
369
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
370
+ },
371
+ "value": {
372
+ "type": "string",
373
+ "minLength": 1,
374
+ "maxLength": 255
375
+ }
376
+ },
377
+ "additionalProperties": false
378
+ },
379
+ "maxItems": 100
380
+ }
381
+ },
382
+ "additionalProperties": false
254
383
  }
384
+ },
385
+ "required": [
386
+ "name",
387
+ "type",
388
+ "defaultValue"
255
389
  ]
256
390
  },
257
- "validationEnabled": {
258
- "type": "boolean"
259
- },
260
- "validationConfig": {
391
+ {
261
392
  "type": "object",
262
393
  "properties": {
263
- "min": {
264
- "type": "number"
394
+ "name": {
395
+ "type": "string",
396
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
265
397
  },
266
- "max": {
267
- "type": "number"
398
+ "type": {
399
+ "type": "string",
400
+ "enum": [
401
+ "number"
402
+ ]
268
403
  },
269
- "regExp": {
404
+ "applicationId": {
270
405
  "type": "string",
271
- "maxLength": 1024
406
+ "pattern": "^[A-Fa-f\\d]{24}$"
272
407
  },
273
- "attributes": {
274
- "type": "array",
275
- "items": {
276
- "type": "string",
277
- "pattern": "^[0-9a-zA-Z_-]{1,255}$"
408
+ "defaultValue": {
409
+ "type": [
410
+ "number",
411
+ "string"
412
+ ]
413
+ },
414
+ "validationEnabled": {
415
+ "type": "boolean"
416
+ },
417
+ "validationConfig": {
418
+ "type": "object",
419
+ "properties": {
420
+ "min": {
421
+ "type": "number"
422
+ },
423
+ "max": {
424
+ "type": "number"
425
+ }
278
426
  },
279
- "maxItems": 100
427
+ "additionalProperties": false
428
+ }
429
+ },
430
+ "required": [
431
+ "name",
432
+ "type",
433
+ "defaultValue"
434
+ ]
435
+ },
436
+ {
437
+ "type": "object",
438
+ "properties": {
439
+ "name": {
440
+ "type": "string",
441
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
442
+ },
443
+ "type": {
444
+ "type": "string",
445
+ "enum": [
446
+ "string"
447
+ ]
280
448
  },
281
- "deviceIds": {
282
- "type": "array",
283
- "items": {
284
- "type": "string",
285
- "pattern": "^[A-Fa-f\\d]{24}$"
449
+ "applicationId": {
450
+ "type": "string",
451
+ "pattern": "^[A-Fa-f\\d]{24}$"
452
+ },
453
+ "defaultValue": {
454
+ "type": "string",
455
+ "maxLength": 32767
456
+ },
457
+ "validationEnabled": {
458
+ "type": "boolean"
459
+ },
460
+ "validationConfig": {
461
+ "type": "object",
462
+ "properties": {
463
+ "regExp": {
464
+ "type": "string",
465
+ "maxLength": 1024
466
+ }
286
467
  },
287
- "maxItems": 1000
468
+ "additionalProperties": false
469
+ }
470
+ },
471
+ "required": [
472
+ "name",
473
+ "type",
474
+ "defaultValue"
475
+ ]
476
+ },
477
+ {
478
+ "type": "object",
479
+ "properties": {
480
+ "name": {
481
+ "type": "string",
482
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
483
+ },
484
+ "type": {
485
+ "type": "string",
486
+ "enum": [
487
+ "experienceUser"
488
+ ]
489
+ },
490
+ "applicationId": {
491
+ "type": "string",
492
+ "pattern": "^[A-Fa-f\\d]{24}$"
493
+ },
494
+ "defaultValue": {
495
+ "type": "string",
496
+ "maxLength": 32767
497
+ },
498
+ "validationEnabled": {
499
+ "type": "boolean"
288
500
  },
289
- "deviceTags": {
290
- "type": "array",
291
- "items": {
292
- "type": "object",
293
- "properties": {
294
- "key": {
501
+ "validationConfig": {
502
+ "type": "object",
503
+ "properties": {
504
+ "experienceGroupIds": {
505
+ "type": "array",
506
+ "items": {
295
507
  "type": "string",
296
- "pattern": "^[0-9a-zA-Z_-]{1,255}$"
508
+ "pattern": "^[A-Fa-f\\d]{24}$"
297
509
  },
298
- "value": {
299
- "type": "string",
300
- "minLength": 1,
301
- "maxLength": 255
302
- }
303
- },
304
- "additionalProperties": false
510
+ "maxItems": 1000
511
+ }
305
512
  },
306
- "maxItems": 100
307
- },
308
- "includeFullDevice": {
309
- "type": "boolean"
513
+ "additionalProperties": false
310
514
  }
311
515
  },
312
- "additionalProperties": false
516
+ "required": [
517
+ "name",
518
+ "type",
519
+ "defaultValue"
520
+ ]
313
521
  }
314
- },
315
- "required": [
316
- "name",
317
- "type",
318
- "defaultValue"
319
- ],
320
- "additionalProperties": false
522
+ ]
321
523
  },
322
524
  "maxItems": 100
323
525
  }
@@ -76,6 +76,18 @@
76
76
  "boolean",
77
77
  "null"
78
78
  ]
79
+ },
80
+ "$startsWith": {
81
+ "type": "string",
82
+ "minLength": 1
83
+ },
84
+ "$endsWith": {
85
+ "type": "string",
86
+ "minLength": 1
87
+ },
88
+ "$contains": {
89
+ "type": "string",
90
+ "minLength": 1
79
91
  }
80
92
  }
81
93
  }
@@ -86,6 +86,18 @@
86
86
  "boolean",
87
87
  "null"
88
88
  ]
89
+ },
90
+ "$startsWith": {
91
+ "type": "string",
92
+ "minLength": 1
93
+ },
94
+ "$endsWith": {
95
+ "type": "string",
96
+ "minLength": 1
97
+ },
98
+ "$contains": {
99
+ "type": "string",
100
+ "minLength": 1
89
101
  }
90
102
  }
91
103
  }
@@ -45,9 +45,7 @@
45
45
  }
46
46
  },
47
47
  "required": [
48
- "deviceId",
49
- "key",
50
- "secret"
48
+ "deviceId"
51
49
  ],
52
50
  "additionalProperties": false
53
51
  }
@@ -63,6 +63,21 @@
63
63
  "maxLength": 32767
64
64
  },
65
65
  "data": {},
66
+ "deviceId": {
67
+ "type": "string",
68
+ "pattern": "^[A-Fa-f\\d]{24}$"
69
+ },
70
+ "eventTags": {
71
+ "type": "object",
72
+ "patternProperties": {
73
+ "^[0-9a-zA-Z_-]{1,255}$": {
74
+ "type": "string",
75
+ "minLength": 1,
76
+ "maxLength": 255
77
+ }
78
+ },
79
+ "additionalProperties": false
80
+ },
66
81
  "updates": {
67
82
  "type": "array",
68
83
  "items": {