losant_rest 1.1.2 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (80) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +29 -0
  3. data/docs/_schemas.md +1805 -267
  4. data/docs/auth.md +1 -1
  5. data/docs/experienceEndpoint.md +130 -0
  6. data/docs/experienceEndpoints.md +131 -0
  7. data/docs/experienceGroup.md +130 -0
  8. data/docs/experienceGroups.md +91 -0
  9. data/docs/experienceUser.md +130 -0
  10. data/docs/experienceUsers.md +92 -0
  11. data/docs/flows.md +1 -0
  12. data/lib/losant_rest/client.rb +26 -2
  13. data/lib/losant_rest/experience_endpoint.rb +174 -0
  14. data/lib/losant_rest/experience_endpoints.rb +186 -0
  15. data/lib/losant_rest/experience_group.rb +174 -0
  16. data/lib/losant_rest/experience_groups.rb +136 -0
  17. data/lib/losant_rest/experience_user.rb +174 -0
  18. data/lib/losant_rest/experience_users.rb +138 -0
  19. data/lib/losant_rest/flows.rb +2 -0
  20. data/lib/losant_rest/version.rb +1 -1
  21. data/lib/losant_rest.rb +6 -0
  22. data/schemas/application.json +30 -5
  23. data/schemas/applicationApiTokenPost.json +22 -0
  24. data/schemas/applicationKey.json +4 -2
  25. data/schemas/applicationKeyPost.json +4 -2
  26. data/schemas/applicationKeys.json +4 -2
  27. data/schemas/applicationPatch.json +13 -0
  28. data/schemas/applicationPost.json +13 -0
  29. data/schemas/applications.json +30 -5
  30. data/schemas/auditLog.json +3 -0
  31. data/schemas/auditLogFilter.json +3 -0
  32. data/schemas/auditLogs.json +3 -0
  33. data/schemas/authedDevice.json +1 -2
  34. data/schemas/dashboard.json +4 -2
  35. data/schemas/dashboardPatch.json +4 -2
  36. data/schemas/dashboardPost.json +4 -2
  37. data/schemas/dashboards.json +4 -2
  38. data/schemas/device.json +5 -4
  39. data/schemas/devicePatch.json +5 -4
  40. data/schemas/devicePost.json +5 -4
  41. data/schemas/deviceRecipe.json +5 -4
  42. data/schemas/deviceRecipePatch.json +5 -4
  43. data/schemas/deviceRecipePost.json +5 -4
  44. data/schemas/deviceRecipes.json +5 -4
  45. data/schemas/deviceTagFilter.json +2 -1
  46. data/schemas/devices.json +5 -4
  47. data/schemas/experienceEndpoint.json +74 -0
  48. data/schemas/experienceEndpointPatch.json +46 -0
  49. data/schemas/experienceEndpointPost.json +50 -0
  50. data/schemas/experienceEndpointStats.json +21 -0
  51. data/schemas/experienceEndpoints.json +45 -0
  52. data/schemas/experienceGroup.json +51 -0
  53. data/schemas/experienceGroupPatch.json +32 -0
  54. data/schemas/experienceGroupPost.json +35 -0
  55. data/schemas/experienceGroups.json +93 -0
  56. data/schemas/experienceUser.json +83 -0
  57. data/schemas/experienceUserPatch.json +48 -0
  58. data/schemas/experienceUserPost.json +52 -0
  59. data/schemas/experienceUsers.json +129 -0
  60. data/schemas/flow.json +34 -10
  61. data/schemas/flowLog.json +2 -19
  62. data/schemas/flowPatch.json +34 -10
  63. data/schemas/flowPost.json +34 -10
  64. data/schemas/flowTriggerFilter.json +19 -0
  65. data/schemas/flows.json +34 -10
  66. data/schemas/lastValueQuery.json +4 -2
  67. data/schemas/me.json +39 -7
  68. data/schemas/multiDeviceCommand.json +4 -2
  69. data/schemas/org.json +41 -9
  70. data/schemas/orgs.json +41 -9
  71. data/schemas/payloadCounts.json +8 -0
  72. data/schemas/resourceTransfer.json +6 -3
  73. data/schemas/solution.json +3 -1
  74. data/schemas/solutionUser.json +2 -1
  75. data/schemas/solutionUserPatch.json +2 -1
  76. data/schemas/solutionUserPost.json +2 -1
  77. data/schemas/solutionUsers.json +2 -1
  78. data/schemas/solutions.json +3 -1
  79. data/schemas/timeSeriesQuery.json +4 -2
  80. metadata +28 -2
data/docs/_schemas.md CHANGED
@@ -47,12 +47,26 @@
47
47
  * [Event Patch](#event-patch)
48
48
  * [Event Post](#event-post)
49
49
  * [Events](#events)
50
+ * [Experience Endpoint](#experience-endpoint)
51
+ * [Experience Endpoint Patch](#experience-endpoint-patch)
52
+ * [Experience Endpoint Post](#experience-endpoint-post)
53
+ * [Experience Endpoint Stats](#experience-endpoint-stats)
54
+ * [Experience Endpoints](#experience-endpoints)
55
+ * [Experience Group](#experience-group)
56
+ * [Experience Group Patch](#experience-group-patch)
57
+ * [Experience Group Post](#experience-group-post)
58
+ * [Experience Groups](#experience-groups)
59
+ * [Experience User](#experience-user)
60
+ * [Experience User Patch](#experience-user-patch)
61
+ * [Experience User Post](#experience-user-post)
62
+ * [Experience Users](#experience-users)
50
63
  * [Workflow](#workflow)
51
64
  * [Workflow Log](#workflow-log)
52
65
  * [Workflow Patch](#workflow-patch)
53
66
  * [Workflow Post](#workflow-post)
54
67
  * [Workflow Storage Entries](#workflow-storage-entries)
55
68
  * [Workflow Storage Entry](#workflow-storage-entry)
69
+ * [Workflow Trigger Filter](#workflow-trigger-filter)
56
70
  * [Workflows](#workflows)
57
71
  * [Github Login](#github-login)
58
72
  * [Last Value Data](#last-value-data)
@@ -78,7 +92,7 @@
78
92
  * [Solution Patch](#solution-patch)
79
93
  * [Solution Post](#solution-post)
80
94
  * [Solution User](#solution-user)
81
- * [User Credentials](#user-credentials)
95
+ * [Solution User Credentials](#solution-user-credentials)
82
96
  * [Solution User Patch](#solution-user-patch)
83
97
  * [Solution User Post](#solution-user-post)
84
98
  * [Solution Users](#solution-users)
@@ -294,25 +308,50 @@ Schema for a single Application
294
308
  "type": "string",
295
309
  "maxLength": 32767
296
310
  },
311
+ "endpointSlug": {
312
+ "type": "string",
313
+ "minLength": 4,
314
+ "maxLength": 255,
315
+ "pattern": "^[0-9a-z_-]*$"
316
+ },
317
+ "expUserTokenCutoff": {
318
+ "type": "string",
319
+ "format": "date-time"
320
+ },
321
+ "endpointDefaultCors": {
322
+ "type": "boolean"
323
+ },
297
324
  "summary": {
298
325
  "type": "object",
299
326
  "properties": {
300
- "deviceCount": {
327
+ "apiTokenCount": {
301
328
  "type": "number"
302
329
  },
303
- "flowCount": {
330
+ "keyCount": {
304
331
  "type": "number"
305
332
  },
306
- "webhookCount": {
333
+ "deviceCount": {
334
+ "type": "number"
335
+ },
336
+ "deviceRecipeCount": {
307
337
  "type": "number"
308
338
  },
309
339
  "eventCount": {
310
340
  "type": "number"
311
341
  },
312
- "keyCount": {
342
+ "experienceEndpointCount": {
313
343
  "type": "number"
314
344
  },
315
- "deviceRecipeCount": {
345
+ "experienceGroupCount": {
346
+ "type": "number"
347
+ },
348
+ "experienceUserCount": {
349
+ "type": "number"
350
+ },
351
+ "flowCount": {
352
+ "type": "number"
353
+ },
354
+ "webhookCount": {
316
355
  "type": "number"
317
356
  }
318
357
  }
@@ -390,6 +429,12 @@ Schema for the body of an Application API Token creation request
390
429
  "devices.*",
391
430
  "event.*",
392
431
  "events.*",
432
+ "experienceEndpoint.*",
433
+ "experienceEndpoints.*",
434
+ "experienceGroup.*",
435
+ "experienceGroups.*",
436
+ "experienceUser.*",
437
+ "experienceUsers.*",
393
438
  "flow.*",
394
439
  "flows.*",
395
440
  "webhook.*",
@@ -438,6 +483,22 @@ Schema for the body of an Application API Token creation request
438
483
  "events.mostRecentBySeverity",
439
484
  "events.patch",
440
485
  "events.post",
486
+ "experienceEndpoint.delete",
487
+ "experienceEndpoint.get",
488
+ "experienceEndpoint.patch",
489
+ "experienceEndpoints.get",
490
+ "experienceEndpoints.post",
491
+ "experienceEndpoints.stats",
492
+ "experienceGroup.delete",
493
+ "experienceGroup.get",
494
+ "experienceGroup.patch",
495
+ "experienceGroups.get",
496
+ "experienceGroups.post",
497
+ "experienceUser.delete",
498
+ "experienceUser.get",
499
+ "experienceUser.patch",
500
+ "experienceUsers.get",
501
+ "experienceUsers.post",
441
502
  "flow.delete",
442
503
  "flow.get",
443
504
  "flow.getStorageEntries",
@@ -533,7 +594,8 @@ Schema for a single Application Key
533
594
  "items": {
534
595
  "type": "string",
535
596
  "pattern": "^[A-Fa-f\\d]{24}$"
536
- }
597
+ },
598
+ "maxItems": 1000
537
599
  },
538
600
  "deviceTags": {
539
601
  "type": "array",
@@ -551,7 +613,8 @@ Schema for a single Application Key
551
613
  }
552
614
  },
553
615
  "additionalProperties": false
554
- }
616
+ },
617
+ "maxItems": 100
555
618
  },
556
619
  "description": {
557
620
  "type": "string",
@@ -630,7 +693,8 @@ Schema for the body of an Application Key creation request
630
693
  "items": {
631
694
  "type": "string",
632
695
  "pattern": "^[A-Fa-f\\d]{24}$"
633
- }
696
+ },
697
+ "maxItems": 1000
634
698
  },
635
699
  "deviceTags": {
636
700
  "type": "array",
@@ -648,7 +712,8 @@ Schema for the body of an Application Key creation request
648
712
  }
649
713
  },
650
714
  "additionalProperties": false
651
- }
715
+ },
716
+ "maxItems": 100
652
717
  },
653
718
  "description": {
654
719
  "type": "string",
@@ -724,7 +789,8 @@ Schema for a collection of Application Keys
724
789
  "items": {
725
790
  "type": "string",
726
791
  "pattern": "^[A-Fa-f\\d]{24}$"
727
- }
792
+ },
793
+ "maxItems": 1000
728
794
  },
729
795
  "deviceTags": {
730
796
  "type": "array",
@@ -742,7 +808,8 @@ Schema for a collection of Application Keys
742
808
  }
743
809
  },
744
810
  "additionalProperties": false
745
- }
811
+ },
812
+ "maxItems": 100
746
813
  },
747
814
  "description": {
748
815
  "type": "string",
@@ -833,6 +900,19 @@ Schema for the body of an Application modification request
833
900
  "description": {
834
901
  "type": "string",
835
902
  "maxLength": 32767
903
+ },
904
+ "endpointSlug": {
905
+ "type": "string",
906
+ "minLength": 4,
907
+ "maxLength": 255,
908
+ "pattern": "^[0-9a-z_-]*$"
909
+ },
910
+ "expUserTokenCutoff": {
911
+ "type": "string",
912
+ "format": "date-time"
913
+ },
914
+ "endpointDefaultCors": {
915
+ "type": "boolean"
836
916
  }
837
917
  },
838
918
  "additionalProperties": false
@@ -872,6 +952,19 @@ Schema for the body of an Application creation request
872
952
  "description": {
873
953
  "type": "string",
874
954
  "maxLength": 32767
955
+ },
956
+ "endpointSlug": {
957
+ "type": "string",
958
+ "minLength": 4,
959
+ "maxLength": 255,
960
+ "pattern": "^[0-9a-z_-]*$"
961
+ },
962
+ "expUserTokenCutoff": {
963
+ "type": "string",
964
+ "format": "date-time"
965
+ },
966
+ "endpointDefaultCors": {
967
+ "type": "boolean"
875
968
  }
876
969
  },
877
970
  "additionalProperties": false,
@@ -945,25 +1038,50 @@ Schema for a collection of Applications
945
1038
  "type": "string",
946
1039
  "maxLength": 32767
947
1040
  },
1041
+ "endpointSlug": {
1042
+ "type": "string",
1043
+ "minLength": 4,
1044
+ "maxLength": 255,
1045
+ "pattern": "^[0-9a-z_-]*$"
1046
+ },
1047
+ "expUserTokenCutoff": {
1048
+ "type": "string",
1049
+ "format": "date-time"
1050
+ },
1051
+ "endpointDefaultCors": {
1052
+ "type": "boolean"
1053
+ },
948
1054
  "summary": {
949
1055
  "type": "object",
950
1056
  "properties": {
951
- "deviceCount": {
1057
+ "apiTokenCount": {
952
1058
  "type": "number"
953
1059
  },
954
- "flowCount": {
1060
+ "keyCount": {
955
1061
  "type": "number"
956
1062
  },
957
- "webhookCount": {
1063
+ "deviceCount": {
1064
+ "type": "number"
1065
+ },
1066
+ "deviceRecipeCount": {
958
1067
  "type": "number"
959
1068
  },
960
1069
  "eventCount": {
961
1070
  "type": "number"
962
1071
  },
963
- "keyCount": {
1072
+ "experienceEndpointCount": {
964
1073
  "type": "number"
965
1074
  },
966
- "deviceRecipeCount": {
1075
+ "experienceGroupCount": {
1076
+ "type": "number"
1077
+ },
1078
+ "experienceUserCount": {
1079
+ "type": "number"
1080
+ },
1081
+ "flowCount": {
1082
+ "type": "number"
1083
+ },
1084
+ "webhookCount": {
967
1085
  "type": "number"
968
1086
  }
969
1087
  }
@@ -1093,6 +1211,9 @@ Schema for a single Audit Log entry
1093
1211
  "Device",
1094
1212
  "DeviceRecipe",
1095
1213
  "Event",
1214
+ "ExperienceEndpoint",
1215
+ "ExperienceGroup",
1216
+ "ExperienceUser",
1096
1217
  "Flow",
1097
1218
  "SolutionUser",
1098
1219
  "Webhook"
@@ -1233,6 +1354,9 @@ Schema for the filter of an audit log query
1233
1354
  "Device",
1234
1355
  "DeviceRecipe",
1235
1356
  "Event",
1357
+ "ExperienceEndpoint",
1358
+ "ExperienceGroup",
1359
+ "ExperienceUser",
1236
1360
  "Flow",
1237
1361
  "SolutionUser",
1238
1362
  "Webhook"
@@ -1390,6 +1514,9 @@ Schema for a collection of Audit Logs
1390
1514
  "Device",
1391
1515
  "DeviceRecipe",
1392
1516
  "Event",
1517
+ "ExperienceEndpoint",
1518
+ "ExperienceGroup",
1519
+ "ExperienceUser",
1393
1520
  "Flow",
1394
1521
  "SolutionUser",
1395
1522
  "Webhook"
@@ -1541,8 +1668,7 @@ Schema for the successful response when authenticating a Device
1541
1668
  "standalone",
1542
1669
  "gateway",
1543
1670
  "peripheral",
1544
- "floating",
1545
- "virtual"
1671
+ "floating"
1546
1672
  ]
1547
1673
  },
1548
1674
  "token": {
@@ -1873,7 +1999,8 @@ Schema for a single Dashboard
1873
1999
  "items": {
1874
2000
  "type": "string",
1875
2001
  "pattern": "^[A-Fa-f\\d]{24}$"
1876
- }
2002
+ },
2003
+ "maxItems": 1000
1877
2004
  },
1878
2005
  "deviceTags": {
1879
2006
  "type": "array",
@@ -1891,7 +2018,8 @@ Schema for a single Dashboard
1891
2018
  }
1892
2019
  },
1893
2020
  "additionalProperties": false
1894
- }
2021
+ },
2022
+ "maxItems": 100
1895
2023
  }
1896
2024
  },
1897
2025
  "additionalProperties": false
@@ -2095,7 +2223,8 @@ Schema for the body of a Dashboard modification request
2095
2223
  "items": {
2096
2224
  "type": "string",
2097
2225
  "pattern": "^[A-Fa-f\\d]{24}$"
2098
- }
2226
+ },
2227
+ "maxItems": 1000
2099
2228
  },
2100
2229
  "deviceTags": {
2101
2230
  "type": "array",
@@ -2113,7 +2242,8 @@ Schema for the body of a Dashboard modification request
2113
2242
  }
2114
2243
  },
2115
2244
  "additionalProperties": false
2116
- }
2245
+ },
2246
+ "maxItems": 100
2117
2247
  }
2118
2248
  },
2119
2249
  "additionalProperties": false
@@ -2283,7 +2413,8 @@ Schema for the body of a Dashboard creation request
2283
2413
  "items": {
2284
2414
  "type": "string",
2285
2415
  "pattern": "^[A-Fa-f\\d]{24}$"
2286
- }
2416
+ },
2417
+ "maxItems": 1000
2287
2418
  },
2288
2419
  "deviceTags": {
2289
2420
  "type": "array",
@@ -2301,7 +2432,8 @@ Schema for the body of a Dashboard creation request
2301
2432
  }
2302
2433
  },
2303
2434
  "additionalProperties": false
2304
- }
2435
+ },
2436
+ "maxItems": 100
2305
2437
  }
2306
2438
  },
2307
2439
  "additionalProperties": false
@@ -2499,7 +2631,8 @@ Schema for a collection of Dashboards
2499
2631
  "items": {
2500
2632
  "type": "string",
2501
2633
  "pattern": "^[A-Fa-f\\d]{24}$"
2502
- }
2634
+ },
2635
+ "maxItems": 1000
2503
2636
  },
2504
2637
  "deviceTags": {
2505
2638
  "type": "array",
@@ -2517,7 +2650,8 @@ Schema for a collection of Dashboards
2517
2650
  }
2518
2651
  },
2519
2652
  "additionalProperties": false
2520
- }
2653
+ },
2654
+ "maxItems": 100
2521
2655
  }
2522
2656
  },
2523
2657
  "additionalProperties": false
@@ -2655,7 +2789,8 @@ Schema for a single Device
2655
2789
  "value"
2656
2790
  ],
2657
2791
  "additionalProperties": false
2658
- }
2792
+ },
2793
+ "maxItems": 100
2659
2794
  },
2660
2795
  "attributes": {
2661
2796
  "type": "array",
@@ -2681,7 +2816,8 @@ Schema for a single Device
2681
2816
  "dataType"
2682
2817
  ],
2683
2818
  "additionalProperties": false
2684
- }
2819
+ },
2820
+ "maxItems": 100
2685
2821
  },
2686
2822
  "deviceClass": {
2687
2823
  "type": "string",
@@ -2689,8 +2825,7 @@ Schema for a single Device
2689
2825
  "standalone",
2690
2826
  "gateway",
2691
2827
  "peripheral",
2692
- "floating",
2693
- "virtual"
2828
+ "floating"
2694
2829
  ]
2695
2830
  },
2696
2831
  "gatewayId": {
@@ -3052,7 +3187,8 @@ Schema for the body of a Device modification request
3052
3187
  "value"
3053
3188
  ],
3054
3189
  "additionalProperties": false
3055
- }
3190
+ },
3191
+ "maxItems": 100
3056
3192
  },
3057
3193
  "attributes": {
3058
3194
  "type": "array",
@@ -3078,7 +3214,8 @@ Schema for the body of a Device modification request
3078
3214
  "dataType"
3079
3215
  ],
3080
3216
  "additionalProperties": false
3081
- }
3217
+ },
3218
+ "maxItems": 100
3082
3219
  },
3083
3220
  "deviceClass": {
3084
3221
  "type": "string",
@@ -3086,8 +3223,7 @@ Schema for the body of a Device modification request
3086
3223
  "standalone",
3087
3224
  "gateway",
3088
3225
  "peripheral",
3089
- "floating",
3090
- "virtual"
3226
+ "floating"
3091
3227
  ]
3092
3228
  },
3093
3229
  "gatewayId": {
@@ -3162,7 +3298,8 @@ Schema for the body of a Device creation request
3162
3298
  "value"
3163
3299
  ],
3164
3300
  "additionalProperties": false
3165
- }
3301
+ },
3302
+ "maxItems": 100
3166
3303
  },
3167
3304
  "attributes": {
3168
3305
  "type": "array",
@@ -3188,7 +3325,8 @@ Schema for the body of a Device creation request
3188
3325
  "dataType"
3189
3326
  ],
3190
3327
  "additionalProperties": false
3191
- }
3328
+ },
3329
+ "maxItems": 100
3192
3330
  },
3193
3331
  "deviceClass": {
3194
3332
  "type": "string",
@@ -3196,8 +3334,7 @@ Schema for the body of a Device creation request
3196
3334
  "standalone",
3197
3335
  "gateway",
3198
3336
  "peripheral",
3199
- "floating",
3200
- "virtual"
3337
+ "floating"
3201
3338
  ]
3202
3339
  },
3203
3340
  "gatewayId": {
@@ -3304,7 +3441,8 @@ Schema for a single Device Recipe
3304
3441
  "value"
3305
3442
  ],
3306
3443
  "additionalProperties": false
3307
- }
3444
+ },
3445
+ "maxItems": 100
3308
3446
  },
3309
3447
  "attributes": {
3310
3448
  "type": "array",
@@ -3330,7 +3468,8 @@ Schema for a single Device Recipe
3330
3468
  "dataType"
3331
3469
  ],
3332
3470
  "additionalProperties": false
3333
- }
3471
+ },
3472
+ "maxItems": 100
3334
3473
  },
3335
3474
  "deviceClass": {
3336
3475
  "type": "string",
@@ -3338,8 +3477,7 @@ Schema for a single Device Recipe
3338
3477
  "standalone",
3339
3478
  "gateway",
3340
3479
  "peripheral",
3341
- "floating",
3342
- "virtual"
3480
+ "floating"
3343
3481
  ]
3344
3482
  },
3345
3483
  "gatewayId": {
@@ -3503,7 +3641,8 @@ Schema for the body of a Device Recipe modification request
3503
3641
  "value"
3504
3642
  ],
3505
3643
  "additionalProperties": false
3506
- }
3644
+ },
3645
+ "maxItems": 100
3507
3646
  },
3508
3647
  "attributes": {
3509
3648
  "type": "array",
@@ -3529,7 +3668,8 @@ Schema for the body of a Device Recipe modification request
3529
3668
  "dataType"
3530
3669
  ],
3531
3670
  "additionalProperties": false
3532
- }
3671
+ },
3672
+ "maxItems": 100
3533
3673
  },
3534
3674
  "deviceClass": {
3535
3675
  "type": "string",
@@ -3537,8 +3677,7 @@ Schema for the body of a Device Recipe modification request
3537
3677
  "standalone",
3538
3678
  "gateway",
3539
3679
  "peripheral",
3540
- "floating",
3541
- "virtual"
3680
+ "floating"
3542
3681
  ]
3543
3682
  },
3544
3683
  "gatewayId": {
@@ -3624,7 +3763,8 @@ Schema for the body of a Device Recipe creation request
3624
3763
  "value"
3625
3764
  ],
3626
3765
  "additionalProperties": false
3627
- }
3766
+ },
3767
+ "maxItems": 100
3628
3768
  },
3629
3769
  "attributes": {
3630
3770
  "type": "array",
@@ -3650,7 +3790,8 @@ Schema for the body of a Device Recipe creation request
3650
3790
  "dataType"
3651
3791
  ],
3652
3792
  "additionalProperties": false
3653
- }
3793
+ },
3794
+ "maxItems": 100
3654
3795
  },
3655
3796
  "deviceClass": {
3656
3797
  "type": "string",
@@ -3658,8 +3799,7 @@ Schema for the body of a Device Recipe creation request
3658
3799
  "standalone",
3659
3800
  "gateway",
3660
3801
  "peripheral",
3661
- "floating",
3662
- "virtual"
3802
+ "floating"
3663
3803
  ]
3664
3804
  },
3665
3805
  "gatewayId": {
@@ -3775,7 +3915,8 @@ Schema for a collection of Device Recipes
3775
3915
  "value"
3776
3916
  ],
3777
3917
  "additionalProperties": false
3778
- }
3918
+ },
3919
+ "maxItems": 100
3779
3920
  },
3780
3921
  "attributes": {
3781
3922
  "type": "array",
@@ -3801,7 +3942,8 @@ Schema for a collection of Device Recipes
3801
3942
  "dataType"
3802
3943
  ],
3803
3944
  "additionalProperties": false
3804
- }
3945
+ },
3946
+ "maxItems": 100
3805
3947
  },
3806
3948
  "deviceClass": {
3807
3949
  "type": "string",
@@ -3809,8 +3951,7 @@ Schema for a collection of Device Recipes
3809
3951
  "standalone",
3810
3952
  "gateway",
3811
3953
  "peripheral",
3812
- "floating",
3813
- "virtual"
3954
+ "floating"
3814
3955
  ]
3815
3956
  },
3816
3957
  "gatewayId": {
@@ -4135,7 +4276,8 @@ Array of Tags for filtering devices. Tag keys and tag values are optional.
4135
4276
  }
4136
4277
  },
4137
4278
  "additionalProperties": false
4138
- }
4279
+ },
4280
+ "maxItems": 100
4139
4281
  }
4140
4282
  ```
4141
4283
  ### <a name="device-tag-filter-example"></a> Example
@@ -4221,7 +4363,8 @@ Schema for a collection of Devices
4221
4363
  "value"
4222
4364
  ],
4223
4365
  "additionalProperties": false
4224
- }
4366
+ },
4367
+ "maxItems": 100
4225
4368
  },
4226
4369
  "attributes": {
4227
4370
  "type": "array",
@@ -4247,7 +4390,8 @@ Schema for a collection of Devices
4247
4390
  "dataType"
4248
4391
  ],
4249
4392
  "additionalProperties": false
4250
- }
4393
+ },
4394
+ "maxItems": 100
4251
4395
  },
4252
4396
  "deviceClass": {
4253
4397
  "type": "string",
@@ -4255,8 +4399,7 @@ Schema for a collection of Devices
4255
4399
  "standalone",
4256
4400
  "gateway",
4257
4401
  "peripheral",
4258
- "floating",
4259
- "virtual"
4402
+ "floating"
4260
4403
  ]
4261
4404
  },
4262
4405
  "gatewayId": {
@@ -4928,11 +5071,11 @@ Schema for a collection of Events
4928
5071
 
4929
5072
  <br/>
4930
5073
 
4931
- ## Workflow
5074
+ ## Experience Endpoint
4932
5075
 
4933
- Schema for a single Workflow
5076
+ Schema for a single Experience Endpoint
4934
5077
 
4935
- ### <a name="workflow-schema"></a> Schema
5078
+ ### <a name="experience-endpoint-schema"></a> Schema
4936
5079
 
4937
5080
  ```json
4938
5081
  {
@@ -4943,7 +5086,7 @@ Schema for a single Workflow
4943
5086
  "type": "string",
4944
5087
  "pattern": "^[A-Fa-f\\d]{24}$"
4945
5088
  },
4946
- "flowId": {
5089
+ "experienceEndpointId": {
4947
5090
  "type": "string",
4948
5091
  "pattern": "^[A-Fa-f\\d]{24}$"
4949
5092
  },
@@ -4959,189 +5102,1351 @@ Schema for a single Workflow
4959
5102
  "type": "string",
4960
5103
  "format": "date-time"
4961
5104
  },
4962
- "name": {
4963
- "type": "string",
4964
- "minLength": 1,
4965
- "maxLength": 255
4966
- },
4967
5105
  "description": {
4968
5106
  "type": "string",
4969
5107
  "maxLength": 32767
4970
5108
  },
5109
+ "route": {
5110
+ "type": "string",
5111
+ "minLength": 1,
5112
+ "maxLength": 1024
5113
+ },
4971
5114
  "enabled": {
4972
5115
  "type": "boolean"
4973
5116
  },
4974
- "triggers": {
4975
- "type": "array",
4976
- "items": {
4977
- "type": "object",
4978
- "properties": {
4979
- "key": {
4980
- "type": "string"
4981
- },
4982
- "type": {
4983
- "type": "string"
4984
- },
4985
- "config": {
4986
- "type": "object"
4987
- },
4988
- "meta": {
4989
- "type": "object"
4990
- },
4991
- "outputIds": {
4992
- "type": "array",
4993
- "items": {
4994
- "type": "array",
4995
- "items": {
4996
- "type": "string"
4997
- }
4998
- }
4999
- }
5000
- },
5001
- "additionalProperties": false,
5002
- "required": [
5003
- "type"
5004
- ]
5005
- }
5117
+ "method": {
5118
+ "type": "string",
5119
+ "enum": [
5120
+ "delete",
5121
+ "get",
5122
+ "options",
5123
+ "patch",
5124
+ "post",
5125
+ "put"
5126
+ ]
5006
5127
  },
5007
- "nodes": {
5008
- "type": "array",
5009
- "items": {
5010
- "type": "object",
5011
- "properties": {
5012
- "id": {
5013
- "type": "string"
5014
- },
5015
- "type": {
5016
- "type": "string"
5017
- },
5018
- "config": {
5019
- "type": "object"
5020
- },
5021
- "meta": {
5022
- "type": "object"
5023
- },
5024
- "outputIds": {
5025
- "type": "array",
5026
- "items": {
5027
- "type": "array",
5028
- "items": {
5029
- "type": "string"
5030
- }
5031
- }
5032
- }
5033
- },
5034
- "additionalProperties": false,
5035
- "required": [
5036
- "type"
5037
- ]
5038
- }
5128
+ "access": {
5129
+ "type": "string",
5130
+ "enum": [
5131
+ "public",
5132
+ "authenticated",
5133
+ "group"
5134
+ ]
5039
5135
  },
5040
- "globals": {
5136
+ "experienceGroups": {
5041
5137
  "type": "array",
5042
5138
  "items": {
5043
5139
  "type": "object",
5044
5140
  "properties": {
5045
- "key": {
5141
+ "name": {
5046
5142
  "type": "string",
5047
- "pattern": "^[0-9a-zA-Z_-]{1,255}$"
5143
+ "minLength": 1,
5144
+ "maxLength": 255
5048
5145
  },
5049
- "json": {
5146
+ "id": {
5050
5147
  "type": "string",
5051
- "minLength": 1
5148
+ "pattern": "^[A-Fa-f\\d]{24}$"
5052
5149
  }
5053
- },
5054
- "additionalProperties": false,
5055
- "required": [
5056
- "key",
5057
- "json"
5058
- ]
5059
- }
5060
- },
5061
- "stats": {
5062
- "type": "object",
5063
- "properties": {
5064
- "runCount": {
5065
- "type": "number"
5066
- },
5067
- "errorCount": {
5068
- "type": "number"
5069
5150
  }
5070
5151
  }
5071
5152
  }
5072
5153
  }
5073
5154
  }
5074
5155
  ```
5075
- ### <a name="workflow-example"></a> Example
5156
+ ### <a name="experience-endpoint-example"></a> Example
5076
5157
 
5077
5158
  ```json
5078
5159
  {
5079
- "id": "575ed18f7ae143cd83dc4aa6",
5080
- "flowId": "575ed18f7ae143cd83dc4aa6",
5160
+ "id": "58c1de6c8f812590d8e82980",
5161
+ "experienceEndpointId": "58c1de6c8f812590d8e82980",
5081
5162
  "applicationId": "575ec8687ae143cd83dc4a97",
5082
5163
  "creationDate": "2016-06-13T04:00:00.000Z",
5083
5164
  "lastUpdated": "2016-06-13T04:00:00.000Z",
5084
- "name": "My Workflow",
5085
- "description": "Description of my empty workflow",
5165
+ "route": "/my/route/{id}",
5086
5166
  "enabled": true,
5087
- "triggers": [],
5088
- "nodes": [],
5089
- "globals": [],
5090
- "stats": {
5091
- "runCount": 0,
5092
- "errorCount": 0
5093
- }
5167
+ "method": "get",
5168
+ "access": "group",
5169
+ "experienceGroups": [
5170
+ {
5171
+ "name": "myGroup",
5172
+ "id": "58b9d794cbfafe1be675744f"
5173
+ }
5174
+ ]
5094
5175
  }
5095
5176
  ```
5096
5177
 
5097
5178
  <br/>
5098
5179
 
5099
- ## Workflow Log
5180
+ ## Experience Endpoint Patch
5100
5181
 
5101
- Log of workflow run information
5182
+ Schema for the body of an Experience Endpoint modification request
5102
5183
 
5103
- ### <a name="workflow-log-schema"></a> Schema
5184
+ ### <a name="experience-endpoint-patch-schema"></a> Schema
5104
5185
 
5105
5186
  ```json
5106
5187
  {
5107
5188
  "$schema": "http://json-schema.org/draft-04/schema#",
5108
- "type": "array",
5109
- "items": {
5110
- "type": "object",
5111
- "properties": {
5112
- "time": {
5189
+ "type": "object",
5190
+ "properties": {
5191
+ "description": {
5192
+ "type": "string",
5193
+ "maxLength": 32767
5194
+ },
5195
+ "route": {
5196
+ "type": "string",
5197
+ "minLength": 1,
5198
+ "maxLength": 1024
5199
+ },
5200
+ "enabled": {
5201
+ "type": "boolean"
5202
+ },
5203
+ "method": {
5204
+ "type": "string",
5205
+ "enum": [
5206
+ "delete",
5207
+ "get",
5208
+ "options",
5209
+ "patch",
5210
+ "post",
5211
+ "put"
5212
+ ]
5213
+ },
5214
+ "access": {
5215
+ "type": "string",
5216
+ "enum": [
5217
+ "public",
5218
+ "authenticated",
5219
+ "group"
5220
+ ]
5221
+ },
5222
+ "experienceGroupIds": {
5223
+ "type": "array",
5224
+ "items": {
5225
+ "type": "string",
5226
+ "pattern": "^[A-Fa-f\\d]{24}$"
5227
+ },
5228
+ "maxItems": 1000
5229
+ }
5230
+ },
5231
+ "additionalProperties": false
5232
+ }
5233
+ ```
5234
+ ### <a name="experience-endpoint-patch-example"></a> Example
5235
+
5236
+ ```json
5237
+ {
5238
+ "access": "group",
5239
+ "experienceGroupIds": [
5240
+ "58c1de6f8f812590d8e82983"
5241
+ ]
5242
+ }
5243
+ ```
5244
+
5245
+ <br/>
5246
+
5247
+ ## Experience Endpoint Post
5248
+
5249
+ Schema for the body of an Experience Endpoint creation request
5250
+
5251
+ ### <a name="experience-endpoint-post-schema"></a> Schema
5252
+
5253
+ ```json
5254
+ {
5255
+ "$schema": "http://json-schema.org/draft-04/schema#",
5256
+ "type": "object",
5257
+ "properties": {
5258
+ "description": {
5259
+ "type": "string",
5260
+ "maxLength": 32767
5261
+ },
5262
+ "route": {
5263
+ "type": "string",
5264
+ "minLength": 1,
5265
+ "maxLength": 1024
5266
+ },
5267
+ "enabled": {
5268
+ "type": "boolean"
5269
+ },
5270
+ "method": {
5271
+ "type": "string",
5272
+ "enum": [
5273
+ "delete",
5274
+ "get",
5275
+ "options",
5276
+ "patch",
5277
+ "post",
5278
+ "put"
5279
+ ]
5280
+ },
5281
+ "access": {
5282
+ "type": "string",
5283
+ "enum": [
5284
+ "public",
5285
+ "authenticated",
5286
+ "group"
5287
+ ]
5288
+ },
5289
+ "experienceGroupIds": {
5290
+ "type": "array",
5291
+ "items": {
5292
+ "type": "string",
5293
+ "pattern": "^[A-Fa-f\\d]{24}$"
5294
+ },
5295
+ "maxItems": 1000
5296
+ }
5297
+ },
5298
+ "additionalProperties": false,
5299
+ "required": [
5300
+ "route",
5301
+ "method"
5302
+ ]
5303
+ }
5304
+ ```
5305
+ ### <a name="experience-endpoint-post-example"></a> Example
5306
+
5307
+ ```json
5308
+ {
5309
+ "route": "/my/route/{id}",
5310
+ "method": "get",
5311
+ "access": "public"
5312
+ }
5313
+ ```
5314
+
5315
+ <br/>
5316
+
5317
+ ## Experience Endpoint Stats
5318
+
5319
+ Schema for stats for an experience&#x27;s endpoints
5320
+
5321
+ ### <a name="experience-endpoint-stats-schema"></a> Schema
5322
+
5323
+ ```json
5324
+ {
5325
+ "$schema": "http://json-schema.org/draft-04/schema#",
5326
+ "type": "object",
5327
+ "patternProperties": {
5328
+ ".*": {
5329
+ "type": "array",
5330
+ "items": {
5331
+ "type": "object",
5332
+ "properties": {
5333
+ "time": {
5334
+ "type": "string",
5335
+ "format": "date-time"
5336
+ },
5337
+ "count": {
5338
+ "type": "number"
5339
+ }
5340
+ }
5341
+ }
5342
+ }
5343
+ }
5344
+ }
5345
+ ```
5346
+ ### <a name="experience-endpoint-stats-example"></a> Example
5347
+
5348
+ ```json
5349
+ {
5350
+ "58cae95a0f5fcd000138ed0d": [
5351
+ {
5352
+ "time": "2017-03-21T20:00:00.000Z",
5353
+ "count": 10
5354
+ },
5355
+ {
5356
+ "time": "2017-03-21T21:00:00.000Z",
5357
+ "count": 1
5358
+ }
5359
+ ],
5360
+ "NotFound": [
5361
+ {
5362
+ "time": "2017-03-21T20:00:00.000Z",
5363
+ "count": 1
5364
+ },
5365
+ {
5366
+ "time": "2017-03-21T21:00:00.000Z",
5367
+ "count": 4
5368
+ }
5369
+ ]
5370
+ }
5371
+ ```
5372
+
5373
+ <br/>
5374
+
5375
+ ## Experience Endpoints
5376
+
5377
+ Schema for a collection of Experience Endpoints
5378
+
5379
+ ### <a name="experience-endpoints-schema"></a> Schema
5380
+
5381
+ ```json
5382
+ {
5383
+ "$schema": "http://json-schema.org/draft-04/schema#",
5384
+ "type": "object",
5385
+ "properties": {
5386
+ "items": {
5387
+ "type": "array",
5388
+ "items": {
5389
+ "$ref": "#/definitions/experienceEndpoints"
5390
+ }
5391
+ },
5392
+ "count": {
5393
+ "type": "integer"
5394
+ },
5395
+ "totalCount": {
5396
+ "type": "integer"
5397
+ },
5398
+ "filter": {
5399
+ "type": "string"
5400
+ },
5401
+ "filterField": {
5402
+ "type": "string"
5403
+ },
5404
+ "sortField": {
5405
+ "type": "string"
5406
+ },
5407
+ "sortDirection": {
5408
+ "type": "string",
5409
+ "enum": [
5410
+ "asc",
5411
+ "desc"
5412
+ ]
5413
+ },
5414
+ "applicationId": {
5415
+ "type": "string",
5416
+ "pattern": "^[A-Fa-f\\d]{24}$"
5417
+ },
5418
+ "experienceGroupId": {
5419
+ "type": "string",
5420
+ "pattern": "^[A-Fa-f\\d]{24}$"
5421
+ },
5422
+ "notFoundRequestCount": {
5423
+ "type": "number"
5424
+ }
5425
+ }
5426
+ }
5427
+ ```
5428
+ ### <a name="experience-endpoints-example"></a> Example
5429
+
5430
+ ```json
5431
+ {
5432
+ "items": [
5433
+ {
5434
+ "id": "58c1de6c8f812590d8e82980",
5435
+ "experienceEndpointId": "58c1de6c8f812590d8e82980",
5436
+ "applicationId": "575ec8687ae143cd83dc4a97",
5437
+ "creationDate": "2016-06-13T04:00:00.000Z",
5438
+ "lastUpdated": "2016-06-13T04:00:00.000Z",
5439
+ "route": "/my/route/{id}",
5440
+ "enabled": true,
5441
+ "method": "get",
5442
+ "access": "group",
5443
+ "experienceGroups": [
5444
+ {
5445
+ "name": "myGroup",
5446
+ "id": "58b9d794cbfafe1be675744f"
5447
+ }
5448
+ ]
5449
+ }
5450
+ ],
5451
+ "count": 1,
5452
+ "totalCount": 4,
5453
+ "perPage": 1,
5454
+ "page": 0,
5455
+ "sortField": "name",
5456
+ "sortDirection": "asc",
5457
+ "applicationId": "575ec8687ae143cd83dc4a97"
5458
+ }
5459
+ ```
5460
+
5461
+ <br/>
5462
+
5463
+ ## Experience Group
5464
+
5465
+ Schema for a single Experience Group
5466
+
5467
+ ### <a name="experience-group-schema"></a> Schema
5468
+
5469
+ ```json
5470
+ {
5471
+ "$schema": "http://json-schema.org/draft-04/schema#",
5472
+ "type": "object",
5473
+ "properties": {
5474
+ "id": {
5475
+ "type": "string",
5476
+ "pattern": "^[A-Fa-f\\d]{24}$"
5477
+ },
5478
+ "experienceGroupId": {
5479
+ "type": "string",
5480
+ "pattern": "^[A-Fa-f\\d]{24}$"
5481
+ },
5482
+ "applicationId": {
5483
+ "type": "string",
5484
+ "pattern": "^[A-Fa-f\\d]{24}$"
5485
+ },
5486
+ "creationDate": {
5487
+ "type": "string",
5488
+ "format": "date-time"
5489
+ },
5490
+ "lastUpdated": {
5491
+ "type": "string",
5492
+ "format": "date-time"
5493
+ },
5494
+ "name": {
5495
+ "type": "string",
5496
+ "minLength": 1,
5497
+ "maxLength": 255
5498
+ },
5499
+ "description": {
5500
+ "type": "string",
5501
+ "maxLength": 32767
5502
+ },
5503
+ "experienceUserIds": {
5504
+ "type": "array",
5505
+ "items": {
5506
+ "type": "string",
5507
+ "pattern": "^[A-Fa-f\\d]{24}$"
5508
+ },
5509
+ "maxItems": 1000
5510
+ },
5511
+ "experienceEndpointIds": {
5512
+ "type": "array",
5513
+ "items": {
5514
+ "type": "string",
5515
+ "pattern": "^[A-Fa-f\\d]{24}$"
5516
+ },
5517
+ "maxItems": 1000
5518
+ }
5519
+ }
5520
+ }
5521
+ ```
5522
+ ### <a name="experience-group-example"></a> Example
5523
+
5524
+ ```json
5525
+ {
5526
+ "id": "58b9d794cbfafe1be675744f",
5527
+ "experienceGroupId": "58b9d794cbfafe1be675744f",
5528
+ "applicationId": "575ec8687ae143cd83dc4a97",
5529
+ "creationDate": "2016-06-13T04:00:00.000Z",
5530
+ "lastUpdated": "2016-06-13T04:00:00.000Z",
5531
+ "name": "My Group",
5532
+ "experienceUserIds": [
5533
+ "58b9d782cbfafe1be675744d",
5534
+ "58b9d787cbfafe1be675744e"
5535
+ ],
5536
+ "experienceEndpointIds": [
5537
+ "58b9d743cbfafe1be675744b",
5538
+ "58b9d743cbfafe1be675744c"
5539
+ ]
5540
+ }
5541
+ ```
5542
+
5543
+ <br/>
5544
+
5545
+ ## Experience Group Patch
5546
+
5547
+ Schema for the body of an Experience Group modification request
5548
+
5549
+ ### <a name="experience-group-patch-schema"></a> Schema
5550
+
5551
+ ```json
5552
+ {
5553
+ "$schema": "http://json-schema.org/draft-04/schema#",
5554
+ "type": "object",
5555
+ "properties": {
5556
+ "name": {
5557
+ "type": "string",
5558
+ "minLength": 1,
5559
+ "maxLength": 255
5560
+ },
5561
+ "description": {
5562
+ "type": "string",
5563
+ "maxLength": 32767
5564
+ },
5565
+ "experienceUserIds": {
5566
+ "type": "array",
5567
+ "items": {
5568
+ "type": "string",
5569
+ "pattern": "^[A-Fa-f\\d]{24}$"
5570
+ },
5571
+ "maxItems": 1000
5572
+ },
5573
+ "experienceEndpointIds": {
5574
+ "type": "array",
5575
+ "items": {
5576
+ "type": "string",
5577
+ "pattern": "^[A-Fa-f\\d]{24}$"
5578
+ },
5579
+ "maxItems": 1000
5580
+ }
5581
+ },
5582
+ "additionalProperties": false
5583
+ }
5584
+ ```
5585
+ ### <a name="experience-group-patch-example"></a> Example
5586
+
5587
+ ```json
5588
+ {
5589
+ "name": "My New Group Name",
5590
+ "experienceUserIds": [
5591
+ "575ed70c7ae143cd83dc4aa9",
5592
+ "675ed70c7ae143cd83dc4aa9"
5593
+ ],
5594
+ "experienceEndpointIds": [
5595
+ "58b9d743cbfafe1be675744b",
5596
+ "58b9d743cbfafe1be675744c"
5597
+ ]
5598
+ }
5599
+ ```
5600
+
5601
+ <br/>
5602
+
5603
+ ## Experience Group Post
5604
+
5605
+ Schema for the body of an Experience Group creation request
5606
+
5607
+ ### <a name="experience-group-post-schema"></a> Schema
5608
+
5609
+ ```json
5610
+ {
5611
+ "$schema": "http://json-schema.org/draft-04/schema#",
5612
+ "type": "object",
5613
+ "properties": {
5614
+ "name": {
5615
+ "type": "string",
5616
+ "minLength": 1,
5617
+ "maxLength": 255
5618
+ },
5619
+ "description": {
5620
+ "type": "string",
5621
+ "maxLength": 32767
5622
+ },
5623
+ "experienceUserIds": {
5624
+ "type": "array",
5625
+ "items": {
5626
+ "type": "string",
5627
+ "pattern": "^[A-Fa-f\\d]{24}$"
5628
+ },
5629
+ "maxItems": 1000
5630
+ },
5631
+ "experienceEndpointIds": {
5632
+ "type": "array",
5633
+ "items": {
5634
+ "type": "string",
5635
+ "pattern": "^[A-Fa-f\\d]{24}$"
5636
+ },
5637
+ "maxItems": 1000
5638
+ }
5639
+ },
5640
+ "additionalProperties": false,
5641
+ "required": [
5642
+ "name"
5643
+ ]
5644
+ }
5645
+ ```
5646
+ ### <a name="experience-group-post-example"></a> Example
5647
+
5648
+ ```json
5649
+ {
5650
+ "name": "My Group",
5651
+ "experienceUserIds": [
5652
+ "575ed70c7ae143cd83dc4aa9",
5653
+ "675ed70c7ae143cd83dc4aa9"
5654
+ ],
5655
+ "experienceEndpointIds": [
5656
+ "58b9d743cbfafe1be675744b",
5657
+ "58b9d743cbfafe1be675744c"
5658
+ ]
5659
+ }
5660
+ ```
5661
+
5662
+ <br/>
5663
+
5664
+ ## Experience Groups
5665
+
5666
+ Schema for a collection of Experience Groups
5667
+
5668
+ ### <a name="experience-groups-schema"></a> Schema
5669
+
5670
+ ```json
5671
+ {
5672
+ "$schema": "http://json-schema.org/draft-04/schema#",
5673
+ "type": "object",
5674
+ "properties": {
5675
+ "items": {
5676
+ "type": "array",
5677
+ "items": {
5678
+ "title": "Experience Group",
5679
+ "description": "Schema for a single Experience Group",
5680
+ "type": "object",
5681
+ "properties": {
5682
+ "id": {
5683
+ "type": "string",
5684
+ "pattern": "^[A-Fa-f\\d]{24}$"
5685
+ },
5686
+ "experienceGroupId": {
5687
+ "type": "string",
5688
+ "pattern": "^[A-Fa-f\\d]{24}$"
5689
+ },
5690
+ "applicationId": {
5691
+ "type": "string",
5692
+ "pattern": "^[A-Fa-f\\d]{24}$"
5693
+ },
5694
+ "creationDate": {
5695
+ "type": "string",
5696
+ "format": "date-time"
5697
+ },
5698
+ "lastUpdated": {
5699
+ "type": "string",
5700
+ "format": "date-time"
5701
+ },
5702
+ "name": {
5703
+ "type": "string",
5704
+ "minLength": 1,
5705
+ "maxLength": 255
5706
+ },
5707
+ "description": {
5708
+ "type": "string",
5709
+ "maxLength": 32767
5710
+ },
5711
+ "experienceUserIds": {
5712
+ "type": "array",
5713
+ "items": {
5714
+ "type": "string",
5715
+ "pattern": "^[A-Fa-f\\d]{24}$"
5716
+ },
5717
+ "maxItems": 1000
5718
+ },
5719
+ "experienceEndpointIds": {
5720
+ "type": "array",
5721
+ "items": {
5722
+ "type": "string",
5723
+ "pattern": "^[A-Fa-f\\d]{24}$"
5724
+ },
5725
+ "maxItems": 1000
5726
+ }
5727
+ }
5728
+ }
5729
+ },
5730
+ "count": {
5731
+ "type": "integer"
5732
+ },
5733
+ "totalCount": {
5734
+ "type": "integer"
5735
+ },
5736
+ "perPage": {
5737
+ "type": "integer"
5738
+ },
5739
+ "page": {
5740
+ "type": "integer"
5741
+ },
5742
+ "filter": {
5743
+ "type": "string"
5744
+ },
5745
+ "filterField": {
5746
+ "type": "string"
5747
+ },
5748
+ "sortField": {
5749
+ "type": "string"
5750
+ },
5751
+ "sortDirection": {
5752
+ "type": "string",
5753
+ "enum": [
5754
+ "asc",
5755
+ "desc"
5756
+ ]
5757
+ },
5758
+ "applicationId": {
5759
+ "type": "string",
5760
+ "pattern": "^[A-Fa-f\\d]{24}$"
5761
+ }
5762
+ }
5763
+ }
5764
+ ```
5765
+ ### <a name="experience-groups-example"></a> Example
5766
+
5767
+ ```json
5768
+ {
5769
+ "items": [
5770
+ {
5771
+ "id": "58b9d794cbfafe1be675744f",
5772
+ "experienceGroupId": "58b9d794cbfafe1be675744f",
5773
+ "applicationId": "575ec8687ae143cd83dc4a97",
5774
+ "creationDate": "2016-06-13T04:00:00.000Z",
5775
+ "lastUpdated": "2016-06-13T04:00:00.000Z",
5776
+ "name": "My Group",
5777
+ "experienceUserIds": [
5778
+ "58b9d782cbfafe1be675744d",
5779
+ "58b9d787cbfafe1be675744e"
5780
+ ],
5781
+ "experienceEndpointIds": [
5782
+ "58b9d743cbfafe1be675744b",
5783
+ "58b9d743cbfafe1be675744c"
5784
+ ]
5785
+ }
5786
+ ],
5787
+ "count": 1,
5788
+ "totalCount": 4,
5789
+ "perPage": 1,
5790
+ "page": 0,
5791
+ "sortField": "name",
5792
+ "sortDirection": "asc",
5793
+ "applicationId": "575ec8687ae143cd83dc4a97"
5794
+ }
5795
+ ```
5796
+
5797
+ <br/>
5798
+
5799
+ ## Experience User
5800
+
5801
+ Schema for a single Experience User
5802
+
5803
+ ### <a name="experience-user-schema"></a> Schema
5804
+
5805
+ ```json
5806
+ {
5807
+ "$schema": "http://json-schema.org/draft-04/schema#",
5808
+ "type": "object",
5809
+ "properties": {
5810
+ "id": {
5811
+ "type": "string",
5812
+ "pattern": "^[A-Fa-f\\d]{24}$"
5813
+ },
5814
+ "experienceUserId": {
5815
+ "type": "string",
5816
+ "pattern": "^[A-Fa-f\\d]{24}$"
5817
+ },
5818
+ "applicationId": {
5819
+ "type": "string",
5820
+ "pattern": "^[A-Fa-f\\d]{24}$"
5821
+ },
5822
+ "creationDate": {
5823
+ "type": "string",
5824
+ "format": "date-time"
5825
+ },
5826
+ "lastUpdated": {
5827
+ "type": "string",
5828
+ "format": "date-time"
5829
+ },
5830
+ "passwordLastUpdated": {
5831
+ "type": "string",
5832
+ "format": "date-time"
5833
+ },
5834
+ "lastLogin": {
5835
+ "type": "string",
5836
+ "format": "date-time"
5837
+ },
5838
+ "email": {
5839
+ "type": "string",
5840
+ "format": "email",
5841
+ "maxLength": 1024
5842
+ },
5843
+ "firstName": {
5844
+ "type": "string",
5845
+ "maxLength": 1024
5846
+ },
5847
+ "lastName": {
5848
+ "type": "string",
5849
+ "maxLength": 1024
5850
+ },
5851
+ "avatarUrl": {
5852
+ "type": "string",
5853
+ "format": "url"
5854
+ },
5855
+ "tokenCutoff": {
5856
+ "type": "string",
5857
+ "format": "date-time"
5858
+ },
5859
+ "userTags": {
5860
+ "type": "object",
5861
+ "patternProperties": {
5862
+ "^[0-9a-zA-Z_-]{1,255}$": {
5863
+ "type": "string",
5864
+ "minLength": 1,
5865
+ "maxLength": 255
5866
+ }
5867
+ },
5868
+ "additionalProperties": false
5869
+ },
5870
+ "experienceGroups": {
5871
+ "type": "array",
5872
+ "items": {
5873
+ "type": "object",
5874
+ "properties": {
5875
+ "name": {
5876
+ "type": "string",
5877
+ "minLength": 1,
5878
+ "maxLength": 255
5879
+ },
5880
+ "id": {
5881
+ "type": "string",
5882
+ "pattern": "^[A-Fa-f\\d]{24}$"
5883
+ }
5884
+ }
5885
+ }
5886
+ }
5887
+ }
5888
+ }
5889
+ ```
5890
+ ### <a name="experience-user-example"></a> Example
5891
+
5892
+ ```json
5893
+ {
5894
+ "id": "58b9d782cbfafe1be675744d",
5895
+ "experienceUserId": "58b9d782cbfafe1be675744d",
5896
+ "applicationId": "575ec8687ae143cd83dc4a97",
5897
+ "creationDate": "2016-06-13T04:00:00.000Z",
5898
+ "lastUpdated": "2016-06-13T04:00:00.000Z",
5899
+ "passwordLastUpdated": "2016-06-13T04:00:00.000Z",
5900
+ "lastLogin": "2016-06-13T04:00:00.000Z",
5901
+ "email": "example@experienceuser.com",
5902
+ "firstName": "Example",
5903
+ "lastName": "Name",
5904
+ "avatarUrl": "https://example.avatar.url/is_here.png",
5905
+ "userTags": {
5906
+ "customKey": "customValue"
5907
+ }
5908
+ }
5909
+ ```
5910
+
5911
+ <br/>
5912
+
5913
+ ## Experience User Patch
5914
+
5915
+ Schema for the body of an Experience User modification request
5916
+
5917
+ ### <a name="experience-user-patch-schema"></a> Schema
5918
+
5919
+ ```json
5920
+ {
5921
+ "$schema": "http://json-schema.org/draft-04/schema#",
5922
+ "type": "object",
5923
+ "properties": {
5924
+ "email": {
5925
+ "type": "string",
5926
+ "format": "email",
5927
+ "maxLength": 1024
5928
+ },
5929
+ "firstName": {
5930
+ "type": "string",
5931
+ "maxLength": 1024
5932
+ },
5933
+ "lastName": {
5934
+ "type": "string",
5935
+ "maxLength": 1024
5936
+ },
5937
+ "password": {
5938
+ "type": "string",
5939
+ "minLength": 8,
5940
+ "maxLength": 2048
5941
+ },
5942
+ "tokenCutoff": {
5943
+ "type": "string",
5944
+ "format": "date-time"
5945
+ },
5946
+ "userTags": {
5947
+ "type": "object",
5948
+ "patternProperties": {
5949
+ "^[0-9a-zA-Z_-]{1,255}$": {
5950
+ "type": "string",
5951
+ "minLength": 1,
5952
+ "maxLength": 255
5953
+ }
5954
+ },
5955
+ "additionalProperties": false
5956
+ },
5957
+ "experienceGroupIds": {
5958
+ "type": "array",
5959
+ "items": {
5960
+ "type": "string",
5961
+ "pattern": "^[A-Fa-f\\d]{24}$"
5962
+ },
5963
+ "maxItems": 1000
5964
+ }
5965
+ },
5966
+ "additionalProperties": false
5967
+ }
5968
+ ```
5969
+ ### <a name="experience-user-patch-example"></a> Example
5970
+
5971
+ ```json
5972
+ {
5973
+ "password": "aNewPassword",
5974
+ "userTags": {
5975
+ "customKey": "newCustomValue"
5976
+ }
5977
+ }
5978
+ ```
5979
+
5980
+ <br/>
5981
+
5982
+ ## Experience User Post
5983
+
5984
+ Schema for the body of an Experience User creation request
5985
+
5986
+ ### <a name="experience-user-post-schema"></a> Schema
5987
+
5988
+ ```json
5989
+ {
5990
+ "$schema": "http://json-schema.org/draft-04/schema#",
5991
+ "type": "object",
5992
+ "properties": {
5993
+ "email": {
5994
+ "type": "string",
5995
+ "format": "email",
5996
+ "maxLength": 1024
5997
+ },
5998
+ "firstName": {
5999
+ "type": "string",
6000
+ "maxLength": 1024
6001
+ },
6002
+ "lastName": {
6003
+ "type": "string",
6004
+ "maxLength": 1024
6005
+ },
6006
+ "password": {
6007
+ "type": "string",
6008
+ "minLength": 8,
6009
+ "maxLength": 2048
6010
+ },
6011
+ "tokenCutoff": {
6012
+ "type": "string",
6013
+ "format": "date-time"
6014
+ },
6015
+ "userTags": {
6016
+ "type": "object",
6017
+ "patternProperties": {
6018
+ "^[0-9a-zA-Z_-]{1,255}$": {
6019
+ "type": "string",
6020
+ "minLength": 1,
6021
+ "maxLength": 255
6022
+ }
6023
+ },
6024
+ "additionalProperties": false
6025
+ },
6026
+ "experienceGroupIds": {
6027
+ "type": "array",
6028
+ "items": {
6029
+ "type": "string",
6030
+ "pattern": "^[A-Fa-f\\d]{24}$"
6031
+ },
6032
+ "maxItems": 1000
6033
+ }
6034
+ },
6035
+ "additionalProperties": false,
6036
+ "required": [
6037
+ "email",
6038
+ "password"
6039
+ ]
6040
+ }
6041
+ ```
6042
+ ### <a name="experience-user-post-example"></a> Example
6043
+
6044
+ ```json
6045
+ {
6046
+ "email": "example@experienceuser.com",
6047
+ "firstName": "Example",
6048
+ "lastName": "Name",
6049
+ "password": "aUserPassword",
6050
+ "userTags": {
6051
+ "customKey": "customValue"
6052
+ }
6053
+ }
6054
+ ```
6055
+
6056
+ <br/>
6057
+
6058
+ ## Experience Users
6059
+
6060
+ Schema for a collection of Experience Users
6061
+
6062
+ ### <a name="experience-users-schema"></a> Schema
6063
+
6064
+ ```json
6065
+ {
6066
+ "$schema": "http://json-schema.org/draft-04/schema#",
6067
+ "type": "object",
6068
+ "properties": {
6069
+ "items": {
6070
+ "type": "array",
6071
+ "items": {
6072
+ "title": "Experience User",
6073
+ "description": "Schema for a single Experience User",
6074
+ "type": "object",
6075
+ "properties": {
6076
+ "id": {
6077
+ "type": "string",
6078
+ "pattern": "^[A-Fa-f\\d]{24}$"
6079
+ },
6080
+ "experienceUserId": {
6081
+ "type": "string",
6082
+ "pattern": "^[A-Fa-f\\d]{24}$"
6083
+ },
6084
+ "applicationId": {
6085
+ "type": "string",
6086
+ "pattern": "^[A-Fa-f\\d]{24}$"
6087
+ },
6088
+ "creationDate": {
6089
+ "type": "string",
6090
+ "format": "date-time"
6091
+ },
6092
+ "lastUpdated": {
6093
+ "type": "string",
6094
+ "format": "date-time"
6095
+ },
6096
+ "passwordLastUpdated": {
6097
+ "type": "string",
6098
+ "format": "date-time"
6099
+ },
6100
+ "lastLogin": {
6101
+ "type": "string",
6102
+ "format": "date-time"
6103
+ },
6104
+ "email": {
6105
+ "type": "string",
6106
+ "format": "email",
6107
+ "maxLength": 1024
6108
+ },
6109
+ "firstName": {
6110
+ "type": "string",
6111
+ "maxLength": 1024
6112
+ },
6113
+ "lastName": {
6114
+ "type": "string",
6115
+ "maxLength": 1024
6116
+ },
6117
+ "avatarUrl": {
6118
+ "type": "string",
6119
+ "format": "url"
6120
+ },
6121
+ "tokenCutoff": {
6122
+ "type": "string",
6123
+ "format": "date-time"
6124
+ },
6125
+ "userTags": {
6126
+ "type": "object",
6127
+ "patternProperties": {
6128
+ "^[0-9a-zA-Z_-]{1,255}$": {
6129
+ "type": "string",
6130
+ "minLength": 1,
6131
+ "maxLength": 255
6132
+ }
6133
+ },
6134
+ "additionalProperties": false
6135
+ },
6136
+ "experienceGroups": {
6137
+ "type": "array",
6138
+ "items": {
6139
+ "type": "object",
6140
+ "properties": {
6141
+ "name": {
6142
+ "type": "string",
6143
+ "minLength": 1,
6144
+ "maxLength": 255
6145
+ },
6146
+ "id": {
6147
+ "type": "string",
6148
+ "pattern": "^[A-Fa-f\\d]{24}$"
6149
+ }
6150
+ }
6151
+ }
6152
+ }
6153
+ }
6154
+ }
6155
+ },
6156
+ "count": {
6157
+ "type": "integer"
6158
+ },
6159
+ "totalCount": {
6160
+ "type": "integer"
6161
+ },
6162
+ "perPage": {
6163
+ "type": "integer"
6164
+ },
6165
+ "page": {
6166
+ "type": "integer"
6167
+ },
6168
+ "filter": {
6169
+ "type": "string"
6170
+ },
6171
+ "filterField": {
6172
+ "type": "string"
6173
+ },
6174
+ "sortField": {
6175
+ "type": "string"
6176
+ },
6177
+ "sortDirection": {
6178
+ "type": "string",
6179
+ "enum": [
6180
+ "asc",
6181
+ "desc"
6182
+ ]
6183
+ },
6184
+ "applicationId": {
6185
+ "type": "string",
6186
+ "pattern": "^[A-Fa-f\\d]{24}$"
6187
+ },
6188
+ "experienceGroupId": {
6189
+ "type": "string",
6190
+ "pattern": "^[A-Fa-f\\d]{24}$"
6191
+ }
6192
+ }
6193
+ }
6194
+ ```
6195
+ ### <a name="experience-users-example"></a> Example
6196
+
6197
+ ```json
6198
+ {
6199
+ "items": [
6200
+ {
6201
+ "id": "58b9d782cbfafe1be675744d",
6202
+ "experienceUserId": "58b9d782cbfafe1be675744d",
6203
+ "applicationId": "575ec8687ae143cd83dc4a97",
6204
+ "creationDate": "2016-06-13T04:00:00.000Z",
6205
+ "lastUpdated": "2016-06-13T04:00:00.000Z",
6206
+ "passwordLastUpdated": "2016-06-13T04:00:00.000Z",
6207
+ "lastLogin": "2016-06-13T04:00:00.000Z",
6208
+ "email": "example@experienceuser.com",
6209
+ "firstName": "Example",
6210
+ "lastName": "Name",
6211
+ "avatarUrl": "https://example.avatar.url/is_here.png",
6212
+ "userTags": {
6213
+ "customKey": "customValue"
6214
+ }
6215
+ }
6216
+ ],
6217
+ "count": 1,
6218
+ "totalCount": 4,
6219
+ "perPage": 1,
6220
+ "page": 0,
6221
+ "sortField": "name",
6222
+ "sortDirection": "asc",
6223
+ "applicationId": "575ec8687ae143cd83dc4a97"
6224
+ }
6225
+ ```
6226
+
6227
+ <br/>
6228
+
6229
+ ## Workflow
6230
+
6231
+ Schema for a single Workflow
6232
+
6233
+ ### <a name="workflow-schema"></a> Schema
6234
+
6235
+ ```json
6236
+ {
6237
+ "$schema": "http://json-schema.org/draft-04/schema#",
6238
+ "type": "object",
6239
+ "properties": {
6240
+ "id": {
6241
+ "type": "string",
6242
+ "pattern": "^[A-Fa-f\\d]{24}$"
6243
+ },
6244
+ "flowId": {
6245
+ "type": "string",
6246
+ "pattern": "^[A-Fa-f\\d]{24}$"
6247
+ },
6248
+ "applicationId": {
6249
+ "type": "string",
6250
+ "pattern": "^[A-Fa-f\\d]{24}$"
6251
+ },
6252
+ "creationDate": {
6253
+ "type": "string",
6254
+ "format": "date-time"
6255
+ },
6256
+ "lastUpdated": {
6257
+ "type": "string",
6258
+ "format": "date-time"
6259
+ },
6260
+ "name": {
6261
+ "type": "string",
6262
+ "minLength": 1,
6263
+ "maxLength": 255
6264
+ },
6265
+ "description": {
6266
+ "type": "string",
6267
+ "maxLength": 32767
6268
+ },
6269
+ "enabled": {
6270
+ "type": "boolean"
6271
+ },
6272
+ "triggers": {
6273
+ "type": "array",
6274
+ "items": {
6275
+ "type": "object",
6276
+ "properties": {
6277
+ "key": {
6278
+ "type": "string",
6279
+ "maxLength": 1024
6280
+ },
6281
+ "type": {
6282
+ "type": "string",
6283
+ "enum": [
6284
+ "deviceId",
6285
+ "deviceTag",
6286
+ "mqttTopic",
6287
+ "webhook",
6288
+ "timer",
6289
+ "event",
6290
+ "virtualButton",
6291
+ "endpoint",
6292
+ "deviceIdConnect",
6293
+ "deviceIdDisconnect",
6294
+ "deviceTagConnect",
6295
+ "deviceTagDisconnect"
6296
+ ]
6297
+ },
6298
+ "config": {
6299
+ "type": "object"
6300
+ },
6301
+ "meta": {
6302
+ "type": "object"
6303
+ },
6304
+ "outputIds": {
6305
+ "type": "array",
6306
+ "items": {
6307
+ "type": "array",
6308
+ "items": {
6309
+ "type": "string",
6310
+ "maxLength": 255
6311
+ },
6312
+ "maxItems": 100
6313
+ },
6314
+ "maxItems": 100
6315
+ }
6316
+ },
6317
+ "additionalProperties": false,
6318
+ "required": [
6319
+ "type"
6320
+ ]
6321
+ }
6322
+ },
6323
+ "nodes": {
6324
+ "type": "array",
6325
+ "items": {
6326
+ "type": "object",
6327
+ "properties": {
6328
+ "id": {
6329
+ "type": "string",
6330
+ "maxLength": 1024
6331
+ },
6332
+ "type": {
6333
+ "type": "string",
6334
+ "minLength": 1,
6335
+ "maxLength": 1024
6336
+ },
6337
+ "config": {
6338
+ "type": "object"
6339
+ },
6340
+ "meta": {
6341
+ "type": "object"
6342
+ },
6343
+ "outputIds": {
6344
+ "type": "array",
6345
+ "items": {
6346
+ "type": "array",
6347
+ "items": {
6348
+ "type": "string",
6349
+ "maxLength": 255
6350
+ },
6351
+ "maxItems": 100
6352
+ },
6353
+ "maxItems": 100
6354
+ }
6355
+ },
6356
+ "additionalProperties": false,
6357
+ "required": [
6358
+ "type"
6359
+ ]
6360
+ }
6361
+ },
6362
+ "globals": {
6363
+ "type": "array",
6364
+ "items": {
6365
+ "type": "object",
6366
+ "properties": {
6367
+ "key": {
6368
+ "type": "string",
6369
+ "pattern": "^[0-9a-zA-Z_-]{1,255}$"
6370
+ },
6371
+ "json": {
6372
+ "type": "string",
6373
+ "minLength": 1
6374
+ }
6375
+ },
6376
+ "additionalProperties": false,
6377
+ "required": [
6378
+ "key",
6379
+ "json"
6380
+ ]
6381
+ }
6382
+ },
6383
+ "stats": {
6384
+ "type": "object",
6385
+ "properties": {
6386
+ "runCount": {
6387
+ "type": "number"
6388
+ },
6389
+ "errorCount": {
6390
+ "type": "number"
6391
+ }
6392
+ }
6393
+ }
6394
+ }
6395
+ }
6396
+ ```
6397
+ ### <a name="workflow-example"></a> Example
6398
+
6399
+ ```json
6400
+ {
6401
+ "id": "575ed18f7ae143cd83dc4aa6",
6402
+ "flowId": "575ed18f7ae143cd83dc4aa6",
6403
+ "applicationId": "575ec8687ae143cd83dc4a97",
6404
+ "creationDate": "2016-06-13T04:00:00.000Z",
6405
+ "lastUpdated": "2016-06-13T04:00:00.000Z",
6406
+ "name": "My Workflow",
6407
+ "description": "Description of my empty workflow",
6408
+ "enabled": true,
6409
+ "triggers": [],
6410
+ "nodes": [],
6411
+ "globals": [],
6412
+ "stats": {
6413
+ "runCount": 0,
6414
+ "errorCount": 0
6415
+ }
6416
+ }
6417
+ ```
6418
+
6419
+ <br/>
6420
+
6421
+ ## Workflow Log
6422
+
6423
+ Log of aggregated workflow run information
6424
+
6425
+ ### <a name="workflow-log-schema"></a> Schema
6426
+
6427
+ ```json
6428
+ {
6429
+ "$schema": "http://json-schema.org/draft-04/schema#",
6430
+ "type": "array",
6431
+ "items": {
6432
+ "type": "object",
6433
+ "properties": {
6434
+ "time": {
5113
6435
  "type": "string",
5114
6436
  "format": "date-time"
5115
6437
  },
5116
- "errorCount": {
6438
+ "pathsFailed": {
5117
6439
  "type": "number"
5118
6440
  },
5119
6441
  "pathsCompleted": {
5120
6442
  "type": "number"
5121
6443
  },
5122
- "totalCount": {
5123
- "type": "number"
5124
- },
5125
- "totalTime": {
6444
+ "runCount": {
5126
6445
  "type": "number"
5127
6446
  },
5128
6447
  "wallTime": {
5129
6448
  "type": "number"
5130
6449
  },
5131
- "nodes": {
5132
- "type": "object",
5133
- "additionalProperties": {
5134
- "type": "object",
5135
- "properties": {
5136
- "time": {
5137
- "type": "number"
5138
- },
5139
- "count": {
5140
- "type": "number"
5141
- }
5142
- }
5143
- }
5144
- },
5145
6450
  "errors": {
5146
6451
  "type": "array",
5147
6452
  "items": {}
@@ -5218,10 +6523,25 @@ Schema for the body of a Workflow modification request
5218
6523
  "type": "object",
5219
6524
  "properties": {
5220
6525
  "key": {
5221
- "type": "string"
6526
+ "type": "string",
6527
+ "maxLength": 1024
5222
6528
  },
5223
6529
  "type": {
5224
- "type": "string"
6530
+ "type": "string",
6531
+ "enum": [
6532
+ "deviceId",
6533
+ "deviceTag",
6534
+ "mqttTopic",
6535
+ "webhook",
6536
+ "timer",
6537
+ "event",
6538
+ "virtualButton",
6539
+ "endpoint",
6540
+ "deviceIdConnect",
6541
+ "deviceIdDisconnect",
6542
+ "deviceTagConnect",
6543
+ "deviceTagDisconnect"
6544
+ ]
5225
6545
  },
5226
6546
  "config": {
5227
6547
  "type": "object"
@@ -5234,9 +6554,12 @@ Schema for the body of a Workflow modification request
5234
6554
  "items": {
5235
6555
  "type": "array",
5236
6556
  "items": {
5237
- "type": "string"
5238
- }
5239
- }
6557
+ "type": "string",
6558
+ "maxLength": 255
6559
+ },
6560
+ "maxItems": 100
6561
+ },
6562
+ "maxItems": 100
5240
6563
  }
5241
6564
  },
5242
6565
  "additionalProperties": false,
@@ -5251,10 +6574,13 @@ Schema for the body of a Workflow modification request
5251
6574
  "type": "object",
5252
6575
  "properties": {
5253
6576
  "id": {
5254
- "type": "string"
6577
+ "type": "string",
6578
+ "maxLength": 1024
5255
6579
  },
5256
6580
  "type": {
5257
- "type": "string"
6581
+ "type": "string",
6582
+ "minLength": 1,
6583
+ "maxLength": 1024
5258
6584
  },
5259
6585
  "config": {
5260
6586
  "type": "object"
@@ -5267,9 +6593,12 @@ Schema for the body of a Workflow modification request
5267
6593
  "items": {
5268
6594
  "type": "array",
5269
6595
  "items": {
5270
- "type": "string"
5271
- }
5272
- }
6596
+ "type": "string",
6597
+ "maxLength": 255
6598
+ },
6599
+ "maxItems": 100
6600
+ },
6601
+ "maxItems": 100
5273
6602
  }
5274
6603
  },
5275
6604
  "additionalProperties": false,
@@ -5344,10 +6673,25 @@ Schema for the body of a Workflow creation request
5344
6673
  "type": "object",
5345
6674
  "properties": {
5346
6675
  "key": {
5347
- "type": "string"
6676
+ "type": "string",
6677
+ "maxLength": 1024
5348
6678
  },
5349
6679
  "type": {
5350
- "type": "string"
6680
+ "type": "string",
6681
+ "enum": [
6682
+ "deviceId",
6683
+ "deviceTag",
6684
+ "mqttTopic",
6685
+ "webhook",
6686
+ "timer",
6687
+ "event",
6688
+ "virtualButton",
6689
+ "endpoint",
6690
+ "deviceIdConnect",
6691
+ "deviceIdDisconnect",
6692
+ "deviceTagConnect",
6693
+ "deviceTagDisconnect"
6694
+ ]
5351
6695
  },
5352
6696
  "config": {
5353
6697
  "type": "object"
@@ -5360,9 +6704,12 @@ Schema for the body of a Workflow creation request
5360
6704
  "items": {
5361
6705
  "type": "array",
5362
6706
  "items": {
5363
- "type": "string"
5364
- }
5365
- }
6707
+ "type": "string",
6708
+ "maxLength": 255
6709
+ },
6710
+ "maxItems": 100
6711
+ },
6712
+ "maxItems": 100
5366
6713
  }
5367
6714
  },
5368
6715
  "additionalProperties": false,
@@ -5377,10 +6724,13 @@ Schema for the body of a Workflow creation request
5377
6724
  "type": "object",
5378
6725
  "properties": {
5379
6726
  "id": {
5380
- "type": "string"
6727
+ "type": "string",
6728
+ "maxLength": 1024
5381
6729
  },
5382
6730
  "type": {
5383
- "type": "string"
6731
+ "type": "string",
6732
+ "minLength": 1,
6733
+ "maxLength": 1024
5384
6734
  },
5385
6735
  "config": {
5386
6736
  "type": "object"
@@ -5393,9 +6743,12 @@ Schema for the body of a Workflow creation request
5393
6743
  "items": {
5394
6744
  "type": "array",
5395
6745
  "items": {
5396
- "type": "string"
5397
- }
5398
- }
6746
+ "type": "string",
6747
+ "maxLength": 255
6748
+ },
6749
+ "maxItems": 100
6750
+ },
6751
+ "maxItems": 100
5399
6752
  }
5400
6753
  },
5401
6754
  "additionalProperties": false,
@@ -5508,6 +6861,46 @@ Schema for the body of a request to set a Workflow storage entry
5508
6861
 
5509
6862
  <br/>
5510
6863
 
6864
+ ## Workflow Trigger Filter
6865
+
6866
+ Array of triggers for filtering workflows. Trigger keys and trigger types are optional.
6867
+
6868
+ ### <a name="workflow-trigger-filter-schema"></a> Schema
6869
+
6870
+ ```json
6871
+ {
6872
+ "$schema": "http://json-schema.org/draft-04/schema#",
6873
+ "type": "array",
6874
+ "items": {
6875
+ "type": "object",
6876
+ "properties": {
6877
+ "key": {
6878
+ "type": "string",
6879
+ "maxLength": 1024
6880
+ },
6881
+ "type": {
6882
+ "type": "string",
6883
+ "maxLength": 1024
6884
+ }
6885
+ },
6886
+ "additionalProperties": false
6887
+ },
6888
+ "maxItems": 100
6889
+ }
6890
+ ```
6891
+ ### <a name="workflow-trigger-filter-example"></a> Example
6892
+
6893
+ ```json
6894
+ [
6895
+ {
6896
+ "type": "webhook",
6897
+ "key": "575ed78e7ae143cd83dc4aab"
6898
+ }
6899
+ ]
6900
+ ```
6901
+
6902
+ <br/>
6903
+
5511
6904
  ## Workflows
5512
6905
 
5513
6906
  Schema for a collection of Workflows
@@ -5564,10 +6957,25 @@ Schema for a collection of Workflows
5564
6957
  "type": "object",
5565
6958
  "properties": {
5566
6959
  "key": {
5567
- "type": "string"
6960
+ "type": "string",
6961
+ "maxLength": 1024
5568
6962
  },
5569
6963
  "type": {
5570
- "type": "string"
6964
+ "type": "string",
6965
+ "enum": [
6966
+ "deviceId",
6967
+ "deviceTag",
6968
+ "mqttTopic",
6969
+ "webhook",
6970
+ "timer",
6971
+ "event",
6972
+ "virtualButton",
6973
+ "endpoint",
6974
+ "deviceIdConnect",
6975
+ "deviceIdDisconnect",
6976
+ "deviceTagConnect",
6977
+ "deviceTagDisconnect"
6978
+ ]
5571
6979
  },
5572
6980
  "config": {
5573
6981
  "type": "object"
@@ -5580,9 +6988,12 @@ Schema for a collection of Workflows
5580
6988
  "items": {
5581
6989
  "type": "array",
5582
6990
  "items": {
5583
- "type": "string"
5584
- }
5585
- }
6991
+ "type": "string",
6992
+ "maxLength": 255
6993
+ },
6994
+ "maxItems": 100
6995
+ },
6996
+ "maxItems": 100
5586
6997
  }
5587
6998
  },
5588
6999
  "additionalProperties": false,
@@ -5597,10 +7008,13 @@ Schema for a collection of Workflows
5597
7008
  "type": "object",
5598
7009
  "properties": {
5599
7010
  "id": {
5600
- "type": "string"
7011
+ "type": "string",
7012
+ "maxLength": 1024
5601
7013
  },
5602
7014
  "type": {
5603
- "type": "string"
7015
+ "type": "string",
7016
+ "minLength": 1,
7017
+ "maxLength": 1024
5604
7018
  },
5605
7019
  "config": {
5606
7020
  "type": "object"
@@ -5613,9 +7027,12 @@ Schema for a collection of Workflows
5613
7027
  "items": {
5614
7028
  "type": "array",
5615
7029
  "items": {
5616
- "type": "string"
5617
- }
5618
- }
7030
+ "type": "string",
7031
+ "maxLength": 255
7032
+ },
7033
+ "maxItems": 100
7034
+ },
7035
+ "maxItems": 100
5619
7036
  }
5620
7037
  },
5621
7038
  "additionalProperties": false,
@@ -5855,14 +7272,16 @@ Schema for the body of a last value query request
5855
7272
  }
5856
7273
  },
5857
7274
  "additionalProperties": false
5858
- }
7275
+ },
7276
+ "maxItems": 100
5859
7277
  },
5860
7278
  "deviceIds": {
5861
7279
  "type": "array",
5862
7280
  "items": {
5863
7281
  "type": "string",
5864
7282
  "pattern": "^[A-Fa-f\\d]{24}$"
5865
- }
7283
+ },
7284
+ "maxItems": 1000
5866
7285
  }
5867
7286
  },
5868
7287
  "additionalProperties": false
@@ -5964,6 +7383,9 @@ Schema for information about the currently authenticated user
5964
7383
  "format": "url"
5965
7384
  },
5966
7385
  "limits": {
7386
+ "apitoken": {
7387
+ "type": "number"
7388
+ },
5967
7389
  "application": {
5968
7390
  "type": "number"
5969
7391
  },
@@ -5979,6 +7401,15 @@ Schema for information about the currently authenticated user
5979
7401
  "devicerecipe": {
5980
7402
  "type": "number"
5981
7403
  },
7404
+ "experienceendpoint": {
7405
+ "type": "number"
7406
+ },
7407
+ "experiencegroup": {
7408
+ "type": "number"
7409
+ },
7410
+ "experienceuser": {
7411
+ "type": "number"
7412
+ },
5982
7413
  "flow": {
5983
7414
  "type": "number"
5984
7415
  },
@@ -6109,33 +7540,42 @@ Schema for information about the currently authenticated user
6109
7540
  "summary": {
6110
7541
  "type": "object",
6111
7542
  "properties": {
7543
+ "apiTokenCount": {
7544
+ "type": "number"
7545
+ },
6112
7546
  "appCount": {
6113
7547
  "type": "number"
6114
7548
  },
6115
- "dashCount": {
7549
+ "keyCount": {
6116
7550
  "type": "number"
6117
7551
  },
6118
- "orgCount": {
7552
+ "dashCount": {
6119
7553
  "type": "number"
6120
7554
  },
6121
7555
  "deviceCount": {
6122
7556
  "type": "number"
6123
7557
  },
6124
- "flowCount": {
7558
+ "deviceRecipeCount": {
6125
7559
  "type": "number"
6126
7560
  },
6127
- "webhookCount": {
7561
+ "experienceEndpointCount": {
6128
7562
  "type": "number"
6129
7563
  },
6130
- "keyCount": {
7564
+ "experienceGroupCount": {
6131
7565
  "type": "number"
6132
7566
  },
6133
- "deviceRecipeCount": {
7567
+ "experienceUserCount": {
7568
+ "type": "number"
7569
+ },
7570
+ "flowCount": {
7571
+ "type": "number"
7572
+ },
7573
+ "orgCount": {
6134
7574
  "type": "number"
6135
7575
  },
6136
7576
  "payloadCount": {
6137
7577
  "title": "Payload Counts",
6138
- "description": "Schema the result of a payload count request",
7578
+ "description": "Schema for the result of a payload count request",
6139
7579
  "type": "object",
6140
7580
  "properties": {
6141
7581
  "mqttOut": {
@@ -6217,8 +7657,19 @@ Schema for information about the currently authenticated user
6217
7657
  "type": "number"
6218
7658
  }
6219
7659
  }
7660
+ },
7661
+ "endpoint": {
7662
+ "type": "object",
7663
+ "patternProperties": {
7664
+ ".*": {
7665
+ "type": "number"
7666
+ }
7667
+ }
6220
7668
  }
6221
7669
  }
7670
+ },
7671
+ "webhookCount": {
7672
+ "type": "number"
6222
7673
  }
6223
7674
  }
6224
7675
  },
@@ -6386,14 +7837,16 @@ Schema for the body of a request to send a command to multiple Devices
6386
7837
  }
6387
7838
  },
6388
7839
  "additionalProperties": false
6389
- }
7840
+ },
7841
+ "maxItems": 100
6390
7842
  },
6391
7843
  "deviceIds": {
6392
7844
  "type": "array",
6393
7845
  "items": {
6394
7846
  "type": "string",
6395
7847
  "pattern": "^[A-Fa-f\\d]{24}$"
6396
- }
7848
+ },
7849
+ "maxItems": 1000
6397
7850
  }
6398
7851
  },
6399
7852
  "required": [
@@ -6505,6 +7958,9 @@ Schema for a single Organization
6505
7958
  }
6506
7959
  },
6507
7960
  "limits": {
7961
+ "apitoken": {
7962
+ "type": "number"
7963
+ },
6508
7964
  "application": {
6509
7965
  "type": "number"
6510
7966
  },
@@ -6520,6 +7976,15 @@ Schema for a single Organization
6520
7976
  "devicerecipe": {
6521
7977
  "type": "number"
6522
7978
  },
7979
+ "experienceendpoint": {
7980
+ "type": "number"
7981
+ },
7982
+ "experiencegroup": {
7983
+ "type": "number"
7984
+ },
7985
+ "experienceuser": {
7986
+ "type": "number"
7987
+ },
6523
7988
  "flow": {
6524
7989
  "type": "number"
6525
7990
  },
@@ -6542,33 +8007,45 @@ Schema for a single Organization
6542
8007
  "summary": {
6543
8008
  "type": "object",
6544
8009
  "properties": {
8010
+ "apiTokenCount": {
8011
+ "type": "number"
8012
+ },
6545
8013
  "appCount": {
6546
8014
  "type": "number"
6547
8015
  },
6548
- "dashCount": {
8016
+ "keyCount": {
6549
8017
  "type": "number"
6550
8018
  },
6551
- "solutionCount": {
8019
+ "dashCount": {
6552
8020
  "type": "number"
6553
8021
  },
6554
8022
  "deviceCount": {
6555
8023
  "type": "number"
6556
8024
  },
6557
- "flowCount": {
8025
+ "deviceRecipeCount": {
6558
8026
  "type": "number"
6559
8027
  },
6560
- "webhookCount": {
8028
+ "experienceEndpointCount": {
6561
8029
  "type": "number"
6562
8030
  },
6563
- "keyCount": {
8031
+ "experienceGroupCount": {
6564
8032
  "type": "number"
6565
8033
  },
6566
- "deviceRecipeCount": {
8034
+ "experienceUserCount": {
8035
+ "type": "number"
8036
+ },
8037
+ "flowCount": {
8038
+ "type": "number"
8039
+ },
8040
+ "memberCount": {
8041
+ "type": "number"
8042
+ },
8043
+ "pendingInviteCount": {
6567
8044
  "type": "number"
6568
8045
  },
6569
8046
  "payloadCount": {
6570
8047
  "title": "Payload Counts",
6571
- "description": "Schema the result of a payload count request",
8048
+ "description": "Schema for the result of a payload count request",
6572
8049
  "type": "object",
6573
8050
  "properties": {
6574
8051
  "mqttOut": {
@@ -6650,13 +8127,21 @@ Schema for a single Organization
6650
8127
  "type": "number"
6651
8128
  }
6652
8129
  }
8130
+ },
8131
+ "endpoint": {
8132
+ "type": "object",
8133
+ "patternProperties": {
8134
+ ".*": {
8135
+ "type": "number"
8136
+ }
8137
+ }
6653
8138
  }
6654
8139
  }
6655
8140
  },
6656
- "pendingInviteCount": {
8141
+ "solutionCount": {
6657
8142
  "type": "number"
6658
8143
  },
6659
- "memberCount": {
8144
+ "webhookCount": {
6660
8145
  "type": "number"
6661
8146
  }
6662
8147
  }
@@ -7204,6 +8689,9 @@ Schema for a collection of Organizations
7204
8689
  }
7205
8690
  },
7206
8691
  "limits": {
8692
+ "apitoken": {
8693
+ "type": "number"
8694
+ },
7207
8695
  "application": {
7208
8696
  "type": "number"
7209
8697
  },
@@ -7219,6 +8707,15 @@ Schema for a collection of Organizations
7219
8707
  "devicerecipe": {
7220
8708
  "type": "number"
7221
8709
  },
8710
+ "experienceendpoint": {
8711
+ "type": "number"
8712
+ },
8713
+ "experiencegroup": {
8714
+ "type": "number"
8715
+ },
8716
+ "experienceuser": {
8717
+ "type": "number"
8718
+ },
7222
8719
  "flow": {
7223
8720
  "type": "number"
7224
8721
  },
@@ -7241,33 +8738,45 @@ Schema for a collection of Organizations
7241
8738
  "summary": {
7242
8739
  "type": "object",
7243
8740
  "properties": {
8741
+ "apiTokenCount": {
8742
+ "type": "number"
8743
+ },
7244
8744
  "appCount": {
7245
8745
  "type": "number"
7246
8746
  },
7247
- "dashCount": {
8747
+ "keyCount": {
7248
8748
  "type": "number"
7249
8749
  },
7250
- "solutionCount": {
8750
+ "dashCount": {
7251
8751
  "type": "number"
7252
8752
  },
7253
8753
  "deviceCount": {
7254
8754
  "type": "number"
7255
8755
  },
7256
- "flowCount": {
8756
+ "deviceRecipeCount": {
7257
8757
  "type": "number"
7258
8758
  },
7259
- "webhookCount": {
8759
+ "experienceEndpointCount": {
7260
8760
  "type": "number"
7261
8761
  },
7262
- "keyCount": {
8762
+ "experienceGroupCount": {
7263
8763
  "type": "number"
7264
8764
  },
7265
- "deviceRecipeCount": {
8765
+ "experienceUserCount": {
8766
+ "type": "number"
8767
+ },
8768
+ "flowCount": {
8769
+ "type": "number"
8770
+ },
8771
+ "memberCount": {
8772
+ "type": "number"
8773
+ },
8774
+ "pendingInviteCount": {
7266
8775
  "type": "number"
7267
8776
  },
7268
8777
  "payloadCount": {
7269
8778
  "title": "Payload Counts",
7270
- "description": "Schema the result of a payload count request",
8779
+ "description": "Schema for the result of a payload count request",
7271
8780
  "type": "object",
7272
8781
  "properties": {
7273
8782
  "mqttOut": {
@@ -7349,13 +8858,21 @@ Schema for a collection of Organizations
7349
8858
  "type": "number"
7350
8859
  }
7351
8860
  }
8861
+ },
8862
+ "endpoint": {
8863
+ "type": "object",
8864
+ "patternProperties": {
8865
+ ".*": {
8866
+ "type": "number"
8867
+ }
8868
+ }
7352
8869
  }
7353
8870
  }
7354
8871
  },
7355
- "pendingInviteCount": {
8872
+ "solutionCount": {
7356
8873
  "type": "number"
7357
8874
  },
7358
- "memberCount": {
8875
+ "webhookCount": {
7359
8876
  "type": "number"
7360
8877
  }
7361
8878
  }
@@ -7480,7 +8997,7 @@ Schema for a collection of Organizations
7480
8997
 
7481
8998
  ## Payload Counts
7482
8999
 
7483
- Schema the result of a payload count request
9000
+ Schema for the result of a payload count request
7484
9001
 
7485
9002
  ### <a name="payload-counts-schema"></a> Schema
7486
9003
 
@@ -7568,6 +9085,14 @@ Schema the result of a payload count request
7568
9085
  "type": "number"
7569
9086
  }
7570
9087
  }
9088
+ },
9089
+ "endpoint": {
9090
+ "type": "object",
9091
+ "patternProperties": {
9092
+ ".*": {
9093
+ "type": "number"
9094
+ }
9095
+ }
7571
9096
  }
7572
9097
  }
7573
9098
  }
@@ -7740,21 +9265,24 @@ Schema for the body of a resource transfer request
7740
9265
  "items": {
7741
9266
  "type": "string",
7742
9267
  "pattern": "^[A-Fa-f\\d]{24}$"
7743
- }
9268
+ },
9269
+ "maxItems": 1000
7744
9270
  },
7745
9271
  "dashboardIds": {
7746
9272
  "type": "array",
7747
9273
  "items": {
7748
9274
  "type": "string",
7749
9275
  "pattern": "^[A-Fa-f\\d]{24}$"
7750
- }
9276
+ },
9277
+ "maxItems": 1000
7751
9278
  },
7752
9279
  "solutionIds": {
7753
9280
  "type": "array",
7754
9281
  "items": {
7755
9282
  "type": "string",
7756
9283
  "pattern": "^[A-Fa-f\\d]{24}$"
7757
- }
9284
+ },
9285
+ "maxItems": 1000
7758
9286
  },
7759
9287
  "strict": {
7760
9288
  "type": "boolean"
@@ -7823,7 +9351,9 @@ Schema for a single Solution
7823
9351
  },
7824
9352
  "slug": {
7825
9353
  "type": "string",
7826
- "pattern": "^[0-9a-z_-]{1,255}$"
9354
+ "minLength": 4,
9355
+ "maxLength": 255,
9356
+ "pattern": "^[0-9a-z_-]*$"
7827
9357
  },
7828
9358
  "allowSelfDeletion": {
7829
9359
  "type": "boolean"
@@ -8117,7 +9647,8 @@ Schema for a single Solution User
8117
9647
  "items": {
8118
9648
  "type": "string",
8119
9649
  "pattern": "^[A-Fa-f\\d]{24}$"
8120
- }
9650
+ },
9651
+ "maxItems": 1000
8121
9652
  }
8122
9653
  }
8123
9654
  }
@@ -8154,11 +9685,11 @@ Schema for a single Solution User
8154
9685
 
8155
9686
  <br/>
8156
9687
 
8157
- ## User Credentials
9688
+ ## Solution User Credentials
8158
9689
 
8159
9690
  Schema for the body of a Solution User authentication request
8160
9691
 
8161
- ### <a name="user-credentials-schema"></a> Schema
9692
+ ### <a name="solution-user-credentials-schema"></a> Schema
8162
9693
 
8163
9694
  ```json
8164
9695
  {
@@ -8192,7 +9723,7 @@ Schema for the body of a Solution User authentication request
8192
9723
  "additionalProperties": false
8193
9724
  }
8194
9725
  ```
8195
- ### <a name="user-credentials-example"></a> Example
9726
+ ### <a name="solution-user-credentials-example"></a> Example
8196
9727
 
8197
9728
  ```json
8198
9729
  {
@@ -8267,7 +9798,8 @@ Schema for the body of a Solution User modification request
8267
9798
  "items": {
8268
9799
  "type": "string",
8269
9800
  "pattern": "^[A-Fa-f\\d]{24}$"
8270
- }
9801
+ },
9802
+ "maxItems": 1000
8271
9803
  },
8272
9804
  "additionalProperties": false
8273
9805
  }
@@ -8350,7 +9882,8 @@ Schema for the body of a Solution User creation request
8350
9882
  "items": {
8351
9883
  "type": "string",
8352
9884
  "pattern": "^[A-Fa-f\\d]{24}$"
8353
- }
9885
+ },
9886
+ "maxItems": 1000
8354
9887
  },
8355
9888
  "additionalProperties": false
8356
9889
  }
@@ -8486,7 +10019,8 @@ Schema for a collection of Solution Users
8486
10019
  "items": {
8487
10020
  "type": "string",
8488
10021
  "pattern": "^[A-Fa-f\\d]{24}$"
8489
- }
10022
+ },
10023
+ "maxItems": 1000
8490
10024
  }
8491
10025
  }
8492
10026
  }
@@ -8623,7 +10157,9 @@ Schema for a collection of Solutions
8623
10157
  },
8624
10158
  "slug": {
8625
10159
  "type": "string",
8626
- "pattern": "^[0-9a-z_-]{1,255}$"
10160
+ "minLength": 4,
10161
+ "maxLength": 255,
10162
+ "pattern": "^[0-9a-z_-]*$"
8627
10163
  },
8628
10164
  "allowSelfDeletion": {
8629
10165
  "type": "boolean"
@@ -8965,14 +10501,16 @@ Schema for the body of a time series query request
8965
10501
  }
8966
10502
  },
8967
10503
  "additionalProperties": false
8968
- }
10504
+ },
10505
+ "maxItems": 100
8969
10506
  },
8970
10507
  "deviceIds": {
8971
10508
  "type": "array",
8972
10509
  "items": {
8973
10510
  "type": "string",
8974
10511
  "pattern": "^[A-Fa-f\\d]{24}$"
8975
- }
10512
+ },
10513
+ "maxItems": 1000
8976
10514
  },
8977
10515
  "limit": {
8978
10516
  "type": "number"