@blues-inc/notehub-js 6.2.0-beta.55 → 6.2.0-beta.56

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (179) hide show
  1. package/README.md +318 -308
  2. package/dist/ApiClient.js +150 -150
  3. package/dist/api/AlertApi.js +22 -22
  4. package/dist/api/AuthorizationApi.js +31 -31
  5. package/dist/api/BillingAccountApi.js +28 -28
  6. package/dist/api/DeviceApi.js +385 -385
  7. package/dist/api/EventApi.js +118 -118
  8. package/dist/api/ExternalDevicesApi.js +41 -41
  9. package/dist/api/JobsApi.js +78 -78
  10. package/dist/api/MonitorApi.js +52 -52
  11. package/dist/api/ProjectApi.js +619 -433
  12. package/dist/api/RouteApi.js +83 -83
  13. package/dist/api/UsageApi.js +67 -67
  14. package/dist/api/WebhookApi.js +108 -108
  15. package/dist/index.js +28 -0
  16. package/dist/model/AWSRoleConfig.js +14 -14
  17. package/dist/model/AddDeviceToFleetsRequest.js +8 -8
  18. package/dist/model/Alert.js +76 -74
  19. package/dist/model/AlertDataInner.js +36 -36
  20. package/dist/model/AlertNotificationsInner.js +18 -18
  21. package/dist/model/AwsRoute.js +70 -70
  22. package/dist/model/AzureRoute.js +43 -43
  23. package/dist/model/BatchJobRequests.js +57 -57
  24. package/dist/model/BillingAccount.js +21 -21
  25. package/dist/model/BillingAccountRole.js +9 -9
  26. package/dist/model/BlynkRoute.js +28 -28
  27. package/dist/model/Body.js +5 -5
  28. package/dist/model/CancelJobRun200Response.js +6 -6
  29. package/dist/model/CellularPlan.js +34 -34
  30. package/dist/model/CloneProjectRequest.js +20 -20
  31. package/dist/model/Contact.js +22 -22
  32. package/dist/model/CreateFleetRequest.js +20 -20
  33. package/dist/model/CreateJob201Response.js +8 -8
  34. package/dist/model/CreateLegacyWebhookEventRequest.js +17 -17
  35. package/dist/model/CreateMonitor.js +144 -143
  36. package/dist/model/CreateProductRequest.js +22 -22
  37. package/dist/model/CreateProjectRequest.js +16 -16
  38. package/dist/model/CreateProjectSecretRequest.js +130 -0
  39. package/dist/model/CreateUpdateRepository.js +17 -17
  40. package/dist/model/CurrentFirmware.js +12 -12
  41. package/dist/model/DFUEnv.js +12 -12
  42. package/dist/model/DFUState.js +65 -65
  43. package/dist/model/DataField.js +7 -7
  44. package/dist/model/DataSetField.js +19 -19
  45. package/dist/model/DataUsage.js +14 -14
  46. package/dist/model/DatacakeRoute.js +35 -35
  47. package/dist/model/DeleteDeviceFromFleetsRequest.js +8 -8
  48. package/dist/model/DeleteJob200Response.js +6 -6
  49. package/dist/model/DeleteNotefilesRequest.js +7 -7
  50. package/dist/model/Device.js +107 -106
  51. package/dist/model/DeviceDfuHistory.js +20 -19
  52. package/dist/model/DeviceDfuHistoryCurrent.js +32 -32
  53. package/dist/model/DeviceDfuHistoryPage.js +13 -12
  54. package/dist/model/DeviceDfuStateMachine.js +25 -24
  55. package/dist/model/DeviceDfuStateMachineNode.js +22 -22
  56. package/dist/model/DeviceDfuStatus.js +20 -20
  57. package/dist/model/DeviceDfuStatusPage.js +13 -12
  58. package/dist/model/DeviceSession.js +221 -221
  59. package/dist/model/DeviceTowerInfo.js +14 -14
  60. package/dist/model/DeviceUsage.js +32 -32
  61. package/dist/model/DfuActionRequest.js +7 -7
  62. package/dist/model/EmailNotification.js +7 -7
  63. package/dist/model/EnvTreeJsonNode.js +69 -67
  64. package/dist/model/EnvVar.js +18 -18
  65. package/dist/model/EnvironmentVariables.js +8 -8
  66. package/dist/model/Error.js +31 -31
  67. package/dist/model/Event.js +248 -248
  68. package/dist/model/Filter.js +16 -16
  69. package/dist/model/Firmware.js +49 -49
  70. package/dist/model/FirmwareInfo.js +68 -68
  71. package/dist/model/Fleet.js +38 -38
  72. package/dist/model/FleetConnectivityAssurance.js +5 -5
  73. package/dist/model/GetAlerts200Response.js +15 -14
  74. package/dist/model/GetBillingAccount200Response.js +25 -25
  75. package/dist/model/GetBillingAccount200ResponsePlan.js +22 -22
  76. package/dist/model/GetBillingAccountBalanceHistory200Response.js +10 -9
  77. package/dist/model/GetBillingAccountBalanceHistory200ResponseDataInner.js +17 -17
  78. package/dist/model/GetBillingAccounts200Response.js +10 -9
  79. package/dist/model/GetDataUsage200Response.js +13 -12
  80. package/dist/model/GetDataUsage200ResponseDataInner.js +44 -43
  81. package/dist/model/GetDbNote200Response.js +13 -13
  82. package/dist/model/GetDeviceEnvironmentVariablesByPin200Response.js +16 -16
  83. package/dist/model/GetDeviceFleets200Response.js +12 -11
  84. package/dist/model/GetDeviceHealthLog200Response.js +12 -11
  85. package/dist/model/GetDeviceHealthLog200ResponseHealthLogInner.js +19 -19
  86. package/dist/model/GetDeviceJourney200Response.js +21 -21
  87. package/dist/model/GetDeviceJourney200ResponseJourney.js +17 -16
  88. package/dist/model/GetDeviceJourneys200Response.js +17 -16
  89. package/dist/model/GetDeviceJourneys200ResponseJourneysInner.js +20 -20
  90. package/dist/model/GetDeviceLatestEvents200Response.js +10 -9
  91. package/dist/model/GetDevicePlans200Response.js +10 -9
  92. package/dist/model/GetDevicePublicKey200Response.js +16 -16
  93. package/dist/model/GetDevicePublicKeys200Response.js +17 -16
  94. package/dist/model/GetDevicePublicKeys200ResponseDevicePublicKeysInner.js +12 -12
  95. package/dist/model/GetDeviceSessions200Response.js +17 -16
  96. package/dist/model/GetDevices200Response.js +17 -16
  97. package/dist/model/GetEvents200Response.js +21 -20
  98. package/dist/model/GetEventsByCursor200Response.js +24 -23
  99. package/dist/model/GetJobRuns200Response.js +12 -11
  100. package/dist/model/GetJobs200Response.js +12 -11
  101. package/dist/model/GetNotefile200Response.js +11 -11
  102. package/dist/model/GetProducts200Response.js +10 -9
  103. package/dist/model/GetProjectMembers200Response.js +12 -11
  104. package/dist/model/GetProjectSecretsResponse.js +132 -0
  105. package/dist/model/GetProjects200Response.js +10 -9
  106. package/dist/model/GetRouteLogsUsage200Response.js +15 -14
  107. package/dist/model/GetSessionsUsage200Response.js +16 -15
  108. package/dist/model/GetWebhooks200Response.js +10 -9
  109. package/dist/model/GoogleRoute.js +33 -33
  110. package/dist/model/HttpRoute.js +35 -35
  111. package/dist/model/Job.js +35 -35
  112. package/dist/model/JobDefinition.js +26 -26
  113. package/dist/model/JobDefinitionReportOptions.js +28 -28
  114. package/dist/model/JobDefinitionSelect.js +25 -25
  115. package/dist/model/JobDetail.js +48 -48
  116. package/dist/model/JobDetailAllOf.js +7 -7
  117. package/dist/model/JobRun.js +57 -57
  118. package/dist/model/Location.js +40 -40
  119. package/dist/model/Login200Response.js +7 -7
  120. package/dist/model/LoginRequest.js +12 -12
  121. package/dist/model/Monitor.js +115 -114
  122. package/dist/model/MonitorAlertRoutesInner.js +9 -10
  123. package/dist/model/MqttRoute.js +68 -68
  124. package/dist/model/Note.js +31 -31
  125. package/dist/model/NoteInput.js +9 -9
  126. package/dist/model/Notefile.js +23 -22
  127. package/dist/model/NotefileSchema.js +19 -18
  128. package/dist/model/NotehubRoute.js +103 -103
  129. package/dist/model/NotehubRouteSummary.js +23 -23
  130. package/dist/model/OAuth2Error.js +20 -20
  131. package/dist/model/OAuth2TokenResponse.js +23 -23
  132. package/dist/model/PersonalAccessToken.js +34 -34
  133. package/dist/model/PersonalAccessTokenCreatedBy.js +17 -17
  134. package/dist/model/PersonalAccessTokenInfo.js +18 -18
  135. package/dist/model/PersonalAccessTokenSecret.js +12 -12
  136. package/dist/model/Product.js +26 -26
  137. package/dist/model/Project.js +34 -34
  138. package/dist/model/ProjectMember.js +22 -22
  139. package/dist/model/ProjectSecret.js +164 -0
  140. package/dist/model/ProvisionDeviceRequest.js +18 -18
  141. package/dist/model/ProxyRoute.js +29 -29
  142. package/dist/model/QubitroRoute.js +33 -33
  143. package/dist/model/RadRoute.js +31 -31
  144. package/dist/model/Repository.js +22 -22
  145. package/dist/model/RepositoryListResponse.js +12 -11
  146. package/dist/model/RepositoryTokenRequest.js +14 -14
  147. package/dist/model/RepositoryTokenResponse.js +38 -38
  148. package/dist/model/Role.js +9 -9
  149. package/dist/model/RouteLog.js +38 -38
  150. package/dist/model/RouteTransformSettings.js +18 -18
  151. package/dist/model/RunJob200Response.js +8 -8
  152. package/dist/model/S3ArchiveRoute.js +79 -79
  153. package/dist/model/SatelliteDataUsage.js +18 -18
  154. package/dist/model/SatellitePlan.js +29 -29
  155. package/dist/model/SchemaProperty.js +38 -36
  156. package/dist/model/SignalDevice200Response.js +5 -5
  157. package/dist/model/SimUsage.js +19 -19
  158. package/dist/model/SlackBearerNotification.js +25 -25
  159. package/dist/model/SlackRoute.js +48 -48
  160. package/dist/model/SlackWebHookNotification.js +20 -20
  161. package/dist/model/SnowflakeRoute.js +45 -45
  162. package/dist/model/SnowpipeStreamingRoute.js +60 -60
  163. package/dist/model/ThingworxRoute.js +33 -33
  164. package/dist/model/TowerLocation.js +54 -54
  165. package/dist/model/TwilioRoute.js +43 -43
  166. package/dist/model/UpdateFleetRequest.js +33 -33
  167. package/dist/model/UpdateHostFirmwareRequest.js +17 -17
  168. package/dist/model/UpdateProjectSecretRequest.js +115 -0
  169. package/dist/model/UploadMetadata.js +64 -64
  170. package/dist/model/UsageData.js +33 -33
  171. package/dist/model/UsageEventsData.js +49 -49
  172. package/dist/model/UsageEventsResponse.js +15 -14
  173. package/dist/model/UsageRouteLogsData.js +30 -30
  174. package/dist/model/UsageSessionsData.js +43 -43
  175. package/dist/model/UserDfuStateMachine.js +20 -20
  176. package/dist/model/UserDfuStateMachineStatus.js +20 -20
  177. package/dist/model/UserFirmwareInfo.js +12 -12
  178. package/dist/model/WebhookSettings.js +15 -15
  179. package/package.json +3 -3
@@ -18,7 +18,7 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
18
18
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
19
19
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
20
20
  * Notehub API
21
- * The OpenAPI definition for the Notehub.io API.
21
+ * The OpenAPI definition for the Notehub.io API.
22
22
  *
23
23
  * The version of the OpenAPI document: 1.2.0
24
24
  * Contact: engineering@blues.io
@@ -31,16 +31,16 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
31
31
  /**
32
32
  * The CreateMonitor model module.
33
33
  * @module model/CreateMonitor
34
- * @version 6.2.0-beta.55
34
+ * @version 6.2.0-beta.56
35
35
  */
36
36
  var CreateMonitor = /*#__PURE__*/function () {
37
37
  /**
38
38
  * Constructs a new <code>CreateMonitor</code>.
39
39
  * @alias module:model/CreateMonitor
40
40
  * @implements module:model/Monitor
41
- * @param alertRoutes {Array.<module:model/MonitorAlertRoutesInner>}
42
- * @param description {String}
43
- * @param name {String}
41
+ * @param alertRoutes {Array.<module:model/MonitorAlertRoutesInner>}
42
+ * @param description {String}
43
+ * @param name {String}
44
44
  * @param sourceType {module:model/CreateMonitor.SourceTypeEnum} The type of source to monitor. Supported values are \"event\" and \"heartbeat\".
45
45
  * @param threshold {Number} The type of condition to apply to the value selected by the source_selector
46
46
  */
@@ -58,11 +58,11 @@ var CreateMonitor = /*#__PURE__*/function () {
58
58
  return _createClass(CreateMonitor, null, [{
59
59
  key: "initialize",
60
60
  value: function initialize(obj, alertRoutes, description, name, sourceType, threshold) {
61
- obj["alert_routes"] = alertRoutes;
62
- obj["description"] = description;
63
- obj["name"] = name;
64
- obj["source_type"] = sourceType;
65
- obj["threshold"] = threshold;
61
+ obj['alert_routes'] = alertRoutes;
62
+ obj['description'] = description;
63
+ obj['name'] = name;
64
+ obj['source_type'] = sourceType;
65
+ obj['threshold'] = threshold;
66
66
  }
67
67
 
68
68
  /**
@@ -78,68 +78,68 @@ var CreateMonitor = /*#__PURE__*/function () {
78
78
  if (data) {
79
79
  obj = obj || new CreateMonitor();
80
80
  _Monitor["default"].constructFromObject(data, obj);
81
- if (data.hasOwnProperty("aggregate_function")) {
82
- obj["aggregate_function"] = _ApiClient["default"].convertToType(data["aggregate_function"], "String");
81
+ if (data.hasOwnProperty('aggregate_function')) {
82
+ obj['aggregate_function'] = _ApiClient["default"].convertToType(data['aggregate_function'], 'String');
83
83
  }
84
- if (data.hasOwnProperty("aggregate_window")) {
85
- obj["aggregate_window"] = _ApiClient["default"].convertToType(data["aggregate_window"], "String");
84
+ if (data.hasOwnProperty('aggregate_window')) {
85
+ obj['aggregate_window'] = _ApiClient["default"].convertToType(data['aggregate_window'], 'String');
86
86
  }
87
- if (data.hasOwnProperty("alert")) {
88
- obj["alert"] = _ApiClient["default"].convertToType(data["alert"], "Boolean");
87
+ if (data.hasOwnProperty('alert')) {
88
+ obj['alert'] = _ApiClient["default"].convertToType(data['alert'], 'Boolean');
89
89
  }
90
- if (data.hasOwnProperty("alert_routes")) {
91
- obj["alert_routes"] = _ApiClient["default"].convertToType(data["alert_routes"], [_MonitorAlertRoutesInner["default"]]);
90
+ if (data.hasOwnProperty('alert_routes')) {
91
+ obj['alert_routes'] = _ApiClient["default"].convertToType(data['alert_routes'], [_MonitorAlertRoutesInner["default"]]);
92
92
  }
93
- if (data.hasOwnProperty("condition_type")) {
94
- obj["condition_type"] = _ApiClient["default"].convertToType(data["condition_type"], "String");
93
+ if (data.hasOwnProperty('condition_type')) {
94
+ obj['condition_type'] = _ApiClient["default"].convertToType(data['condition_type'], 'String');
95
95
  }
96
- if (data.hasOwnProperty("description")) {
97
- obj["description"] = _ApiClient["default"].convertToType(data["description"], "String");
96
+ if (data.hasOwnProperty('description')) {
97
+ obj['description'] = _ApiClient["default"].convertToType(data['description'], 'String');
98
98
  }
99
- if (data.hasOwnProperty("disabled")) {
100
- obj["disabled"] = _ApiClient["default"].convertToType(data["disabled"], "Boolean");
99
+ if (data.hasOwnProperty('disabled')) {
100
+ obj['disabled'] = _ApiClient["default"].convertToType(data['disabled'], 'Boolean');
101
101
  }
102
- if (data.hasOwnProperty("fleet_filter")) {
103
- obj["fleet_filter"] = _ApiClient["default"].convertToType(data["fleet_filter"], ["String"]);
102
+ if (data.hasOwnProperty('fleet_filter')) {
103
+ obj['fleet_filter'] = _ApiClient["default"].convertToType(data['fleet_filter'], ['String']);
104
104
  }
105
- if (data.hasOwnProperty("last_routed_at")) {
106
- obj["last_routed_at"] = _ApiClient["default"].convertToType(data["last_routed_at"], "String");
105
+ if (data.hasOwnProperty('last_routed_at')) {
106
+ obj['last_routed_at'] = _ApiClient["default"].convertToType(data['last_routed_at'], 'String');
107
107
  }
108
- if (data.hasOwnProperty("name")) {
109
- obj["name"] = _ApiClient["default"].convertToType(data["name"], "String");
108
+ if (data.hasOwnProperty('name')) {
109
+ obj['name'] = _ApiClient["default"].convertToType(data['name'], 'String');
110
110
  }
111
- if (data.hasOwnProperty("notefile_filter")) {
112
- obj["notefile_filter"] = _ApiClient["default"].convertToType(data["notefile_filter"], ["String"]);
111
+ if (data.hasOwnProperty('notefile_filter')) {
112
+ obj['notefile_filter'] = _ApiClient["default"].convertToType(data['notefile_filter'], ['String']);
113
113
  }
114
- if (data.hasOwnProperty("per_device")) {
115
- obj["per_device"] = _ApiClient["default"].convertToType(data["per_device"], "Boolean");
114
+ if (data.hasOwnProperty('per_device')) {
115
+ obj['per_device'] = _ApiClient["default"].convertToType(data['per_device'], 'Boolean');
116
116
  }
117
- if (data.hasOwnProperty("routing_cooldown_period")) {
118
- obj["routing_cooldown_period"] = _ApiClient["default"].convertToType(data["routing_cooldown_period"], "String");
117
+ if (data.hasOwnProperty('routing_cooldown_period')) {
118
+ obj['routing_cooldown_period'] = _ApiClient["default"].convertToType(data['routing_cooldown_period'], 'String');
119
119
  }
120
- if (data.hasOwnProperty("silenced")) {
121
- obj["silenced"] = _ApiClient["default"].convertToType(data["silenced"], "Boolean");
120
+ if (data.hasOwnProperty('silenced')) {
121
+ obj['silenced'] = _ApiClient["default"].convertToType(data['silenced'], 'Boolean');
122
122
  }
123
- if (data.hasOwnProperty("source_selector")) {
124
- obj["source_selector"] = _ApiClient["default"].convertToType(data["source_selector"], "String");
123
+ if (data.hasOwnProperty('source_selector')) {
124
+ obj['source_selector'] = _ApiClient["default"].convertToType(data['source_selector'], 'String');
125
125
  }
126
- if (data.hasOwnProperty("source_type")) {
127
- obj["source_type"] = _ApiClient["default"].convertToType(data["source_type"], "String");
126
+ if (data.hasOwnProperty('source_type')) {
127
+ obj['source_type'] = _ApiClient["default"].convertToType(data['source_type'], 'String');
128
128
  }
129
- if (data.hasOwnProperty("threshold")) {
130
- obj["threshold"] = _ApiClient["default"].convertToType(data["threshold"], "Number");
129
+ if (data.hasOwnProperty('threshold')) {
130
+ obj['threshold'] = _ApiClient["default"].convertToType(data['threshold'], 'Number');
131
131
  }
132
- if (data.hasOwnProperty("uid")) {
133
- obj["uid"] = _ApiClient["default"].convertToType(data["uid"], "String");
132
+ if (data.hasOwnProperty('uid')) {
133
+ obj['uid'] = _ApiClient["default"].convertToType(data['uid'], 'String');
134
134
  }
135
- if (data.hasOwnProperty("usage_scope")) {
136
- obj["usage_scope"] = _ApiClient["default"].convertToType(data["usage_scope"], "String");
135
+ if (data.hasOwnProperty('usage_scope')) {
136
+ obj['usage_scope'] = _ApiClient["default"].convertToType(data['usage_scope'], 'String');
137
137
  }
138
- if (data.hasOwnProperty("usage_type")) {
139
- obj["usage_type"] = _ApiClient["default"].convertToType(data["usage_type"], "String");
138
+ if (data.hasOwnProperty('usage_type')) {
139
+ obj['usage_type'] = _ApiClient["default"].convertToType(data['usage_type'], 'String');
140
140
  }
141
- if (data.hasOwnProperty("usage_window")) {
142
- obj["usage_window"] = _ApiClient["default"].convertToType(data["usage_window"], "Number");
141
+ if (data.hasOwnProperty('usage_window')) {
142
+ obj['usage_window'] = _ApiClient["default"].convertToType(data['usage_window'], 'Number');
143
143
  }
144
144
  } else if (data === null) {
145
145
  return null;
@@ -171,21 +171,21 @@ var CreateMonitor = /*#__PURE__*/function () {
171
171
  } finally {
172
172
  _iterator.f();
173
173
  }
174
- if (data["aggregate_function"] && !(typeof data["aggregate_function"] === "string" || data["aggregate_function"] instanceof String)) {
175
- throw new Error("Expected the field `aggregate_function` to be a primitive type in the JSON string but got " + data["aggregate_function"]);
174
+ if (data['aggregate_function'] && !(typeof data['aggregate_function'] === 'string' || data['aggregate_function'] instanceof String)) {
175
+ throw new Error("Expected the field `aggregate_function` to be a primitive type in the JSON string but got " + data['aggregate_function']);
176
176
  }
177
177
  // ensure the json data is a string
178
- if (data["aggregate_window"] && !(typeof data["aggregate_window"] === "string" || data["aggregate_window"] instanceof String)) {
179
- throw new Error("Expected the field `aggregate_window` to be a primitive type in the JSON string but got " + data["aggregate_window"]);
178
+ if (data['aggregate_window'] && !(typeof data['aggregate_window'] === 'string' || data['aggregate_window'] instanceof String)) {
179
+ throw new Error("Expected the field `aggregate_window` to be a primitive type in the JSON string but got " + data['aggregate_window']);
180
180
  }
181
- if (data["alert_routes"]) {
181
+ if (data['alert_routes']) {
182
182
  // data not null
183
183
  // ensure the json data is an array
184
- if (!Array.isArray(data["alert_routes"])) {
185
- throw new Error("Expected the field `alert_routes` to be an array in the JSON data but got " + data["alert_routes"]);
184
+ if (!Array.isArray(data['alert_routes'])) {
185
+ throw new Error("Expected the field `alert_routes` to be an array in the JSON data but got " + data['alert_routes']);
186
186
  }
187
187
  // validate the optional field `alert_routes` (array)
188
- var _iterator2 = _createForOfIteratorHelper(data["alert_routes"]),
188
+ var _iterator2 = _createForOfIteratorHelper(data['alert_routes']),
189
189
  _step2;
190
190
  try {
191
191
  for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
@@ -197,54 +197,55 @@ var CreateMonitor = /*#__PURE__*/function () {
197
197
  } finally {
198
198
  _iterator2.f();
199
199
  }
200
+ ;
200
201
  }
201
202
  // ensure the json data is a string
202
- if (data["condition_type"] && !(typeof data["condition_type"] === "string" || data["condition_type"] instanceof String)) {
203
- throw new Error("Expected the field `condition_type` to be a primitive type in the JSON string but got " + data["condition_type"]);
203
+ if (data['condition_type'] && !(typeof data['condition_type'] === 'string' || data['condition_type'] instanceof String)) {
204
+ throw new Error("Expected the field `condition_type` to be a primitive type in the JSON string but got " + data['condition_type']);
204
205
  }
205
206
  // ensure the json data is a string
206
- if (data["description"] && !(typeof data["description"] === "string" || data["description"] instanceof String)) {
207
- throw new Error("Expected the field `description` to be a primitive type in the JSON string but got " + data["description"]);
207
+ if (data['description'] && !(typeof data['description'] === 'string' || data['description'] instanceof String)) {
208
+ throw new Error("Expected the field `description` to be a primitive type in the JSON string but got " + data['description']);
208
209
  }
209
210
  // ensure the json data is an array
210
- if (!Array.isArray(data["fleet_filter"])) {
211
- throw new Error("Expected the field `fleet_filter` to be an array in the JSON data but got " + data["fleet_filter"]);
211
+ if (!Array.isArray(data['fleet_filter'])) {
212
+ throw new Error("Expected the field `fleet_filter` to be an array in the JSON data but got " + data['fleet_filter']);
212
213
  }
213
214
  // ensure the json data is a string
214
- if (data["last_routed_at"] && !(typeof data["last_routed_at"] === "string" || data["last_routed_at"] instanceof String)) {
215
- throw new Error("Expected the field `last_routed_at` to be a primitive type in the JSON string but got " + data["last_routed_at"]);
215
+ if (data['last_routed_at'] && !(typeof data['last_routed_at'] === 'string' || data['last_routed_at'] instanceof String)) {
216
+ throw new Error("Expected the field `last_routed_at` to be a primitive type in the JSON string but got " + data['last_routed_at']);
216
217
  }
217
218
  // ensure the json data is a string
218
- if (data["name"] && !(typeof data["name"] === "string" || data["name"] instanceof String)) {
219
- throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data["name"]);
219
+ if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) {
220
+ throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']);
220
221
  }
221
222
  // ensure the json data is an array
222
- if (!Array.isArray(data["notefile_filter"])) {
223
- throw new Error("Expected the field `notefile_filter` to be an array in the JSON data but got " + data["notefile_filter"]);
223
+ if (!Array.isArray(data['notefile_filter'])) {
224
+ throw new Error("Expected the field `notefile_filter` to be an array in the JSON data but got " + data['notefile_filter']);
224
225
  }
225
226
  // ensure the json data is a string
226
- if (data["routing_cooldown_period"] && !(typeof data["routing_cooldown_period"] === "string" || data["routing_cooldown_period"] instanceof String)) {
227
- throw new Error("Expected the field `routing_cooldown_period` to be a primitive type in the JSON string but got " + data["routing_cooldown_period"]);
227
+ if (data['routing_cooldown_period'] && !(typeof data['routing_cooldown_period'] === 'string' || data['routing_cooldown_period'] instanceof String)) {
228
+ throw new Error("Expected the field `routing_cooldown_period` to be a primitive type in the JSON string but got " + data['routing_cooldown_period']);
228
229
  }
229
230
  // ensure the json data is a string
230
- if (data["source_selector"] && !(typeof data["source_selector"] === "string" || data["source_selector"] instanceof String)) {
231
- throw new Error("Expected the field `source_selector` to be a primitive type in the JSON string but got " + data["source_selector"]);
231
+ if (data['source_selector'] && !(typeof data['source_selector'] === 'string' || data['source_selector'] instanceof String)) {
232
+ throw new Error("Expected the field `source_selector` to be a primitive type in the JSON string but got " + data['source_selector']);
232
233
  }
233
234
  // ensure the json data is a string
234
- if (data["source_type"] && !(typeof data["source_type"] === "string" || data["source_type"] instanceof String)) {
235
- throw new Error("Expected the field `source_type` to be a primitive type in the JSON string but got " + data["source_type"]);
235
+ if (data['source_type'] && !(typeof data['source_type'] === 'string' || data['source_type'] instanceof String)) {
236
+ throw new Error("Expected the field `source_type` to be a primitive type in the JSON string but got " + data['source_type']);
236
237
  }
237
238
  // ensure the json data is a string
238
- if (data["uid"] && !(typeof data["uid"] === "string" || data["uid"] instanceof String)) {
239
- throw new Error("Expected the field `uid` to be a primitive type in the JSON string but got " + data["uid"]);
239
+ if (data['uid'] && !(typeof data['uid'] === 'string' || data['uid'] instanceof String)) {
240
+ throw new Error("Expected the field `uid` to be a primitive type in the JSON string but got " + data['uid']);
240
241
  }
241
242
  // ensure the json data is a string
242
- if (data["usage_scope"] && !(typeof data["usage_scope"] === "string" || data["usage_scope"] instanceof String)) {
243
- throw new Error("Expected the field `usage_scope` to be a primitive type in the JSON string but got " + data["usage_scope"]);
243
+ if (data['usage_scope'] && !(typeof data['usage_scope'] === 'string' || data['usage_scope'] instanceof String)) {
244
+ throw new Error("Expected the field `usage_scope` to be a primitive type in the JSON string but got " + data['usage_scope']);
244
245
  }
245
246
  // ensure the json data is a string
246
- if (data["usage_type"] && !(typeof data["usage_type"] === "string" || data["usage_type"] instanceof String)) {
247
- throw new Error("Expected the field `usage_type` to be a primitive type in the JSON string but got " + data["usage_type"]);
247
+ if (data['usage_type'] && !(typeof data['usage_type'] === 'string' || data['usage_type'] instanceof String)) {
248
+ throw new Error("Expected the field `usage_type` to be a primitive type in the JSON string but got " + data['usage_type']);
248
249
  }
249
250
  return true;
250
251
  }
@@ -256,254 +257,254 @@ CreateMonitor.RequiredProperties = ["alert_routes", "description", "name", "sour
256
257
  * Aggregate function to apply to the selected values before applying the condition. [none, sum, average, max, min]
257
258
  * @member {module:model/CreateMonitor.AggregateFunctionEnum} aggregate_function
258
259
  */
259
- CreateMonitor.prototype["aggregate_function"] = undefined;
260
+ CreateMonitor.prototype['aggregate_function'] = undefined;
260
261
 
261
262
  /**
262
263
  * The time window to aggregate the selected values. It follows the format of a number followed by a time unit
263
264
  * @member {String} aggregate_window
264
265
  */
265
- CreateMonitor.prototype["aggregate_window"] = undefined;
266
+ CreateMonitor.prototype['aggregate_window'] = undefined;
266
267
 
267
268
  /**
268
269
  * If true, the monitor is in alert state.
269
270
  * @member {Boolean} alert
270
271
  */
271
- CreateMonitor.prototype["alert"] = undefined;
272
+ CreateMonitor.prototype['alert'] = undefined;
272
273
 
273
274
  /**
274
275
  * @member {Array.<module:model/MonitorAlertRoutesInner>} alert_routes
275
276
  */
276
- CreateMonitor.prototype["alert_routes"] = undefined;
277
+ CreateMonitor.prototype['alert_routes'] = undefined;
277
278
 
278
279
  /**
279
280
  * A comparison operation to apply to the value selected by the source_selector [greater_than, greater_than_or_equal_to, less_than, less_than_or_equal_to, equal_to, not_equal_to]
280
281
  * @member {module:model/CreateMonitor.ConditionTypeEnum} condition_type
281
282
  */
282
- CreateMonitor.prototype["condition_type"] = undefined;
283
+ CreateMonitor.prototype['condition_type'] = undefined;
283
284
 
284
285
  /**
285
286
  * @member {String} description
286
287
  */
287
- CreateMonitor.prototype["description"] = undefined;
288
+ CreateMonitor.prototype['description'] = undefined;
288
289
 
289
290
  /**
290
291
  * If true, the monitor will not be evaluated.
291
292
  * @member {Boolean} disabled
292
293
  */
293
- CreateMonitor.prototype["disabled"] = undefined;
294
+ CreateMonitor.prototype['disabled'] = undefined;
294
295
 
295
296
  /**
296
297
  * @member {Array.<String>} fleet_filter
297
298
  */
298
- CreateMonitor.prototype["fleet_filter"] = undefined;
299
+ CreateMonitor.prototype['fleet_filter'] = undefined;
299
300
 
300
301
  /**
301
302
  * The last time the monitor was evaluated and routed.
302
303
  * @member {String} last_routed_at
303
304
  */
304
- CreateMonitor.prototype["last_routed_at"] = undefined;
305
+ CreateMonitor.prototype['last_routed_at'] = undefined;
305
306
 
306
307
  /**
307
308
  * @member {String} name
308
309
  */
309
- CreateMonitor.prototype["name"] = undefined;
310
+ CreateMonitor.prototype['name'] = undefined;
310
311
 
311
312
  /**
312
313
  * @member {Array.<String>} notefile_filter
313
314
  */
314
- CreateMonitor.prototype["notefile_filter"] = undefined;
315
+ CreateMonitor.prototype['notefile_filter'] = undefined;
315
316
 
316
317
  /**
317
318
  * Only relevant when using an aggregate_function. If true, the monitor will be evaluated per device, | rather than across the set of selected devices. If true then if a single device matches the specified criteria, | and alert will be created, otherwise the aggregate function will be applied across all devices.
318
319
  * @member {Boolean} per_device
319
320
  */
320
- CreateMonitor.prototype["per_device"] = undefined;
321
+ CreateMonitor.prototype['per_device'] = undefined;
321
322
 
322
323
  /**
323
324
  * The time period to wait before routing another event after the monitor | has been triggered. It follows the format of a number followed by a time unit.
324
325
  * @member {String} routing_cooldown_period
325
326
  */
326
- CreateMonitor.prototype["routing_cooldown_period"] = undefined;
327
+ CreateMonitor.prototype['routing_cooldown_period'] = undefined;
327
328
 
328
329
  /**
329
330
  * If true, alerts will be created, but no notifications will be sent.
330
331
  * @member {Boolean} silenced
331
332
  */
332
- CreateMonitor.prototype["silenced"] = undefined;
333
+ CreateMonitor.prototype['silenced'] = undefined;
333
334
 
334
335
  /**
335
336
  * A valid JSONata expression that selects the value to monitor from the source. | It should return a single, numeric value.
336
337
  * @member {String} source_selector
337
338
  */
338
- CreateMonitor.prototype["source_selector"] = undefined;
339
+ CreateMonitor.prototype['source_selector'] = undefined;
339
340
 
340
341
  /**
341
342
  * The type of source to monitor. Supported values are \"event\" and \"heartbeat\".
342
343
  * @member {module:model/CreateMonitor.SourceTypeEnum} source_type
343
344
  */
344
- CreateMonitor.prototype["source_type"] = undefined;
345
+ CreateMonitor.prototype['source_type'] = undefined;
345
346
 
346
347
  /**
347
348
  * The type of condition to apply to the value selected by the source_selector
348
349
  * @member {Number} threshold
349
350
  */
350
- CreateMonitor.prototype["threshold"] = undefined;
351
+ CreateMonitor.prototype['threshold'] = undefined;
351
352
 
352
353
  /**
353
354
  * @member {String} uid
354
355
  */
355
- CreateMonitor.prototype["uid"] = undefined;
356
+ CreateMonitor.prototype['uid'] = undefined;
356
357
 
357
358
  /**
358
359
  * For usage monitors: the scope of aggregation. Supported values are \"device\" and \"fleet\".
359
360
  * @member {String} usage_scope
360
361
  */
361
- CreateMonitor.prototype["usage_scope"] = undefined;
362
+ CreateMonitor.prototype['usage_scope'] = undefined;
362
363
 
363
364
  /**
364
365
  * For usage monitors: the type of data usage to monitor. Supported values are \"cellular\" and \"satellite\".
365
366
  * @member {String} usage_type
366
367
  */
367
- CreateMonitor.prototype["usage_type"] = undefined;
368
+ CreateMonitor.prototype['usage_type'] = undefined;
368
369
 
369
370
  /**
370
371
  * For usage monitors: the rolling time window in days to sum usage over (e.g. 30 for 30 days).
371
372
  * @member {Number} usage_window
372
373
  */
373
- CreateMonitor.prototype["usage_window"] = undefined;
374
+ CreateMonitor.prototype['usage_window'] = undefined;
374
375
 
375
376
  // Implement Monitor interface:
376
377
  /**
377
378
  * Aggregate function to apply to the selected values before applying the condition. [none, sum, average, max, min]
378
379
  * @member {module:model/Monitor.AggregateFunctionEnum} aggregate_function
379
380
  */
380
- _Monitor["default"].prototype["aggregate_function"] = undefined;
381
+ _Monitor["default"].prototype['aggregate_function'] = undefined;
381
382
  /**
382
383
  * The time window to aggregate the selected values. It follows the format of a number followed by a time unit
383
384
  * @member {String} aggregate_window
384
385
  */
385
- _Monitor["default"].prototype["aggregate_window"] = undefined;
386
+ _Monitor["default"].prototype['aggregate_window'] = undefined;
386
387
  /**
387
388
  * If true, the monitor is in alert state.
388
389
  * @member {Boolean} alert
389
390
  */
390
- _Monitor["default"].prototype["alert"] = undefined;
391
+ _Monitor["default"].prototype['alert'] = undefined;
391
392
  /**
392
393
  * @member {Array.<module:model/MonitorAlertRoutesInner>} alert_routes
393
394
  */
394
- _Monitor["default"].prototype["alert_routes"] = undefined;
395
+ _Monitor["default"].prototype['alert_routes'] = undefined;
395
396
  /**
396
397
  * A comparison operation to apply to the value selected by the source_selector [greater_than, greater_than_or_equal_to, less_than, less_than_or_equal_to, equal_to, not_equal_to]
397
398
  * @member {module:model/Monitor.ConditionTypeEnum} condition_type
398
399
  */
399
- _Monitor["default"].prototype["condition_type"] = undefined;
400
+ _Monitor["default"].prototype['condition_type'] = undefined;
400
401
  /**
401
402
  * @member {String} description
402
403
  */
403
- _Monitor["default"].prototype["description"] = undefined;
404
+ _Monitor["default"].prototype['description'] = undefined;
404
405
  /**
405
406
  * If true, the monitor will not be evaluated.
406
407
  * @member {Boolean} disabled
407
408
  */
408
- _Monitor["default"].prototype["disabled"] = undefined;
409
+ _Monitor["default"].prototype['disabled'] = undefined;
409
410
  /**
410
411
  * @member {Array.<String>} fleet_filter
411
412
  */
412
- _Monitor["default"].prototype["fleet_filter"] = undefined;
413
+ _Monitor["default"].prototype['fleet_filter'] = undefined;
413
414
  /**
414
415
  * The last time the monitor was evaluated and routed.
415
416
  * @member {String} last_routed_at
416
417
  */
417
- _Monitor["default"].prototype["last_routed_at"] = undefined;
418
+ _Monitor["default"].prototype['last_routed_at'] = undefined;
418
419
  /**
419
420
  * @member {String} name
420
421
  */
421
- _Monitor["default"].prototype["name"] = undefined;
422
+ _Monitor["default"].prototype['name'] = undefined;
422
423
  /**
423
424
  * @member {Array.<String>} notefile_filter
424
425
  */
425
- _Monitor["default"].prototype["notefile_filter"] = undefined;
426
+ _Monitor["default"].prototype['notefile_filter'] = undefined;
426
427
  /**
427
428
  * Only relevant when using an aggregate_function. If true, the monitor will be evaluated per device, | rather than across the set of selected devices. If true then if a single device matches the specified criteria, | and alert will be created, otherwise the aggregate function will be applied across all devices.
428
429
  * @member {Boolean} per_device
429
430
  */
430
- _Monitor["default"].prototype["per_device"] = undefined;
431
+ _Monitor["default"].prototype['per_device'] = undefined;
431
432
  /**
432
433
  * The time period to wait before routing another event after the monitor | has been triggered. It follows the format of a number followed by a time unit.
433
434
  * @member {String} routing_cooldown_period
434
435
  */
435
- _Monitor["default"].prototype["routing_cooldown_period"] = undefined;
436
+ _Monitor["default"].prototype['routing_cooldown_period'] = undefined;
436
437
  /**
437
438
  * If true, alerts will be created, but no notifications will be sent.
438
439
  * @member {Boolean} silenced
439
440
  */
440
- _Monitor["default"].prototype["silenced"] = undefined;
441
+ _Monitor["default"].prototype['silenced'] = undefined;
441
442
  /**
442
443
  * A valid JSONata expression that selects the value to monitor from the source. | It should return a single, numeric value.
443
444
  * @member {String} source_selector
444
445
  */
445
- _Monitor["default"].prototype["source_selector"] = undefined;
446
+ _Monitor["default"].prototype['source_selector'] = undefined;
446
447
  /**
447
448
  * The type of source to monitor. Supported values are \"event\" and \"heartbeat\".
448
449
  * @member {module:model/Monitor.SourceTypeEnum} source_type
449
450
  */
450
- _Monitor["default"].prototype["source_type"] = undefined;
451
+ _Monitor["default"].prototype['source_type'] = undefined;
451
452
  /**
452
453
  * The type of condition to apply to the value selected by the source_selector
453
454
  * @member {Number} threshold
454
455
  */
455
- _Monitor["default"].prototype["threshold"] = undefined;
456
+ _Monitor["default"].prototype['threshold'] = undefined;
456
457
  /**
457
458
  * @member {String} uid
458
459
  */
459
- _Monitor["default"].prototype["uid"] = undefined;
460
+ _Monitor["default"].prototype['uid'] = undefined;
460
461
  /**
461
462
  * For usage monitors: the scope of aggregation. Supported values are \"device\" and \"fleet\".
462
463
  * @member {String} usage_scope
463
464
  */
464
- _Monitor["default"].prototype["usage_scope"] = undefined;
465
+ _Monitor["default"].prototype['usage_scope'] = undefined;
465
466
  /**
466
467
  * For usage monitors: the type of data usage to monitor. Supported values are \"cellular\" and \"satellite\".
467
468
  * @member {String} usage_type
468
469
  */
469
- _Monitor["default"].prototype["usage_type"] = undefined;
470
+ _Monitor["default"].prototype['usage_type'] = undefined;
470
471
  /**
471
472
  * For usage monitors: the rolling time window in days to sum usage over (e.g. 30 for 30 days).
472
473
  * @member {Number} usage_window
473
474
  */
474
- _Monitor["default"].prototype["usage_window"] = undefined;
475
+ _Monitor["default"].prototype['usage_window'] = undefined;
475
476
 
476
477
  /**
477
478
  * Allowed values for the <code>aggregate_function</code> property.
478
479
  * @enum {String}
479
480
  * @readonly
480
481
  */
481
- CreateMonitor["AggregateFunctionEnum"] = {
482
+ CreateMonitor['AggregateFunctionEnum'] = {
482
483
  /**
483
484
  * value: "none"
484
485
  * @const
485
486
  */
486
- none: "none",
487
+ "none": "none",
487
488
  /**
488
489
  * value: "sum"
489
490
  * @const
490
491
  */
491
- sum: "sum",
492
+ "sum": "sum",
492
493
  /**
493
494
  * value: "average"
494
495
  * @const
495
496
  */
496
- average: "average",
497
+ "average": "average",
497
498
  /**
498
499
  * value: "max"
499
500
  * @const
500
501
  */
501
- max: "max",
502
+ "max": "max",
502
503
  /**
503
504
  * value: "min"
504
505
  * @const
505
506
  */
506
- min: "min"
507
+ "min": "min"
507
508
  };
508
509
 
509
510
  /**
@@ -511,42 +512,42 @@ CreateMonitor["AggregateFunctionEnum"] = {
511
512
  * @enum {String}
512
513
  * @readonly
513
514
  */
514
- CreateMonitor["ConditionTypeEnum"] = {
515
+ CreateMonitor['ConditionTypeEnum'] = {
515
516
  /**
516
517
  * value: "greater_than"
517
518
  * @const
518
519
  */
519
- greater_than: "greater_than",
520
+ "greater_than": "greater_than",
520
521
  /**
521
522
  * value: "greater_than_or_equal_to"
522
523
  * @const
523
524
  */
524
- greater_than_or_equal_to: "greater_than_or_equal_to",
525
+ "greater_than_or_equal_to": "greater_than_or_equal_to",
525
526
  /**
526
527
  * value: "less_than"
527
528
  * @const
528
529
  */
529
- less_than: "less_than",
530
+ "less_than": "less_than",
530
531
  /**
531
532
  * value: "less_than_or_equal_to"
532
533
  * @const
533
534
  */
534
- less_than_or_equal_to: "less_than_or_equal_to",
535
+ "less_than_or_equal_to": "less_than_or_equal_to",
535
536
  /**
536
537
  * value: "equal_to"
537
538
  * @const
538
539
  */
539
- equal_to: "equal_to",
540
+ "equal_to": "equal_to",
540
541
  /**
541
542
  * value: "not_equal_to"
542
543
  * @const
543
544
  */
544
- not_equal_to: "not_equal_to",
545
+ "not_equal_to": "not_equal_to",
545
546
  /**
546
547
  * value: "count"
547
548
  * @const
548
549
  */
549
- count: "count"
550
+ "count": "count"
550
551
  };
551
552
 
552
553
  /**
@@ -554,16 +555,16 @@ CreateMonitor["ConditionTypeEnum"] = {
554
555
  * @enum {String}
555
556
  * @readonly
556
557
  */
557
- CreateMonitor["SourceTypeEnum"] = {
558
+ CreateMonitor['SourceTypeEnum'] = {
558
559
  /**
559
560
  * value: "event"
560
561
  * @const
561
562
  */
562
- event: "event",
563
+ "event": "event",
563
564
  /**
564
565
  * value: "heartbeat"
565
566
  * @const
566
567
  */
567
- heartbeat: "heartbeat"
568
+ "heartbeat": "heartbeat"
568
569
  };
569
570
  var _default = exports["default"] = CreateMonitor;