@blues-inc/notehub-js 1.0.23 → 1.0.24-beta.2
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.
- package/README.md +199 -178
- package/dist/ApiClient.js +156 -156
- package/dist/api/AlertApi.js +23 -23
- package/dist/api/AuthorizationApi.js +17 -17
- package/dist/api/BillingAccountApi.js +15 -15
- package/dist/api/DeviceApi.js +352 -352
- package/dist/api/EventApi.js +134 -124
- package/dist/api/MonitorApi.js +53 -53
- package/dist/api/ProjectApi.js +599 -330
- package/dist/api/RouteApi.js +103 -103
- package/dist/index.js +102 -39
- package/dist/model/Alert.js +108 -62
- package/dist/model/AlertDataInner.js +36 -36
- package/dist/model/AlertNotificationsInner.js +19 -19
- package/dist/model/Aws.js +66 -66
- package/dist/model/Azure.js +44 -44
- package/dist/model/BillingAccount.js +22 -22
- package/dist/model/BillingAccountRole.js +10 -10
- package/dist/model/Body.js +6 -6
- package/dist/model/CloneProjectRequest.js +21 -21
- package/dist/model/Contact.js +23 -23
- package/dist/model/CreateFleetRequest.js +8 -8
- package/dist/model/CreateMonitor.js +127 -126
- package/dist/model/CreateProductRequest.js +23 -23
- package/dist/model/CreateProjectRequest.js +17 -17
- package/dist/model/{OTAUpdateStatus.js → CurrentFirmware.js} +34 -47
- package/dist/model/DFUEnv.js +13 -13
- package/dist/model/DFUState.js +66 -66
- package/dist/model/DeleteDeviceFleetsRequest.js +9 -9
- package/dist/model/Device.js +85 -85
- package/dist/model/DeviceDfuHistory.js +139 -0
- package/dist/model/DeviceDfuHistoryPage.js +121 -0
- package/dist/model/DeviceDfuStateMachine.js +152 -0
- package/dist/model/DeviceDfuStateMachineNode.js +132 -0
- package/dist/model/DeviceDfuStatus.js +129 -0
- package/dist/model/DeviceDfuStatusCurrent.js +158 -0
- package/dist/model/{OTAStatusList.js → DeviceDfuStatusPage.js} +34 -33
- package/dist/model/DeviceSession.js +183 -183
- package/dist/model/DeviceTowerInfo.js +15 -15
- package/dist/model/DeviceUsage.js +33 -33
- package/dist/model/DfuActionRequest.js +92 -0
- package/dist/model/EmailNotification.js +8 -8
- package/dist/model/EnvironmentVariables.js +9 -9
- package/dist/model/Error.js +32 -32
- package/dist/model/Event.js +224 -224
- package/dist/model/Firmware.js +195 -0
- package/dist/model/FirmwareInfo.js +61 -61
- package/dist/model/Fleet.js +22 -22
- package/dist/model/GetAlerts200Response.js +16 -15
- package/dist/model/GetBillingAccounts200Response.js +11 -10
- package/dist/model/GetDeviceEnvironmentVariables200Response.js +13 -13
- package/dist/model/GetDeviceHealthLog200Response.js +13 -12
- package/dist/model/GetDeviceHealthLog200ResponseHealthLogInner.js +20 -20
- package/dist/model/GetDeviceLatest200Response.js +11 -10
- package/dist/model/GetDevicePublicKey200Response.js +17 -17
- package/dist/model/GetDeviceSessions200Response.js +18 -17
- package/dist/model/GetProjectDevicePublicKeys200Response.js +18 -17
- package/dist/model/GetProjectDevicePublicKeys200ResponseDevicePublicKeysInner.js +13 -13
- package/dist/model/GetProjectDevices200Response.js +18 -17
- package/dist/model/GetProjectEvents200Response.js +22 -21
- package/dist/model/GetProjectEventsByCursor200Response.js +25 -24
- package/dist/model/GetProjectFleets200Response.js +13 -12
- package/dist/model/GetProjectMembers200Response.js +13 -12
- package/dist/model/GetProjectProducts200Response.js +11 -10
- package/dist/model/GetProjects200Response.js +11 -10
- package/dist/model/GetRouteLogsByRoute200ResponseInner.js +36 -36
- package/dist/model/Google.js +34 -34
- package/dist/model/HandleNoteChanges200Response.js +12 -12
- package/dist/model/HandleNoteGet200Response.js +14 -14
- package/dist/model/HandleNoteSignal200Response.js +6 -6
- package/dist/model/HandleNotefileChanges200Response.js +12 -12
- package/dist/model/HandleNotefileChangesPending200Response.js +15 -15
- package/dist/model/HandleNotefileDeleteRequest.js +8 -8
- package/dist/model/Http.js +36 -36
- package/dist/model/HttpFilter.js +20 -20
- package/dist/model/HttpTransform.js +21 -21
- package/dist/model/Location.js +41 -41
- package/dist/model/Login200Response.js +8 -8
- package/dist/model/LoginRequest.js +13 -13
- package/dist/model/Monitor.js +101 -100
- package/dist/model/MonitorAlertRoutesInner.js +10 -11
- package/dist/model/Mqtt.js +67 -67
- package/dist/model/Note.js +11 -11
- package/dist/model/{Route.js → NotehubRoute.js} +56 -56
- package/dist/model/{RouteSchema.js → NotehubRouteSchema.js} +70 -71
- package/dist/model/PostProvisionProjectDeviceRequest.js +14 -14
- package/dist/model/Product.js +27 -27
- package/dist/model/Project.js +35 -35
- package/dist/model/ProjectMember.js +23 -23
- package/dist/model/Proxy.js +25 -25
- package/dist/model/PutDeviceFleetsRequest.js +9 -9
- package/dist/model/Radresponder.js +26 -26
- package/dist/model/Role.js +10 -10
- package/dist/model/Slack.js +54 -54
- package/dist/model/SlackBearerNotification.js +26 -26
- package/dist/model/SlackWebHookNotification.js +21 -21
- package/dist/model/Snowflake.js +46 -46
- package/dist/model/SnowflakeTransform.js +13 -13
- package/dist/model/Thingworx.js +34 -34
- package/dist/model/TowerLocation.js +53 -53
- package/dist/model/Twilio.js +44 -44
- package/dist/model/UpdateFleetRequest.js +18 -18
- package/dist/model/UploadMetadata.js +221 -0
- package/dist/model/UserDbRoute.js +26 -26
- package/dist/model/UserDfuStateMachine.js +127 -0
- package/dist/model/UserDfuStateMachineStatus.js +123 -0
- package/dist/model/UserFirmwareInfo.js +107 -0
- package/package.json +3 -3
- package/dist/model/FirmwareStatus.js +0 -144
- package/dist/model/OTAStatus.js +0 -306
- package/dist/model/OTAUpdateRequest.js +0 -214
|
@@ -0,0 +1,195 @@
|
|
|
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 Firmware model module.
|
|
28
|
+
* @module model/Firmware
|
|
29
|
+
* @version 1.0.24-beta.2
|
|
30
|
+
*/
|
|
31
|
+
var Firmware = /*#__PURE__*/function () {
|
|
32
|
+
/**
|
|
33
|
+
* Constructs a new <code>Firmware</code>.
|
|
34
|
+
* @alias module:model/Firmware
|
|
35
|
+
*/
|
|
36
|
+
function Firmware() {
|
|
37
|
+
_classCallCheck(this, Firmware);
|
|
38
|
+
Firmware.initialize(this);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Initializes the fields of this object.
|
|
43
|
+
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
|
44
|
+
* Only for internal use.
|
|
45
|
+
*/
|
|
46
|
+
return _createClass(Firmware, null, [{
|
|
47
|
+
key: "initialize",
|
|
48
|
+
value: function initialize(obj) {}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Constructs a <code>Firmware</code> from a plain JavaScript object, optionally creating a new instance.
|
|
52
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
53
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
54
|
+
* @param {module:model/Firmware} obj Optional instance to populate.
|
|
55
|
+
* @return {module:model/Firmware} The populated <code>Firmware</code> instance.
|
|
56
|
+
*/
|
|
57
|
+
}, {
|
|
58
|
+
key: "constructFromObject",
|
|
59
|
+
value: function constructFromObject(data, obj) {
|
|
60
|
+
if (data) {
|
|
61
|
+
obj = obj || new Firmware();
|
|
62
|
+
if (data.hasOwnProperty('org')) {
|
|
63
|
+
obj['org'] = _ApiClient["default"].convertToType(data['org'], 'String');
|
|
64
|
+
}
|
|
65
|
+
if (data.hasOwnProperty('product')) {
|
|
66
|
+
obj['product'] = _ApiClient["default"].convertToType(data['product'], 'String');
|
|
67
|
+
}
|
|
68
|
+
if (data.hasOwnProperty('firmware')) {
|
|
69
|
+
obj['firmware'] = _ApiClient["default"].convertToType(data['firmware'], 'String');
|
|
70
|
+
}
|
|
71
|
+
if (data.hasOwnProperty('version')) {
|
|
72
|
+
obj['version'] = _ApiClient["default"].convertToType(data['version'], 'String');
|
|
73
|
+
}
|
|
74
|
+
if (data.hasOwnProperty('target')) {
|
|
75
|
+
obj['target'] = _ApiClient["default"].convertToType(data['target'], 'String');
|
|
76
|
+
}
|
|
77
|
+
if (data.hasOwnProperty('ver_major')) {
|
|
78
|
+
obj['ver_major'] = _ApiClient["default"].convertToType(data['ver_major'], 'Number');
|
|
79
|
+
}
|
|
80
|
+
if (data.hasOwnProperty('ver_minor')) {
|
|
81
|
+
obj['ver_minor'] = _ApiClient["default"].convertToType(data['ver_minor'], 'Number');
|
|
82
|
+
}
|
|
83
|
+
if (data.hasOwnProperty('ver_patch')) {
|
|
84
|
+
obj['ver_patch'] = _ApiClient["default"].convertToType(data['ver_patch'], 'Number');
|
|
85
|
+
}
|
|
86
|
+
if (data.hasOwnProperty('ver_build')) {
|
|
87
|
+
obj['ver_build'] = _ApiClient["default"].convertToType(data['ver_build'], 'Number');
|
|
88
|
+
}
|
|
89
|
+
if (data.hasOwnProperty('built')) {
|
|
90
|
+
obj['built'] = _ApiClient["default"].convertToType(data['built'], 'String');
|
|
91
|
+
}
|
|
92
|
+
if (data.hasOwnProperty('builder')) {
|
|
93
|
+
obj['builder'] = _ApiClient["default"].convertToType(data['builder'], 'String');
|
|
94
|
+
}
|
|
95
|
+
} else if (data === null) {
|
|
96
|
+
return null;
|
|
97
|
+
}
|
|
98
|
+
return obj;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Validates the JSON data with respect to <code>Firmware</code>.
|
|
103
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
104
|
+
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>Firmware</code>.
|
|
105
|
+
*/
|
|
106
|
+
}, {
|
|
107
|
+
key: "validateJSON",
|
|
108
|
+
value: function validateJSON(data) {
|
|
109
|
+
// ensure the json data is a string
|
|
110
|
+
if (data['org'] && !(typeof data['org'] === 'string' || data['org'] instanceof String)) {
|
|
111
|
+
throw new Error("Expected the field `org` to be a primitive type in the JSON string but got " + data['org']);
|
|
112
|
+
}
|
|
113
|
+
// ensure the json data is a string
|
|
114
|
+
if (data['product'] && !(typeof data['product'] === 'string' || data['product'] instanceof String)) {
|
|
115
|
+
throw new Error("Expected the field `product` to be a primitive type in the JSON string but got " + data['product']);
|
|
116
|
+
}
|
|
117
|
+
// ensure the json data is a string
|
|
118
|
+
if (data['firmware'] && !(typeof data['firmware'] === 'string' || data['firmware'] instanceof String)) {
|
|
119
|
+
throw new Error("Expected the field `firmware` to be a primitive type in the JSON string but got " + data['firmware']);
|
|
120
|
+
}
|
|
121
|
+
// ensure the json data is a string
|
|
122
|
+
if (data['version'] && !(typeof data['version'] === 'string' || data['version'] instanceof String)) {
|
|
123
|
+
throw new Error("Expected the field `version` to be a primitive type in the JSON string but got " + data['version']);
|
|
124
|
+
}
|
|
125
|
+
// ensure the json data is a string
|
|
126
|
+
if (data['target'] && !(typeof data['target'] === 'string' || data['target'] instanceof String)) {
|
|
127
|
+
throw new Error("Expected the field `target` to be a primitive type in the JSON string but got " + data['target']);
|
|
128
|
+
}
|
|
129
|
+
// ensure the json data is a string
|
|
130
|
+
if (data['built'] && !(typeof data['built'] === 'string' || data['built'] instanceof String)) {
|
|
131
|
+
throw new Error("Expected the field `built` to be a primitive type in the JSON string but got " + data['built']);
|
|
132
|
+
}
|
|
133
|
+
// ensure the json data is a string
|
|
134
|
+
if (data['builder'] && !(typeof data['builder'] === 'string' || data['builder'] instanceof String)) {
|
|
135
|
+
throw new Error("Expected the field `builder` to be a primitive type in the JSON string but got " + data['builder']);
|
|
136
|
+
}
|
|
137
|
+
return true;
|
|
138
|
+
}
|
|
139
|
+
}]);
|
|
140
|
+
}();
|
|
141
|
+
/**
|
|
142
|
+
* @member {String} org
|
|
143
|
+
*/
|
|
144
|
+
Firmware.prototype['org'] = undefined;
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* @member {String} product
|
|
148
|
+
*/
|
|
149
|
+
Firmware.prototype['product'] = undefined;
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* @member {String} firmware
|
|
153
|
+
*/
|
|
154
|
+
Firmware.prototype['firmware'] = undefined;
|
|
155
|
+
|
|
156
|
+
/**
|
|
157
|
+
* @member {String} version
|
|
158
|
+
*/
|
|
159
|
+
Firmware.prototype['version'] = undefined;
|
|
160
|
+
|
|
161
|
+
/**
|
|
162
|
+
* @member {String} target
|
|
163
|
+
*/
|
|
164
|
+
Firmware.prototype['target'] = undefined;
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* @member {Number} ver_major
|
|
168
|
+
*/
|
|
169
|
+
Firmware.prototype['ver_major'] = undefined;
|
|
170
|
+
|
|
171
|
+
/**
|
|
172
|
+
* @member {Number} ver_minor
|
|
173
|
+
*/
|
|
174
|
+
Firmware.prototype['ver_minor'] = undefined;
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* @member {Number} ver_patch
|
|
178
|
+
*/
|
|
179
|
+
Firmware.prototype['ver_patch'] = undefined;
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* @member {Number} ver_build
|
|
183
|
+
*/
|
|
184
|
+
Firmware.prototype['ver_build'] = undefined;
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* @member {String} built
|
|
188
|
+
*/
|
|
189
|
+
Firmware.prototype['built'] = undefined;
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* @member {String} builder
|
|
193
|
+
*/
|
|
194
|
+
Firmware.prototype['builder'] = undefined;
|
|
195
|
+
var _default = exports["default"] = Firmware;
|
|
@@ -13,9 +13,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
13
13
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
14
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
15
|
* Notehub API
|
|
16
|
-
* The OpenAPI definition for the Notehub.io API.
|
|
16
|
+
* The OpenAPI definition for the Notehub.io API.
|
|
17
17
|
*
|
|
18
|
-
* The version of the OpenAPI document: 1.
|
|
18
|
+
* The version of the OpenAPI document: 1.2.0
|
|
19
19
|
* Contact: engineering@blues.io
|
|
20
20
|
*
|
|
21
21
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The FirmwareInfo model module.
|
|
28
28
|
* @module model/FirmwareInfo
|
|
29
|
-
* @version 1.0.
|
|
29
|
+
* @version 1.0.24-beta.2
|
|
30
30
|
*/
|
|
31
31
|
var FirmwareInfo = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
|
@@ -59,41 +59,41 @@ var FirmwareInfo = /*#__PURE__*/function () {
|
|
|
59
59
|
value: function constructFromObject(data, obj) {
|
|
60
60
|
if (data) {
|
|
61
61
|
obj = obj || new FirmwareInfo();
|
|
62
|
-
if (data.hasOwnProperty(
|
|
63
|
-
obj[
|
|
62
|
+
if (data.hasOwnProperty('filename')) {
|
|
63
|
+
obj['filename'] = _ApiClient["default"].convertToType(data['filename'], 'String');
|
|
64
64
|
}
|
|
65
|
-
if (data.hasOwnProperty(
|
|
66
|
-
obj[
|
|
65
|
+
if (data.hasOwnProperty('version')) {
|
|
66
|
+
obj['version'] = _ApiClient["default"].convertToType(data['version'], 'String');
|
|
67
67
|
}
|
|
68
|
-
if (data.hasOwnProperty(
|
|
69
|
-
obj[
|
|
68
|
+
if (data.hasOwnProperty('MD5')) {
|
|
69
|
+
obj['MD5'] = _ApiClient["default"].convertToType(data['MD5'], 'String');
|
|
70
70
|
}
|
|
71
|
-
if (data.hasOwnProperty(
|
|
72
|
-
obj[
|
|
71
|
+
if (data.hasOwnProperty('organization')) {
|
|
72
|
+
obj['organization'] = _ApiClient["default"].convertToType(data['organization'], 'String');
|
|
73
73
|
}
|
|
74
|
-
if (data.hasOwnProperty(
|
|
75
|
-
obj[
|
|
74
|
+
if (data.hasOwnProperty('built')) {
|
|
75
|
+
obj['built'] = _ApiClient["default"].convertToType(data['built'], 'String');
|
|
76
76
|
}
|
|
77
|
-
if (data.hasOwnProperty(
|
|
78
|
-
obj[
|
|
77
|
+
if (data.hasOwnProperty('product')) {
|
|
78
|
+
obj['product'] = _ApiClient["default"].convertToType(data['product'], 'String');
|
|
79
79
|
}
|
|
80
|
-
if (data.hasOwnProperty(
|
|
81
|
-
obj[
|
|
80
|
+
if (data.hasOwnProperty('description')) {
|
|
81
|
+
obj['description'] = _ApiClient["default"].convertToType(data['description'], 'String');
|
|
82
82
|
}
|
|
83
|
-
if (data.hasOwnProperty(
|
|
84
|
-
obj[
|
|
83
|
+
if (data.hasOwnProperty('tags')) {
|
|
84
|
+
obj['tags'] = _ApiClient["default"].convertToType(data['tags'], 'String');
|
|
85
85
|
}
|
|
86
|
-
if (data.hasOwnProperty(
|
|
87
|
-
obj[
|
|
86
|
+
if (data.hasOwnProperty('type')) {
|
|
87
|
+
obj['type'] = _ApiClient["default"].convertToType(data['type'], 'String');
|
|
88
88
|
}
|
|
89
|
-
if (data.hasOwnProperty(
|
|
90
|
-
obj[
|
|
89
|
+
if (data.hasOwnProperty('created')) {
|
|
90
|
+
obj['created'] = _ApiClient["default"].convertToType(data['created'], 'String');
|
|
91
91
|
}
|
|
92
|
-
if (data.hasOwnProperty(
|
|
93
|
-
obj[
|
|
92
|
+
if (data.hasOwnProperty('target')) {
|
|
93
|
+
obj['target'] = _ApiClient["default"].convertToType(data['target'], 'String');
|
|
94
94
|
}
|
|
95
|
-
if (data.hasOwnProperty(
|
|
96
|
-
obj[
|
|
95
|
+
if (data.hasOwnProperty('published')) {
|
|
96
|
+
obj['published'] = _ApiClient["default"].convertToType(data['published'], 'Boolean');
|
|
97
97
|
}
|
|
98
98
|
} else if (data === null) {
|
|
99
99
|
return null;
|
|
@@ -110,48 +110,48 @@ var FirmwareInfo = /*#__PURE__*/function () {
|
|
|
110
110
|
key: "validateJSON",
|
|
111
111
|
value: function validateJSON(data) {
|
|
112
112
|
// ensure the json data is a string
|
|
113
|
-
if (data[
|
|
114
|
-
throw new Error("Expected the field `filename` to be a primitive type in the JSON string but got " + data[
|
|
113
|
+
if (data['filename'] && !(typeof data['filename'] === 'string' || data['filename'] instanceof String)) {
|
|
114
|
+
throw new Error("Expected the field `filename` to be a primitive type in the JSON string but got " + data['filename']);
|
|
115
115
|
}
|
|
116
116
|
// ensure the json data is a string
|
|
117
|
-
if (data[
|
|
118
|
-
throw new Error("Expected the field `version` to be a primitive type in the JSON string but got " + data[
|
|
117
|
+
if (data['version'] && !(typeof data['version'] === 'string' || data['version'] instanceof String)) {
|
|
118
|
+
throw new Error("Expected the field `version` to be a primitive type in the JSON string but got " + data['version']);
|
|
119
119
|
}
|
|
120
120
|
// ensure the json data is a string
|
|
121
|
-
if (data[
|
|
122
|
-
throw new Error("Expected the field `MD5` to be a primitive type in the JSON string but got " + data[
|
|
121
|
+
if (data['MD5'] && !(typeof data['MD5'] === 'string' || data['MD5'] instanceof String)) {
|
|
122
|
+
throw new Error("Expected the field `MD5` to be a primitive type in the JSON string but got " + data['MD5']);
|
|
123
123
|
}
|
|
124
124
|
// ensure the json data is a string
|
|
125
|
-
if (data[
|
|
126
|
-
throw new Error("Expected the field `organization` to be a primitive type in the JSON string but got " + data[
|
|
125
|
+
if (data['organization'] && !(typeof data['organization'] === 'string' || data['organization'] instanceof String)) {
|
|
126
|
+
throw new Error("Expected the field `organization` to be a primitive type in the JSON string but got " + data['organization']);
|
|
127
127
|
}
|
|
128
128
|
// ensure the json data is a string
|
|
129
|
-
if (data[
|
|
130
|
-
throw new Error("Expected the field `built` to be a primitive type in the JSON string but got " + data[
|
|
129
|
+
if (data['built'] && !(typeof data['built'] === 'string' || data['built'] instanceof String)) {
|
|
130
|
+
throw new Error("Expected the field `built` to be a primitive type in the JSON string but got " + data['built']);
|
|
131
131
|
}
|
|
132
132
|
// ensure the json data is a string
|
|
133
|
-
if (data[
|
|
134
|
-
throw new Error("Expected the field `product` to be a primitive type in the JSON string but got " + data[
|
|
133
|
+
if (data['product'] && !(typeof data['product'] === 'string' || data['product'] instanceof String)) {
|
|
134
|
+
throw new Error("Expected the field `product` to be a primitive type in the JSON string but got " + data['product']);
|
|
135
135
|
}
|
|
136
136
|
// ensure the json data is a string
|
|
137
|
-
if (data[
|
|
138
|
-
throw new Error("Expected the field `description` to be a primitive type in the JSON string but got " + data[
|
|
137
|
+
if (data['description'] && !(typeof data['description'] === 'string' || data['description'] instanceof String)) {
|
|
138
|
+
throw new Error("Expected the field `description` to be a primitive type in the JSON string but got " + data['description']);
|
|
139
139
|
}
|
|
140
140
|
// ensure the json data is a string
|
|
141
|
-
if (data[
|
|
142
|
-
throw new Error("Expected the field `tags` to be a primitive type in the JSON string but got " + data[
|
|
141
|
+
if (data['tags'] && !(typeof data['tags'] === 'string' || data['tags'] instanceof String)) {
|
|
142
|
+
throw new Error("Expected the field `tags` to be a primitive type in the JSON string but got " + data['tags']);
|
|
143
143
|
}
|
|
144
144
|
// ensure the json data is a string
|
|
145
|
-
if (data[
|
|
146
|
-
throw new Error("Expected the field `type` to be a primitive type in the JSON string but got " + data[
|
|
145
|
+
if (data['type'] && !(typeof data['type'] === 'string' || data['type'] instanceof String)) {
|
|
146
|
+
throw new Error("Expected the field `type` to be a primitive type in the JSON string but got " + data['type']);
|
|
147
147
|
}
|
|
148
148
|
// ensure the json data is a string
|
|
149
|
-
if (data[
|
|
150
|
-
throw new Error("Expected the field `created` to be a primitive type in the JSON string but got " + data[
|
|
149
|
+
if (data['created'] && !(typeof data['created'] === 'string' || data['created'] instanceof String)) {
|
|
150
|
+
throw new Error("Expected the field `created` to be a primitive type in the JSON string but got " + data['created']);
|
|
151
151
|
}
|
|
152
152
|
// ensure the json data is a string
|
|
153
|
-
if (data[
|
|
154
|
-
throw new Error("Expected the field `target` to be a primitive type in the JSON string but got " + data[
|
|
153
|
+
if (data['target'] && !(typeof data['target'] === 'string' || data['target'] instanceof String)) {
|
|
154
|
+
throw new Error("Expected the field `target` to be a primitive type in the JSON string but got " + data['target']);
|
|
155
155
|
}
|
|
156
156
|
return true;
|
|
157
157
|
}
|
|
@@ -161,71 +161,71 @@ var FirmwareInfo = /*#__PURE__*/function () {
|
|
|
161
161
|
* The name of the firmware file.
|
|
162
162
|
* @member {String} filename
|
|
163
163
|
*/
|
|
164
|
-
FirmwareInfo.prototype[
|
|
164
|
+
FirmwareInfo.prototype['filename'] = undefined;
|
|
165
165
|
|
|
166
166
|
/**
|
|
167
167
|
* The version of the firmware.
|
|
168
168
|
* @member {String} version
|
|
169
169
|
*/
|
|
170
|
-
FirmwareInfo.prototype[
|
|
170
|
+
FirmwareInfo.prototype['version'] = undefined;
|
|
171
171
|
|
|
172
172
|
/**
|
|
173
173
|
* The MD5 hash of the firmware file.
|
|
174
174
|
* @member {String} MD5
|
|
175
175
|
*/
|
|
176
|
-
FirmwareInfo.prototype[
|
|
176
|
+
FirmwareInfo.prototype['MD5'] = undefined;
|
|
177
177
|
|
|
178
178
|
/**
|
|
179
179
|
* The organization that owns the firmware.
|
|
180
180
|
* @member {String} organization
|
|
181
181
|
*/
|
|
182
|
-
FirmwareInfo.prototype[
|
|
182
|
+
FirmwareInfo.prototype['organization'] = undefined;
|
|
183
183
|
|
|
184
184
|
/**
|
|
185
185
|
* The date the firmware was built.
|
|
186
186
|
* @member {String} built
|
|
187
187
|
*/
|
|
188
|
-
FirmwareInfo.prototype[
|
|
188
|
+
FirmwareInfo.prototype['built'] = undefined;
|
|
189
189
|
|
|
190
190
|
/**
|
|
191
191
|
* The product that the firmware is for.
|
|
192
192
|
* @member {String} product
|
|
193
193
|
*/
|
|
194
|
-
FirmwareInfo.prototype[
|
|
194
|
+
FirmwareInfo.prototype['product'] = undefined;
|
|
195
195
|
|
|
196
196
|
/**
|
|
197
197
|
* A description of the firmware.
|
|
198
198
|
* @member {String} description
|
|
199
199
|
*/
|
|
200
|
-
FirmwareInfo.prototype[
|
|
200
|
+
FirmwareInfo.prototype['description'] = undefined;
|
|
201
201
|
|
|
202
202
|
/**
|
|
203
203
|
* A list of tags associated with the firmware.
|
|
204
204
|
* @member {String} tags
|
|
205
205
|
*/
|
|
206
|
-
FirmwareInfo.prototype[
|
|
206
|
+
FirmwareInfo.prototype['tags'] = undefined;
|
|
207
207
|
|
|
208
208
|
/**
|
|
209
209
|
* The type of firmware.
|
|
210
210
|
* @member {String} type
|
|
211
211
|
*/
|
|
212
|
-
FirmwareInfo.prototype[
|
|
212
|
+
FirmwareInfo.prototype['type'] = undefined;
|
|
213
213
|
|
|
214
214
|
/**
|
|
215
215
|
* The date the firmware was created.
|
|
216
216
|
* @member {String} created
|
|
217
217
|
*/
|
|
218
|
-
FirmwareInfo.prototype[
|
|
218
|
+
FirmwareInfo.prototype['created'] = undefined;
|
|
219
219
|
|
|
220
220
|
/**
|
|
221
221
|
* The target device for the firmware.
|
|
222
222
|
* @member {String} target
|
|
223
223
|
*/
|
|
224
|
-
FirmwareInfo.prototype[
|
|
224
|
+
FirmwareInfo.prototype['target'] = undefined;
|
|
225
225
|
|
|
226
226
|
/**
|
|
227
227
|
* True if the firmware is published.
|
|
228
228
|
* @member {Boolean} published
|
|
229
229
|
*/
|
|
230
|
-
FirmwareInfo.prototype[
|
|
230
|
+
FirmwareInfo.prototype['published'] = undefined;
|
|
231
231
|
var _default = exports["default"] = FirmwareInfo;
|
package/dist/model/Fleet.js
CHANGED
|
@@ -16,9 +16,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
16
16
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
17
17
|
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); } /**
|
|
18
18
|
* Notehub API
|
|
19
|
-
* The OpenAPI definition for the Notehub.io API.
|
|
19
|
+
* The OpenAPI definition for the Notehub.io API.
|
|
20
20
|
*
|
|
21
|
-
* The version of the OpenAPI document: 1.
|
|
21
|
+
* The version of the OpenAPI document: 1.2.0
|
|
22
22
|
* Contact: engineering@blues.io
|
|
23
23
|
*
|
|
24
24
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -29,15 +29,15 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
29
29
|
/**
|
|
30
30
|
* The Fleet model module.
|
|
31
31
|
* @module model/Fleet
|
|
32
|
-
* @version 1.0.
|
|
32
|
+
* @version 1.0.24-beta.2
|
|
33
33
|
*/
|
|
34
34
|
var Fleet = /*#__PURE__*/function () {
|
|
35
35
|
/**
|
|
36
36
|
* Constructs a new <code>Fleet</code>.
|
|
37
37
|
* @alias module:model/Fleet
|
|
38
|
-
* @param uid {String}
|
|
39
|
-
* @param label {String}
|
|
40
|
-
* @param created {Date}
|
|
38
|
+
* @param uid {String}
|
|
39
|
+
* @param label {String}
|
|
40
|
+
* @param created {Date}
|
|
41
41
|
*/
|
|
42
42
|
function Fleet(uid, label, created) {
|
|
43
43
|
_classCallCheck(this, Fleet);
|
|
@@ -52,9 +52,9 @@ var Fleet = /*#__PURE__*/function () {
|
|
|
52
52
|
return _createClass(Fleet, null, [{
|
|
53
53
|
key: "initialize",
|
|
54
54
|
value: function initialize(obj, uid, label, created) {
|
|
55
|
-
obj[
|
|
56
|
-
obj[
|
|
57
|
-
obj[
|
|
55
|
+
obj['uid'] = uid;
|
|
56
|
+
obj['label'] = label;
|
|
57
|
+
obj['created'] = created;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
/**
|
|
@@ -69,14 +69,14 @@ var Fleet = /*#__PURE__*/function () {
|
|
|
69
69
|
value: function constructFromObject(data, obj) {
|
|
70
70
|
if (data) {
|
|
71
71
|
obj = obj || new Fleet();
|
|
72
|
-
if (data.hasOwnProperty(
|
|
73
|
-
obj[
|
|
72
|
+
if (data.hasOwnProperty('uid')) {
|
|
73
|
+
obj['uid'] = _ApiClient["default"].convertToType(data['uid'], 'String');
|
|
74
74
|
}
|
|
75
|
-
if (data.hasOwnProperty(
|
|
76
|
-
obj[
|
|
75
|
+
if (data.hasOwnProperty('label')) {
|
|
76
|
+
obj['label'] = _ApiClient["default"].convertToType(data['label'], 'String');
|
|
77
77
|
}
|
|
78
|
-
if (data.hasOwnProperty(
|
|
79
|
-
obj[
|
|
78
|
+
if (data.hasOwnProperty('created')) {
|
|
79
|
+
obj['created'] = _ApiClient["default"].convertToType(data['created'], 'Date');
|
|
80
80
|
}
|
|
81
81
|
} else if (data === null) {
|
|
82
82
|
return null;
|
|
@@ -108,12 +108,12 @@ var Fleet = /*#__PURE__*/function () {
|
|
|
108
108
|
} finally {
|
|
109
109
|
_iterator.f();
|
|
110
110
|
}
|
|
111
|
-
if (data[
|
|
112
|
-
throw new Error("Expected the field `uid` to be a primitive type in the JSON string but got " + data[
|
|
111
|
+
if (data['uid'] && !(typeof data['uid'] === 'string' || data['uid'] instanceof String)) {
|
|
112
|
+
throw new Error("Expected the field `uid` to be a primitive type in the JSON string but got " + data['uid']);
|
|
113
113
|
}
|
|
114
114
|
// ensure the json data is a string
|
|
115
|
-
if (data[
|
|
116
|
-
throw new Error("Expected the field `label` to be a primitive type in the JSON string but got " + data[
|
|
115
|
+
if (data['label'] && !(typeof data['label'] === 'string' || data['label'] instanceof String)) {
|
|
116
|
+
throw new Error("Expected the field `label` to be a primitive type in the JSON string but got " + data['label']);
|
|
117
117
|
}
|
|
118
118
|
return true;
|
|
119
119
|
}
|
|
@@ -124,15 +124,15 @@ Fleet.RequiredProperties = ["uid", "label", "created"];
|
|
|
124
124
|
/**
|
|
125
125
|
* @member {String} uid
|
|
126
126
|
*/
|
|
127
|
-
Fleet.prototype[
|
|
127
|
+
Fleet.prototype['uid'] = undefined;
|
|
128
128
|
|
|
129
129
|
/**
|
|
130
130
|
* @member {String} label
|
|
131
131
|
*/
|
|
132
|
-
Fleet.prototype[
|
|
132
|
+
Fleet.prototype['label'] = undefined;
|
|
133
133
|
|
|
134
134
|
/**
|
|
135
135
|
* @member {Date} created
|
|
136
136
|
*/
|
|
137
|
-
Fleet.prototype[
|
|
137
|
+
Fleet.prototype['created'] = undefined;
|
|
138
138
|
var _default = exports["default"] = Fleet;
|
|
@@ -17,9 +17,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
17
17
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
18
18
|
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); } /**
|
|
19
19
|
* Notehub API
|
|
20
|
-
* The OpenAPI definition for the Notehub.io API.
|
|
20
|
+
* The OpenAPI definition for the Notehub.io API.
|
|
21
21
|
*
|
|
22
|
-
* The version of the OpenAPI document: 1.
|
|
22
|
+
* The version of the OpenAPI document: 1.2.0
|
|
23
23
|
* Contact: engineering@blues.io
|
|
24
24
|
*
|
|
25
25
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -30,7 +30,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
30
30
|
/**
|
|
31
31
|
* The GetAlerts200Response model module.
|
|
32
32
|
* @module model/GetAlerts200Response
|
|
33
|
-
* @version 1.0.
|
|
33
|
+
* @version 1.0.24-beta.2
|
|
34
34
|
*/
|
|
35
35
|
var GetAlerts200Response = /*#__PURE__*/function () {
|
|
36
36
|
/**
|
|
@@ -52,8 +52,8 @@ var GetAlerts200Response = /*#__PURE__*/function () {
|
|
|
52
52
|
return _createClass(GetAlerts200Response, null, [{
|
|
53
53
|
key: "initialize",
|
|
54
54
|
value: function initialize(obj, alerts, hasMore) {
|
|
55
|
-
obj[
|
|
56
|
-
obj[
|
|
55
|
+
obj['alerts'] = alerts;
|
|
56
|
+
obj['has_more'] = hasMore;
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
/**
|
|
@@ -68,11 +68,11 @@ var GetAlerts200Response = /*#__PURE__*/function () {
|
|
|
68
68
|
value: function constructFromObject(data, obj) {
|
|
69
69
|
if (data) {
|
|
70
70
|
obj = obj || new GetAlerts200Response();
|
|
71
|
-
if (data.hasOwnProperty(
|
|
72
|
-
obj[
|
|
71
|
+
if (data.hasOwnProperty('alerts')) {
|
|
72
|
+
obj['alerts'] = _ApiClient["default"].convertToType(data['alerts'], [_Alert["default"]]);
|
|
73
73
|
}
|
|
74
|
-
if (data.hasOwnProperty(
|
|
75
|
-
obj[
|
|
74
|
+
if (data.hasOwnProperty('has_more')) {
|
|
75
|
+
obj['has_more'] = _ApiClient["default"].convertToType(data['has_more'], 'Boolean');
|
|
76
76
|
}
|
|
77
77
|
} else if (data === null) {
|
|
78
78
|
return null;
|
|
@@ -103,14 +103,14 @@ var GetAlerts200Response = /*#__PURE__*/function () {
|
|
|
103
103
|
} finally {
|
|
104
104
|
_iterator.f();
|
|
105
105
|
}
|
|
106
|
-
if (data[
|
|
106
|
+
if (data['alerts']) {
|
|
107
107
|
// data not null
|
|
108
108
|
// ensure the json data is an array
|
|
109
|
-
if (!Array.isArray(data[
|
|
110
|
-
throw new Error("Expected the field `alerts` to be an array in the JSON data but got " + data[
|
|
109
|
+
if (!Array.isArray(data['alerts'])) {
|
|
110
|
+
throw new Error("Expected the field `alerts` to be an array in the JSON data but got " + data['alerts']);
|
|
111
111
|
}
|
|
112
112
|
// validate the optional field `alerts` (array)
|
|
113
|
-
var _iterator2 = _createForOfIteratorHelper(data[
|
|
113
|
+
var _iterator2 = _createForOfIteratorHelper(data['alerts']),
|
|
114
114
|
_step2;
|
|
115
115
|
try {
|
|
116
116
|
for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
|
|
@@ -122,6 +122,7 @@ var GetAlerts200Response = /*#__PURE__*/function () {
|
|
|
122
122
|
} finally {
|
|
123
123
|
_iterator2.f();
|
|
124
124
|
}
|
|
125
|
+
;
|
|
125
126
|
}
|
|
126
127
|
return true;
|
|
127
128
|
}
|
|
@@ -133,11 +134,11 @@ GetAlerts200Response.RequiredProperties = ["alerts", "has_more"];
|
|
|
133
134
|
* The list of alerts
|
|
134
135
|
* @member {Array.<module:model/Alert>} alerts
|
|
135
136
|
*/
|
|
136
|
-
GetAlerts200Response.prototype[
|
|
137
|
+
GetAlerts200Response.prototype['alerts'] = undefined;
|
|
137
138
|
|
|
138
139
|
/**
|
|
139
140
|
* True if there are more alerts
|
|
140
141
|
* @member {Boolean} has_more
|
|
141
142
|
*/
|
|
142
|
-
GetAlerts200Response.prototype[
|
|
143
|
+
GetAlerts200Response.prototype['has_more'] = undefined;
|
|
143
144
|
var _default = exports["default"] = GetAlerts200Response;
|