@blues-inc/notehub-js 2.3.0-beta.8 → 2.3.0-beta.9

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 (144) hide show
  1. package/README.md +47 -46
  2. package/dist/ApiClient.js +2 -2
  3. package/dist/api/AlertApi.js +1 -1
  4. package/dist/api/AuthorizationApi.js +1 -1
  5. package/dist/api/BillingAccountApi.js +1 -1
  6. package/dist/api/DeviceApi.js +786 -739
  7. package/dist/api/EventApi.js +83 -83
  8. package/dist/api/ExternalDevicesApi.js +1 -1
  9. package/dist/api/MonitorApi.js +1 -1
  10. package/dist/api/ProjectApi.js +282 -282
  11. package/dist/api/RouteApi.js +1 -1
  12. package/dist/api/UsageApi.js +1 -10
  13. package/dist/api/WebhookApi.js +1 -1
  14. package/dist/index.js +84 -84
  15. package/dist/model/{PutDeviceFleetsRequest.js → AddDeviceToFleetsRequest.js} +20 -20
  16. package/dist/model/Alert.js +1 -1
  17. package/dist/model/AlertDataInner.js +1 -1
  18. package/dist/model/AlertNotificationsInner.js +1 -1
  19. package/dist/model/AwsRoute.js +1 -1
  20. package/dist/model/AzureRoute.js +1 -1
  21. package/dist/model/BillingAccount.js +1 -1
  22. package/dist/model/BlynkRoute.js +1 -1
  23. package/dist/model/Body.js +1 -1
  24. package/dist/model/CellularPlan.js +1 -1
  25. package/dist/model/CloneProjectRequest.js +1 -1
  26. package/dist/model/Contact.js +1 -1
  27. package/dist/model/CreateFleetRequest.js +1 -1
  28. package/dist/model/CreateMonitor.js +1 -1
  29. package/dist/model/CreateProductRequest.js +1 -1
  30. package/dist/model/CreateProjectRequest.js +1 -1
  31. package/dist/model/CreateUpdateRepository.js +1 -1
  32. package/dist/model/CurrentFirmware.js +1 -1
  33. package/dist/model/DFUEnv.js +1 -1
  34. package/dist/model/DFUState.js +1 -1
  35. package/dist/model/DataField.js +1 -1
  36. package/dist/model/DataSetField.js +1 -1
  37. package/dist/model/DataUsage.js +1 -1
  38. package/dist/model/DatacakeRoute.js +1 -1
  39. package/dist/model/{DeleteDeviceFleetsRequest.js → DeleteDeviceFromFleetsRequest.js} +20 -20
  40. package/dist/model/{HandleNotefileDeleteRequest.js → DeleteNotefilesRequest.js} +19 -19
  41. package/dist/model/Device.js +1 -1
  42. package/dist/model/DeviceDfuHistory.js +1 -1
  43. package/dist/model/DeviceDfuHistoryCurrent.js +1 -1
  44. package/dist/model/DeviceDfuHistoryPage.js +1 -1
  45. package/dist/model/DeviceDfuStateMachine.js +1 -1
  46. package/dist/model/DeviceDfuStateMachineNode.js +1 -1
  47. package/dist/model/DeviceDfuStatus.js +1 -1
  48. package/dist/model/DeviceDfuStatusPage.js +1 -1
  49. package/dist/model/DeviceSession.js +1 -1
  50. package/dist/model/DeviceTowerInfo.js +1 -1
  51. package/dist/model/DeviceUsage.js +1 -1
  52. package/dist/model/DfuActionRequest.js +1 -1
  53. package/dist/model/EmailNotification.js +1 -1
  54. package/dist/model/EnvTreeJsonNode.js +1 -1
  55. package/dist/model/EnvVar.js +1 -1
  56. package/dist/model/EnvironmentVariables.js +1 -1
  57. package/dist/model/Error.js +1 -1
  58. package/dist/model/Event.js +1 -1
  59. package/dist/model/Filter.js +1 -1
  60. package/dist/model/Firmware.js +1 -1
  61. package/dist/model/FirmwareInfo.js +1 -1
  62. package/dist/model/Fleet.js +1 -1
  63. package/dist/model/FleetConnectivityAssurance.js +1 -1
  64. package/dist/model/GetAlerts200Response.js +1 -1
  65. package/dist/model/GetBillingAccounts200Response.js +1 -1
  66. package/dist/model/GetDataUsage200Response.js +1 -1
  67. package/dist/model/GetDataUsage200ResponseDataInner.js +1 -1
  68. package/dist/model/{HandleNoteGet200Response.js → GetDbNote200Response.js} +20 -20
  69. package/dist/model/GetDeviceEnvironmentVariablesByPin200Response.js +1 -1
  70. package/dist/model/GetDeviceFleets200Response.js +1 -1
  71. package/dist/model/GetDeviceHealthLog200Response.js +1 -1
  72. package/dist/model/GetDeviceHealthLog200ResponseHealthLogInner.js +1 -1
  73. package/dist/model/{GetDeviceLatest200Response.js → GetDeviceLatestEvents200Response.js} +18 -18
  74. package/dist/model/GetDevicePlans200Response.js +1 -1
  75. package/dist/model/GetDevicePublicKey200Response.js +1 -1
  76. package/dist/model/{GetProjectDevicePublicKeys200Response.js → GetDevicePublicKeys200Response.js} +26 -26
  77. package/dist/model/{GetProjectDevicePublicKeys200ResponseDevicePublicKeysInner.js → GetDevicePublicKeys200ResponseDevicePublicKeysInner.js} +19 -19
  78. package/dist/model/GetDeviceSessions200Response.js +1 -1
  79. package/dist/model/{GetProjectDevices200Response.js → GetDevices200Response.js} +21 -21
  80. package/dist/model/{GetProjectEvents200Response.js → GetEvents200Response.js} +22 -22
  81. package/dist/model/{GetProjectEventsByCursor200Response.js → GetEventsByCursor200Response.js} +22 -22
  82. package/dist/model/{HandleNoteChanges200Response.js → GetNotefile200Response.js} +20 -20
  83. package/dist/model/GetProducts200Response.js +1 -1
  84. package/dist/model/GetProjectMembers200Response.js +1 -1
  85. package/dist/model/GetProjects200Response.js +1 -1
  86. package/dist/model/GetSessionsUsage200Response.js +1 -1
  87. package/dist/model/GetWebhooks200Response.js +1 -1
  88. package/dist/model/GoogleRoute.js +1 -1
  89. package/dist/model/HttpRoute.js +1 -1
  90. package/dist/model/{HandleNotefileChangesPending200Response.js → ListPendingNotefiles200Response.js} +21 -21
  91. package/dist/model/Location.js +1 -1
  92. package/dist/model/Login200Response.js +1 -1
  93. package/dist/model/LoginRequest.js +1 -1
  94. package/dist/model/Monitor.js +1 -1
  95. package/dist/model/MonitorAlertRoutesInner.js +1 -1
  96. package/dist/model/MqttRoute.js +1 -1
  97. package/dist/model/Note.js +90 -10
  98. package/dist/model/Notefile.js +147 -0
  99. package/dist/model/NotefileSchema.js +1 -1
  100. package/dist/model/NotefileTemplate.js +128 -0
  101. package/dist/model/NotehubRoute.js +1 -15
  102. package/dist/model/NotehubRouteSummary.js +1 -1
  103. package/dist/model/OAuth2Error.js +1 -1
  104. package/dist/model/OAuth2TokenResponse.js +1 -1
  105. package/dist/model/PersonalAccessToken.js +1 -1
  106. package/dist/model/PersonalAccessTokenCreatedBy.js +1 -1
  107. package/dist/model/PersonalAccessTokenInfo.js +1 -1
  108. package/dist/model/PersonalAccessTokenSecret.js +1 -1
  109. package/dist/model/Product.js +1 -1
  110. package/dist/model/Project.js +1 -1
  111. package/dist/model/ProjectMember.js +1 -1
  112. package/dist/model/{PostProvisionProjectDeviceRequest.js → ProvisionDeviceRequest.js} +22 -22
  113. package/dist/model/ProxyRoute.js +1 -1
  114. package/dist/model/QubitroRoute.js +1 -1
  115. package/dist/model/RadRoute.js +1 -1
  116. package/dist/model/Repository.js +1 -1
  117. package/dist/model/RouteLog.js +1 -1
  118. package/dist/model/RouteTransformSettings.js +1 -1
  119. package/dist/model/S3ArchiveRoute.js +1 -1
  120. package/dist/model/SatellitePlan.js +1 -1
  121. package/dist/model/SchemaProperty.js +1 -1
  122. package/dist/model/{HandleNoteSignal200Response.js → SignalDevice200Response.js} +18 -18
  123. package/dist/model/SimUsage.js +1 -1
  124. package/dist/model/SlackBearerNotification.js +1 -1
  125. package/dist/model/SlackRoute.js +1 -1
  126. package/dist/model/SlackWebHookNotification.js +1 -1
  127. package/dist/model/SnowflakeRoute.js +1 -1
  128. package/dist/model/ThingworxRoute.js +1 -1
  129. package/dist/model/TowerLocation.js +1 -1
  130. package/dist/model/TwilioRoute.js +1 -1
  131. package/dist/model/UpdateFleetRequest.js +1 -1
  132. package/dist/model/UploadMetadata.js +1 -1
  133. package/dist/model/UsageData.js +1 -1
  134. package/dist/model/UsageEventsData.js +1 -1
  135. package/dist/model/UsageEventsResponse.js +1 -1
  136. package/dist/model/UsageRouteLogsData.js +1 -1
  137. package/dist/model/UsageSessionsData.js +1 -1
  138. package/dist/model/UserDfuStateMachine.js +1 -1
  139. package/dist/model/UserDfuStateMachineStatus.js +1 -1
  140. package/dist/model/UserFirmwareInfo.js +1 -1
  141. package/dist/model/WebhookSettings.js +1 -1
  142. package/package.json +1 -1
  143. package/dist/model/HandleNotefileChanges200Response.js +0 -106
  144. package/dist/model/SnowpipeStreamingRoute.js +0 -223
@@ -6,26 +6,27 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports["default"] = void 0;
7
7
  var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
8
  var _Body = _interopRequireDefault(require("../model/Body"));
9
+ var _DeleteNotefilesRequest = _interopRequireDefault(require("../model/DeleteNotefilesRequest"));
9
10
  var _Device = _interopRequireDefault(require("../model/Device"));
10
11
  var _EnvTreeJsonNode = _interopRequireDefault(require("../model/EnvTreeJsonNode"));
11
12
  var _EnvironmentVariables = _interopRequireDefault(require("../model/EnvironmentVariables"));
12
13
  var _Error = _interopRequireDefault(require("../model/Error"));
14
+ var _GetDbNote200Response = _interopRequireDefault(require("../model/GetDbNote200Response"));
13
15
  var _GetDeviceEnvironmentVariablesByPin200Response = _interopRequireDefault(require("../model/GetDeviceEnvironmentVariablesByPin200Response"));
14
16
  var _GetDeviceHealthLog200Response = _interopRequireDefault(require("../model/GetDeviceHealthLog200Response"));
15
- var _GetDeviceLatest200Response = _interopRequireDefault(require("../model/GetDeviceLatest200Response"));
17
+ var _GetDeviceLatestEvents200Response = _interopRequireDefault(require("../model/GetDeviceLatestEvents200Response"));
16
18
  var _GetDevicePlans200Response = _interopRequireDefault(require("../model/GetDevicePlans200Response"));
17
19
  var _GetDevicePublicKey200Response = _interopRequireDefault(require("../model/GetDevicePublicKey200Response"));
20
+ var _GetDevicePublicKeys200Response = _interopRequireDefault(require("../model/GetDevicePublicKeys200Response"));
18
21
  var _GetDeviceSessions200Response = _interopRequireDefault(require("../model/GetDeviceSessions200Response"));
19
- var _GetProjectDevicePublicKeys200Response = _interopRequireDefault(require("../model/GetProjectDevicePublicKeys200Response"));
20
- var _GetProjectDevices200Response = _interopRequireDefault(require("../model/GetProjectDevices200Response"));
21
- var _HandleNoteChanges200Response = _interopRequireDefault(require("../model/HandleNoteChanges200Response"));
22
- var _HandleNoteGet200Response = _interopRequireDefault(require("../model/HandleNoteGet200Response"));
23
- var _HandleNoteSignal200Response = _interopRequireDefault(require("../model/HandleNoteSignal200Response"));
24
- var _HandleNotefileChanges200Response = _interopRequireDefault(require("../model/HandleNotefileChanges200Response"));
25
- var _HandleNotefileChangesPending200Response = _interopRequireDefault(require("../model/HandleNotefileChangesPending200Response"));
26
- var _HandleNotefileDeleteRequest = _interopRequireDefault(require("../model/HandleNotefileDeleteRequest"));
22
+ var _GetDevices200Response = _interopRequireDefault(require("../model/GetDevices200Response"));
23
+ var _GetNotefile200Response = _interopRequireDefault(require("../model/GetNotefile200Response"));
24
+ var _ListPendingNotefiles200Response = _interopRequireDefault(require("../model/ListPendingNotefiles200Response"));
27
25
  var _Note = _interopRequireDefault(require("../model/Note"));
28
- var _PostProvisionProjectDeviceRequest = _interopRequireDefault(require("../model/PostProvisionProjectDeviceRequest"));
26
+ var _Notefile = _interopRequireDefault(require("../model/Notefile"));
27
+ var _NotefileTemplate = _interopRequireDefault(require("../model/NotefileTemplate"));
28
+ var _ProvisionDeviceRequest = _interopRequireDefault(require("../model/ProvisionDeviceRequest"));
29
+ var _SignalDevice200Response = _interopRequireDefault(require("../model/SignalDevice200Response"));
29
30
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
30
31
  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); }
31
32
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
@@ -47,7 +48,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
47
48
  /**
48
49
  * Device service.
49
50
  * @module api/DeviceApi
50
- * @version 2.3.0-beta.8
51
+ * @version 2.3.0-beta.9
51
52
  */
52
53
  var DeviceApi = exports["default"] = /*#__PURE__*/function () {
53
54
  /**
@@ -63,225 +64,267 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
63
64
  }
64
65
 
65
66
  /**
66
- * Delete environment variable of a device
67
+ * Add a Note to a .db notefile. if noteID is '-' then payload is ignored and empty notefile is created
67
68
  * @param {String} projectOrProductUID
68
69
  * @param {String} deviceUID
69
- * @param {String} key The environment variable key to delete.
70
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
70
+ * @param {String} notefileID
71
+ * @param {String} noteID
72
+ * @param {module:model/Note} note Body or payload of note to be added to the device
73
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
71
74
  */
72
75
  return _createClass(DeviceApi, [{
73
- key: "deleteDeviceEnvironmentVariableWithHttpInfo",
74
- value: function deleteDeviceEnvironmentVariableWithHttpInfo(projectOrProductUID, deviceUID, key) {
75
- var postBody = null;
76
+ key: "addDbNoteWithHttpInfo",
77
+ value: function addDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note) {
78
+ var postBody = note;
76
79
  // verify the required parameter 'projectOrProductUID' is set
77
80
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
78
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling deleteDeviceEnvironmentVariable");
81
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling addDbNote");
79
82
  }
80
83
  // verify the required parameter 'deviceUID' is set
81
84
  if (deviceUID === undefined || deviceUID === null) {
82
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling deleteDeviceEnvironmentVariable");
85
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling addDbNote");
83
86
  }
84
- // verify the required parameter 'key' is set
85
- if (key === undefined || key === null) {
86
- throw new _Error["default"]("Missing the required parameter 'key' when calling deleteDeviceEnvironmentVariable");
87
+ // verify the required parameter 'notefileID' is set
88
+ if (notefileID === undefined || notefileID === null) {
89
+ throw new _Error["default"]("Missing the required parameter 'notefileID' when calling addDbNote");
90
+ }
91
+ // verify the required parameter 'noteID' is set
92
+ if (noteID === undefined || noteID === null) {
93
+ throw new _Error["default"]("Missing the required parameter 'noteID' when calling addDbNote");
94
+ }
95
+ // verify the required parameter 'note' is set
96
+ if (note === undefined || note === null) {
97
+ throw new _Error["default"]("Missing the required parameter 'note' when calling addDbNote");
87
98
  }
88
99
  var pathParams = {
89
100
  'projectOrProductUID': projectOrProductUID,
90
101
  'deviceUID': deviceUID,
91
- 'key': key
102
+ 'notefileID': notefileID,
103
+ 'noteID': noteID
92
104
  };
93
105
  var queryParams = {};
94
106
  var headerParams = {};
95
107
  var formParams = {};
96
108
  var authNames = ['personalAccessToken'];
97
- var contentTypes = [];
109
+ var contentTypes = ['application/json'];
98
110
  var accepts = ['application/json'];
99
- var returnType = _EnvironmentVariables["default"];
100
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_variables/{key}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
111
+ var returnType = null;
112
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
101
113
  }
102
114
 
103
115
  /**
104
- * Delete environment variable of a device
116
+ * Add a Note to a .db notefile. if noteID is '-' then payload is ignored and empty notefile is created
105
117
  * @param {String} projectOrProductUID
106
118
  * @param {String} deviceUID
107
- * @param {String} key The environment variable key to delete.
108
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
119
+ * @param {String} notefileID
120
+ * @param {String} noteID
121
+ * @param {module:model/Note} note Body or payload of note to be added to the device
122
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
109
123
  */
110
124
  }, {
111
- key: "deleteDeviceEnvironmentVariable",
112
- value: function deleteDeviceEnvironmentVariable(projectOrProductUID, deviceUID, key) {
113
- return this.deleteDeviceEnvironmentVariableWithHttpInfo(projectOrProductUID, deviceUID, key).then(function (response_and_data) {
125
+ key: "addDbNote",
126
+ value: function addDbNote(projectOrProductUID, deviceUID, notefileID, noteID, note) {
127
+ return this.addDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note).then(function (response_and_data) {
114
128
  return response_and_data.data;
115
129
  });
116
130
  }
117
131
 
118
132
  /**
119
- * Delete Device
133
+ * Add environment variables of a device
120
134
  * @param {String} projectOrProductUID
121
135
  * @param {String} deviceUID
122
- * @param {Boolean} purge
123
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
136
+ * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
137
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
124
138
  */
125
139
  }, {
126
- key: "deleteProjectDeviceWithHttpInfo",
127
- value: function deleteProjectDeviceWithHttpInfo(projectOrProductUID, deviceUID, purge) {
128
- var postBody = null;
140
+ key: "addDeviceEnvironmentVariablesWithHttpInfo",
141
+ value: function addDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID, environmentVariables) {
142
+ var postBody = environmentVariables;
129
143
  // verify the required parameter 'projectOrProductUID' is set
130
144
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
131
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling deleteProjectDevice");
145
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling addDeviceEnvironmentVariables");
132
146
  }
133
147
  // verify the required parameter 'deviceUID' is set
134
148
  if (deviceUID === undefined || deviceUID === null) {
135
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling deleteProjectDevice");
149
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling addDeviceEnvironmentVariables");
136
150
  }
137
- // verify the required parameter 'purge' is set
138
- if (purge === undefined || purge === null) {
139
- throw new _Error["default"]("Missing the required parameter 'purge' when calling deleteProjectDevice");
151
+ // verify the required parameter 'environmentVariables' is set
152
+ if (environmentVariables === undefined || environmentVariables === null) {
153
+ throw new _Error["default"]("Missing the required parameter 'environmentVariables' when calling addDeviceEnvironmentVariables");
140
154
  }
141
155
  var pathParams = {
142
156
  'projectOrProductUID': projectOrProductUID,
143
157
  'deviceUID': deviceUID
144
158
  };
145
- var queryParams = {
146
- 'purge': purge
147
- };
159
+ var queryParams = {};
148
160
  var headerParams = {};
149
161
  var formParams = {};
150
162
  var authNames = ['personalAccessToken'];
151
- var contentTypes = [];
163
+ var contentTypes = ['application/json'];
152
164
  var accepts = ['application/json'];
153
- var returnType = null;
154
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
165
+ var returnType = _EnvironmentVariables["default"];
166
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_variables', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
155
167
  }
156
168
 
157
169
  /**
158
- * Delete Device
170
+ * Add environment variables of a device
159
171
  * @param {String} projectOrProductUID
160
172
  * @param {String} deviceUID
161
- * @param {Boolean} purge
162
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
173
+ * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
174
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
163
175
  */
164
176
  }, {
165
- key: "deleteProjectDevice",
166
- value: function deleteProjectDevice(projectOrProductUID, deviceUID, purge) {
167
- return this.deleteProjectDeviceWithHttpInfo(projectOrProductUID, deviceUID, purge).then(function (response_and_data) {
177
+ key: "addDeviceEnvironmentVariables",
178
+ value: function addDeviceEnvironmentVariables(projectOrProductUID, deviceUID, environmentVariables) {
179
+ return this.addDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID, environmentVariables).then(function (response_and_data) {
168
180
  return response_and_data.data;
169
181
  });
170
182
  }
171
183
 
172
184
  /**
173
- * Disable Device
174
- * @param {String} projectOrProductUID
185
+ * Add environment variables of a device with device pin authorization
186
+ * @param {String} productUID
175
187
  * @param {String} deviceUID
176
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
188
+ * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
189
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
177
190
  */
178
191
  }, {
179
- key: "disableDeviceWithHttpInfo",
180
- value: function disableDeviceWithHttpInfo(projectOrProductUID, deviceUID) {
181
- var postBody = null;
182
- // verify the required parameter 'projectOrProductUID' is set
183
- if (projectOrProductUID === undefined || projectOrProductUID === null) {
184
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling disableDevice");
192
+ key: "addDeviceEnvironmentVariablesByPinWithHttpInfo",
193
+ value: function addDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID, environmentVariables) {
194
+ var postBody = environmentVariables;
195
+ // verify the required parameter 'productUID' is set
196
+ if (productUID === undefined || productUID === null) {
197
+ throw new _Error["default"]("Missing the required parameter 'productUID' when calling addDeviceEnvironmentVariablesByPin");
185
198
  }
186
199
  // verify the required parameter 'deviceUID' is set
187
200
  if (deviceUID === undefined || deviceUID === null) {
188
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling disableDevice");
201
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling addDeviceEnvironmentVariablesByPin");
202
+ }
203
+ // verify the required parameter 'environmentVariables' is set
204
+ if (environmentVariables === undefined || environmentVariables === null) {
205
+ throw new _Error["default"]("Missing the required parameter 'environmentVariables' when calling addDeviceEnvironmentVariablesByPin");
189
206
  }
190
207
  var pathParams = {
191
- 'projectOrProductUID': projectOrProductUID,
208
+ 'productUID': productUID,
192
209
  'deviceUID': deviceUID
193
210
  };
194
211
  var queryParams = {};
195
212
  var headerParams = {};
196
213
  var formParams = {};
197
- var authNames = ['personalAccessToken'];
198
- var contentTypes = [];
214
+ var authNames = ['pin'];
215
+ var contentTypes = ['application/json'];
199
216
  var accepts = ['application/json'];
200
- var returnType = null;
201
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/disable', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
217
+ var returnType = _EnvironmentVariables["default"];
218
+ return this.apiClient.callApi('/v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
202
219
  }
203
220
 
204
221
  /**
205
- * Disable Device
206
- * @param {String} projectOrProductUID
222
+ * Add environment variables of a device with device pin authorization
223
+ * @param {String} productUID
207
224
  * @param {String} deviceUID
208
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
225
+ * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
226
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
209
227
  */
210
228
  }, {
211
- key: "disableDevice",
212
- value: function disableDevice(projectOrProductUID, deviceUID) {
213
- return this.disableDeviceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
229
+ key: "addDeviceEnvironmentVariablesByPin",
230
+ value: function addDeviceEnvironmentVariablesByPin(productUID, deviceUID, environmentVariables) {
231
+ return this.addDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID, environmentVariables).then(function (response_and_data) {
214
232
  return response_and_data.data;
215
233
  });
216
234
  }
217
235
 
218
236
  /**
219
- * Disable Connectivity Assurance
237
+ * Adds a Note to a Notefile, creating the Notefile if it doesn't yet exist.
220
238
  * @param {String} projectOrProductUID
221
239
  * @param {String} deviceUID
240
+ * @param {String} notefileID
241
+ * @param {module:model/Note} note Body or payload of note to be added to the device
222
242
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
223
243
  */
224
244
  }, {
225
- key: "disableDeviceConnectivityAssuranceWithHttpInfo",
226
- value: function disableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID) {
227
- var postBody = null;
245
+ key: "addQiNoteWithHttpInfo",
246
+ value: function addQiNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, note) {
247
+ var postBody = note;
228
248
  // verify the required parameter 'projectOrProductUID' is set
229
249
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
230
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling disableDeviceConnectivityAssurance");
250
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling addQiNote");
231
251
  }
232
252
  // verify the required parameter 'deviceUID' is set
233
253
  if (deviceUID === undefined || deviceUID === null) {
234
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling disableDeviceConnectivityAssurance");
254
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling addQiNote");
255
+ }
256
+ // verify the required parameter 'notefileID' is set
257
+ if (notefileID === undefined || notefileID === null) {
258
+ throw new _Error["default"]("Missing the required parameter 'notefileID' when calling addQiNote");
259
+ }
260
+ // verify the required parameter 'note' is set
261
+ if (note === undefined || note === null) {
262
+ throw new _Error["default"]("Missing the required parameter 'note' when calling addQiNote");
235
263
  }
236
264
  var pathParams = {
237
265
  'projectOrProductUID': projectOrProductUID,
238
- 'deviceUID': deviceUID
266
+ 'deviceUID': deviceUID,
267
+ 'notefileID': notefileID
239
268
  };
240
269
  var queryParams = {};
241
270
  var headerParams = {};
242
271
  var formParams = {};
243
272
  var authNames = ['personalAccessToken'];
244
- var contentTypes = [];
273
+ var contentTypes = ['application/json'];
245
274
  var accepts = ['application/json'];
246
275
  var returnType = null;
247
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/disable-connectivity-assurance', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
276
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
248
277
  }
249
278
 
250
279
  /**
251
- * Disable Connectivity Assurance
280
+ * Adds a Note to a Notefile, creating the Notefile if it doesn't yet exist.
252
281
  * @param {String} projectOrProductUID
253
282
  * @param {String} deviceUID
283
+ * @param {String} notefileID
284
+ * @param {module:model/Note} note Body or payload of note to be added to the device
254
285
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}
255
286
  */
256
287
  }, {
257
- key: "disableDeviceConnectivityAssurance",
258
- value: function disableDeviceConnectivityAssurance(projectOrProductUID, deviceUID) {
259
- return this.disableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
288
+ key: "addQiNote",
289
+ value: function addQiNote(projectOrProductUID, deviceUID, notefileID, note) {
290
+ return this.addQiNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, note).then(function (response_and_data) {
260
291
  return response_and_data.data;
261
292
  });
262
293
  }
263
294
 
264
295
  /**
265
- * Enable Device
296
+ * Delete a note from a .db or .qi notefile
266
297
  * @param {String} projectOrProductUID
267
298
  * @param {String} deviceUID
299
+ * @param {String} notefileID
300
+ * @param {String} noteID
268
301
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
269
302
  */
270
303
  }, {
271
- key: "enableDeviceWithHttpInfo",
272
- value: function enableDeviceWithHttpInfo(projectOrProductUID, deviceUID) {
304
+ key: "deleteDbNoteWithHttpInfo",
305
+ value: function deleteDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID) {
273
306
  var postBody = null;
274
307
  // verify the required parameter 'projectOrProductUID' is set
275
308
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
276
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling enableDevice");
309
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling deleteDbNote");
277
310
  }
278
311
  // verify the required parameter 'deviceUID' is set
279
312
  if (deviceUID === undefined || deviceUID === null) {
280
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling enableDevice");
313
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling deleteDbNote");
314
+ }
315
+ // verify the required parameter 'notefileID' is set
316
+ if (notefileID === undefined || notefileID === null) {
317
+ throw new _Error["default"]("Missing the required parameter 'notefileID' when calling deleteDbNote");
318
+ }
319
+ // verify the required parameter 'noteID' is set
320
+ if (noteID === undefined || noteID === null) {
321
+ throw new _Error["default"]("Missing the required parameter 'noteID' when calling deleteDbNote");
281
322
  }
282
323
  var pathParams = {
283
324
  'projectOrProductUID': projectOrProductUID,
284
- 'deviceUID': deviceUID
325
+ 'deviceUID': deviceUID,
326
+ 'notefileID': notefileID,
327
+ 'noteID': noteID
285
328
  };
286
329
  var queryParams = {};
287
330
  var headerParams = {};
@@ -290,90 +333,106 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
290
333
  var contentTypes = [];
291
334
  var accepts = ['application/json'];
292
335
  var returnType = null;
293
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/enable', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
336
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
294
337
  }
295
338
 
296
339
  /**
297
- * Enable Device
340
+ * Delete a note from a .db or .qi notefile
298
341
  * @param {String} projectOrProductUID
299
342
  * @param {String} deviceUID
343
+ * @param {String} notefileID
344
+ * @param {String} noteID
300
345
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}
301
346
  */
302
347
  }, {
303
- key: "enableDevice",
304
- value: function enableDevice(projectOrProductUID, deviceUID) {
305
- return this.enableDeviceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
348
+ key: "deleteDbNote",
349
+ value: function deleteDbNote(projectOrProductUID, deviceUID, notefileID, noteID) {
350
+ return this.deleteDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID).then(function (response_and_data) {
306
351
  return response_and_data.data;
307
352
  });
308
353
  }
309
354
 
310
355
  /**
311
- * Enable Connectivity Assurance
356
+ * Delete Device
312
357
  * @param {String} projectOrProductUID
313
358
  * @param {String} deviceUID
359
+ * @param {Boolean} purge
314
360
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
315
361
  */
316
362
  }, {
317
- key: "enableDeviceConnectivityAssuranceWithHttpInfo",
318
- value: function enableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID) {
363
+ key: "deleteDeviceWithHttpInfo",
364
+ value: function deleteDeviceWithHttpInfo(projectOrProductUID, deviceUID, purge) {
319
365
  var postBody = null;
320
366
  // verify the required parameter 'projectOrProductUID' is set
321
367
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
322
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling enableDeviceConnectivityAssurance");
368
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling deleteDevice");
323
369
  }
324
370
  // verify the required parameter 'deviceUID' is set
325
371
  if (deviceUID === undefined || deviceUID === null) {
326
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling enableDeviceConnectivityAssurance");
372
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling deleteDevice");
373
+ }
374
+ // verify the required parameter 'purge' is set
375
+ if (purge === undefined || purge === null) {
376
+ throw new _Error["default"]("Missing the required parameter 'purge' when calling deleteDevice");
327
377
  }
328
378
  var pathParams = {
329
379
  'projectOrProductUID': projectOrProductUID,
330
380
  'deviceUID': deviceUID
331
381
  };
332
- var queryParams = {};
382
+ var queryParams = {
383
+ 'purge': purge
384
+ };
333
385
  var headerParams = {};
334
386
  var formParams = {};
335
387
  var authNames = ['personalAccessToken'];
336
388
  var contentTypes = [];
337
389
  var accepts = ['application/json'];
338
390
  var returnType = null;
339
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/enable-connectivity-assurance', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
391
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
340
392
  }
341
393
 
342
394
  /**
343
- * Enable Connectivity Assurance
395
+ * Delete Device
344
396
  * @param {String} projectOrProductUID
345
397
  * @param {String} deviceUID
398
+ * @param {Boolean} purge
346
399
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}
347
400
  */
348
401
  }, {
349
- key: "enableDeviceConnectivityAssurance",
350
- value: function enableDeviceConnectivityAssurance(projectOrProductUID, deviceUID) {
351
- return this.enableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
402
+ key: "deleteDevice",
403
+ value: function deleteDevice(projectOrProductUID, deviceUID, purge) {
404
+ return this.deleteDeviceWithHttpInfo(projectOrProductUID, deviceUID, purge).then(function (response_and_data) {
352
405
  return response_and_data.data;
353
406
  });
354
407
  }
355
408
 
356
409
  /**
357
- * Get Device
410
+ * Delete environment variable of a device
358
411
  * @param {String} projectOrProductUID
359
412
  * @param {String} deviceUID
360
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/Device} and HTTP response
413
+ * @param {String} key The environment variable key to delete.
414
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
361
415
  */
362
416
  }, {
363
- key: "getDeviceWithHttpInfo",
364
- value: function getDeviceWithHttpInfo(projectOrProductUID, deviceUID) {
417
+ key: "deleteDeviceEnvironmentVariableWithHttpInfo",
418
+ value: function deleteDeviceEnvironmentVariableWithHttpInfo(projectOrProductUID, deviceUID, key) {
365
419
  var postBody = null;
366
420
  // verify the required parameter 'projectOrProductUID' is set
367
421
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
368
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevice");
422
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling deleteDeviceEnvironmentVariable");
369
423
  }
370
424
  // verify the required parameter 'deviceUID' is set
371
425
  if (deviceUID === undefined || deviceUID === null) {
372
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDevice");
426
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling deleteDeviceEnvironmentVariable");
427
+ }
428
+ // verify the required parameter 'key' is set
429
+ if (key === undefined || key === null) {
430
+ throw new _Error["default"]("Missing the required parameter 'key' when calling deleteDeviceEnvironmentVariable");
373
431
  }
374
432
  var pathParams = {
375
433
  'projectOrProductUID': projectOrProductUID,
376
- 'deviceUID': deviceUID
434
+ 'deviceUID': deviceUID,
435
+ 'key': key
377
436
  };
378
437
  var queryParams = {};
379
438
  var headerParams = {};
@@ -381,41 +440,47 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
381
440
  var authNames = ['personalAccessToken'];
382
441
  var contentTypes = [];
383
442
  var accepts = ['application/json'];
384
- var returnType = _Device["default"];
385
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
443
+ var returnType = _EnvironmentVariables["default"];
444
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_variables/{key}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
386
445
  }
387
446
 
388
447
  /**
389
- * Get Device
448
+ * Delete environment variable of a device
390
449
  * @param {String} projectOrProductUID
391
450
  * @param {String} deviceUID
392
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/Device}
451
+ * @param {String} key The environment variable key to delete.
452
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
393
453
  */
394
454
  }, {
395
- key: "getDevice",
396
- value: function getDevice(projectOrProductUID, deviceUID) {
397
- return this.getDeviceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
455
+ key: "deleteDeviceEnvironmentVariable",
456
+ value: function deleteDeviceEnvironmentVariable(projectOrProductUID, deviceUID, key) {
457
+ return this.deleteDeviceEnvironmentVariableWithHttpInfo(projectOrProductUID, deviceUID, key).then(function (response_and_data) {
398
458
  return response_and_data.data;
399
459
  });
400
460
  }
401
461
 
402
462
  /**
403
- * Get environment variable hierarchy for a device
463
+ * Deletes Notefiles and the Notes they contain.
404
464
  * @param {String} projectOrProductUID
405
465
  * @param {String} deviceUID
406
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvTreeJsonNode} and HTTP response
466
+ * @param {module:model/DeleteNotefilesRequest} deleteNotefilesRequest
467
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
407
468
  */
408
469
  }, {
409
- key: "getDeviceEnvironmentHierarchyWithHttpInfo",
410
- value: function getDeviceEnvironmentHierarchyWithHttpInfo(projectOrProductUID, deviceUID) {
411
- var postBody = null;
470
+ key: "deleteNotefilesWithHttpInfo",
471
+ value: function deleteNotefilesWithHttpInfo(projectOrProductUID, deviceUID, deleteNotefilesRequest) {
472
+ var postBody = deleteNotefilesRequest;
412
473
  // verify the required parameter 'projectOrProductUID' is set
413
474
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
414
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceEnvironmentHierarchy");
475
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling deleteNotefiles");
415
476
  }
416
477
  // verify the required parameter 'deviceUID' is set
417
478
  if (deviceUID === undefined || deviceUID === null) {
418
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceEnvironmentHierarchy");
479
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling deleteNotefiles");
480
+ }
481
+ // verify the required parameter 'deleteNotefilesRequest' is set
482
+ if (deleteNotefilesRequest === undefined || deleteNotefilesRequest === null) {
483
+ throw new _Error["default"]("Missing the required parameter 'deleteNotefilesRequest' when calling deleteNotefiles");
419
484
  }
420
485
  var pathParams = {
421
486
  'projectOrProductUID': projectOrProductUID,
@@ -425,43 +490,44 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
425
490
  var headerParams = {};
426
491
  var formParams = {};
427
492
  var authNames = ['personalAccessToken'];
428
- var contentTypes = [];
493
+ var contentTypes = ['application/json'];
429
494
  var accepts = ['application/json'];
430
- var returnType = _EnvTreeJsonNode["default"];
431
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_hierarchy', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
495
+ var returnType = null;
496
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
432
497
  }
433
498
 
434
499
  /**
435
- * Get environment variable hierarchy for a device
500
+ * Deletes Notefiles and the Notes they contain.
436
501
  * @param {String} projectOrProductUID
437
502
  * @param {String} deviceUID
438
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvTreeJsonNode}
503
+ * @param {module:model/DeleteNotefilesRequest} deleteNotefilesRequest
504
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
439
505
  */
440
506
  }, {
441
- key: "getDeviceEnvironmentHierarchy",
442
- value: function getDeviceEnvironmentHierarchy(projectOrProductUID, deviceUID) {
443
- return this.getDeviceEnvironmentHierarchyWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
507
+ key: "deleteNotefiles",
508
+ value: function deleteNotefiles(projectOrProductUID, deviceUID, deleteNotefilesRequest) {
509
+ return this.deleteNotefilesWithHttpInfo(projectOrProductUID, deviceUID, deleteNotefilesRequest).then(function (response_and_data) {
444
510
  return response_and_data.data;
445
511
  });
446
512
  }
447
513
 
448
514
  /**
449
- * Get environment variables of a device
515
+ * Disable Device
450
516
  * @param {String} projectOrProductUID
451
517
  * @param {String} deviceUID
452
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response} and HTTP response
518
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
453
519
  */
454
520
  }, {
455
- key: "getDeviceEnvironmentVariablesWithHttpInfo",
456
- value: function getDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID) {
521
+ key: "disableDeviceWithHttpInfo",
522
+ value: function disableDeviceWithHttpInfo(projectOrProductUID, deviceUID) {
457
523
  var postBody = null;
458
524
  // verify the required parameter 'projectOrProductUID' is set
459
525
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
460
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceEnvironmentVariables");
526
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling disableDevice");
461
527
  }
462
528
  // verify the required parameter 'deviceUID' is set
463
529
  if (deviceUID === undefined || deviceUID === null) {
464
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceEnvironmentVariables");
530
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling disableDevice");
465
531
  }
466
532
  var pathParams = {
467
533
  'projectOrProductUID': projectOrProductUID,
@@ -473,146 +539,133 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
473
539
  var authNames = ['personalAccessToken'];
474
540
  var contentTypes = [];
475
541
  var accepts = ['application/json'];
476
- var returnType = _GetDeviceEnvironmentVariablesByPin200Response["default"];
477
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_variables', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
542
+ var returnType = null;
543
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/disable', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
478
544
  }
479
545
 
480
546
  /**
481
- * Get environment variables of a device
547
+ * Disable Device
482
548
  * @param {String} projectOrProductUID
483
549
  * @param {String} deviceUID
484
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response}
550
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
485
551
  */
486
552
  }, {
487
- key: "getDeviceEnvironmentVariables",
488
- value: function getDeviceEnvironmentVariables(projectOrProductUID, deviceUID) {
489
- return this.getDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
553
+ key: "disableDevice",
554
+ value: function disableDevice(projectOrProductUID, deviceUID) {
555
+ return this.disableDeviceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
490
556
  return response_and_data.data;
491
557
  });
492
558
  }
493
559
 
494
560
  /**
495
- * Get environment variables of a device with device pin authorization
496
- * @param {String} productUID
561
+ * Disable Connectivity Assurance
562
+ * @param {String} projectOrProductUID
497
563
  * @param {String} deviceUID
498
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response} and HTTP response
564
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
499
565
  */
500
566
  }, {
501
- key: "getDeviceEnvironmentVariablesByPinWithHttpInfo",
502
- value: function getDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID) {
567
+ key: "disableDeviceConnectivityAssuranceWithHttpInfo",
568
+ value: function disableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID) {
503
569
  var postBody = null;
504
- // verify the required parameter 'productUID' is set
505
- if (productUID === undefined || productUID === null) {
506
- throw new _Error["default"]("Missing the required parameter 'productUID' when calling getDeviceEnvironmentVariablesByPin");
570
+ // verify the required parameter 'projectOrProductUID' is set
571
+ if (projectOrProductUID === undefined || projectOrProductUID === null) {
572
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling disableDeviceConnectivityAssurance");
507
573
  }
508
574
  // verify the required parameter 'deviceUID' is set
509
575
  if (deviceUID === undefined || deviceUID === null) {
510
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceEnvironmentVariablesByPin");
576
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling disableDeviceConnectivityAssurance");
511
577
  }
512
578
  var pathParams = {
513
- 'productUID': productUID,
579
+ 'projectOrProductUID': projectOrProductUID,
514
580
  'deviceUID': deviceUID
515
581
  };
516
582
  var queryParams = {};
517
583
  var headerParams = {};
518
584
  var formParams = {};
519
- var authNames = ['pin'];
585
+ var authNames = ['personalAccessToken'];
520
586
  var contentTypes = [];
521
587
  var accepts = ['application/json'];
522
- var returnType = _GetDeviceEnvironmentVariablesByPin200Response["default"];
523
- return this.apiClient.callApi('/v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
588
+ var returnType = null;
589
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/disable-connectivity-assurance', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
524
590
  }
525
591
 
526
592
  /**
527
- * Get environment variables of a device with device pin authorization
528
- * @param {String} productUID
593
+ * Disable Connectivity Assurance
594
+ * @param {String} projectOrProductUID
529
595
  * @param {String} deviceUID
530
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response}
596
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
531
597
  */
532
598
  }, {
533
- key: "getDeviceEnvironmentVariablesByPin",
534
- value: function getDeviceEnvironmentVariablesByPin(productUID, deviceUID) {
535
- return this.getDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID).then(function (response_and_data) {
599
+ key: "disableDeviceConnectivityAssurance",
600
+ value: function disableDeviceConnectivityAssurance(projectOrProductUID, deviceUID) {
601
+ return this.disableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
536
602
  return response_and_data.data;
537
603
  });
538
604
  }
539
605
 
540
606
  /**
541
- * Get Device Health Log
607
+ * Enable Device
542
608
  * @param {String} projectOrProductUID
543
609
  * @param {String} deviceUID
544
- * @param {Object} opts Optional parameters
545
- * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
546
- * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
547
- * @param {Array.<module:model/String>} opts.logType Return only specified log types
548
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceHealthLog200Response} and HTTP response
610
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
549
611
  */
550
612
  }, {
551
- key: "getDeviceHealthLogWithHttpInfo",
552
- value: function getDeviceHealthLogWithHttpInfo(projectOrProductUID, deviceUID, opts) {
553
- opts = opts || {};
613
+ key: "enableDeviceWithHttpInfo",
614
+ value: function enableDeviceWithHttpInfo(projectOrProductUID, deviceUID) {
554
615
  var postBody = null;
555
616
  // verify the required parameter 'projectOrProductUID' is set
556
617
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
557
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceHealthLog");
618
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling enableDevice");
558
619
  }
559
620
  // verify the required parameter 'deviceUID' is set
560
621
  if (deviceUID === undefined || deviceUID === null) {
561
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceHealthLog");
622
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling enableDevice");
562
623
  }
563
624
  var pathParams = {
564
625
  'projectOrProductUID': projectOrProductUID,
565
626
  'deviceUID': deviceUID
566
627
  };
567
- var queryParams = {
568
- 'startDate': opts['startDate'],
569
- 'endDate': opts['endDate'],
570
- 'log_type': this.apiClient.buildCollectionParam(opts['logType'], 'multi')
571
- };
628
+ var queryParams = {};
572
629
  var headerParams = {};
573
630
  var formParams = {};
574
631
  var authNames = ['personalAccessToken'];
575
632
  var contentTypes = [];
576
633
  var accepts = ['application/json'];
577
- var returnType = _GetDeviceHealthLog200Response["default"];
578
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/health-log', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
634
+ var returnType = null;
635
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/enable', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
579
636
  }
580
637
 
581
638
  /**
582
- * Get Device Health Log
639
+ * Enable Device
583
640
  * @param {String} projectOrProductUID
584
641
  * @param {String} deviceUID
585
- * @param {Object} opts Optional parameters
586
- * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
587
- * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
588
- * @param {Array.<module:model/String>} opts.logType Return only specified log types
589
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceHealthLog200Response}
642
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
590
643
  */
591
644
  }, {
592
- key: "getDeviceHealthLog",
593
- value: function getDeviceHealthLog(projectOrProductUID, deviceUID, opts) {
594
- return this.getDeviceHealthLogWithHttpInfo(projectOrProductUID, deviceUID, opts).then(function (response_and_data) {
645
+ key: "enableDevice",
646
+ value: function enableDevice(projectOrProductUID, deviceUID) {
647
+ return this.enableDeviceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
595
648
  return response_and_data.data;
596
649
  });
597
650
  }
598
651
 
599
652
  /**
600
- * Get Device Latest Events
653
+ * Enable Connectivity Assurance
601
654
  * @param {String} projectOrProductUID
602
655
  * @param {String} deviceUID
603
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceLatest200Response} and HTTP response
656
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
604
657
  */
605
658
  }, {
606
- key: "getDeviceLatestWithHttpInfo",
607
- value: function getDeviceLatestWithHttpInfo(projectOrProductUID, deviceUID) {
659
+ key: "enableDeviceConnectivityAssuranceWithHttpInfo",
660
+ value: function enableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID) {
608
661
  var postBody = null;
609
662
  // verify the required parameter 'projectOrProductUID' is set
610
663
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
611
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceLatest");
664
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling enableDeviceConnectivityAssurance");
612
665
  }
613
666
  // verify the required parameter 'deviceUID' is set
614
667
  if (deviceUID === undefined || deviceUID === null) {
615
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceLatest");
668
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling enableDeviceConnectivityAssurance");
616
669
  }
617
670
  var pathParams = {
618
671
  'projectOrProductUID': projectOrProductUID,
@@ -624,87 +677,111 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
624
677
  var authNames = ['personalAccessToken'];
625
678
  var contentTypes = [];
626
679
  var accepts = ['application/json'];
627
- var returnType = _GetDeviceLatest200Response["default"];
628
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/latest', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
680
+ var returnType = null;
681
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/enable-connectivity-assurance', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
629
682
  }
630
683
 
631
684
  /**
632
- * Get Device Latest Events
685
+ * Enable Connectivity Assurance
633
686
  * @param {String} projectOrProductUID
634
687
  * @param {String} deviceUID
635
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceLatest200Response}
688
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
636
689
  */
637
690
  }, {
638
- key: "getDeviceLatest",
639
- value: function getDeviceLatest(projectOrProductUID, deviceUID) {
640
- return this.getDeviceLatestWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
691
+ key: "enableDeviceConnectivityAssurance",
692
+ value: function enableDeviceConnectivityAssurance(projectOrProductUID, deviceUID) {
693
+ return this.enableDeviceConnectivityAssuranceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
641
694
  return response_and_data.data;
642
695
  });
643
696
  }
644
697
 
645
698
  /**
646
- * Get Data Plans associated with the device, this include the primary sim, any external sim, as well as any satellite connections.
699
+ * Get a note from a .db or .qi notefile
647
700
  * @param {String} projectOrProductUID
648
701
  * @param {String} deviceUID
649
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePlans200Response} and HTTP response
702
+ * @param {String} notefileID
703
+ * @param {String} noteID
704
+ * @param {Object} opts Optional parameters
705
+ * @param {Boolean} opts._delete Whether to delete the note from the DB notefile
706
+ * @param {Boolean} opts.deleted Whether to return deleted notes
707
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDbNote200Response} and HTTP response
650
708
  */
651
709
  }, {
652
- key: "getDevicePlansWithHttpInfo",
653
- value: function getDevicePlansWithHttpInfo(projectOrProductUID, deviceUID) {
710
+ key: "getDbNoteWithHttpInfo",
711
+ value: function getDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, opts) {
712
+ opts = opts || {};
654
713
  var postBody = null;
655
714
  // verify the required parameter 'projectOrProductUID' is set
656
715
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
657
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevicePlans");
716
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDbNote");
658
717
  }
659
718
  // verify the required parameter 'deviceUID' is set
660
719
  if (deviceUID === undefined || deviceUID === null) {
661
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDevicePlans");
720
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDbNote");
721
+ }
722
+ // verify the required parameter 'notefileID' is set
723
+ if (notefileID === undefined || notefileID === null) {
724
+ throw new _Error["default"]("Missing the required parameter 'notefileID' when calling getDbNote");
725
+ }
726
+ // verify the required parameter 'noteID' is set
727
+ if (noteID === undefined || noteID === null) {
728
+ throw new _Error["default"]("Missing the required parameter 'noteID' when calling getDbNote");
662
729
  }
663
730
  var pathParams = {
664
731
  'projectOrProductUID': projectOrProductUID,
665
- 'deviceUID': deviceUID
732
+ 'deviceUID': deviceUID,
733
+ 'notefileID': notefileID,
734
+ 'noteID': noteID
735
+ };
736
+ var queryParams = {
737
+ 'delete': opts['_delete'],
738
+ 'deleted': opts['deleted']
666
739
  };
667
- var queryParams = {};
668
740
  var headerParams = {};
669
741
  var formParams = {};
670
742
  var authNames = ['personalAccessToken'];
671
743
  var contentTypes = [];
672
744
  var accepts = ['application/json'];
673
- var returnType = _GetDevicePlans200Response["default"];
674
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/plans', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
745
+ var returnType = _GetDbNote200Response["default"];
746
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
675
747
  }
676
748
 
677
749
  /**
678
- * Get Data Plans associated with the device, this include the primary sim, any external sim, as well as any satellite connections.
750
+ * Get a note from a .db or .qi notefile
679
751
  * @param {String} projectOrProductUID
680
752
  * @param {String} deviceUID
681
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePlans200Response}
753
+ * @param {String} notefileID
754
+ * @param {String} noteID
755
+ * @param {Object} opts Optional parameters
756
+ * @param {Boolean} opts._delete Whether to delete the note from the DB notefile
757
+ * @param {Boolean} opts.deleted Whether to return deleted notes
758
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDbNote200Response}
682
759
  */
683
760
  }, {
684
- key: "getDevicePlans",
685
- value: function getDevicePlans(projectOrProductUID, deviceUID) {
686
- return this.getDevicePlansWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
761
+ key: "getDbNote",
762
+ value: function getDbNote(projectOrProductUID, deviceUID, notefileID, noteID, opts) {
763
+ return this.getDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, opts).then(function (response_and_data) {
687
764
  return response_and_data.data;
688
765
  });
689
766
  }
690
767
 
691
768
  /**
692
- * Get Device Public Key
769
+ * Get Device
693
770
  * @param {String} projectOrProductUID
694
771
  * @param {String} deviceUID
695
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePublicKey200Response} and HTTP response
772
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/Device} and HTTP response
696
773
  */
697
774
  }, {
698
- key: "getDevicePublicKeyWithHttpInfo",
699
- value: function getDevicePublicKeyWithHttpInfo(projectOrProductUID, deviceUID) {
775
+ key: "getDeviceWithHttpInfo",
776
+ value: function getDeviceWithHttpInfo(projectOrProductUID, deviceUID) {
700
777
  var postBody = null;
701
778
  // verify the required parameter 'projectOrProductUID' is set
702
779
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
703
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevicePublicKey");
780
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevice");
704
781
  }
705
782
  // verify the required parameter 'deviceUID' is set
706
783
  if (deviceUID === undefined || deviceUID === null) {
707
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDevicePublicKey");
784
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDevice");
708
785
  }
709
786
  var pathParams = {
710
787
  'projectOrProductUID': projectOrProductUID,
@@ -716,851 +793,808 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
716
793
  var authNames = ['personalAccessToken'];
717
794
  var contentTypes = [];
718
795
  var accepts = ['application/json'];
719
- var returnType = _GetDevicePublicKey200Response["default"];
720
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/public-key', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
796
+ var returnType = _Device["default"];
797
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
721
798
  }
722
799
 
723
800
  /**
724
- * Get Device Public Key
801
+ * Get Device
725
802
  * @param {String} projectOrProductUID
726
803
  * @param {String} deviceUID
727
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePublicKey200Response}
804
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/Device}
728
805
  */
729
806
  }, {
730
- key: "getDevicePublicKey",
731
- value: function getDevicePublicKey(projectOrProductUID, deviceUID) {
732
- return this.getDevicePublicKeyWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
807
+ key: "getDevice",
808
+ value: function getDevice(projectOrProductUID, deviceUID) {
809
+ return this.getDeviceWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
733
810
  return response_and_data.data;
734
811
  });
735
812
  }
736
813
 
737
814
  /**
738
- * Get Device Sessions
815
+ * Get environment variable hierarchy for a device
739
816
  * @param {String} projectOrProductUID
740
817
  * @param {String} deviceUID
741
- * @param {Object} opts Optional parameters
742
- * @param {Number} opts.pageSize (default to 50)
743
- * @param {Number} opts.pageNum (default to 1)
744
- * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
745
- * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
746
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceSessions200Response} and HTTP response
818
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvTreeJsonNode} and HTTP response
747
819
  */
748
820
  }, {
749
- key: "getDeviceSessionsWithHttpInfo",
750
- value: function getDeviceSessionsWithHttpInfo(projectOrProductUID, deviceUID, opts) {
751
- opts = opts || {};
821
+ key: "getDeviceEnvironmentHierarchyWithHttpInfo",
822
+ value: function getDeviceEnvironmentHierarchyWithHttpInfo(projectOrProductUID, deviceUID) {
752
823
  var postBody = null;
753
824
  // verify the required parameter 'projectOrProductUID' is set
754
825
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
755
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceSessions");
826
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceEnvironmentHierarchy");
756
827
  }
757
828
  // verify the required parameter 'deviceUID' is set
758
829
  if (deviceUID === undefined || deviceUID === null) {
759
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceSessions");
830
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceEnvironmentHierarchy");
760
831
  }
761
832
  var pathParams = {
762
833
  'projectOrProductUID': projectOrProductUID,
763
834
  'deviceUID': deviceUID
764
835
  };
765
- var queryParams = {
766
- 'pageSize': opts['pageSize'],
767
- 'pageNum': opts['pageNum'],
768
- 'startDate': opts['startDate'],
769
- 'endDate': opts['endDate']
770
- };
836
+ var queryParams = {};
771
837
  var headerParams = {};
772
838
  var formParams = {};
773
839
  var authNames = ['personalAccessToken'];
774
840
  var contentTypes = [];
775
841
  var accepts = ['application/json'];
776
- var returnType = _GetDeviceSessions200Response["default"];
777
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/sessions', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
842
+ var returnType = _EnvTreeJsonNode["default"];
843
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_hierarchy', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
778
844
  }
779
845
 
780
846
  /**
781
- * Get Device Sessions
847
+ * Get environment variable hierarchy for a device
782
848
  * @param {String} projectOrProductUID
783
849
  * @param {String} deviceUID
784
- * @param {Object} opts Optional parameters
785
- * @param {Number} opts.pageSize (default to 50)
786
- * @param {Number} opts.pageNum (default to 1)
787
- * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
788
- * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
789
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceSessions200Response}
850
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvTreeJsonNode}
790
851
  */
791
852
  }, {
792
- key: "getDeviceSessions",
793
- value: function getDeviceSessions(projectOrProductUID, deviceUID, opts) {
794
- return this.getDeviceSessionsWithHttpInfo(projectOrProductUID, deviceUID, opts).then(function (response_and_data) {
853
+ key: "getDeviceEnvironmentHierarchy",
854
+ value: function getDeviceEnvironmentHierarchy(projectOrProductUID, deviceUID) {
855
+ return this.getDeviceEnvironmentHierarchyWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
795
856
  return response_and_data.data;
796
857
  });
797
858
  }
798
859
 
799
860
  /**
800
- * Get Device Public Keys of a Project
861
+ * Get environment variables of a device
801
862
  * @param {String} projectOrProductUID
802
- * @param {Object} opts Optional parameters
803
- * @param {Number} opts.pageSize (default to 50)
804
- * @param {Number} opts.pageNum (default to 1)
805
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetProjectDevicePublicKeys200Response} and HTTP response
863
+ * @param {String} deviceUID
864
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response} and HTTP response
806
865
  */
807
866
  }, {
808
- key: "getProjectDevicePublicKeysWithHttpInfo",
809
- value: function getProjectDevicePublicKeysWithHttpInfo(projectOrProductUID, opts) {
810
- opts = opts || {};
867
+ key: "getDeviceEnvironmentVariablesWithHttpInfo",
868
+ value: function getDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID) {
811
869
  var postBody = null;
812
870
  // verify the required parameter 'projectOrProductUID' is set
813
871
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
814
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getProjectDevicePublicKeys");
872
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceEnvironmentVariables");
873
+ }
874
+ // verify the required parameter 'deviceUID' is set
875
+ if (deviceUID === undefined || deviceUID === null) {
876
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceEnvironmentVariables");
815
877
  }
816
878
  var pathParams = {
817
- 'projectOrProductUID': projectOrProductUID
818
- };
819
- var queryParams = {
820
- 'pageSize': opts['pageSize'],
821
- 'pageNum': opts['pageNum']
879
+ 'projectOrProductUID': projectOrProductUID,
880
+ 'deviceUID': deviceUID
822
881
  };
882
+ var queryParams = {};
823
883
  var headerParams = {};
824
884
  var formParams = {};
825
885
  var authNames = ['personalAccessToken'];
826
886
  var contentTypes = [];
827
887
  var accepts = ['application/json'];
828
- var returnType = _GetProjectDevicePublicKeys200Response["default"];
829
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/public-keys', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
888
+ var returnType = _GetDeviceEnvironmentVariablesByPin200Response["default"];
889
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_variables', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
830
890
  }
831
891
 
832
892
  /**
833
- * Get Device Public Keys of a Project
893
+ * Get environment variables of a device
834
894
  * @param {String} projectOrProductUID
835
- * @param {Object} opts Optional parameters
836
- * @param {Number} opts.pageSize (default to 50)
837
- * @param {Number} opts.pageNum (default to 1)
838
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetProjectDevicePublicKeys200Response}
895
+ * @param {String} deviceUID
896
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response}
839
897
  */
840
898
  }, {
841
- key: "getProjectDevicePublicKeys",
842
- value: function getProjectDevicePublicKeys(projectOrProductUID, opts) {
843
- return this.getProjectDevicePublicKeysWithHttpInfo(projectOrProductUID, opts).then(function (response_and_data) {
899
+ key: "getDeviceEnvironmentVariables",
900
+ value: function getDeviceEnvironmentVariables(projectOrProductUID, deviceUID) {
901
+ return this.getDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
844
902
  return response_and_data.data;
845
903
  });
846
904
  }
847
905
 
848
906
  /**
849
- * Get Devices of a Project
850
- * @param {String} projectOrProductUID
851
- * @param {Object} opts Optional parameters
852
- * @param {Number} opts.pageSize (default to 50)
853
- * @param {Number} opts.pageNum (default to 1)
854
- * @param {Array.<String>} opts.deviceUID A Device UID.
855
- * @param {Array.<String>} opts.tag Tag filter
856
- * @param {Array.<String>} opts.serialNumber Serial number filter
857
- * @param {Array.<String>} opts.fleetUID
858
- * @param {Array.<String>} opts.notecardFirmware Firmware version filter
859
- * @param {Array.<String>} opts.location Location filter
860
- * @param {Array.<String>} opts.hostFirmware Host firmware filter
861
- * @param {Array.<String>} opts.productUID
862
- * @param {Array.<String>} opts.sku SKU filter
863
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetProjectDevices200Response} and HTTP response
907
+ * Get environment variables of a device with device pin authorization
908
+ * @param {String} productUID
909
+ * @param {String} deviceUID
910
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response} and HTTP response
864
911
  */
865
912
  }, {
866
- key: "getProjectDevicesWithHttpInfo",
867
- value: function getProjectDevicesWithHttpInfo(projectOrProductUID, opts) {
868
- opts = opts || {};
913
+ key: "getDeviceEnvironmentVariablesByPinWithHttpInfo",
914
+ value: function getDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID) {
869
915
  var postBody = null;
870
- // verify the required parameter 'projectOrProductUID' is set
871
- if (projectOrProductUID === undefined || projectOrProductUID === null) {
872
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getProjectDevices");
916
+ // verify the required parameter 'productUID' is set
917
+ if (productUID === undefined || productUID === null) {
918
+ throw new _Error["default"]("Missing the required parameter 'productUID' when calling getDeviceEnvironmentVariablesByPin");
919
+ }
920
+ // verify the required parameter 'deviceUID' is set
921
+ if (deviceUID === undefined || deviceUID === null) {
922
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceEnvironmentVariablesByPin");
873
923
  }
874
924
  var pathParams = {
875
- 'projectOrProductUID': projectOrProductUID
876
- };
877
- var queryParams = {
878
- 'pageSize': opts['pageSize'],
879
- 'pageNum': opts['pageNum'],
880
- 'deviceUID': this.apiClient.buildCollectionParam(opts['deviceUID'], 'multi'),
881
- 'tag': this.apiClient.buildCollectionParam(opts['tag'], 'multi'),
882
- 'serialNumber': this.apiClient.buildCollectionParam(opts['serialNumber'], 'multi'),
883
- 'fleetUID': this.apiClient.buildCollectionParam(opts['fleetUID'], 'multi'),
884
- 'notecardFirmware': this.apiClient.buildCollectionParam(opts['notecardFirmware'], 'multi'),
885
- 'location': this.apiClient.buildCollectionParam(opts['location'], 'multi'),
886
- 'hostFirmware': this.apiClient.buildCollectionParam(opts['hostFirmware'], 'multi'),
887
- 'productUID': this.apiClient.buildCollectionParam(opts['productUID'], 'multi'),
888
- 'sku': this.apiClient.buildCollectionParam(opts['sku'], 'multi')
925
+ 'productUID': productUID,
926
+ 'deviceUID': deviceUID
889
927
  };
928
+ var queryParams = {};
890
929
  var headerParams = {};
891
930
  var formParams = {};
892
- var authNames = ['personalAccessToken'];
931
+ var authNames = ['pin'];
893
932
  var contentTypes = [];
894
933
  var accepts = ['application/json'];
895
- var returnType = _GetProjectDevices200Response["default"];
896
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
934
+ var returnType = _GetDeviceEnvironmentVariablesByPin200Response["default"];
935
+ return this.apiClient.callApi('/v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
897
936
  }
898
937
 
899
938
  /**
900
- * Get Devices of a Project
901
- * @param {String} projectOrProductUID
902
- * @param {Object} opts Optional parameters
903
- * @param {Number} opts.pageSize (default to 50)
904
- * @param {Number} opts.pageNum (default to 1)
905
- * @param {Array.<String>} opts.deviceUID A Device UID.
906
- * @param {Array.<String>} opts.tag Tag filter
907
- * @param {Array.<String>} opts.serialNumber Serial number filter
908
- * @param {Array.<String>} opts.fleetUID
909
- * @param {Array.<String>} opts.notecardFirmware Firmware version filter
910
- * @param {Array.<String>} opts.location Location filter
911
- * @param {Array.<String>} opts.hostFirmware Host firmware filter
912
- * @param {Array.<String>} opts.productUID
913
- * @param {Array.<String>} opts.sku SKU filter
914
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetProjectDevices200Response}
939
+ * Get environment variables of a device with device pin authorization
940
+ * @param {String} productUID
941
+ * @param {String} deviceUID
942
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response}
915
943
  */
916
944
  }, {
917
- key: "getProjectDevices",
918
- value: function getProjectDevices(projectOrProductUID, opts) {
919
- return this.getProjectDevicesWithHttpInfo(projectOrProductUID, opts).then(function (response_and_data) {
945
+ key: "getDeviceEnvironmentVariablesByPin",
946
+ value: function getDeviceEnvironmentVariablesByPin(productUID, deviceUID) {
947
+ return this.getDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID).then(function (response_and_data) {
920
948
  return response_and_data.data;
921
949
  });
922
950
  }
923
951
 
924
952
  /**
925
- * Get Devices of a Fleet within a Project
953
+ * Get Device Health Log
926
954
  * @param {String} projectOrProductUID
927
- * @param {String} fleetUID
955
+ * @param {String} deviceUID
928
956
  * @param {Object} opts Optional parameters
929
- * @param {Number} opts.pageSize (default to 50)
930
- * @param {Number} opts.pageNum (default to 1)
931
- * @param {Array.<String>} opts.deviceUID A Device UID.
932
- * @param {Array.<String>} opts.tag Tag filter
933
- * @param {Array.<String>} opts.serialNumber Serial number filter
934
- * @param {Array.<String>} opts.notecardFirmware Firmware version filter
935
- * @param {Array.<String>} opts.location Location filter
936
- * @param {Array.<String>} opts.hostFirmware Host firmware filter
937
- * @param {Array.<String>} opts.productUID
938
- * @param {Array.<String>} opts.sku SKU filter
939
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetProjectDevices200Response} and HTTP response
957
+ * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
958
+ * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
959
+ * @param {Array.<module:model/String>} opts.logType Return only specified log types
960
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceHealthLog200Response} and HTTP response
940
961
  */
941
962
  }, {
942
- key: "getProjectFleetDevicesWithHttpInfo",
943
- value: function getProjectFleetDevicesWithHttpInfo(projectOrProductUID, fleetUID, opts) {
963
+ key: "getDeviceHealthLogWithHttpInfo",
964
+ value: function getDeviceHealthLogWithHttpInfo(projectOrProductUID, deviceUID, opts) {
944
965
  opts = opts || {};
945
966
  var postBody = null;
946
967
  // verify the required parameter 'projectOrProductUID' is set
947
968
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
948
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getProjectFleetDevices");
969
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceHealthLog");
949
970
  }
950
- // verify the required parameter 'fleetUID' is set
951
- if (fleetUID === undefined || fleetUID === null) {
952
- throw new _Error["default"]("Missing the required parameter 'fleetUID' when calling getProjectFleetDevices");
971
+ // verify the required parameter 'deviceUID' is set
972
+ if (deviceUID === undefined || deviceUID === null) {
973
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceHealthLog");
953
974
  }
954
975
  var pathParams = {
955
976
  'projectOrProductUID': projectOrProductUID,
956
- 'fleetUID': fleetUID
977
+ 'deviceUID': deviceUID
957
978
  };
958
979
  var queryParams = {
959
- 'pageSize': opts['pageSize'],
960
- 'pageNum': opts['pageNum'],
961
- 'deviceUID': this.apiClient.buildCollectionParam(opts['deviceUID'], 'multi'),
962
- 'tag': this.apiClient.buildCollectionParam(opts['tag'], 'multi'),
963
- 'serialNumber': this.apiClient.buildCollectionParam(opts['serialNumber'], 'multi'),
964
- 'notecardFirmware': this.apiClient.buildCollectionParam(opts['notecardFirmware'], 'multi'),
965
- 'location': this.apiClient.buildCollectionParam(opts['location'], 'multi'),
966
- 'hostFirmware': this.apiClient.buildCollectionParam(opts['hostFirmware'], 'multi'),
967
- 'productUID': this.apiClient.buildCollectionParam(opts['productUID'], 'multi'),
968
- 'sku': this.apiClient.buildCollectionParam(opts['sku'], 'multi')
980
+ 'startDate': opts['startDate'],
981
+ 'endDate': opts['endDate'],
982
+ 'log_type': this.apiClient.buildCollectionParam(opts['logType'], 'multi')
969
983
  };
970
984
  var headerParams = {};
971
985
  var formParams = {};
972
986
  var authNames = ['personalAccessToken'];
973
987
  var contentTypes = [];
974
988
  var accepts = ['application/json'];
975
- var returnType = _GetProjectDevices200Response["default"];
976
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/fleets/{fleetUID}/devices', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
989
+ var returnType = _GetDeviceHealthLog200Response["default"];
990
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/health-log', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
977
991
  }
978
992
 
979
993
  /**
980
- * Get Devices of a Fleet within a Project
994
+ * Get Device Health Log
981
995
  * @param {String} projectOrProductUID
982
- * @param {String} fleetUID
996
+ * @param {String} deviceUID
983
997
  * @param {Object} opts Optional parameters
984
- * @param {Number} opts.pageSize (default to 50)
985
- * @param {Number} opts.pageNum (default to 1)
986
- * @param {Array.<String>} opts.deviceUID A Device UID.
987
- * @param {Array.<String>} opts.tag Tag filter
988
- * @param {Array.<String>} opts.serialNumber Serial number filter
989
- * @param {Array.<String>} opts.notecardFirmware Firmware version filter
990
- * @param {Array.<String>} opts.location Location filter
991
- * @param {Array.<String>} opts.hostFirmware Host firmware filter
992
- * @param {Array.<String>} opts.productUID
993
- * @param {Array.<String>} opts.sku SKU filter
994
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetProjectDevices200Response}
998
+ * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
999
+ * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
1000
+ * @param {Array.<module:model/String>} opts.logType Return only specified log types
1001
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceHealthLog200Response}
995
1002
  */
996
1003
  }, {
997
- key: "getProjectFleetDevices",
998
- value: function getProjectFleetDevices(projectOrProductUID, fleetUID, opts) {
999
- return this.getProjectFleetDevicesWithHttpInfo(projectOrProductUID, fleetUID, opts).then(function (response_and_data) {
1004
+ key: "getDeviceHealthLog",
1005
+ value: function getDeviceHealthLog(projectOrProductUID, deviceUID, opts) {
1006
+ return this.getDeviceHealthLogWithHttpInfo(projectOrProductUID, deviceUID, opts).then(function (response_and_data) {
1000
1007
  return response_and_data.data;
1001
1008
  });
1002
1009
  }
1003
1010
 
1004
1011
  /**
1005
- * Adds a Note to a Notefile, creating the Notefile if it doesn't yet exist.
1012
+ * Get Device Latest Events
1006
1013
  * @param {String} projectOrProductUID
1007
1014
  * @param {String} deviceUID
1008
- * @param {String} notefileID
1009
- * @param {module:model/Note} note Body or payload of note to be added to the device
1010
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
1015
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceLatestEvents200Response} and HTTP response
1011
1016
  */
1012
1017
  }, {
1013
- key: "handleNoteAddWithHttpInfo",
1014
- value: function handleNoteAddWithHttpInfo(projectOrProductUID, deviceUID, notefileID, note) {
1015
- var postBody = note;
1018
+ key: "getDeviceLatestEventsWithHttpInfo",
1019
+ value: function getDeviceLatestEventsWithHttpInfo(projectOrProductUID, deviceUID) {
1020
+ var postBody = null;
1016
1021
  // verify the required parameter 'projectOrProductUID' is set
1017
1022
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1018
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteAdd");
1023
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceLatestEvents");
1019
1024
  }
1020
1025
  // verify the required parameter 'deviceUID' is set
1021
1026
  if (deviceUID === undefined || deviceUID === null) {
1022
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteAdd");
1023
- }
1024
- // verify the required parameter 'notefileID' is set
1025
- if (notefileID === undefined || notefileID === null) {
1026
- throw new _Error["default"]("Missing the required parameter 'notefileID' when calling handleNoteAdd");
1027
- }
1028
- // verify the required parameter 'note' is set
1029
- if (note === undefined || note === null) {
1030
- throw new _Error["default"]("Missing the required parameter 'note' when calling handleNoteAdd");
1027
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceLatestEvents");
1031
1028
  }
1032
1029
  var pathParams = {
1033
1030
  'projectOrProductUID': projectOrProductUID,
1034
- 'deviceUID': deviceUID,
1035
- 'notefileID': notefileID
1031
+ 'deviceUID': deviceUID
1036
1032
  };
1037
1033
  var queryParams = {};
1038
1034
  var headerParams = {};
1039
1035
  var formParams = {};
1040
1036
  var authNames = ['personalAccessToken'];
1041
- var contentTypes = ['application/json'];
1037
+ var contentTypes = [];
1042
1038
  var accepts = ['application/json'];
1043
- var returnType = null;
1044
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1039
+ var returnType = _GetDeviceLatestEvents200Response["default"];
1040
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/latest', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1045
1041
  }
1046
1042
 
1047
1043
  /**
1048
- * Adds a Note to a Notefile, creating the Notefile if it doesn't yet exist.
1044
+ * Get Device Latest Events
1049
1045
  * @param {String} projectOrProductUID
1050
1046
  * @param {String} deviceUID
1051
- * @param {String} notefileID
1052
- * @param {module:model/Note} note Body or payload of note to be added to the device
1053
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
1047
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceLatestEvents200Response}
1054
1048
  */
1055
1049
  }, {
1056
- key: "handleNoteAdd",
1057
- value: function handleNoteAdd(projectOrProductUID, deviceUID, notefileID, note) {
1058
- return this.handleNoteAddWithHttpInfo(projectOrProductUID, deviceUID, notefileID, note).then(function (response_and_data) {
1050
+ key: "getDeviceLatestEvents",
1051
+ value: function getDeviceLatestEvents(projectOrProductUID, deviceUID) {
1052
+ return this.getDeviceLatestEventsWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
1059
1053
  return response_and_data.data;
1060
1054
  });
1061
1055
  }
1062
1056
 
1063
1057
  /**
1064
- * Incrementally retrieve changes within a specific Notefile.
1058
+ * Get Data Plans associated with the device, this include the primary sim, any external sim, as well as any satellite connections.
1065
1059
  * @param {String} projectOrProductUID
1066
1060
  * @param {String} deviceUID
1067
- * @param {String} notefileID
1068
- * @param {Object} opts Optional parameters
1069
- * @param {Number} opts.max The maximum number of Notes to return in the request.
1070
- * @param {Boolean} opts.deleted true to return deleted notes.
1071
- * @param {Boolean} opts._delete true to delete the notes returned by the request.
1072
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/HandleNoteChanges200Response} and HTTP response
1061
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePlans200Response} and HTTP response
1073
1062
  */
1074
1063
  }, {
1075
- key: "handleNoteChangesWithHttpInfo",
1076
- value: function handleNoteChangesWithHttpInfo(projectOrProductUID, deviceUID, notefileID, opts) {
1077
- opts = opts || {};
1064
+ key: "getDevicePlansWithHttpInfo",
1065
+ value: function getDevicePlansWithHttpInfo(projectOrProductUID, deviceUID) {
1078
1066
  var postBody = null;
1079
1067
  // verify the required parameter 'projectOrProductUID' is set
1080
1068
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1081
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteChanges");
1069
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevicePlans");
1082
1070
  }
1083
1071
  // verify the required parameter 'deviceUID' is set
1084
1072
  if (deviceUID === undefined || deviceUID === null) {
1085
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteChanges");
1086
- }
1087
- // verify the required parameter 'notefileID' is set
1088
- if (notefileID === undefined || notefileID === null) {
1089
- throw new _Error["default"]("Missing the required parameter 'notefileID' when calling handleNoteChanges");
1073
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDevicePlans");
1090
1074
  }
1091
1075
  var pathParams = {
1092
1076
  'projectOrProductUID': projectOrProductUID,
1093
- 'deviceUID': deviceUID,
1094
- 'notefileID': notefileID
1095
- };
1096
- var queryParams = {
1097
- 'max': opts['max'],
1098
- 'deleted': opts['deleted'],
1099
- 'delete': opts['_delete']
1077
+ 'deviceUID': deviceUID
1100
1078
  };
1079
+ var queryParams = {};
1101
1080
  var headerParams = {};
1102
1081
  var formParams = {};
1103
1082
  var authNames = ['personalAccessToken'];
1104
1083
  var contentTypes = [];
1105
1084
  var accepts = ['application/json'];
1106
- var returnType = _HandleNoteChanges200Response["default"];
1107
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/changes', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1085
+ var returnType = _GetDevicePlans200Response["default"];
1086
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/plans', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1108
1087
  }
1109
1088
 
1110
1089
  /**
1111
- * Incrementally retrieve changes within a specific Notefile.
1090
+ * Get Data Plans associated with the device, this include the primary sim, any external sim, as well as any satellite connections.
1112
1091
  * @param {String} projectOrProductUID
1113
1092
  * @param {String} deviceUID
1114
- * @param {String} notefileID
1115
- * @param {Object} opts Optional parameters
1116
- * @param {Number} opts.max The maximum number of Notes to return in the request.
1117
- * @param {Boolean} opts.deleted true to return deleted notes.
1118
- * @param {Boolean} opts._delete true to delete the notes returned by the request.
1119
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/HandleNoteChanges200Response}
1093
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePlans200Response}
1120
1094
  */
1121
1095
  }, {
1122
- key: "handleNoteChanges",
1123
- value: function handleNoteChanges(projectOrProductUID, deviceUID, notefileID, opts) {
1124
- return this.handleNoteChangesWithHttpInfo(projectOrProductUID, deviceUID, notefileID, opts).then(function (response_and_data) {
1096
+ key: "getDevicePlans",
1097
+ value: function getDevicePlans(projectOrProductUID, deviceUID) {
1098
+ return this.getDevicePlansWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
1125
1099
  return response_and_data.data;
1126
1100
  });
1127
1101
  }
1128
1102
 
1129
1103
  /**
1130
- * Adds a Note to a Notefile, creating the Notefile if it doesn't yet exist.
1104
+ * Get Device Public Key
1131
1105
  * @param {String} projectOrProductUID
1132
1106
  * @param {String} deviceUID
1133
- * @param {String} notefileID
1134
- * @param {String} noteID
1135
- * @param {module:model/Note} note Body or payload of note to be added to the device
1136
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
1107
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePublicKey200Response} and HTTP response
1137
1108
  */
1138
1109
  }, {
1139
- key: "handleNoteCreateAddWithHttpInfo",
1140
- value: function handleNoteCreateAddWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note) {
1141
- var postBody = note;
1110
+ key: "getDevicePublicKeyWithHttpInfo",
1111
+ value: function getDevicePublicKeyWithHttpInfo(projectOrProductUID, deviceUID) {
1112
+ var postBody = null;
1142
1113
  // verify the required parameter 'projectOrProductUID' is set
1143
1114
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1144
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteCreateAdd");
1115
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevicePublicKey");
1145
1116
  }
1146
1117
  // verify the required parameter 'deviceUID' is set
1147
1118
  if (deviceUID === undefined || deviceUID === null) {
1148
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteCreateAdd");
1149
- }
1150
- // verify the required parameter 'notefileID' is set
1151
- if (notefileID === undefined || notefileID === null) {
1152
- throw new _Error["default"]("Missing the required parameter 'notefileID' when calling handleNoteCreateAdd");
1153
- }
1154
- // verify the required parameter 'noteID' is set
1155
- if (noteID === undefined || noteID === null) {
1156
- throw new _Error["default"]("Missing the required parameter 'noteID' when calling handleNoteCreateAdd");
1157
- }
1158
- // verify the required parameter 'note' is set
1159
- if (note === undefined || note === null) {
1160
- throw new _Error["default"]("Missing the required parameter 'note' when calling handleNoteCreateAdd");
1119
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDevicePublicKey");
1161
1120
  }
1162
1121
  var pathParams = {
1163
1122
  'projectOrProductUID': projectOrProductUID,
1164
- 'deviceUID': deviceUID,
1165
- 'notefileID': notefileID,
1166
- 'noteID': noteID
1123
+ 'deviceUID': deviceUID
1167
1124
  };
1168
1125
  var queryParams = {};
1169
1126
  var headerParams = {};
1170
1127
  var formParams = {};
1171
1128
  var authNames = ['personalAccessToken'];
1172
- var contentTypes = ['application/json'];
1129
+ var contentTypes = [];
1173
1130
  var accepts = ['application/json'];
1174
- var returnType = null;
1175
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1131
+ var returnType = _GetDevicePublicKey200Response["default"];
1132
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/public-key', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1176
1133
  }
1177
1134
 
1178
1135
  /**
1179
- * Adds a Note to a Notefile, creating the Notefile if it doesn't yet exist.
1136
+ * Get Device Public Key
1180
1137
  * @param {String} projectOrProductUID
1181
1138
  * @param {String} deviceUID
1182
- * @param {String} notefileID
1183
- * @param {String} noteID
1184
- * @param {module:model/Note} note Body or payload of note to be added to the device
1185
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
1139
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePublicKey200Response}
1140
+ */
1141
+ }, {
1142
+ key: "getDevicePublicKey",
1143
+ value: function getDevicePublicKey(projectOrProductUID, deviceUID) {
1144
+ return this.getDevicePublicKeyWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
1145
+ return response_and_data.data;
1146
+ });
1147
+ }
1148
+
1149
+ /**
1150
+ * Get Device Public Keys of a Project
1151
+ * @param {String} projectOrProductUID
1152
+ * @param {Object} opts Optional parameters
1153
+ * @param {Number} opts.pageSize (default to 50)
1154
+ * @param {Number} opts.pageNum (default to 1)
1155
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePublicKeys200Response} and HTTP response
1186
1156
  */
1187
1157
  }, {
1188
- key: "handleNoteCreateAdd",
1189
- value: function handleNoteCreateAdd(projectOrProductUID, deviceUID, notefileID, noteID, note) {
1190
- return this.handleNoteCreateAddWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note).then(function (response_and_data) {
1158
+ key: "getDevicePublicKeysWithHttpInfo",
1159
+ value: function getDevicePublicKeysWithHttpInfo(projectOrProductUID, opts) {
1160
+ opts = opts || {};
1161
+ var postBody = null;
1162
+ // verify the required parameter 'projectOrProductUID' is set
1163
+ if (projectOrProductUID === undefined || projectOrProductUID === null) {
1164
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevicePublicKeys");
1165
+ }
1166
+ var pathParams = {
1167
+ 'projectOrProductUID': projectOrProductUID
1168
+ };
1169
+ var queryParams = {
1170
+ 'pageSize': opts['pageSize'],
1171
+ 'pageNum': opts['pageNum']
1172
+ };
1173
+ var headerParams = {};
1174
+ var formParams = {};
1175
+ var authNames = ['personalAccessToken'];
1176
+ var contentTypes = [];
1177
+ var accepts = ['application/json'];
1178
+ var returnType = _GetDevicePublicKeys200Response["default"];
1179
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/public-keys', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1180
+ }
1181
+
1182
+ /**
1183
+ * Get Device Public Keys of a Project
1184
+ * @param {String} projectOrProductUID
1185
+ * @param {Object} opts Optional parameters
1186
+ * @param {Number} opts.pageSize (default to 50)
1187
+ * @param {Number} opts.pageNum (default to 1)
1188
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePublicKeys200Response}
1189
+ */
1190
+ }, {
1191
+ key: "getDevicePublicKeys",
1192
+ value: function getDevicePublicKeys(projectOrProductUID, opts) {
1193
+ return this.getDevicePublicKeysWithHttpInfo(projectOrProductUID, opts).then(function (response_and_data) {
1191
1194
  return response_and_data.data;
1192
1195
  });
1193
1196
  }
1194
1197
 
1195
1198
  /**
1196
- * Delete a note from a DB notefile
1199
+ * Get Device Sessions
1197
1200
  * @param {String} projectOrProductUID
1198
1201
  * @param {String} deviceUID
1199
- * @param {String} notefileID
1200
- * @param {String} noteID
1201
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
1202
+ * @param {Object} opts Optional parameters
1203
+ * @param {Number} opts.pageSize (default to 50)
1204
+ * @param {Number} opts.pageNum (default to 1)
1205
+ * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
1206
+ * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
1207
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceSessions200Response} and HTTP response
1202
1208
  */
1203
1209
  }, {
1204
- key: "handleNoteDeleteWithHttpInfo",
1205
- value: function handleNoteDeleteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID) {
1210
+ key: "getDeviceSessionsWithHttpInfo",
1211
+ value: function getDeviceSessionsWithHttpInfo(projectOrProductUID, deviceUID, opts) {
1212
+ opts = opts || {};
1206
1213
  var postBody = null;
1207
1214
  // verify the required parameter 'projectOrProductUID' is set
1208
1215
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1209
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteDelete");
1216
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDeviceSessions");
1210
1217
  }
1211
1218
  // verify the required parameter 'deviceUID' is set
1212
1219
  if (deviceUID === undefined || deviceUID === null) {
1213
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteDelete");
1214
- }
1215
- // verify the required parameter 'notefileID' is set
1216
- if (notefileID === undefined || notefileID === null) {
1217
- throw new _Error["default"]("Missing the required parameter 'notefileID' when calling handleNoteDelete");
1218
- }
1219
- // verify the required parameter 'noteID' is set
1220
- if (noteID === undefined || noteID === null) {
1221
- throw new _Error["default"]("Missing the required parameter 'noteID' when calling handleNoteDelete");
1220
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getDeviceSessions");
1222
1221
  }
1223
1222
  var pathParams = {
1224
1223
  'projectOrProductUID': projectOrProductUID,
1225
- 'deviceUID': deviceUID,
1226
- 'notefileID': notefileID,
1227
- 'noteID': noteID
1224
+ 'deviceUID': deviceUID
1225
+ };
1226
+ var queryParams = {
1227
+ 'pageSize': opts['pageSize'],
1228
+ 'pageNum': opts['pageNum'],
1229
+ 'startDate': opts['startDate'],
1230
+ 'endDate': opts['endDate']
1228
1231
  };
1229
- var queryParams = {};
1230
1232
  var headerParams = {};
1231
1233
  var formParams = {};
1232
1234
  var authNames = ['personalAccessToken'];
1233
1235
  var contentTypes = [];
1234
1236
  var accepts = ['application/json'];
1235
- var returnType = null;
1236
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1237
+ var returnType = _GetDeviceSessions200Response["default"];
1238
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/sessions', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1237
1239
  }
1238
1240
 
1239
1241
  /**
1240
- * Delete a note from a DB notefile
1242
+ * Get Device Sessions
1241
1243
  * @param {String} projectOrProductUID
1242
1244
  * @param {String} deviceUID
1243
- * @param {String} notefileID
1244
- * @param {String} noteID
1245
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
1245
+ * @param {Object} opts Optional parameters
1246
+ * @param {Number} opts.pageSize (default to 50)
1247
+ * @param {Number} opts.pageNum (default to 1)
1248
+ * @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
1249
+ * @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
1250
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceSessions200Response}
1246
1251
  */
1247
1252
  }, {
1248
- key: "handleNoteDelete",
1249
- value: function handleNoteDelete(projectOrProductUID, deviceUID, notefileID, noteID) {
1250
- return this.handleNoteDeleteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID).then(function (response_and_data) {
1253
+ key: "getDeviceSessions",
1254
+ value: function getDeviceSessions(projectOrProductUID, deviceUID, opts) {
1255
+ return this.getDeviceSessionsWithHttpInfo(projectOrProductUID, deviceUID, opts).then(function (response_and_data) {
1251
1256
  return response_and_data.data;
1252
1257
  });
1253
1258
  }
1254
1259
 
1255
1260
  /**
1256
- * Get a note from a DB notefile
1261
+ * Get Devices of a Project
1257
1262
  * @param {String} projectOrProductUID
1258
- * @param {String} deviceUID
1259
- * @param {String} notefileID
1260
- * @param {String} noteID
1261
1263
  * @param {Object} opts Optional parameters
1262
- * @param {Boolean} opts._delete Whether to delete the note from the DB notefile
1263
- * @param {Boolean} opts.deleted Whether to return deleted notes
1264
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/HandleNoteGet200Response} and HTTP response
1264
+ * @param {Number} opts.pageSize (default to 50)
1265
+ * @param {Number} opts.pageNum (default to 1)
1266
+ * @param {Array.<String>} opts.deviceUID A Device UID.
1267
+ * @param {Array.<String>} opts.tag Tag filter
1268
+ * @param {Array.<String>} opts.serialNumber Serial number filter
1269
+ * @param {Array.<String>} opts.fleetUID
1270
+ * @param {Array.<String>} opts.notecardFirmware Firmware version filter
1271
+ * @param {Array.<String>} opts.location Location filter
1272
+ * @param {Array.<String>} opts.hostFirmware Host firmware filter
1273
+ * @param {Array.<String>} opts.productUID
1274
+ * @param {Array.<String>} opts.sku SKU filter
1275
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevices200Response} and HTTP response
1265
1276
  */
1266
1277
  }, {
1267
- key: "handleNoteGetWithHttpInfo",
1268
- value: function handleNoteGetWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, opts) {
1278
+ key: "getDevicesWithHttpInfo",
1279
+ value: function getDevicesWithHttpInfo(projectOrProductUID, opts) {
1269
1280
  opts = opts || {};
1270
1281
  var postBody = null;
1271
1282
  // verify the required parameter 'projectOrProductUID' is set
1272
1283
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1273
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteGet");
1274
- }
1275
- // verify the required parameter 'deviceUID' is set
1276
- if (deviceUID === undefined || deviceUID === null) {
1277
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteGet");
1278
- }
1279
- // verify the required parameter 'notefileID' is set
1280
- if (notefileID === undefined || notefileID === null) {
1281
- throw new _Error["default"]("Missing the required parameter 'notefileID' when calling handleNoteGet");
1282
- }
1283
- // verify the required parameter 'noteID' is set
1284
- if (noteID === undefined || noteID === null) {
1285
- throw new _Error["default"]("Missing the required parameter 'noteID' when calling handleNoteGet");
1284
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getDevices");
1286
1285
  }
1287
1286
  var pathParams = {
1288
- 'projectOrProductUID': projectOrProductUID,
1289
- 'deviceUID': deviceUID,
1290
- 'notefileID': notefileID,
1291
- 'noteID': noteID
1287
+ 'projectOrProductUID': projectOrProductUID
1292
1288
  };
1293
1289
  var queryParams = {
1294
- 'delete': opts['_delete'],
1295
- 'deleted': opts['deleted']
1290
+ 'pageSize': opts['pageSize'],
1291
+ 'pageNum': opts['pageNum'],
1292
+ 'deviceUID': this.apiClient.buildCollectionParam(opts['deviceUID'], 'multi'),
1293
+ 'tag': this.apiClient.buildCollectionParam(opts['tag'], 'multi'),
1294
+ 'serialNumber': this.apiClient.buildCollectionParam(opts['serialNumber'], 'multi'),
1295
+ 'fleetUID': this.apiClient.buildCollectionParam(opts['fleetUID'], 'multi'),
1296
+ 'notecardFirmware': this.apiClient.buildCollectionParam(opts['notecardFirmware'], 'multi'),
1297
+ 'location': this.apiClient.buildCollectionParam(opts['location'], 'multi'),
1298
+ 'hostFirmware': this.apiClient.buildCollectionParam(opts['hostFirmware'], 'multi'),
1299
+ 'productUID': this.apiClient.buildCollectionParam(opts['productUID'], 'multi'),
1300
+ 'sku': this.apiClient.buildCollectionParam(opts['sku'], 'multi')
1296
1301
  };
1297
1302
  var headerParams = {};
1298
1303
  var formParams = {};
1299
1304
  var authNames = ['personalAccessToken'];
1300
1305
  var contentTypes = [];
1301
1306
  var accepts = ['application/json'];
1302
- var returnType = _HandleNoteGet200Response["default"];
1303
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1307
+ var returnType = _GetDevices200Response["default"];
1308
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1304
1309
  }
1305
1310
 
1306
1311
  /**
1307
- * Get a note from a DB notefile
1312
+ * Get Devices of a Project
1308
1313
  * @param {String} projectOrProductUID
1309
- * @param {String} deviceUID
1310
- * @param {String} notefileID
1311
- * @param {String} noteID
1312
1314
  * @param {Object} opts Optional parameters
1313
- * @param {Boolean} opts._delete Whether to delete the note from the DB notefile
1314
- * @param {Boolean} opts.deleted Whether to return deleted notes
1315
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/HandleNoteGet200Response}
1315
+ * @param {Number} opts.pageSize (default to 50)
1316
+ * @param {Number} opts.pageNum (default to 1)
1317
+ * @param {Array.<String>} opts.deviceUID A Device UID.
1318
+ * @param {Array.<String>} opts.tag Tag filter
1319
+ * @param {Array.<String>} opts.serialNumber Serial number filter
1320
+ * @param {Array.<String>} opts.fleetUID
1321
+ * @param {Array.<String>} opts.notecardFirmware Firmware version filter
1322
+ * @param {Array.<String>} opts.location Location filter
1323
+ * @param {Array.<String>} opts.hostFirmware Host firmware filter
1324
+ * @param {Array.<String>} opts.productUID
1325
+ * @param {Array.<String>} opts.sku SKU filter
1326
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevices200Response}
1316
1327
  */
1317
1328
  }, {
1318
- key: "handleNoteGet",
1319
- value: function handleNoteGet(projectOrProductUID, deviceUID, notefileID, noteID, opts) {
1320
- return this.handleNoteGetWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, opts).then(function (response_and_data) {
1329
+ key: "getDevices",
1330
+ value: function getDevices(projectOrProductUID, opts) {
1331
+ return this.getDevicesWithHttpInfo(projectOrProductUID, opts).then(function (response_and_data) {
1321
1332
  return response_and_data.data;
1322
1333
  });
1323
1334
  }
1324
1335
 
1325
1336
  /**
1326
- * Send a signal from Notehub to a Notecard.
1337
+ * Get Devices of a Fleet within a Project
1327
1338
  * @param {String} projectOrProductUID
1328
- * @param {String} deviceUID
1329
- * @param {module:model/Body} body Body or payload of singnal to be sent to the device
1330
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/HandleNoteSignal200Response} and HTTP response
1339
+ * @param {String} fleetUID
1340
+ * @param {Object} opts Optional parameters
1341
+ * @param {Number} opts.pageSize (default to 50)
1342
+ * @param {Number} opts.pageNum (default to 1)
1343
+ * @param {Array.<String>} opts.deviceUID A Device UID.
1344
+ * @param {Array.<String>} opts.tag Tag filter
1345
+ * @param {Array.<String>} opts.serialNumber Serial number filter
1346
+ * @param {Array.<String>} opts.notecardFirmware Firmware version filter
1347
+ * @param {Array.<String>} opts.location Location filter
1348
+ * @param {Array.<String>} opts.hostFirmware Host firmware filter
1349
+ * @param {Array.<String>} opts.productUID
1350
+ * @param {Array.<String>} opts.sku SKU filter
1351
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevices200Response} and HTTP response
1331
1352
  */
1332
1353
  }, {
1333
- key: "handleNoteSignalWithHttpInfo",
1334
- value: function handleNoteSignalWithHttpInfo(projectOrProductUID, deviceUID, body) {
1335
- var postBody = body;
1354
+ key: "getFleetDevicesWithHttpInfo",
1355
+ value: function getFleetDevicesWithHttpInfo(projectOrProductUID, fleetUID, opts) {
1356
+ opts = opts || {};
1357
+ var postBody = null;
1336
1358
  // verify the required parameter 'projectOrProductUID' is set
1337
1359
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1338
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteSignal");
1339
- }
1340
- // verify the required parameter 'deviceUID' is set
1341
- if (deviceUID === undefined || deviceUID === null) {
1342
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteSignal");
1360
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getFleetDevices");
1343
1361
  }
1344
- // verify the required parameter 'body' is set
1345
- if (body === undefined || body === null) {
1346
- throw new _Error["default"]("Missing the required parameter 'body' when calling handleNoteSignal");
1362
+ // verify the required parameter 'fleetUID' is set
1363
+ if (fleetUID === undefined || fleetUID === null) {
1364
+ throw new _Error["default"]("Missing the required parameter 'fleetUID' when calling getFleetDevices");
1347
1365
  }
1348
1366
  var pathParams = {
1349
1367
  'projectOrProductUID': projectOrProductUID,
1350
- 'deviceUID': deviceUID
1368
+ 'fleetUID': fleetUID
1369
+ };
1370
+ var queryParams = {
1371
+ 'pageSize': opts['pageSize'],
1372
+ 'pageNum': opts['pageNum'],
1373
+ 'deviceUID': this.apiClient.buildCollectionParam(opts['deviceUID'], 'multi'),
1374
+ 'tag': this.apiClient.buildCollectionParam(opts['tag'], 'multi'),
1375
+ 'serialNumber': this.apiClient.buildCollectionParam(opts['serialNumber'], 'multi'),
1376
+ 'notecardFirmware': this.apiClient.buildCollectionParam(opts['notecardFirmware'], 'multi'),
1377
+ 'location': this.apiClient.buildCollectionParam(opts['location'], 'multi'),
1378
+ 'hostFirmware': this.apiClient.buildCollectionParam(opts['hostFirmware'], 'multi'),
1379
+ 'productUID': this.apiClient.buildCollectionParam(opts['productUID'], 'multi'),
1380
+ 'sku': this.apiClient.buildCollectionParam(opts['sku'], 'multi')
1351
1381
  };
1352
- var queryParams = {};
1353
1382
  var headerParams = {};
1354
1383
  var formParams = {};
1355
1384
  var authNames = ['personalAccessToken'];
1356
- var contentTypes = ['application/json'];
1385
+ var contentTypes = [];
1357
1386
  var accepts = ['application/json'];
1358
- var returnType = _HandleNoteSignal200Response["default"];
1359
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/signal', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1387
+ var returnType = _GetDevices200Response["default"];
1388
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/fleets/{fleetUID}/devices', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1360
1389
  }
1361
1390
 
1362
1391
  /**
1363
- * Send a signal from Notehub to a Notecard.
1392
+ * Get Devices of a Fleet within a Project
1364
1393
  * @param {String} projectOrProductUID
1365
- * @param {String} deviceUID
1366
- * @param {module:model/Body} body Body or payload of singnal to be sent to the device
1367
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/HandleNoteSignal200Response}
1394
+ * @param {String} fleetUID
1395
+ * @param {Object} opts Optional parameters
1396
+ * @param {Number} opts.pageSize (default to 50)
1397
+ * @param {Number} opts.pageNum (default to 1)
1398
+ * @param {Array.<String>} opts.deviceUID A Device UID.
1399
+ * @param {Array.<String>} opts.tag Tag filter
1400
+ * @param {Array.<String>} opts.serialNumber Serial number filter
1401
+ * @param {Array.<String>} opts.notecardFirmware Firmware version filter
1402
+ * @param {Array.<String>} opts.location Location filter
1403
+ * @param {Array.<String>} opts.hostFirmware Host firmware filter
1404
+ * @param {Array.<String>} opts.productUID
1405
+ * @param {Array.<String>} opts.sku SKU filter
1406
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevices200Response}
1368
1407
  */
1369
1408
  }, {
1370
- key: "handleNoteSignal",
1371
- value: function handleNoteSignal(projectOrProductUID, deviceUID, body) {
1372
- return this.handleNoteSignalWithHttpInfo(projectOrProductUID, deviceUID, body).then(function (response_and_data) {
1409
+ key: "getFleetDevices",
1410
+ value: function getFleetDevices(projectOrProductUID, fleetUID, opts) {
1411
+ return this.getFleetDevicesWithHttpInfo(projectOrProductUID, fleetUID, opts).then(function (response_and_data) {
1373
1412
  return response_and_data.data;
1374
1413
  });
1375
1414
  }
1376
1415
 
1377
1416
  /**
1378
- * Update a note in a DB notefile
1417
+ * For .qi files, returns the queued up notes. For .db files, returns all notes in the notefile
1379
1418
  * @param {String} projectOrProductUID
1380
1419
  * @param {String} deviceUID
1381
1420
  * @param {String} notefileID
1382
- * @param {String} noteID
1383
- * @param {module:model/Note} note Body or payload of note to be added to the device
1384
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
1421
+ * @param {Object} opts Optional parameters
1422
+ * @param {Number} opts.max The maximum number of Notes to return in the request.
1423
+ * @param {Boolean} opts.deleted true to return deleted notes.
1424
+ * @param {Boolean} opts._delete true to delete the notes returned by the request.
1425
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetNotefile200Response} and HTTP response
1385
1426
  */
1386
1427
  }, {
1387
- key: "handleNoteUpdateWithHttpInfo",
1388
- value: function handleNoteUpdateWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note) {
1389
- var postBody = note;
1428
+ key: "getNotefileWithHttpInfo",
1429
+ value: function getNotefileWithHttpInfo(projectOrProductUID, deviceUID, notefileID, opts) {
1430
+ opts = opts || {};
1431
+ var postBody = null;
1390
1432
  // verify the required parameter 'projectOrProductUID' is set
1391
1433
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1392
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNoteUpdate");
1434
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getNotefile");
1393
1435
  }
1394
1436
  // verify the required parameter 'deviceUID' is set
1395
1437
  if (deviceUID === undefined || deviceUID === null) {
1396
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNoteUpdate");
1438
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getNotefile");
1397
1439
  }
1398
1440
  // verify the required parameter 'notefileID' is set
1399
1441
  if (notefileID === undefined || notefileID === null) {
1400
- throw new _Error["default"]("Missing the required parameter 'notefileID' when calling handleNoteUpdate");
1401
- }
1402
- // verify the required parameter 'noteID' is set
1403
- if (noteID === undefined || noteID === null) {
1404
- throw new _Error["default"]("Missing the required parameter 'noteID' when calling handleNoteUpdate");
1405
- }
1406
- // verify the required parameter 'note' is set
1407
- if (note === undefined || note === null) {
1408
- throw new _Error["default"]("Missing the required parameter 'note' when calling handleNoteUpdate");
1442
+ throw new _Error["default"]("Missing the required parameter 'notefileID' when calling getNotefile");
1409
1443
  }
1410
1444
  var pathParams = {
1411
1445
  'projectOrProductUID': projectOrProductUID,
1412
1446
  'deviceUID': deviceUID,
1413
- 'notefileID': notefileID,
1414
- 'noteID': noteID
1447
+ 'notefileID': notefileID
1448
+ };
1449
+ var queryParams = {
1450
+ 'max': opts['max'],
1451
+ 'deleted': opts['deleted'],
1452
+ 'delete': opts['_delete']
1415
1453
  };
1416
- var queryParams = {};
1417
1454
  var headerParams = {};
1418
1455
  var formParams = {};
1419
1456
  var authNames = ['personalAccessToken'];
1420
- var contentTypes = ['application/json'];
1457
+ var contentTypes = [];
1421
1458
  var accepts = ['application/json'];
1422
- var returnType = null;
1423
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1459
+ var returnType = _GetNotefile200Response["default"];
1460
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1424
1461
  }
1425
1462
 
1426
1463
  /**
1427
- * Update a note in a DB notefile
1464
+ * For .qi files, returns the queued up notes. For .db files, returns all notes in the notefile
1428
1465
  * @param {String} projectOrProductUID
1429
1466
  * @param {String} deviceUID
1430
1467
  * @param {String} notefileID
1431
- * @param {String} noteID
1432
- * @param {module:model/Note} note Body or payload of note to be added to the device
1433
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
1468
+ * @param {Object} opts Optional parameters
1469
+ * @param {Number} opts.max The maximum number of Notes to return in the request.
1470
+ * @param {Boolean} opts.deleted true to return deleted notes.
1471
+ * @param {Boolean} opts._delete true to delete the notes returned by the request.
1472
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetNotefile200Response}
1434
1473
  */
1435
1474
  }, {
1436
- key: "handleNoteUpdate",
1437
- value: function handleNoteUpdate(projectOrProductUID, deviceUID, notefileID, noteID, note) {
1438
- return this.handleNoteUpdateWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note).then(function (response_and_data) {
1475
+ key: "getNotefile",
1476
+ value: function getNotefile(projectOrProductUID, deviceUID, notefileID, opts) {
1477
+ return this.getNotefileWithHttpInfo(projectOrProductUID, deviceUID, notefileID, opts).then(function (response_and_data) {
1439
1478
  return response_and_data.data;
1440
1479
  });
1441
1480
  }
1442
1481
 
1443
1482
  /**
1444
- * Used to perform queries on a single or multiple files to determine if new Notes are available to read
1483
+ * Get Notefile Templates
1445
1484
  * @param {String} projectOrProductUID
1446
1485
  * @param {String} deviceUID
1447
- * @param {Object} opts Optional parameters
1448
- * @param {Array.<String>} opts.files One or more files to obtain change information from.
1449
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/HandleNotefileChanges200Response} and HTTP response
1486
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/NotefileTemplate>} and HTTP response
1450
1487
  */
1451
1488
  }, {
1452
- key: "handleNotefileChangesWithHttpInfo",
1453
- value: function handleNotefileChangesWithHttpInfo(projectOrProductUID, deviceUID, opts) {
1454
- opts = opts || {};
1489
+ key: "getNotefileTemplatesWithHttpInfo",
1490
+ value: function getNotefileTemplatesWithHttpInfo(projectOrProductUID, deviceUID) {
1455
1491
  var postBody = null;
1456
1492
  // verify the required parameter 'projectOrProductUID' is set
1457
1493
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1458
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNotefileChanges");
1494
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getNotefileTemplates");
1459
1495
  }
1460
1496
  // verify the required parameter 'deviceUID' is set
1461
1497
  if (deviceUID === undefined || deviceUID === null) {
1462
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNotefileChanges");
1498
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling getNotefileTemplates");
1463
1499
  }
1464
1500
  var pathParams = {
1465
1501
  'projectOrProductUID': projectOrProductUID,
1466
1502
  'deviceUID': deviceUID
1467
1503
  };
1468
- var queryParams = {
1469
- 'files': this.apiClient.buildCollectionParam(opts['files'], 'multi')
1470
- };
1504
+ var queryParams = {};
1471
1505
  var headerParams = {};
1472
1506
  var formParams = {};
1473
1507
  var authNames = ['personalAccessToken'];
1474
1508
  var contentTypes = [];
1475
1509
  var accepts = ['application/json'];
1476
- var returnType = _HandleNotefileChanges200Response["default"];
1477
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files/changes', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1510
+ var returnType = [_NotefileTemplate["default"]];
1511
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files/templates', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1478
1512
  }
1479
1513
 
1480
1514
  /**
1481
- * Used to perform queries on a single or multiple files to determine if new Notes are available to read
1515
+ * Get Notefile Templates
1482
1516
  * @param {String} projectOrProductUID
1483
1517
  * @param {String} deviceUID
1484
- * @param {Object} opts Optional parameters
1485
- * @param {Array.<String>} opts.files One or more files to obtain change information from.
1486
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/HandleNotefileChanges200Response}
1518
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/NotefileTemplate>}
1487
1519
  */
1488
1520
  }, {
1489
- key: "handleNotefileChanges",
1490
- value: function handleNotefileChanges(projectOrProductUID, deviceUID, opts) {
1491
- return this.handleNotefileChangesWithHttpInfo(projectOrProductUID, deviceUID, opts).then(function (response_and_data) {
1521
+ key: "getNotefileTemplates",
1522
+ value: function getNotefileTemplates(projectOrProductUID, deviceUID) {
1523
+ return this.getNotefileTemplatesWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
1492
1524
  return response_and_data.data;
1493
1525
  });
1494
1526
  }
1495
1527
 
1496
1528
  /**
1497
- * Returns info about file changes that are pending upload to Notehub or download to the Notecard.
1529
+ * Lists .qi and .db files for the device
1498
1530
  * @param {String} projectOrProductUID
1499
1531
  * @param {String} deviceUID
1500
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/HandleNotefileChangesPending200Response} and HTTP response
1532
+ * @param {Object} opts Optional parameters
1533
+ * @param {Array.<String>} opts.files One or more files to obtain change information from.
1534
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/Notefile>} and HTTP response
1501
1535
  */
1502
1536
  }, {
1503
- key: "handleNotefileChangesPendingWithHttpInfo",
1504
- value: function handleNotefileChangesPendingWithHttpInfo(projectOrProductUID, deviceUID) {
1537
+ key: "listNotefilesWithHttpInfo",
1538
+ value: function listNotefilesWithHttpInfo(projectOrProductUID, deviceUID, opts) {
1539
+ opts = opts || {};
1505
1540
  var postBody = null;
1506
1541
  // verify the required parameter 'projectOrProductUID' is set
1507
1542
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1508
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNotefileChangesPending");
1543
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling listNotefiles");
1509
1544
  }
1510
1545
  // verify the required parameter 'deviceUID' is set
1511
1546
  if (deviceUID === undefined || deviceUID === null) {
1512
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNotefileChangesPending");
1547
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling listNotefiles");
1513
1548
  }
1514
1549
  var pathParams = {
1515
1550
  'projectOrProductUID': projectOrProductUID,
1516
1551
  'deviceUID': deviceUID
1517
1552
  };
1518
- var queryParams = {};
1553
+ var queryParams = {
1554
+ 'files': this.apiClient.buildCollectionParam(opts['files'], 'multi')
1555
+ };
1519
1556
  var headerParams = {};
1520
1557
  var formParams = {};
1521
1558
  var authNames = ['personalAccessToken'];
1522
1559
  var contentTypes = [];
1523
1560
  var accepts = ['application/json'];
1524
- var returnType = _HandleNotefileChangesPending200Response["default"];
1525
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files/changes/pending', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1561
+ var returnType = [_Notefile["default"]];
1562
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1526
1563
  }
1527
1564
 
1528
1565
  /**
1529
- * Returns info about file changes that are pending upload to Notehub or download to the Notecard.
1566
+ * Lists .qi and .db files for the device
1530
1567
  * @param {String} projectOrProductUID
1531
1568
  * @param {String} deviceUID
1532
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/HandleNotefileChangesPending200Response}
1569
+ * @param {Object} opts Optional parameters
1570
+ * @param {Array.<String>} opts.files One or more files to obtain change information from.
1571
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/Notefile>}
1533
1572
  */
1534
1573
  }, {
1535
- key: "handleNotefileChangesPending",
1536
- value: function handleNotefileChangesPending(projectOrProductUID, deviceUID) {
1537
- return this.handleNotefileChangesPendingWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
1574
+ key: "listNotefiles",
1575
+ value: function listNotefiles(projectOrProductUID, deviceUID, opts) {
1576
+ return this.listNotefilesWithHttpInfo(projectOrProductUID, deviceUID, opts).then(function (response_and_data) {
1538
1577
  return response_and_data.data;
1539
1578
  });
1540
1579
  }
1541
1580
 
1542
1581
  /**
1543
- * Deletes Notefiles and the Notes they contain.
1582
+ * Lists .qi and .db files that are pending sync to the Notecard
1544
1583
  * @param {String} projectOrProductUID
1545
1584
  * @param {String} deviceUID
1546
- * @param {module:model/HandleNotefileDeleteRequest} handleNotefileDeleteRequest
1547
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
1585
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListPendingNotefiles200Response} and HTTP response
1548
1586
  */
1549
1587
  }, {
1550
- key: "handleNotefileDeleteWithHttpInfo",
1551
- value: function handleNotefileDeleteWithHttpInfo(projectOrProductUID, deviceUID, handleNotefileDeleteRequest) {
1552
- var postBody = handleNotefileDeleteRequest;
1588
+ key: "listPendingNotefilesWithHttpInfo",
1589
+ value: function listPendingNotefilesWithHttpInfo(projectOrProductUID, deviceUID) {
1590
+ var postBody = null;
1553
1591
  // verify the required parameter 'projectOrProductUID' is set
1554
1592
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1555
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling handleNotefileDelete");
1593
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling listPendingNotefiles");
1556
1594
  }
1557
1595
  // verify the required parameter 'deviceUID' is set
1558
1596
  if (deviceUID === undefined || deviceUID === null) {
1559
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling handleNotefileDelete");
1560
- }
1561
- // verify the required parameter 'handleNotefileDeleteRequest' is set
1562
- if (handleNotefileDeleteRequest === undefined || handleNotefileDeleteRequest === null) {
1563
- throw new _Error["default"]("Missing the required parameter 'handleNotefileDeleteRequest' when calling handleNotefileDelete");
1597
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling listPendingNotefiles");
1564
1598
  }
1565
1599
  var pathParams = {
1566
1600
  'projectOrProductUID': projectOrProductUID,
@@ -1570,23 +1604,22 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
1570
1604
  var headerParams = {};
1571
1605
  var formParams = {};
1572
1606
  var authNames = ['personalAccessToken'];
1573
- var contentTypes = ['application/json'];
1607
+ var contentTypes = [];
1574
1608
  var accepts = ['application/json'];
1575
- var returnType = null;
1576
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1609
+ var returnType = _ListPendingNotefiles200Response["default"];
1610
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/files/changes/pending', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1577
1611
  }
1578
1612
 
1579
1613
  /**
1580
- * Deletes Notefiles and the Notes they contain.
1614
+ * Lists .qi and .db files that are pending sync to the Notecard
1581
1615
  * @param {String} projectOrProductUID
1582
1616
  * @param {String} deviceUID
1583
- * @param {module:model/HandleNotefileDeleteRequest} handleNotefileDeleteRequest
1584
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}
1617
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListPendingNotefiles200Response}
1585
1618
  */
1586
1619
  }, {
1587
- key: "handleNotefileDelete",
1588
- value: function handleNotefileDelete(projectOrProductUID, deviceUID, handleNotefileDeleteRequest) {
1589
- return this.handleNotefileDeleteWithHttpInfo(projectOrProductUID, deviceUID, handleNotefileDeleteRequest).then(function (response_and_data) {
1620
+ key: "listPendingNotefiles",
1621
+ value: function listPendingNotefiles(projectOrProductUID, deviceUID) {
1622
+ return this.listPendingNotefilesWithHttpInfo(projectOrProductUID, deviceUID).then(function (response_and_data) {
1590
1623
  return response_and_data.data;
1591
1624
  });
1592
1625
  }
@@ -1595,24 +1628,24 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
1595
1628
  * Provision Device for a Project
1596
1629
  * @param {String} projectOrProductUID
1597
1630
  * @param {String} deviceUID
1598
- * @param {module:model/PostProvisionProjectDeviceRequest} postProvisionProjectDeviceRequest Provision a device to a specific ProductUID
1631
+ * @param {module:model/ProvisionDeviceRequest} provisionDeviceRequest Provision a device to a specific ProductUID
1599
1632
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Object} and HTTP response
1600
1633
  */
1601
1634
  }, {
1602
- key: "postProvisionProjectDeviceWithHttpInfo",
1603
- value: function postProvisionProjectDeviceWithHttpInfo(projectOrProductUID, deviceUID, postProvisionProjectDeviceRequest) {
1604
- var postBody = postProvisionProjectDeviceRequest;
1635
+ key: "provisionDeviceWithHttpInfo",
1636
+ value: function provisionDeviceWithHttpInfo(projectOrProductUID, deviceUID, provisionDeviceRequest) {
1637
+ var postBody = provisionDeviceRequest;
1605
1638
  // verify the required parameter 'projectOrProductUID' is set
1606
1639
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1607
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling postProvisionProjectDevice");
1640
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling provisionDevice");
1608
1641
  }
1609
1642
  // verify the required parameter 'deviceUID' is set
1610
1643
  if (deviceUID === undefined || deviceUID === null) {
1611
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling postProvisionProjectDevice");
1644
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling provisionDevice");
1612
1645
  }
1613
- // verify the required parameter 'postProvisionProjectDeviceRequest' is set
1614
- if (postProvisionProjectDeviceRequest === undefined || postProvisionProjectDeviceRequest === null) {
1615
- throw new _Error["default"]("Missing the required parameter 'postProvisionProjectDeviceRequest' when calling postProvisionProjectDevice");
1646
+ // verify the required parameter 'provisionDeviceRequest' is set
1647
+ if (provisionDeviceRequest === undefined || provisionDeviceRequest === null) {
1648
+ throw new _Error["default"]("Missing the required parameter 'provisionDeviceRequest' when calling provisionDevice");
1616
1649
  }
1617
1650
  var pathParams = {
1618
1651
  'projectOrProductUID': projectOrProductUID,
@@ -1632,39 +1665,39 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
1632
1665
  * Provision Device for a Project
1633
1666
  * @param {String} projectOrProductUID
1634
1667
  * @param {String} deviceUID
1635
- * @param {module:model/PostProvisionProjectDeviceRequest} postProvisionProjectDeviceRequest Provision a device to a specific ProductUID
1668
+ * @param {module:model/ProvisionDeviceRequest} provisionDeviceRequest Provision a device to a specific ProductUID
1636
1669
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Object}
1637
1670
  */
1638
1671
  }, {
1639
- key: "postProvisionProjectDevice",
1640
- value: function postProvisionProjectDevice(projectOrProductUID, deviceUID, postProvisionProjectDeviceRequest) {
1641
- return this.postProvisionProjectDeviceWithHttpInfo(projectOrProductUID, deviceUID, postProvisionProjectDeviceRequest).then(function (response_and_data) {
1672
+ key: "provisionDevice",
1673
+ value: function provisionDevice(projectOrProductUID, deviceUID, provisionDeviceRequest) {
1674
+ return this.provisionDeviceWithHttpInfo(projectOrProductUID, deviceUID, provisionDeviceRequest).then(function (response_and_data) {
1642
1675
  return response_and_data.data;
1643
1676
  });
1644
1677
  }
1645
1678
 
1646
1679
  /**
1647
- * Put environment variables of a device
1680
+ * Send a signal from Notehub to a Notecard.
1648
1681
  * @param {String} projectOrProductUID
1649
1682
  * @param {String} deviceUID
1650
- * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
1651
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
1683
+ * @param {module:model/Body} body Body or payload of signal to be sent to the device
1684
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/SignalDevice200Response} and HTTP response
1652
1685
  */
1653
1686
  }, {
1654
- key: "putDeviceEnvironmentVariablesWithHttpInfo",
1655
- value: function putDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID, environmentVariables) {
1656
- var postBody = environmentVariables;
1687
+ key: "signalDeviceWithHttpInfo",
1688
+ value: function signalDeviceWithHttpInfo(projectOrProductUID, deviceUID, body) {
1689
+ var postBody = body;
1657
1690
  // verify the required parameter 'projectOrProductUID' is set
1658
1691
  if (projectOrProductUID === undefined || projectOrProductUID === null) {
1659
- throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling putDeviceEnvironmentVariables");
1692
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling signalDevice");
1660
1693
  }
1661
1694
  // verify the required parameter 'deviceUID' is set
1662
1695
  if (deviceUID === undefined || deviceUID === null) {
1663
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling putDeviceEnvironmentVariables");
1696
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling signalDevice");
1664
1697
  }
1665
- // verify the required parameter 'environmentVariables' is set
1666
- if (environmentVariables === undefined || environmentVariables === null) {
1667
- throw new _Error["default"]("Missing the required parameter 'environmentVariables' when calling putDeviceEnvironmentVariables");
1698
+ // verify the required parameter 'body' is set
1699
+ if (body === undefined || body === null) {
1700
+ throw new _Error["default"]("Missing the required parameter 'body' when calling signalDevice");
1668
1701
  }
1669
1702
  var pathParams = {
1670
1703
  'projectOrProductUID': projectOrProductUID,
@@ -1676,73 +1709,87 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
1676
1709
  var authNames = ['personalAccessToken'];
1677
1710
  var contentTypes = ['application/json'];
1678
1711
  var accepts = ['application/json'];
1679
- var returnType = _EnvironmentVariables["default"];
1680
- return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/environment_variables', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1712
+ var returnType = _SignalDevice200Response["default"];
1713
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/signal', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1681
1714
  }
1682
1715
 
1683
1716
  /**
1684
- * Put environment variables of a device
1717
+ * Send a signal from Notehub to a Notecard.
1685
1718
  * @param {String} projectOrProductUID
1686
1719
  * @param {String} deviceUID
1687
- * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
1688
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
1720
+ * @param {module:model/Body} body Body or payload of signal to be sent to the device
1721
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/SignalDevice200Response}
1689
1722
  */
1690
1723
  }, {
1691
- key: "putDeviceEnvironmentVariables",
1692
- value: function putDeviceEnvironmentVariables(projectOrProductUID, deviceUID, environmentVariables) {
1693
- return this.putDeviceEnvironmentVariablesWithHttpInfo(projectOrProductUID, deviceUID, environmentVariables).then(function (response_and_data) {
1724
+ key: "signalDevice",
1725
+ value: function signalDevice(projectOrProductUID, deviceUID, body) {
1726
+ return this.signalDeviceWithHttpInfo(projectOrProductUID, deviceUID, body).then(function (response_and_data) {
1694
1727
  return response_and_data.data;
1695
1728
  });
1696
1729
  }
1697
1730
 
1698
1731
  /**
1699
- * Put environment variables of a device with device pin authorization
1700
- * @param {String} productUID
1732
+ * Update a note in a .db or .qi notefile
1733
+ * @param {String} projectOrProductUID
1701
1734
  * @param {String} deviceUID
1702
- * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
1703
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
1735
+ * @param {String} notefileID
1736
+ * @param {String} noteID
1737
+ * @param {module:model/Note} note Body or payload of note to be added to the device
1738
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
1704
1739
  */
1705
1740
  }, {
1706
- key: "putDeviceEnvironmentVariablesByPinWithHttpInfo",
1707
- value: function putDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID, environmentVariables) {
1708
- var postBody = environmentVariables;
1709
- // verify the required parameter 'productUID' is set
1710
- if (productUID === undefined || productUID === null) {
1711
- throw new _Error["default"]("Missing the required parameter 'productUID' when calling putDeviceEnvironmentVariablesByPin");
1741
+ key: "updateDbNoteWithHttpInfo",
1742
+ value: function updateDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note) {
1743
+ var postBody = note;
1744
+ // verify the required parameter 'projectOrProductUID' is set
1745
+ if (projectOrProductUID === undefined || projectOrProductUID === null) {
1746
+ throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling updateDbNote");
1712
1747
  }
1713
1748
  // verify the required parameter 'deviceUID' is set
1714
1749
  if (deviceUID === undefined || deviceUID === null) {
1715
- throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling putDeviceEnvironmentVariablesByPin");
1750
+ throw new _Error["default"]("Missing the required parameter 'deviceUID' when calling updateDbNote");
1716
1751
  }
1717
- // verify the required parameter 'environmentVariables' is set
1718
- if (environmentVariables === undefined || environmentVariables === null) {
1719
- throw new _Error["default"]("Missing the required parameter 'environmentVariables' when calling putDeviceEnvironmentVariablesByPin");
1752
+ // verify the required parameter 'notefileID' is set
1753
+ if (notefileID === undefined || notefileID === null) {
1754
+ throw new _Error["default"]("Missing the required parameter 'notefileID' when calling updateDbNote");
1755
+ }
1756
+ // verify the required parameter 'noteID' is set
1757
+ if (noteID === undefined || noteID === null) {
1758
+ throw new _Error["default"]("Missing the required parameter 'noteID' when calling updateDbNote");
1759
+ }
1760
+ // verify the required parameter 'note' is set
1761
+ if (note === undefined || note === null) {
1762
+ throw new _Error["default"]("Missing the required parameter 'note' when calling updateDbNote");
1720
1763
  }
1721
1764
  var pathParams = {
1722
- 'productUID': productUID,
1723
- 'deviceUID': deviceUID
1765
+ 'projectOrProductUID': projectOrProductUID,
1766
+ 'deviceUID': deviceUID,
1767
+ 'notefileID': notefileID,
1768
+ 'noteID': noteID
1724
1769
  };
1725
1770
  var queryParams = {};
1726
1771
  var headerParams = {};
1727
1772
  var formParams = {};
1728
- var authNames = ['pin'];
1773
+ var authNames = ['personalAccessToken'];
1729
1774
  var contentTypes = ['application/json'];
1730
1775
  var accepts = ['application/json'];
1731
- var returnType = _EnvironmentVariables["default"];
1732
- return this.apiClient.callApi('/v1/products/{productUID}/devices/{deviceUID}/environment_variables_with_pin', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1776
+ var returnType = null;
1777
+ return this.apiClient.callApi('/v1/projects/{projectOrProductUID}/devices/{deviceUID}/notes/{notefileID}/{noteID}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1733
1778
  }
1734
1779
 
1735
1780
  /**
1736
- * Put environment variables of a device with device pin authorization
1737
- * @param {String} productUID
1781
+ * Update a note in a .db or .qi notefile
1782
+ * @param {String} projectOrProductUID
1738
1783
  * @param {String} deviceUID
1739
- * @param {module:model/EnvironmentVariables} environmentVariables Environment variables to be added to the device
1740
- * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
1784
+ * @param {String} notefileID
1785
+ * @param {String} noteID
1786
+ * @param {module:model/Note} note Body or payload of note to be added to the device
1787
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}
1741
1788
  */
1742
1789
  }, {
1743
- key: "putDeviceEnvironmentVariablesByPin",
1744
- value: function putDeviceEnvironmentVariablesByPin(productUID, deviceUID, environmentVariables) {
1745
- return this.putDeviceEnvironmentVariablesByPinWithHttpInfo(productUID, deviceUID, environmentVariables).then(function (response_and_data) {
1790
+ key: "updateDbNote",
1791
+ value: function updateDbNote(projectOrProductUID, deviceUID, notefileID, noteID, note) {
1792
+ return this.updateDbNoteWithHttpInfo(projectOrProductUID, deviceUID, notefileID, noteID, note).then(function (response_and_data) {
1746
1793
  return response_and_data.data;
1747
1794
  });
1748
1795
  }