@blues-inc/notehub-js 2.2.0-beta.23 → 2.2.0-beta.24

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