losant_rest 1.8.9 → 1.9.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (41) hide show
  1. checksums.yaml +5 -5
  2. data/docs/_schemas.md +26390 -4889
  3. data/docs/device.md +1 -1
  4. data/docs/devices.md +44 -4
  5. data/lib/losant_rest/client.rb +2 -2
  6. data/lib/losant_rest/device.rb +1 -1
  7. data/lib/losant_rest/devices.rb +52 -4
  8. data/lib/losant_rest/version.rb +1 -1
  9. data/schemas/application.json +25 -0
  10. data/schemas/applicationApiTokenPost.json +1 -0
  11. data/schemas/applicationPatch.json +25 -0
  12. data/schemas/applicationPost.json +25 -0
  13. data/schemas/applications.json +25 -0
  14. data/schemas/authedDevice.json +2 -1
  15. data/schemas/dashboard.json +34 -11
  16. data/schemas/dashboardPatch.json +34 -11
  17. data/schemas/dashboardPost.json +34 -11
  18. data/schemas/dashboards.json +34 -11
  19. data/schemas/device.json +110 -1
  20. data/schemas/deviceClassFilter.json +31 -0
  21. data/schemas/devicePatch.json +110 -1
  22. data/schemas/devicePost.json +110 -1
  23. data/schemas/deviceRecipe.json +110 -1
  24. data/schemas/deviceRecipePatch.json +110 -1
  25. data/schemas/deviceRecipePost.json +110 -1
  26. data/schemas/deviceRecipes.json +110 -1
  27. data/schemas/devices.json +123 -2
  28. data/schemas/devicesPatch.json +209 -0
  29. data/schemas/flow.json +1491 -54
  30. data/schemas/flowPatch.json +1491 -54
  31. data/schemas/flowPost.json +1491 -54
  32. data/schemas/flowVersion.json +3319 -445
  33. data/schemas/flowVersionPost.json +1491 -54
  34. data/schemas/flowVersions.json +3319 -445
  35. data/schemas/flows.json +1491 -54
  36. data/schemas/flowsImportPost.json +3313 -439
  37. data/schemas/flowsImportResult.json +5129 -818
  38. data/schemas/githubLogin.json +1 -0
  39. data/schemas/userCredentials.json +1 -0
  40. data/schemas/userPost.json +1 -0
  41. metadata +5 -3
data/schemas/flows.json CHANGED
@@ -66,68 +66,1505 @@
66
66
  "triggers": {
67
67
  "type": "array",
68
68
  "items": {
69
- "type": "object",
70
- "properties": {
71
- "key": {
72
- "type": "string",
73
- "maxLength": 1024
69
+ "oneOf": [
70
+ {
71
+ "type": "object",
72
+ "properties": {
73
+ "key": {
74
+ "type": "string",
75
+ "maxLength": 1024
76
+ },
77
+ "type": {
78
+ "type": "string",
79
+ "enum": [
80
+ "customNodeStart",
81
+ "deviceCommand",
82
+ "deviceIdConnect",
83
+ "deviceTagConnect",
84
+ "deviceIdDisconnect",
85
+ "deviceTagDisconnect",
86
+ "integration",
87
+ "mqttTopic",
88
+ "notebook",
89
+ "onBoot",
90
+ "onConnect",
91
+ "onDisconnect",
92
+ "request",
93
+ "udp",
94
+ "webhook"
95
+ ]
96
+ },
97
+ "config": {
98
+ "type": "object",
99
+ "additionalProperties": false
100
+ },
101
+ "meta": {
102
+ "type": "object",
103
+ "properties": {
104
+ "category": {
105
+ "type": "string",
106
+ "enum": [
107
+ "trigger"
108
+ ]
109
+ },
110
+ "name": {
111
+ "type": "string",
112
+ "enum": [
113
+ "customNodeStart",
114
+ "deviceCommand",
115
+ "deviceIdsTagsConnect",
116
+ "deviceIdsTagsDisconnect",
117
+ "googlePubSub",
118
+ "meridian",
119
+ "mqtt",
120
+ "notebook",
121
+ "onBoot",
122
+ "onConnect",
123
+ "onDisconnect",
124
+ "particle",
125
+ "request",
126
+ "udp",
127
+ "webhook"
128
+ ]
129
+ },
130
+ "label": {
131
+ "type": "string",
132
+ "minLength": 1,
133
+ "maxLength": 255
134
+ },
135
+ "x": {
136
+ "type": "number"
137
+ },
138
+ "y": {
139
+ "type": "number"
140
+ },
141
+ "uiId": {
142
+ "type": "string",
143
+ "maxLength": 48
144
+ },
145
+ "description": {
146
+ "type": "string",
147
+ "maxLength": 32767
148
+ },
149
+ "icon": {
150
+ "type": "string",
151
+ "maxLength": 1024
152
+ },
153
+ "color": {
154
+ "type": "string",
155
+ "maxLength": 1024
156
+ },
157
+ "inputCount": {
158
+ "type": "number"
159
+ },
160
+ "outputCount": {
161
+ "type": "number"
162
+ },
163
+ "triggerId": {
164
+ "type": "string",
165
+ "maxLength": 48
166
+ },
167
+ "id": {
168
+ "type": "string",
169
+ "maxLength": 48
170
+ }
171
+ },
172
+ "additionalProperties": false
173
+ },
174
+ "outputIds": {
175
+ "type": "array",
176
+ "items": {
177
+ "type": "array",
178
+ "items": {
179
+ "type": "string",
180
+ "maxLength": 255
181
+ },
182
+ "maxItems": 100
183
+ },
184
+ "maxItems": 100
185
+ }
186
+ },
187
+ "required": [
188
+ "type"
189
+ ],
190
+ "additionalProperties": false
191
+ },
192
+ {
193
+ "type": "object",
194
+ "properties": {
195
+ "key": {
196
+ "type": "string",
197
+ "maxLength": 1024
198
+ },
199
+ "type": {
200
+ "type": "string",
201
+ "enum": [
202
+ "dataTable"
203
+ ]
204
+ },
205
+ "config": {
206
+ "type": "object",
207
+ "properties": {
208
+ "bulkInsert": {
209
+ "type": "boolean"
210
+ },
211
+ "delete": {
212
+ "type": "boolean"
213
+ },
214
+ "insert": {
215
+ "type": "boolean"
216
+ },
217
+ "update": {
218
+ "type": "boolean"
219
+ }
220
+ },
221
+ "additionalProperties": false
222
+ },
223
+ "meta": {
224
+ "type": "object",
225
+ "properties": {
226
+ "category": {
227
+ "type": "string",
228
+ "enum": [
229
+ "trigger"
230
+ ]
231
+ },
232
+ "name": {
233
+ "type": "string",
234
+ "enum": [
235
+ "dataTable"
236
+ ]
237
+ },
238
+ "label": {
239
+ "type": "string",
240
+ "minLength": 1,
241
+ "maxLength": 255
242
+ },
243
+ "x": {
244
+ "type": "number"
245
+ },
246
+ "y": {
247
+ "type": "number"
248
+ },
249
+ "uiId": {
250
+ "type": "string",
251
+ "maxLength": 48
252
+ },
253
+ "description": {
254
+ "type": "string",
255
+ "maxLength": 32767
256
+ },
257
+ "icon": {
258
+ "type": "string",
259
+ "maxLength": 1024
260
+ },
261
+ "color": {
262
+ "type": "string",
263
+ "maxLength": 1024
264
+ },
265
+ "inputCount": {
266
+ "type": "number"
267
+ },
268
+ "outputCount": {
269
+ "type": "number"
270
+ },
271
+ "id": {
272
+ "type": "string",
273
+ "maxLength": 48
274
+ }
275
+ },
276
+ "additionalProperties": false
277
+ },
278
+ "outputIds": {
279
+ "type": "array",
280
+ "items": {
281
+ "type": "array",
282
+ "items": {
283
+ "type": "string",
284
+ "maxLength": 255
285
+ },
286
+ "maxItems": 100
287
+ },
288
+ "maxItems": 100
289
+ }
290
+ },
291
+ "required": [
292
+ "type"
293
+ ],
294
+ "additionalProperties": false
295
+ },
296
+ {
297
+ "type": "object",
298
+ "properties": {
299
+ "key": {
300
+ "type": "string",
301
+ "maxLength": 1024
302
+ },
303
+ "type": {
304
+ "type": "string",
305
+ "enum": [
306
+ "deviceId",
307
+ "deviceTag"
308
+ ]
309
+ },
310
+ "config": {
311
+ "type": "object",
312
+ "properties": {
313
+ "attributeBlacklist": {
314
+ "type": "array",
315
+ "maxItems": 100,
316
+ "items": {
317
+ "type": "string",
318
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
319
+ }
320
+ },
321
+ "attributeWhitelist": {
322
+ "type": "array",
323
+ "maxItems": 100,
324
+ "items": {
325
+ "type": "string",
326
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
327
+ }
328
+ },
329
+ "maxAge": {
330
+ "type": "number"
331
+ }
332
+ },
333
+ "additionalProperties": false
334
+ },
335
+ "meta": {
336
+ "type": "object",
337
+ "properties": {
338
+ "category": {
339
+ "type": "string",
340
+ "enum": [
341
+ "trigger"
342
+ ]
343
+ },
344
+ "name": {
345
+ "type": "string",
346
+ "enum": [
347
+ "deviceIdsTags",
348
+ "device",
349
+ "deviceTag"
350
+ ]
351
+ },
352
+ "label": {
353
+ "type": "string",
354
+ "minLength": 1,
355
+ "maxLength": 255
356
+ },
357
+ "x": {
358
+ "type": "number"
359
+ },
360
+ "y": {
361
+ "type": "number"
362
+ },
363
+ "uiId": {
364
+ "type": "string",
365
+ "maxLength": 48
366
+ },
367
+ "description": {
368
+ "type": "string",
369
+ "maxLength": 32767
370
+ },
371
+ "icon": {
372
+ "type": "string",
373
+ "maxLength": 1024
374
+ },
375
+ "color": {
376
+ "type": "string",
377
+ "maxLength": 1024
378
+ },
379
+ "inputCount": {
380
+ "type": "number"
381
+ },
382
+ "outputCount": {
383
+ "type": "number"
384
+ },
385
+ "id": {
386
+ "type": "string",
387
+ "maxLength": 48
388
+ },
389
+ "timeUnit": {
390
+ "type": "string",
391
+ "maxLength": 48
392
+ },
393
+ "maxAgeToggle": {
394
+ "type": "boolean"
395
+ },
396
+ "allowedAttributeType": {
397
+ "type": "string",
398
+ "enum": [
399
+ "attributeWhitelist",
400
+ "any",
401
+ "attributeBlacklist"
402
+ ]
403
+ }
404
+ },
405
+ "additionalProperties": false
406
+ },
407
+ "outputIds": {
408
+ "type": "array",
409
+ "items": {
410
+ "type": "array",
411
+ "items": {
412
+ "type": "string",
413
+ "maxLength": 255
414
+ },
415
+ "maxItems": 100
416
+ },
417
+ "maxItems": 100
418
+ }
419
+ },
420
+ "required": [
421
+ "type"
422
+ ],
423
+ "additionalProperties": false
424
+ },
425
+ {
426
+ "type": "object",
427
+ "properties": {
428
+ "key": {
429
+ "type": "string",
430
+ "maxLength": 1024
431
+ },
432
+ "type": {
433
+ "type": "string",
434
+ "enum": [
435
+ "deviceIdInactivity",
436
+ "deviceTagInactivity"
437
+ ]
438
+ },
439
+ "config": {
440
+ "type": "object",
441
+ "properties": {
442
+ "seconds": {
443
+ "type": "number"
444
+ }
445
+ },
446
+ "additionalProperties": false
447
+ },
448
+ "meta": {
449
+ "type": "object",
450
+ "properties": {
451
+ "category": {
452
+ "type": "string",
453
+ "enum": [
454
+ "trigger"
455
+ ]
456
+ },
457
+ "name": {
458
+ "type": "string",
459
+ "enum": [
460
+ "deviceIdsTagsInactivity"
461
+ ]
462
+ },
463
+ "label": {
464
+ "type": "string",
465
+ "minLength": 1,
466
+ "maxLength": 255
467
+ },
468
+ "x": {
469
+ "type": "number"
470
+ },
471
+ "y": {
472
+ "type": "number"
473
+ },
474
+ "uiId": {
475
+ "type": "string",
476
+ "maxLength": 48
477
+ },
478
+ "description": {
479
+ "type": "string",
480
+ "maxLength": 32767
481
+ },
482
+ "icon": {
483
+ "type": "string",
484
+ "maxLength": 1024
485
+ },
486
+ "color": {
487
+ "type": "string",
488
+ "maxLength": 1024
489
+ },
490
+ "inputCount": {
491
+ "type": "number"
492
+ },
493
+ "outputCount": {
494
+ "type": "number"
495
+ },
496
+ "id": {
497
+ "type": "string",
498
+ "maxLength": 48
499
+ }
500
+ },
501
+ "additionalProperties": false
502
+ },
503
+ "outputIds": {
504
+ "type": "array",
505
+ "items": {
506
+ "type": "array",
507
+ "items": {
508
+ "type": "string",
509
+ "maxLength": 255
510
+ },
511
+ "maxItems": 100
512
+ },
513
+ "maxItems": 100
514
+ }
515
+ },
516
+ "required": [
517
+ "type"
518
+ ],
519
+ "additionalProperties": false
520
+ },
521
+ {
522
+ "type": "object",
523
+ "properties": {
524
+ "key": {
525
+ "type": "string",
526
+ "maxLength": 1024
527
+ },
528
+ "type": {
529
+ "type": "string",
530
+ "enum": [
531
+ "endpoint"
532
+ ]
533
+ },
534
+ "config": {
535
+ "type": "object",
536
+ "properties": {
537
+ "experienceVersion": {
538
+ "type": "string",
539
+ "minLength": 1,
540
+ "maxLength": 255
541
+ }
542
+ },
543
+ "additionalProperties": false
544
+ },
545
+ "meta": {
546
+ "type": "object",
547
+ "properties": {
548
+ "category": {
549
+ "type": "string",
550
+ "enum": [
551
+ "trigger"
552
+ ]
553
+ },
554
+ "name": {
555
+ "type": "string",
556
+ "enum": [
557
+ "endpoint"
558
+ ]
559
+ },
560
+ "label": {
561
+ "type": "string",
562
+ "minLength": 1,
563
+ "maxLength": 255
564
+ },
565
+ "x": {
566
+ "type": "number"
567
+ },
568
+ "y": {
569
+ "type": "number"
570
+ },
571
+ "uiId": {
572
+ "type": "string",
573
+ "maxLength": 48
574
+ },
575
+ "description": {
576
+ "type": "string",
577
+ "maxLength": 32767
578
+ },
579
+ "icon": {
580
+ "type": "string",
581
+ "maxLength": 1024
582
+ },
583
+ "color": {
584
+ "type": "string",
585
+ "maxLength": 1024
586
+ },
587
+ "inputCount": {
588
+ "type": "number"
589
+ },
590
+ "outputCount": {
591
+ "type": "number"
592
+ },
593
+ "id": {
594
+ "type": "string",
595
+ "maxLength": 48
596
+ }
597
+ },
598
+ "additionalProperties": false
599
+ },
600
+ "outputIds": {
601
+ "type": "array",
602
+ "items": {
603
+ "type": "array",
604
+ "items": {
605
+ "type": "string",
606
+ "maxLength": 255
607
+ },
608
+ "maxItems": 100
609
+ },
610
+ "maxItems": 100
611
+ }
612
+ },
613
+ "required": [
614
+ "type"
615
+ ],
616
+ "additionalProperties": false
617
+ },
618
+ {
619
+ "type": "object",
620
+ "properties": {
621
+ "key": {
622
+ "type": "string",
623
+ "maxLength": 1024
624
+ },
625
+ "type": {
626
+ "type": "string",
627
+ "enum": [
628
+ "event"
629
+ ]
630
+ },
631
+ "config": {
632
+ "type": "object",
633
+ "properties": {
634
+ "subject": {
635
+ "type": "string",
636
+ "maxLength": 255
637
+ },
638
+ "new": {
639
+ "type": "boolean"
640
+ },
641
+ "acknowledged": {
642
+ "type": "boolean"
643
+ },
644
+ "resolved": {
645
+ "type": "boolean"
646
+ }
647
+ },
648
+ "additionalProperties": false
649
+ },
650
+ "meta": {
651
+ "type": "object",
652
+ "properties": {
653
+ "category": {
654
+ "type": "string",
655
+ "enum": [
656
+ "trigger"
657
+ ]
658
+ },
659
+ "name": {
660
+ "type": "string",
661
+ "enum": [
662
+ "event"
663
+ ]
664
+ },
665
+ "label": {
666
+ "type": "string",
667
+ "minLength": 1,
668
+ "maxLength": 255
669
+ },
670
+ "x": {
671
+ "type": "number"
672
+ },
673
+ "y": {
674
+ "type": "number"
675
+ },
676
+ "uiId": {
677
+ "type": "string",
678
+ "maxLength": 48
679
+ },
680
+ "description": {
681
+ "type": "string",
682
+ "maxLength": 32767
683
+ },
684
+ "icon": {
685
+ "type": "string",
686
+ "maxLength": 1024
687
+ },
688
+ "color": {
689
+ "type": "string",
690
+ "maxLength": 1024
691
+ },
692
+ "inputCount": {
693
+ "type": "number"
694
+ },
695
+ "outputCount": {
696
+ "type": "number"
697
+ },
698
+ "id": {
699
+ "type": "string",
700
+ "maxLength": 48
701
+ }
702
+ },
703
+ "additionalProperties": false
704
+ },
705
+ "outputIds": {
706
+ "type": "array",
707
+ "items": {
708
+ "type": "array",
709
+ "items": {
710
+ "type": "string",
711
+ "maxLength": 255
712
+ },
713
+ "maxItems": 100
714
+ },
715
+ "maxItems": 100
716
+ }
717
+ },
718
+ "required": [
719
+ "type"
720
+ ],
721
+ "additionalProperties": false
74
722
  },
75
- "type": {
76
- "type": "string",
77
- "enum": [
78
- "customNodeStart",
79
- "dataTable",
80
- "deviceCommand",
81
- "deviceId",
82
- "deviceIdConnect",
83
- "deviceIdDisconnect",
84
- "deviceIdInactivity",
85
- "deviceTag",
86
- "deviceTagConnect",
87
- "deviceTagDisconnect",
88
- "deviceTagInactivity",
89
- "endpoint",
90
- "event",
91
- "fileTail",
92
- "fileWatch",
93
- "integration",
94
- "mqttTopic",
95
- "notebook",
96
- "onBoot",
97
- "onConnect",
98
- "onDisconnect",
99
- "opcua",
100
- "redis",
101
- "request",
102
- "serial",
103
- "timer",
104
- "udp",
105
- "virtualButton",
106
- "webhook"
107
- ]
723
+ {
724
+ "type": "object",
725
+ "properties": {
726
+ "key": {
727
+ "type": "string",
728
+ "maxLength": 1024
729
+ },
730
+ "type": {
731
+ "type": "string",
732
+ "enum": [
733
+ "fileTail"
734
+ ]
735
+ },
736
+ "config": {
737
+ "type": "object",
738
+ "properties": {
739
+ "path": {
740
+ "type": "string",
741
+ "maxLength": 1024
742
+ },
743
+ "encoding": {
744
+ "type": "string",
745
+ "maxLength": 48
746
+ },
747
+ "byteLength": {
748
+ "type": "string",
749
+ "maxLength": 48
750
+ },
751
+ "delimiter": {
752
+ "type": "string",
753
+ "maxLength": 48
754
+ }
755
+ },
756
+ "additionalProperties": false
757
+ },
758
+ "meta": {
759
+ "type": "object",
760
+ "properties": {
761
+ "category": {
762
+ "type": "string",
763
+ "enum": [
764
+ "trigger"
765
+ ]
766
+ },
767
+ "name": {
768
+ "type": "string",
769
+ "enum": [
770
+ "fileTail"
771
+ ]
772
+ },
773
+ "label": {
774
+ "type": "string",
775
+ "minLength": 1,
776
+ "maxLength": 255
777
+ },
778
+ "x": {
779
+ "type": "number"
780
+ },
781
+ "y": {
782
+ "type": "number"
783
+ },
784
+ "uiId": {
785
+ "type": "string",
786
+ "maxLength": 48
787
+ },
788
+ "description": {
789
+ "type": "string",
790
+ "maxLength": 32767
791
+ },
792
+ "icon": {
793
+ "type": "string",
794
+ "maxLength": 1024
795
+ },
796
+ "color": {
797
+ "type": "string",
798
+ "maxLength": 1024
799
+ },
800
+ "inputCount": {
801
+ "type": "number"
802
+ },
803
+ "outputCount": {
804
+ "type": "number"
805
+ },
806
+ "id": {
807
+ "type": "string",
808
+ "maxLength": 48
809
+ }
810
+ },
811
+ "additionalProperties": false
812
+ },
813
+ "outputIds": {
814
+ "type": "array",
815
+ "items": {
816
+ "type": "array",
817
+ "items": {
818
+ "type": "string",
819
+ "maxLength": 255
820
+ },
821
+ "maxItems": 100
822
+ },
823
+ "maxItems": 100
824
+ }
825
+ },
826
+ "required": [
827
+ "type"
828
+ ],
829
+ "additionalProperties": false
830
+ },
831
+ {
832
+ "type": "object",
833
+ "properties": {
834
+ "key": {
835
+ "type": "string",
836
+ "maxLength": 1024
837
+ },
838
+ "type": {
839
+ "type": "string",
840
+ "enum": [
841
+ "fileWatch"
842
+ ]
843
+ },
844
+ "config": {
845
+ "type": "object",
846
+ "properties": {
847
+ "path": {
848
+ "type": "string",
849
+ "maxLength": 1024
850
+ },
851
+ "fileAdded": {
852
+ "type": "boolean"
853
+ },
854
+ "fileChanged": {
855
+ "type": "boolean"
856
+ },
857
+ "fileRemoved": {
858
+ "type": "boolean"
859
+ },
860
+ "directoryAdded": {
861
+ "type": "boolean"
862
+ },
863
+ "directoryRemoved": {
864
+ "type": "boolean"
865
+ }
866
+ },
867
+ "additionalProperties": false
868
+ },
869
+ "meta": {
870
+ "type": "object",
871
+ "properties": {
872
+ "category": {
873
+ "type": "string",
874
+ "enum": [
875
+ "trigger"
876
+ ]
877
+ },
878
+ "name": {
879
+ "type": "string",
880
+ "enum": [
881
+ "fileWatch"
882
+ ]
883
+ },
884
+ "label": {
885
+ "type": "string",
886
+ "minLength": 1,
887
+ "maxLength": 255
888
+ },
889
+ "x": {
890
+ "type": "number"
891
+ },
892
+ "y": {
893
+ "type": "number"
894
+ },
895
+ "uiId": {
896
+ "type": "string",
897
+ "maxLength": 48
898
+ },
899
+ "description": {
900
+ "type": "string",
901
+ "maxLength": 32767
902
+ },
903
+ "icon": {
904
+ "type": "string",
905
+ "maxLength": 1024
906
+ },
907
+ "color": {
908
+ "type": "string",
909
+ "maxLength": 1024
910
+ },
911
+ "inputCount": {
912
+ "type": "number"
913
+ },
914
+ "outputCount": {
915
+ "type": "number"
916
+ },
917
+ "id": {
918
+ "type": "string",
919
+ "maxLength": 48
920
+ }
921
+ },
922
+ "additionalProperties": false
923
+ },
924
+ "outputIds": {
925
+ "type": "array",
926
+ "items": {
927
+ "type": "array",
928
+ "items": {
929
+ "type": "string",
930
+ "maxLength": 255
931
+ },
932
+ "maxItems": 100
933
+ },
934
+ "maxItems": 100
935
+ }
936
+ },
937
+ "required": [
938
+ "type"
939
+ ],
940
+ "additionalProperties": false
941
+ },
942
+ {
943
+ "type": "object",
944
+ "properties": {
945
+ "key": {
946
+ "type": "string",
947
+ "maxLength": 1024
948
+ },
949
+ "type": {
950
+ "type": "string",
951
+ "enum": [
952
+ "opcua"
953
+ ]
954
+ },
955
+ "config": {
956
+ "type": "object",
957
+ "properties": {
958
+ "uri": {
959
+ "type": "string",
960
+ "maxLength": 1024
961
+ },
962
+ "securityPolicy": {
963
+ "type": "string",
964
+ "maxLength": 255
965
+ },
966
+ "securityMode": {
967
+ "type": "string",
968
+ "maxLength": 255
969
+ },
970
+ "username": {
971
+ "type": "string",
972
+ "maxLength": 1024
973
+ },
974
+ "password": {
975
+ "type": "string",
976
+ "maxLength": 1024
977
+ },
978
+ "cert": {
979
+ "type": "string",
980
+ "maxLength": 32767
981
+ },
982
+ "privateKey": {
983
+ "type": "string",
984
+ "maxLength": 32767
985
+ },
986
+ "nameSpace": {
987
+ "type": "string",
988
+ "maxLength": 255
989
+ },
990
+ "identifier": {
991
+ "type": "string",
992
+ "maxLength": 255
993
+ },
994
+ "samplingInterval": {
995
+ "type": "string",
996
+ "maxLength": 255
997
+ },
998
+ "eventFilter": {
999
+ "type": "array",
1000
+ "maxItems": 100,
1001
+ "items": {
1002
+ "type": "string",
1003
+ "maxLength": 255
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
+ "opcua"
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
+ "id": {
1058
+ "type": "string",
1059
+ "maxLength": 48
1060
+ }
1061
+ },
1062
+ "additionalProperties": false
1063
+ },
1064
+ "outputIds": {
1065
+ "type": "array",
1066
+ "items": {
1067
+ "type": "array",
1068
+ "items": {
1069
+ "type": "string",
1070
+ "maxLength": 255
1071
+ },
1072
+ "maxItems": 100
1073
+ },
1074
+ "maxItems": 100
1075
+ }
1076
+ },
1077
+ "required": [
1078
+ "type"
1079
+ ],
1080
+ "additionalProperties": false
1081
+ },
1082
+ {
1083
+ "type": "object",
1084
+ "properties": {
1085
+ "key": {
1086
+ "type": "string",
1087
+ "maxLength": 1024
1088
+ },
1089
+ "type": {
1090
+ "type": "string",
1091
+ "enum": [
1092
+ "redis"
1093
+ ]
1094
+ },
1095
+ "config": {
1096
+ "type": "object",
1097
+ "properties": {
1098
+ "host": {
1099
+ "type": "string",
1100
+ "maxLength": 1024
1101
+ },
1102
+ "port": {
1103
+ "type": "string",
1104
+ "maxLength": 16
1105
+ },
1106
+ "password": {
1107
+ "type": "string",
1108
+ "maxLength": 1024
1109
+ },
1110
+ "topic": {
1111
+ "type": "string",
1112
+ "maxLength": 1024
1113
+ },
1114
+ "fileAdded": {
1115
+ "type": "boolean"
1116
+ },
1117
+ "fileChanged": {
1118
+ "type": "boolean"
1119
+ },
1120
+ "fileRemoved": {
1121
+ "type": "boolean"
1122
+ },
1123
+ "directoryAdded": {
1124
+ "type": "boolean"
1125
+ },
1126
+ "directoryRemoved": {
1127
+ "type": "boolean"
1128
+ }
1129
+ },
1130
+ "additionalProperties": false
1131
+ },
1132
+ "meta": {
1133
+ "type": "object",
1134
+ "properties": {
1135
+ "category": {
1136
+ "type": "string",
1137
+ "enum": [
1138
+ "trigger"
1139
+ ]
1140
+ },
1141
+ "name": {
1142
+ "type": "string",
1143
+ "enum": [
1144
+ "redisTrigger"
1145
+ ]
1146
+ },
1147
+ "label": {
1148
+ "type": "string",
1149
+ "minLength": 1,
1150
+ "maxLength": 255
1151
+ },
1152
+ "x": {
1153
+ "type": "number"
1154
+ },
1155
+ "y": {
1156
+ "type": "number"
1157
+ },
1158
+ "uiId": {
1159
+ "type": "string",
1160
+ "maxLength": 48
1161
+ },
1162
+ "description": {
1163
+ "type": "string",
1164
+ "maxLength": 32767
1165
+ },
1166
+ "icon": {
1167
+ "type": "string",
1168
+ "maxLength": 1024
1169
+ },
1170
+ "color": {
1171
+ "type": "string",
1172
+ "maxLength": 1024
1173
+ },
1174
+ "inputCount": {
1175
+ "type": "number"
1176
+ },
1177
+ "outputCount": {
1178
+ "type": "number"
1179
+ },
1180
+ "id": {
1181
+ "type": "string",
1182
+ "maxLength": 48
1183
+ }
1184
+ },
1185
+ "additionalProperties": false
1186
+ },
1187
+ "outputIds": {
1188
+ "type": "array",
1189
+ "items": {
1190
+ "type": "array",
1191
+ "items": {
1192
+ "type": "string",
1193
+ "maxLength": 255
1194
+ },
1195
+ "maxItems": 100
1196
+ },
1197
+ "maxItems": 100
1198
+ }
1199
+ },
1200
+ "required": [
1201
+ "type"
1202
+ ],
1203
+ "additionalProperties": false
108
1204
  },
109
- "config": {
110
- "type": "object"
1205
+ {
1206
+ "type": "object",
1207
+ "properties": {
1208
+ "key": {
1209
+ "type": "string",
1210
+ "maxLength": 1024
1211
+ },
1212
+ "type": {
1213
+ "type": "string",
1214
+ "enum": [
1215
+ "serial"
1216
+ ]
1217
+ },
1218
+ "config": {
1219
+ "type": "object",
1220
+ "properties": {
1221
+ "path": {
1222
+ "type": "string",
1223
+ "maxLength": 1024
1224
+ },
1225
+ "baudRate": {
1226
+ "type": "number"
1227
+ },
1228
+ "encoding": {
1229
+ "type": "string",
1230
+ "maxLength": 48
1231
+ },
1232
+ "writeOnOpen": {
1233
+ "type": "string",
1234
+ "maxLength": 1024
1235
+ },
1236
+ "byteLength": {
1237
+ "type": "string",
1238
+ "maxLength": 48
1239
+ },
1240
+ "delimiter": {
1241
+ "type": "string",
1242
+ "maxLength": 48
1243
+ }
1244
+ },
1245
+ "additionalProperties": false
1246
+ },
1247
+ "meta": {
1248
+ "type": "object",
1249
+ "properties": {
1250
+ "category": {
1251
+ "type": "string",
1252
+ "enum": [
1253
+ "trigger"
1254
+ ]
1255
+ },
1256
+ "name": {
1257
+ "type": "string",
1258
+ "enum": [
1259
+ "serial"
1260
+ ]
1261
+ },
1262
+ "label": {
1263
+ "type": "string",
1264
+ "minLength": 1,
1265
+ "maxLength": 255
1266
+ },
1267
+ "x": {
1268
+ "type": "number"
1269
+ },
1270
+ "y": {
1271
+ "type": "number"
1272
+ },
1273
+ "uiId": {
1274
+ "type": "string",
1275
+ "maxLength": 48
1276
+ },
1277
+ "description": {
1278
+ "type": "string",
1279
+ "maxLength": 32767
1280
+ },
1281
+ "icon": {
1282
+ "type": "string",
1283
+ "maxLength": 1024
1284
+ },
1285
+ "color": {
1286
+ "type": "string",
1287
+ "maxLength": 1024
1288
+ },
1289
+ "inputCount": {
1290
+ "type": "number"
1291
+ },
1292
+ "outputCount": {
1293
+ "type": "number"
1294
+ },
1295
+ "id": {
1296
+ "type": "string",
1297
+ "maxLength": 48
1298
+ },
1299
+ "parseBy": {
1300
+ "type": "string",
1301
+ "enum": [
1302
+ "byteLength",
1303
+ "delimiter"
1304
+ ]
1305
+ }
1306
+ },
1307
+ "additionalProperties": false
1308
+ },
1309
+ "outputIds": {
1310
+ "type": "array",
1311
+ "items": {
1312
+ "type": "array",
1313
+ "items": {
1314
+ "type": "string",
1315
+ "maxLength": 255
1316
+ },
1317
+ "maxItems": 100
1318
+ },
1319
+ "maxItems": 100
1320
+ }
1321
+ },
1322
+ "required": [
1323
+ "type"
1324
+ ],
1325
+ "additionalProperties": false
111
1326
  },
112
- "meta": {
113
- "type": "object"
1327
+ {
1328
+ "type": "object",
1329
+ "properties": {
1330
+ "key": {
1331
+ "type": "string",
1332
+ "maxLength": 1024
1333
+ },
1334
+ "type": {
1335
+ "type": "string",
1336
+ "enum": [
1337
+ "timer"
1338
+ ]
1339
+ },
1340
+ "config": {
1341
+ "type": "object",
1342
+ "properties": {
1343
+ "seconds": {
1344
+ "type": "number"
1345
+ },
1346
+ "cron": {
1347
+ "type": "string",
1348
+ "maxLength": 255
1349
+ },
1350
+ "tz": {
1351
+ "type": "string",
1352
+ "maxLength": 255
1353
+ }
1354
+ },
1355
+ "additionalProperties": false
1356
+ },
1357
+ "meta": {
1358
+ "type": "object",
1359
+ "properties": {
1360
+ "category": {
1361
+ "type": "string",
1362
+ "enum": [
1363
+ "trigger"
1364
+ ]
1365
+ },
1366
+ "name": {
1367
+ "type": "string",
1368
+ "enum": [
1369
+ "timer"
1370
+ ]
1371
+ },
1372
+ "label": {
1373
+ "type": "string",
1374
+ "minLength": 1,
1375
+ "maxLength": 255
1376
+ },
1377
+ "x": {
1378
+ "type": "number"
1379
+ },
1380
+ "y": {
1381
+ "type": "number"
1382
+ },
1383
+ "uiId": {
1384
+ "type": "string",
1385
+ "maxLength": 48
1386
+ },
1387
+ "description": {
1388
+ "type": "string",
1389
+ "maxLength": 32767
1390
+ },
1391
+ "icon": {
1392
+ "type": "string",
1393
+ "maxLength": 1024
1394
+ },
1395
+ "color": {
1396
+ "type": "string",
1397
+ "maxLength": 1024
1398
+ },
1399
+ "inputCount": {
1400
+ "type": "number"
1401
+ },
1402
+ "outputCount": {
1403
+ "type": "number"
1404
+ },
1405
+ "id": {
1406
+ "type": "string",
1407
+ "maxLength": 48
1408
+ },
1409
+ "timerTypeSelect": {
1410
+ "type": "string",
1411
+ "enum": [
1412
+ "cronWeekly",
1413
+ "seconds",
1414
+ "cron"
1415
+ ]
1416
+ },
1417
+ "timeAt": {
1418
+ "type": "string",
1419
+ "maxLength": 255
1420
+ },
1421
+ "timezone": {
1422
+ "type": "string",
1423
+ "maxLength": 255
1424
+ },
1425
+ "weekdays": {
1426
+ "type": "array",
1427
+ "maxItems": 7,
1428
+ "items": {
1429
+ "type": "number"
1430
+ }
1431
+ }
1432
+ },
1433
+ "additionalProperties": false
1434
+ },
1435
+ "outputIds": {
1436
+ "type": "array",
1437
+ "items": {
1438
+ "type": "array",
1439
+ "items": {
1440
+ "type": "string",
1441
+ "maxLength": 255
1442
+ },
1443
+ "maxItems": 100
1444
+ },
1445
+ "maxItems": 100
1446
+ }
1447
+ },
1448
+ "required": [
1449
+ "type"
1450
+ ],
1451
+ "additionalProperties": false
114
1452
  },
115
- "outputIds": {
116
- "type": "array",
117
- "items": {
118
- "type": "array",
119
- "items": {
1453
+ {
1454
+ "type": "object",
1455
+ "properties": {
1456
+ "key": {
120
1457
  "type": "string",
121
- "maxLength": 255
1458
+ "maxLength": 1024
122
1459
  },
123
- "maxItems": 100
1460
+ "type": {
1461
+ "type": "string",
1462
+ "enum": [
1463
+ "virtualButton"
1464
+ ]
1465
+ },
1466
+ "config": {
1467
+ "type": "object",
1468
+ "additionalProperties": false
1469
+ },
1470
+ "meta": {
1471
+ "type": "object",
1472
+ "properties": {
1473
+ "category": {
1474
+ "type": "string",
1475
+ "enum": [
1476
+ "trigger"
1477
+ ]
1478
+ },
1479
+ "name": {
1480
+ "type": "string",
1481
+ "enum": [
1482
+ "virtualButton"
1483
+ ]
1484
+ },
1485
+ "label": {
1486
+ "type": "string",
1487
+ "minLength": 1,
1488
+ "maxLength": 255
1489
+ },
1490
+ "x": {
1491
+ "type": "number"
1492
+ },
1493
+ "y": {
1494
+ "type": "number"
1495
+ },
1496
+ "uiId": {
1497
+ "type": "string",
1498
+ "maxLength": 48
1499
+ },
1500
+ "groupId": {
1501
+ "type": "string",
1502
+ "maxLength": 48
1503
+ },
1504
+ "description": {
1505
+ "type": "string",
1506
+ "maxLength": 32767
1507
+ },
1508
+ "icon": {
1509
+ "type": "string",
1510
+ "maxLength": 1024
1511
+ },
1512
+ "color": {
1513
+ "type": "string",
1514
+ "maxLength": 1024
1515
+ },
1516
+ "inputCount": {
1517
+ "type": "number"
1518
+ },
1519
+ "outputCount": {
1520
+ "type": "number"
1521
+ },
1522
+ "id": {
1523
+ "type": "string",
1524
+ "maxLength": 48
1525
+ },
1526
+ "payload": {
1527
+ "type": "string",
1528
+ "maxLength": 262144
1529
+ },
1530
+ "deviceId": {
1531
+ "oneOf": [
1532
+ {
1533
+ "type": "string",
1534
+ "pattern": "^[A-Fa-f\\d]{24}$"
1535
+ },
1536
+ {
1537
+ "type": "string",
1538
+ "enum": [
1539
+ ""
1540
+ ]
1541
+ },
1542
+ {
1543
+ "type": "null"
1544
+ }
1545
+ ]
1546
+ }
1547
+ },
1548
+ "additionalProperties": false
1549
+ },
1550
+ "outputIds": {
1551
+ "type": "array",
1552
+ "items": {
1553
+ "type": "array",
1554
+ "items": {
1555
+ "type": "string",
1556
+ "maxLength": 255
1557
+ },
1558
+ "maxItems": 100
1559
+ },
1560
+ "maxItems": 100
1561
+ }
124
1562
  },
125
- "maxItems": 100
1563
+ "required": [
1564
+ "type"
1565
+ ],
1566
+ "additionalProperties": false
126
1567
  }
127
- },
128
- "additionalProperties": false,
129
- "required": [
130
- "type"
131
1568
  ]
132
1569
  }
133
1570
  },