@blues-inc/notehub-js 6.1.0 → 6.2.0-beta.1

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 (161) hide show
  1. package/README.md +277 -268
  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 +30 -30
  6. package/dist/api/DeviceApi.js +354 -354
  7. package/dist/api/EventApi.js +118 -118
  8. package/dist/api/ExternalDevicesApi.js +41 -41
  9. package/dist/api/JobsApi.js +127 -74
  10. package/dist/api/MonitorApi.js +52 -52
  11. package/dist/api/ProjectApi.js +516 -403
  12. package/dist/api/RouteApi.js +83 -83
  13. package/dist/api/UsageApi.js +67 -67
  14. package/dist/api/WebhookApi.js +51 -51
  15. package/dist/index.js +7 -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/BillingAccount.js +21 -21
  24. package/dist/model/BillingAccountRole.js +9 -9
  25. package/dist/model/BlynkRoute.js +28 -28
  26. package/dist/model/Body.js +5 -5
  27. package/dist/model/CancelJobRun200Response.js +6 -6
  28. package/dist/model/CellularPlan.js +34 -34
  29. package/dist/model/CloneProjectRequest.js +20 -20
  30. package/dist/model/Contact.js +22 -22
  31. package/dist/model/CreateFleetRequest.js +20 -20
  32. package/dist/model/CreateJob201Response.js +8 -8
  33. package/dist/model/CreateMonitor.js +128 -127
  34. package/dist/model/CreateProductRequest.js +22 -22
  35. package/dist/model/CreateProjectRequest.js +16 -16
  36. package/dist/model/CreateUpdateRepository.js +17 -17
  37. package/dist/model/CurrentFirmware.js +12 -12
  38. package/dist/model/DFUEnv.js +12 -12
  39. package/dist/model/DFUState.js +65 -65
  40. package/dist/model/DataField.js +7 -7
  41. package/dist/model/DataSetField.js +19 -19
  42. package/dist/model/DataUsage.js +14 -14
  43. package/dist/model/DatacakeRoute.js +35 -35
  44. package/dist/model/DeleteDeviceFromFleetsRequest.js +8 -8
  45. package/dist/model/DeleteJob200Response.js +6 -6
  46. package/dist/model/DeleteNotefilesRequest.js +7 -7
  47. package/dist/model/Device.js +107 -106
  48. package/dist/model/DeviceDfuHistory.js +20 -19
  49. package/dist/model/DeviceDfuHistoryCurrent.js +32 -32
  50. package/dist/model/DeviceDfuHistoryPage.js +13 -12
  51. package/dist/model/DeviceDfuStateMachine.js +25 -24
  52. package/dist/model/DeviceDfuStateMachineNode.js +22 -22
  53. package/dist/model/DeviceDfuStatus.js +20 -20
  54. package/dist/model/DeviceDfuStatusPage.js +13 -12
  55. package/dist/model/DeviceSession.js +221 -221
  56. package/dist/model/DeviceTowerInfo.js +14 -14
  57. package/dist/model/DeviceUsage.js +32 -32
  58. package/dist/model/DfuActionRequest.js +7 -7
  59. package/dist/model/EmailNotification.js +7 -7
  60. package/dist/model/EnvTreeJsonNode.js +69 -67
  61. package/dist/model/EnvVar.js +18 -18
  62. package/dist/model/EnvironmentVariables.js +8 -8
  63. package/dist/model/Error.js +31 -31
  64. package/dist/model/Event.js +248 -248
  65. package/dist/model/Filter.js +16 -16
  66. package/dist/model/Firmware.js +49 -49
  67. package/dist/model/FirmwareInfo.js +68 -68
  68. package/dist/model/Fleet.js +38 -38
  69. package/dist/model/FleetConnectivityAssurance.js +5 -5
  70. package/dist/model/GetAlerts200Response.js +15 -14
  71. package/dist/model/GetBillingAccount200Response.js +25 -25
  72. package/dist/model/GetBillingAccount200ResponsePlan.js +22 -22
  73. package/dist/model/GetBillingAccountBalanceHistory200Response.js +10 -9
  74. package/dist/model/GetBillingAccountBalanceHistory200ResponseDataInner.js +17 -17
  75. package/dist/model/GetBillingAccounts200Response.js +10 -9
  76. package/dist/model/GetDataUsage200Response.js +13 -12
  77. package/dist/model/GetDataUsage200ResponseDataInner.js +44 -43
  78. package/dist/model/GetDbNote200Response.js +13 -13
  79. package/dist/model/GetDeviceEnvironmentVariablesByPin200Response.js +16 -16
  80. package/dist/model/GetDeviceFleets200Response.js +12 -11
  81. package/dist/model/GetDeviceHealthLog200Response.js +12 -11
  82. package/dist/model/GetDeviceHealthLog200ResponseHealthLogInner.js +19 -19
  83. package/dist/model/GetDeviceLatestEvents200Response.js +10 -9
  84. package/dist/model/GetDevicePlans200Response.js +10 -9
  85. package/dist/model/GetDevicePublicKey200Response.js +16 -16
  86. package/dist/model/GetDevicePublicKeys200Response.js +17 -16
  87. package/dist/model/GetDevicePublicKeys200ResponseDevicePublicKeysInner.js +12 -12
  88. package/dist/model/GetDeviceSessions200Response.js +17 -16
  89. package/dist/model/GetDevices200Response.js +17 -16
  90. package/dist/model/GetEvents200Response.js +21 -20
  91. package/dist/model/GetEventsByCursor200Response.js +24 -23
  92. package/dist/model/GetJobRuns200Response.js +12 -11
  93. package/dist/model/GetJobs200Response.js +12 -11
  94. package/dist/model/GetNotefile200Response.js +11 -11
  95. package/dist/model/GetProducts200Response.js +10 -9
  96. package/dist/model/GetProjectMembers200Response.js +12 -11
  97. package/dist/model/GetProjects200Response.js +10 -9
  98. package/dist/model/GetRouteLogsUsage200Response.js +15 -14
  99. package/dist/model/GetSessionsUsage200Response.js +16 -15
  100. package/dist/model/GetWebhooks200Response.js +10 -9
  101. package/dist/model/GoogleRoute.js +33 -33
  102. package/dist/model/HttpRoute.js +35 -35
  103. package/dist/model/Job.js +59 -28
  104. package/dist/model/JobRun.js +57 -57
  105. package/dist/model/Location.js +40 -40
  106. package/dist/model/Login200Response.js +7 -7
  107. package/dist/model/LoginRequest.js +12 -12
  108. package/dist/model/Monitor.js +102 -101
  109. package/dist/model/MonitorAlertRoutesInner.js +9 -10
  110. package/dist/model/MqttRoute.js +68 -68
  111. package/dist/model/Note.js +31 -31
  112. package/dist/model/NoteInput.js +9 -9
  113. package/dist/model/Notefile.js +23 -22
  114. package/dist/model/NotefileSchema.js +19 -18
  115. package/dist/model/NotehubRoute.js +103 -103
  116. package/dist/model/NotehubRouteSummary.js +23 -23
  117. package/dist/model/OAuth2Error.js +20 -20
  118. package/dist/model/OAuth2TokenResponse.js +23 -23
  119. package/dist/model/PersonalAccessToken.js +34 -34
  120. package/dist/model/PersonalAccessTokenCreatedBy.js +17 -17
  121. package/dist/model/PersonalAccessTokenInfo.js +18 -18
  122. package/dist/model/PersonalAccessTokenSecret.js +12 -12
  123. package/dist/model/Product.js +26 -26
  124. package/dist/model/Project.js +34 -34
  125. package/dist/model/ProjectMember.js +22 -22
  126. package/dist/model/ProvisionDeviceRequest.js +18 -18
  127. package/dist/model/ProxyRoute.js +29 -29
  128. package/dist/model/QubitroRoute.js +33 -33
  129. package/dist/model/RadRoute.js +31 -31
  130. package/dist/model/Repository.js +22 -22
  131. package/dist/model/Role.js +9 -9
  132. package/dist/model/RouteLog.js +38 -38
  133. package/dist/model/RouteTransformSettings.js +18 -18
  134. package/dist/model/RunJob200Response.js +8 -8
  135. package/dist/model/S3ArchiveRoute.js +79 -79
  136. package/dist/model/SatelliteDataUsage.js +18 -18
  137. package/dist/model/SatellitePlan.js +29 -29
  138. package/dist/model/SchemaProperty.js +38 -36
  139. package/dist/model/SignalDevice200Response.js +5 -5
  140. package/dist/model/SimUsage.js +19 -19
  141. package/dist/model/SlackBearerNotification.js +25 -25
  142. package/dist/model/SlackRoute.js +48 -48
  143. package/dist/model/SlackWebHookNotification.js +20 -20
  144. package/dist/model/SnowflakeRoute.js +45 -45
  145. package/dist/model/SnowpipeStreamingRoute.js +60 -60
  146. package/dist/model/ThingworxRoute.js +33 -33
  147. package/dist/model/TowerLocation.js +54 -54
  148. package/dist/model/TwilioRoute.js +43 -43
  149. package/dist/model/UpdateFleetRequest.js +33 -33
  150. package/dist/model/UpdateHostFirmwareRequest.js +117 -0
  151. package/dist/model/UploadMetadata.js +64 -64
  152. package/dist/model/UsageData.js +33 -33
  153. package/dist/model/UsageEventsData.js +49 -49
  154. package/dist/model/UsageEventsResponse.js +15 -14
  155. package/dist/model/UsageRouteLogsData.js +30 -30
  156. package/dist/model/UsageSessionsData.js +43 -43
  157. package/dist/model/UserDfuStateMachine.js +20 -20
  158. package/dist/model/UserDfuStateMachineStatus.js +20 -20
  159. package/dist/model/UserFirmwareInfo.js +12 -12
  160. package/dist/model/WebhookSettings.js +15 -15
  161. package/package.json +3 -3
@@ -14,7 +14,7 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
14
14
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
15
15
  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); } /**
16
16
  * Notehub API
17
- * The OpenAPI definition for the Notehub.io API.
17
+ * The OpenAPI definition for the Notehub.io API.
18
18
  *
19
19
  * The version of the OpenAPI document: 1.2.0
20
20
  * Contact: engineering@blues.io
@@ -27,7 +27,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
27
27
  /**
28
28
  * The TwilioRoute model module.
29
29
  * @module model/TwilioRoute
30
- * @version 6.1.0
30
+ * @version 6.2.0-beta.1
31
31
  */
32
32
  var TwilioRoute = /*#__PURE__*/function () {
33
33
  /**
@@ -60,32 +60,32 @@ var TwilioRoute = /*#__PURE__*/function () {
60
60
  value: function constructFromObject(data, obj) {
61
61
  if (data) {
62
62
  obj = obj || new TwilioRoute();
63
- if (data.hasOwnProperty("account_sid")) {
64
- obj["account_sid"] = _ApiClient["default"].convertToType(data["account_sid"], "String");
63
+ if (data.hasOwnProperty('account_sid')) {
64
+ obj['account_sid'] = _ApiClient["default"].convertToType(data['account_sid'], 'String');
65
65
  }
66
- if (data.hasOwnProperty("auth_token")) {
67
- obj["auth_token"] = _ApiClient["default"].convertToType(data["auth_token"], "String");
66
+ if (data.hasOwnProperty('auth_token')) {
67
+ obj['auth_token'] = _ApiClient["default"].convertToType(data['auth_token'], 'String');
68
68
  }
69
- if (data.hasOwnProperty("filter")) {
70
- obj["filter"] = _Filter["default"].constructFromObject(data["filter"]);
69
+ if (data.hasOwnProperty('filter')) {
70
+ obj['filter'] = _Filter["default"].constructFromObject(data['filter']);
71
71
  }
72
- if (data.hasOwnProperty("fleets")) {
73
- obj["fleets"] = _ApiClient["default"].convertToType(data["fleets"], ["String"]);
72
+ if (data.hasOwnProperty('fleets')) {
73
+ obj['fleets'] = _ApiClient["default"].convertToType(data['fleets'], ['String']);
74
74
  }
75
- if (data.hasOwnProperty("from")) {
76
- obj["from"] = _ApiClient["default"].convertToType(data["from"], "String");
75
+ if (data.hasOwnProperty('from')) {
76
+ obj['from'] = _ApiClient["default"].convertToType(data['from'], 'String');
77
77
  }
78
- if (data.hasOwnProperty("message")) {
79
- obj["message"] = _ApiClient["default"].convertToType(data["message"], "String");
78
+ if (data.hasOwnProperty('message')) {
79
+ obj['message'] = _ApiClient["default"].convertToType(data['message'], 'String');
80
80
  }
81
- if (data.hasOwnProperty("throttle_ms")) {
82
- obj["throttle_ms"] = _ApiClient["default"].convertToType(data["throttle_ms"], "Number");
81
+ if (data.hasOwnProperty('throttle_ms')) {
82
+ obj['throttle_ms'] = _ApiClient["default"].convertToType(data['throttle_ms'], 'Number');
83
83
  }
84
- if (data.hasOwnProperty("timeout")) {
85
- obj["timeout"] = _ApiClient["default"].convertToType(data["timeout"], "Number");
84
+ if (data.hasOwnProperty('timeout')) {
85
+ obj['timeout'] = _ApiClient["default"].convertToType(data['timeout'], 'Number');
86
86
  }
87
- if (data.hasOwnProperty("to")) {
88
- obj["to"] = _ApiClient["default"].convertToType(data["to"], "String");
87
+ if (data.hasOwnProperty('to')) {
88
+ obj['to'] = _ApiClient["default"].convertToType(data['to'], 'String');
89
89
  }
90
90
  } else if (data === null) {
91
91
  return null;
@@ -102,33 +102,33 @@ var TwilioRoute = /*#__PURE__*/function () {
102
102
  key: "validateJSON",
103
103
  value: function validateJSON(data) {
104
104
  // ensure the json data is a string
105
- if (data["account_sid"] && !(typeof data["account_sid"] === "string" || data["account_sid"] instanceof String)) {
106
- throw new Error("Expected the field `account_sid` to be a primitive type in the JSON string but got " + data["account_sid"]);
105
+ if (data['account_sid'] && !(typeof data['account_sid'] === 'string' || data['account_sid'] instanceof String)) {
106
+ throw new Error("Expected the field `account_sid` to be a primitive type in the JSON string but got " + data['account_sid']);
107
107
  }
108
108
  // ensure the json data is a string
109
- if (data["auth_token"] && !(typeof data["auth_token"] === "string" || data["auth_token"] instanceof String)) {
110
- throw new Error("Expected the field `auth_token` to be a primitive type in the JSON string but got " + data["auth_token"]);
109
+ if (data['auth_token'] && !(typeof data['auth_token'] === 'string' || data['auth_token'] instanceof String)) {
110
+ throw new Error("Expected the field `auth_token` to be a primitive type in the JSON string but got " + data['auth_token']);
111
111
  }
112
112
  // validate the optional field `filter`
113
- if (data["filter"]) {
113
+ if (data['filter']) {
114
114
  // data not null
115
- _Filter["default"].validateJSON(data["filter"]);
115
+ _Filter["default"].validateJSON(data['filter']);
116
116
  }
117
117
  // ensure the json data is an array
118
- if (!Array.isArray(data["fleets"])) {
119
- throw new Error("Expected the field `fleets` to be an array in the JSON data but got " + data["fleets"]);
118
+ if (!Array.isArray(data['fleets'])) {
119
+ throw new Error("Expected the field `fleets` to be an array in the JSON data but got " + data['fleets']);
120
120
  }
121
121
  // ensure the json data is a string
122
- if (data["from"] && !(typeof data["from"] === "string" || data["from"] instanceof String)) {
123
- throw new Error("Expected the field `from` to be a primitive type in the JSON string but got " + data["from"]);
122
+ if (data['from'] && !(typeof data['from'] === 'string' || data['from'] instanceof String)) {
123
+ throw new Error("Expected the field `from` to be a primitive type in the JSON string but got " + data['from']);
124
124
  }
125
125
  // ensure the json data is a string
126
- if (data["message"] && !(typeof data["message"] === "string" || data["message"] instanceof String)) {
127
- throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data["message"]);
126
+ if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) {
127
+ throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']);
128
128
  }
129
129
  // ensure the json data is a string
130
- if (data["to"] && !(typeof data["to"] === "string" || data["to"] instanceof String)) {
131
- throw new Error("Expected the field `to` to be a primitive type in the JSON string but got " + data["to"]);
130
+ if (data['to'] && !(typeof data['to'] === 'string' || data['to'] instanceof String)) {
131
+ throw new Error("Expected the field `to` to be a primitive type in the JSON string but got " + data['to']);
132
132
  }
133
133
  return true;
134
134
  }
@@ -137,45 +137,45 @@ var TwilioRoute = /*#__PURE__*/function () {
137
137
  /**
138
138
  * @member {String} account_sid
139
139
  */
140
- TwilioRoute.prototype["account_sid"] = undefined;
140
+ TwilioRoute.prototype['account_sid'] = undefined;
141
141
 
142
142
  /**
143
143
  * @member {String} auth_token
144
144
  */
145
- TwilioRoute.prototype["auth_token"] = undefined;
145
+ TwilioRoute.prototype['auth_token'] = undefined;
146
146
 
147
147
  /**
148
148
  * @member {module:model/Filter} filter
149
149
  */
150
- TwilioRoute.prototype["filter"] = undefined;
150
+ TwilioRoute.prototype['filter'] = undefined;
151
151
 
152
152
  /**
153
153
  * @member {Array.<String>} fleets
154
154
  */
155
- TwilioRoute.prototype["fleets"] = undefined;
155
+ TwilioRoute.prototype['fleets'] = undefined;
156
156
 
157
157
  /**
158
158
  * @member {String} from
159
159
  */
160
- TwilioRoute.prototype["from"] = undefined;
160
+ TwilioRoute.prototype['from'] = undefined;
161
161
 
162
162
  /**
163
163
  * @member {String} message
164
164
  */
165
- TwilioRoute.prototype["message"] = undefined;
165
+ TwilioRoute.prototype['message'] = undefined;
166
166
 
167
167
  /**
168
168
  * @member {Number} throttle_ms
169
169
  */
170
- TwilioRoute.prototype["throttle_ms"] = undefined;
170
+ TwilioRoute.prototype['throttle_ms'] = undefined;
171
171
 
172
172
  /**
173
173
  * @member {Number} timeout
174
174
  */
175
- TwilioRoute.prototype["timeout"] = undefined;
175
+ TwilioRoute.prototype['timeout'] = undefined;
176
176
 
177
177
  /**
178
178
  * @member {String} to
179
179
  */
180
- TwilioRoute.prototype["to"] = undefined;
180
+ TwilioRoute.prototype['to'] = undefined;
181
181
  var _default = exports["default"] = TwilioRoute;
@@ -14,7 +14,7 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
14
14
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
15
15
  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); } /**
16
16
  * Notehub API
17
- * The OpenAPI definition for the Notehub.io API.
17
+ * The OpenAPI definition for the Notehub.io API.
18
18
  *
19
19
  * The version of the OpenAPI document: 1.2.0
20
20
  * Contact: engineering@blues.io
@@ -27,7 +27,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
27
27
  /**
28
28
  * The UpdateFleetRequest model module.
29
29
  * @module model/UpdateFleetRequest
30
- * @version 6.1.0
30
+ * @version 6.2.0-beta.1
31
31
  */
32
32
  var UpdateFleetRequest = /*#__PURE__*/function () {
33
33
  /**
@@ -60,26 +60,26 @@ var UpdateFleetRequest = /*#__PURE__*/function () {
60
60
  value: function constructFromObject(data, obj) {
61
61
  if (data) {
62
62
  obj = obj || new UpdateFleetRequest();
63
- if (data.hasOwnProperty("addDevices")) {
64
- obj["addDevices"] = _ApiClient["default"].convertToType(data["addDevices"], ["String"]);
63
+ if (data.hasOwnProperty('addDevices')) {
64
+ obj['addDevices'] = _ApiClient["default"].convertToType(data['addDevices'], ['String']);
65
65
  }
66
- if (data.hasOwnProperty("connectivity_assurance")) {
67
- obj["connectivity_assurance"] = _FleetConnectivityAssurance["default"].constructFromObject(data["connectivity_assurance"]);
66
+ if (data.hasOwnProperty('connectivity_assurance')) {
67
+ obj['connectivity_assurance'] = _FleetConnectivityAssurance["default"].constructFromObject(data['connectivity_assurance']);
68
68
  }
69
- if (data.hasOwnProperty("label")) {
70
- obj["label"] = _ApiClient["default"].convertToType(data["label"], "String");
69
+ if (data.hasOwnProperty('label')) {
70
+ obj['label'] = _ApiClient["default"].convertToType(data['label'], 'String');
71
71
  }
72
- if (data.hasOwnProperty("removeDevices")) {
73
- obj["removeDevices"] = _ApiClient["default"].convertToType(data["removeDevices"], ["String"]);
72
+ if (data.hasOwnProperty('removeDevices')) {
73
+ obj['removeDevices'] = _ApiClient["default"].convertToType(data['removeDevices'], ['String']);
74
74
  }
75
- if (data.hasOwnProperty("smart_rule")) {
76
- obj["smart_rule"] = _ApiClient["default"].convertToType(data["smart_rule"], "String");
75
+ if (data.hasOwnProperty('smart_rule')) {
76
+ obj['smart_rule'] = _ApiClient["default"].convertToType(data['smart_rule'], 'String');
77
77
  }
78
- if (data.hasOwnProperty("smart_rule_enabled")) {
79
- obj["smart_rule_enabled"] = _ApiClient["default"].convertToType(data["smart_rule_enabled"], "Boolean");
78
+ if (data.hasOwnProperty('smart_rule_enabled')) {
79
+ obj['smart_rule_enabled'] = _ApiClient["default"].convertToType(data['smart_rule_enabled'], 'Boolean');
80
80
  }
81
- if (data.hasOwnProperty("watchdog_mins")) {
82
- obj["watchdog_mins"] = _ApiClient["default"].convertToType(data["watchdog_mins"], "Number");
81
+ if (data.hasOwnProperty('watchdog_mins')) {
82
+ obj['watchdog_mins'] = _ApiClient["default"].convertToType(data['watchdog_mins'], 'Number');
83
83
  }
84
84
  } else if (data === null) {
85
85
  return null;
@@ -96,25 +96,25 @@ var UpdateFleetRequest = /*#__PURE__*/function () {
96
96
  key: "validateJSON",
97
97
  value: function validateJSON(data) {
98
98
  // ensure the json data is an array
99
- if (!Array.isArray(data["addDevices"])) {
100
- throw new Error("Expected the field `addDevices` to be an array in the JSON data but got " + data["addDevices"]);
99
+ if (!Array.isArray(data['addDevices'])) {
100
+ throw new Error("Expected the field `addDevices` to be an array in the JSON data but got " + data['addDevices']);
101
101
  }
102
102
  // validate the optional field `connectivity_assurance`
103
- if (data["connectivity_assurance"]) {
103
+ if (data['connectivity_assurance']) {
104
104
  // data not null
105
- _FleetConnectivityAssurance["default"].validateJSON(data["connectivity_assurance"]);
105
+ _FleetConnectivityAssurance["default"].validateJSON(data['connectivity_assurance']);
106
106
  }
107
107
  // ensure the json data is a string
108
- if (data["label"] && !(typeof data["label"] === "string" || data["label"] instanceof String)) {
109
- throw new Error("Expected the field `label` to be a primitive type in the JSON string but got " + data["label"]);
108
+ if (data['label'] && !(typeof data['label'] === 'string' || data['label'] instanceof String)) {
109
+ throw new Error("Expected the field `label` to be a primitive type in the JSON string but got " + data['label']);
110
110
  }
111
111
  // ensure the json data is an array
112
- if (!Array.isArray(data["removeDevices"])) {
113
- throw new Error("Expected the field `removeDevices` to be an array in the JSON data but got " + data["removeDevices"]);
112
+ if (!Array.isArray(data['removeDevices'])) {
113
+ throw new Error("Expected the field `removeDevices` to be an array in the JSON data but got " + data['removeDevices']);
114
114
  }
115
115
  // ensure the json data is a string
116
- if (data["smart_rule"] && !(typeof data["smart_rule"] === "string" || data["smart_rule"] instanceof String)) {
117
- throw new Error("Expected the field `smart_rule` to be a primitive type in the JSON string but got " + data["smart_rule"]);
116
+ if (data['smart_rule'] && !(typeof data['smart_rule'] === 'string' || data['smart_rule'] instanceof String)) {
117
+ throw new Error("Expected the field `smart_rule` to be a primitive type in the JSON string but got " + data['smart_rule']);
118
118
  }
119
119
  return true;
120
120
  }
@@ -124,39 +124,39 @@ var UpdateFleetRequest = /*#__PURE__*/function () {
124
124
  * List of DeviceUIDs to add to fleet
125
125
  * @member {Array.<String>} addDevices
126
126
  */
127
- UpdateFleetRequest.prototype["addDevices"] = undefined;
127
+ UpdateFleetRequest.prototype['addDevices'] = undefined;
128
128
 
129
129
  /**
130
130
  * @member {module:model/FleetConnectivityAssurance} connectivity_assurance
131
131
  */
132
- UpdateFleetRequest.prototype["connectivity_assurance"] = undefined;
132
+ UpdateFleetRequest.prototype['connectivity_assurance'] = undefined;
133
133
 
134
134
  /**
135
135
  * The label for the Fleet.
136
136
  * @member {String} label
137
137
  */
138
- UpdateFleetRequest.prototype["label"] = undefined;
138
+ UpdateFleetRequest.prototype['label'] = undefined;
139
139
 
140
140
  /**
141
141
  * List of DeviceUIDs to remove from fleet
142
142
  * @member {Array.<String>} removeDevices
143
143
  */
144
- UpdateFleetRequest.prototype["removeDevices"] = undefined;
144
+ UpdateFleetRequest.prototype['removeDevices'] = undefined;
145
145
 
146
146
  /**
147
147
  * JSONata expression that will be evaluated to determine device membership into this fleet, if the expression evaluates to a 1, the device will be included, if it evaluates to -1 it will be removed, and if it evaluates to 0 or errors it will be left unchanged.
148
148
  * @member {String} smart_rule
149
149
  */
150
- UpdateFleetRequest.prototype["smart_rule"] = undefined;
150
+ UpdateFleetRequest.prototype['smart_rule'] = undefined;
151
151
 
152
152
  /**
153
153
  * @member {Boolean} smart_rule_enabled
154
154
  */
155
- UpdateFleetRequest.prototype["smart_rule_enabled"] = undefined;
155
+ UpdateFleetRequest.prototype['smart_rule_enabled'] = undefined;
156
156
 
157
157
  /**
158
158
  * A watchdog timer is used to generate an event every N minutes of inactivity. 0 means no watchdog
159
159
  * @member {Number} watchdog_mins
160
160
  */
161
- UpdateFleetRequest.prototype["watchdog_mins"] = undefined;
161
+ UpdateFleetRequest.prototype['watchdog_mins'] = undefined;
162
162
  var _default = exports["default"] = UpdateFleetRequest;
@@ -0,0 +1,117 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
9
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
10
+ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
11
+ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
12
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
13
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
14
+ 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); } /**
15
+ * Notehub API
16
+ * The OpenAPI definition for the Notehub.io API.
17
+ *
18
+ * The version of the OpenAPI document: 1.2.0
19
+ * Contact: engineering@blues.io
20
+ *
21
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
22
+ * https://openapi-generator.tech
23
+ * Do not edit the class manually.
24
+ *
25
+ */
26
+ /**
27
+ * The UpdateHostFirmwareRequest model module.
28
+ * @module model/UpdateHostFirmwareRequest
29
+ * @version 6.2.0-beta.1
30
+ */
31
+ var UpdateHostFirmwareRequest = /*#__PURE__*/function () {
32
+ /**
33
+ * Constructs a new <code>UpdateHostFirmwareRequest</code>.
34
+ * Request body for updating host firmware metadata. All fields are optional; only provided fields will be updated.
35
+ * @alias module:model/UpdateHostFirmwareRequest
36
+ */
37
+ function UpdateHostFirmwareRequest() {
38
+ _classCallCheck(this, UpdateHostFirmwareRequest);
39
+ UpdateHostFirmwareRequest.initialize(this);
40
+ }
41
+
42
+ /**
43
+ * Initializes the fields of this object.
44
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
45
+ * Only for internal use.
46
+ */
47
+ return _createClass(UpdateHostFirmwareRequest, null, [{
48
+ key: "initialize",
49
+ value: function initialize(obj) {}
50
+
51
+ /**
52
+ * Constructs a <code>UpdateHostFirmwareRequest</code> from a plain JavaScript object, optionally creating a new instance.
53
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
54
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
55
+ * @param {module:model/UpdateHostFirmwareRequest} obj Optional instance to populate.
56
+ * @return {module:model/UpdateHostFirmwareRequest} The populated <code>UpdateHostFirmwareRequest</code> instance.
57
+ */
58
+ }, {
59
+ key: "constructFromObject",
60
+ value: function constructFromObject(data, obj) {
61
+ if (data) {
62
+ obj = obj || new UpdateHostFirmwareRequest();
63
+ if (data.hasOwnProperty('info')) {
64
+ obj['info'] = _ApiClient["default"].convertToType(data['info'], {
65
+ 'String': Object
66
+ });
67
+ }
68
+ if (data.hasOwnProperty('notes')) {
69
+ obj['notes'] = _ApiClient["default"].convertToType(data['notes'], 'String');
70
+ }
71
+ if (data.hasOwnProperty('version')) {
72
+ obj['version'] = _ApiClient["default"].convertToType(data['version'], 'String');
73
+ }
74
+ } else if (data === null) {
75
+ return null;
76
+ }
77
+ return obj;
78
+ }
79
+
80
+ /**
81
+ * Validates the JSON data with respect to <code>UpdateHostFirmwareRequest</code>.
82
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
83
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>UpdateHostFirmwareRequest</code>.
84
+ */
85
+ }, {
86
+ key: "validateJSON",
87
+ value: function validateJSON(data) {
88
+ // ensure the json data is a string
89
+ if (data['notes'] && !(typeof data['notes'] === 'string' || data['notes'] instanceof String)) {
90
+ throw new Error("Expected the field `notes` to be a primitive type in the JSON string but got " + data['notes']);
91
+ }
92
+ // ensure the json data is a string
93
+ if (data['version'] && !(typeof data['version'] === 'string' || data['version'] instanceof String)) {
94
+ throw new Error("Expected the field `version` to be a primitive type in the JSON string but got " + data['version']);
95
+ }
96
+ return true;
97
+ }
98
+ }]);
99
+ }();
100
+ /**
101
+ * Arbitrary JSON metadata associated with this firmware entry.
102
+ * @member {Object.<String, Object>} info
103
+ */
104
+ UpdateHostFirmwareRequest.prototype['info'] = undefined;
105
+
106
+ /**
107
+ * Notes describing this firmware version.
108
+ * @member {String} notes
109
+ */
110
+ UpdateHostFirmwareRequest.prototype['notes'] = undefined;
111
+
112
+ /**
113
+ * The firmware version string.
114
+ * @member {String} version
115
+ */
116
+ UpdateHostFirmwareRequest.prototype['version'] = undefined;
117
+ var _default = exports["default"] = UpdateHostFirmwareRequest;