@blues-inc/notehub-js 6.7.0 → 7.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +156 -152
- package/dist/ApiClient.js +3 -3
- package/dist/api/AlertApi.js +17 -12
- package/dist/api/AuthorizationApi.js +12 -51
- package/dist/api/DescriptionApi.js +58 -42
- package/dist/api/DeviceApi.js +434 -291
- package/dist/api/EventApi.js +88 -221
- package/dist/api/ExternalDevicesApi.js +32 -26
- package/dist/api/JobsApi.js +76 -58
- package/dist/api/MonitorApi.js +38 -28
- package/dist/api/OrganizationApi.js +26 -20
- package/dist/api/ProjectApi.js +424 -330
- package/dist/api/RouteApi.js +69 -54
- package/dist/api/SkillsApi.js +279 -0
- package/dist/api/UsageApi.js +84 -74
- package/dist/api/WebhookApi.js +96 -74
- package/dist/index.js +91 -63
- package/dist/model/AWSRoleConfig.js +2 -2
- package/dist/model/AddDeviceToFleetsRequest.js +4 -4
- package/dist/model/Alert.js +17 -10
- package/dist/model/AlertDataInner.js +10 -5
- package/dist/model/AlertNotificationsInner.js +15 -5
- package/dist/model/ArchiveStats.js +2 -2
- package/dist/model/AwsRoute.js +15 -3
- package/dist/model/AzureRoute.js +9 -2
- package/dist/model/BatchJobNoteRequest.js +2 -2
- package/dist/model/BatchJobRequests.js +7 -6
- package/dist/model/BillingAccount.js +6 -4
- package/dist/model/BillingAccountRole.js +1 -1
- package/dist/model/BlynkRoute.js +7 -2
- package/dist/model/Body.js +3 -2
- package/dist/model/CancelJobRun200Response.js +2 -2
- package/dist/model/CellularPlan.js +4 -3
- package/dist/model/CloneProjectRequest.js +8 -8
- package/dist/model/Contact.js +6 -2
- package/dist/model/CreateFleetRequest.js +5 -4
- package/dist/model/CreateJob201Response.js +2 -2
- package/dist/model/CreateMonitor.js +38 -26
- package/dist/model/CreateProductRequest.js +8 -7
- package/dist/model/CreateProjectRequest.js +6 -6
- package/dist/model/CreateProjectSecretRequest.js +6 -6
- package/dist/model/CreateUpdateRepository.js +4 -2
- package/dist/model/CreatedRepository.js +6 -6
- package/dist/model/CurrentFirmware.js +2 -2
- package/dist/model/DFUEnv.js +2 -2
- package/dist/model/DFUState.js +3 -2
- package/dist/model/DataField.js +2 -2
- package/dist/model/DataSet.js +6 -5
- package/dist/model/DataSetField.js +3 -3
- package/dist/model/DataUsage.js +2 -2
- package/dist/model/DatacakeRoute.js +8 -2
- package/dist/model/DatasetReloadProgress.js +2 -2
- package/dist/model/DeleteDeviceFromFleetsRequest.js +4 -4
- package/dist/model/DeleteJob200Response.js +2 -2
- package/dist/model/DeleteNotefilesRequest.js +3 -3
- package/dist/model/DescriptionRecord.js +7 -7
- package/dist/model/DescriptionRecordList.js +4 -3
- package/dist/model/Device.js +37 -9
- package/dist/model/DeviceDfuHistory.js +13 -3
- package/dist/model/DeviceDfuHistoryCurrent.js +3 -3
- package/dist/model/DeviceDfuHistoryPage.js +17 -2
- package/dist/model/DeviceDfuStateMachine.js +3 -2
- package/dist/model/DeviceDfuStateMachineNode.js +3 -3
- package/dist/model/DeviceDfuStatus.js +13 -4
- package/dist/model/DeviceDfuStatusPage.js +17 -2
- package/dist/model/DeviceSensor.js +2 -2
- package/dist/model/DeviceSession.js +38 -6
- package/dist/model/DeviceTowerInfo.js +7 -2
- package/dist/model/DeviceUsage.js +8 -2
- package/dist/model/DfuActionRequest.js +3 -3
- package/dist/model/EmailNotification.js +30 -7
- package/dist/model/EnvTreeJsonNode.js +18 -7
- package/dist/model/EnvVar.js +6 -2
- package/dist/model/EnvironmentVariables.js +4 -3
- package/dist/model/Error.js +5 -2
- package/dist/model/Event.js +17 -8
- package/dist/model/Filter.js +6 -6
- package/dist/model/Firmware.js +2 -2
- package/dist/model/FirmwareInfo.js +7 -7
- package/dist/model/Fleet.js +12 -11
- package/dist/model/FleetConnectivityAssurance.js +2 -2
- package/dist/model/GetAlerts200Response.js +15 -2
- package/dist/model/GetApiUsage200Response.js +3 -3
- package/dist/model/GetDataUsage200Response.js +3 -3
- package/dist/model/GetDataUsage200ResponseDataInner.js +4 -4
- package/dist/model/GetDbNote200Response.js +2 -2
- package/dist/model/GetDeviceEnvironmentVariablesByPin200Response.js +2 -2
- package/dist/model/GetDeviceFleets200Response.js +2 -2
- package/dist/model/GetDeviceHealthLog200Response.js +2 -2
- package/dist/model/GetDeviceJourney200Response.js +2 -2
- package/dist/model/GetDeviceJourney200ResponseJourney.js +2 -2
- package/dist/model/GetDeviceJourneys200Response.js +2 -2
- package/dist/model/GetDeviceJourneys200ResponseJourneysInner.js +2 -2
- package/dist/model/GetDeviceLatestEvents200Response.js +3 -3
- package/dist/model/GetDevicePlans200Response.js +3 -2
- package/dist/model/GetDevicePublicKey200Response.js +6 -4
- package/dist/model/GetDevicePublicKeys200Response.js +15 -2
- package/dist/model/GetDevicePublicKeys200ResponseDevicePublicKeysInner.js +13 -2
- package/dist/model/GetDeviceSessions200Response.js +15 -2
- package/dist/model/GetDevices200Response.js +15 -2
- package/dist/model/GetEvents200Response.js +15 -2
- package/dist/model/GetJobRuns200Response.js +2 -2
- package/dist/model/GetJobs200Response.js +2 -2
- package/dist/model/GetNotefile200Response.js +2 -2
- package/dist/model/{GetBillingAccount200Response.js → GetOrganization200Response.js} +29 -29
- package/dist/model/{GetBillingAccount200ResponsePlan.js → GetOrganization200ResponsePlan.js} +25 -25
- package/dist/model/{GetBillingAccountBalanceHistory200Response.js → GetOrganizationBalanceHistory200Response.js} +23 -23
- package/dist/model/{GetBillingAccountBalanceHistory200ResponseDataInner.js → GetOrganizationBalanceHistory200ResponseDataInner.js} +23 -23
- package/dist/model/GetOrganizations200Response.js +2 -2
- package/dist/model/GetProducts200Response.js +2 -2
- package/dist/model/GetProjectMembers200Response.js +2 -2
- package/dist/model/GetProjectSecretsResponse.js +4 -3
- package/dist/model/GetProjects200Response.js +2 -2
- package/dist/model/GetRouteLogsUsage200Response.js +3 -3
- package/dist/model/GetSessionsUsage200Response.js +4 -4
- package/dist/model/GetWebhooks200Response.js +2 -2
- package/dist/model/GoogleRoute.js +7 -2
- package/dist/model/HealthLog.js +8 -5
- package/dist/model/HttpRoute.js +8 -3
- package/dist/model/Job.js +2 -2
- package/dist/model/JobDefinition.js +3 -3
- package/dist/model/JobDefinitionReportOptions.js +3 -2
- package/dist/model/JobDefinitionSelect.js +5 -4
- package/dist/model/JobDetail.js +2 -2
- package/dist/model/JobDetailAllOf.js +2 -2
- package/dist/model/JobRun.js +2 -2
- package/dist/model/Location.js +14 -8
- package/dist/model/Monitor.js +19 -13
- package/dist/model/MonitorAlertRoutesInner.js +61 -15
- package/dist/model/MqttRoute.js +15 -2
- package/dist/model/Note.js +3 -3
- package/dist/model/NoteInput.js +2 -2
- package/dist/model/Notefile.js +5 -3
- package/dist/model/NotefileSchema.js +6 -4
- package/dist/model/NotehubRoute.js +8 -4
- package/dist/model/NotehubRouteSummary.js +7 -2
- package/dist/model/OAuth2Error.js +2 -2
- package/dist/model/OAuth2TokenResponse.js +2 -2
- package/dist/model/Organization.js +6 -4
- package/dist/model/OrganizationRole.js +1 -1
- package/dist/model/Product.js +9 -5
- package/dist/model/Project.js +8 -5
- package/dist/model/ProjectMember.js +6 -5
- package/dist/model/ProjectSecret.js +8 -8
- package/dist/model/ProvisionDeviceRequest.js +6 -6
- package/dist/model/ProxyRoute.js +7 -2
- package/dist/model/QubitroRoute.js +8 -2
- package/dist/model/RadRoute.js +10 -2
- package/dist/model/Repository.js +4 -4
- package/dist/model/RepositoryListResponse.js +4 -3
- package/dist/model/RepositoryRecord.js +119 -0
- package/dist/model/RepositoryTokenRequest.js +2 -2
- package/dist/model/RepositoryTokenResponse.js +2 -2
- package/dist/model/Role.js +1 -1
- package/dist/model/RouteLog.js +10 -10
- package/dist/model/RouteTransformSettings.js +6 -6
- package/dist/model/RunJob200Response.js +2 -2
- package/dist/model/S3ArchiveRoute.js +17 -2
- package/dist/model/SatelliteDataUsage.js +2 -2
- package/dist/model/SatellitePlan.js +2 -2
- package/dist/model/SchemaProperty.js +7 -5
- package/dist/model/SignalDevice200Response.js +3 -3
- package/dist/model/SimUsage.js +2 -2
- package/dist/model/Skill.js +210 -0
- package/dist/model/{GetBillingAccounts200Response.js → SkillLinks.js} +60 -41
- package/dist/model/SkillSet.js +185 -0
- package/dist/model/SkillSummary.js +208 -0
- package/dist/model/SkillWrite.js +128 -0
- package/dist/model/{GetEventsByCursor200Response.js → SkillWriteResult.js} +62 -65
- package/dist/model/SlackBearerNotification.js +32 -9
- package/dist/model/SlackRoute.js +10 -2
- package/dist/model/SlackWebHookNotification.js +32 -9
- package/dist/model/SnowflakeRoute.js +10 -2
- package/dist/model/SnowpipeStreamingRoute.js +13 -2
- package/dist/model/ThingworxRoute.js +7 -2
- package/dist/model/TowerLocation.js +2 -2
- package/dist/model/TwilioNotification.js +167 -0
- package/dist/model/TwilioRoute.js +10 -2
- package/dist/model/UpdateFleetRequest.js +8 -7
- package/dist/model/UpdateHostFirmwareRequest.js +5 -5
- package/dist/model/UpdateProjectSecretRequest.js +4 -4
- package/dist/model/UploadMetadata.js +2 -2
- package/dist/model/UsageApiData.js +4 -3
- package/dist/model/UsageData.js +8 -4
- package/dist/model/UsageEventsData.js +6 -3
- package/dist/model/UsageEventsResponse.js +5 -4
- package/dist/model/UsageRouteLogsData.js +11 -7
- package/dist/model/UsageSessionsData.js +12 -6
- package/dist/model/UserDfuStateMachine.js +2 -2
- package/dist/model/UserDfuStateMachineStatus.js +2 -2
- package/dist/model/UserFirmwareInfo.js +2 -2
- package/dist/model/WebhookSettings.js +5 -5
- package/package.json +1 -1
- package/dist/api/BillingAccountApi.js +0 -167
- package/dist/model/Login200Response.js +0 -91
- package/dist/model/LoginRequest.js +0 -103
package/dist/api/DeviceApi.js
CHANGED
|
@@ -33,7 +33,7 @@ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Can
|
|
|
33
33
|
function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
|
|
34
34
|
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
35
35
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
36
|
-
function _toPrimitive(t,
|
|
36
|
+
function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r; if ("undefined" != typeof Symbol && void 0 !== (r = t[Symbol.toPrimitive])) { var i = r.call(t, e || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === e ? String : Number)(t); } /**
|
|
37
37
|
* Notehub API
|
|
38
38
|
* The OpenAPI definition for the Notehub.io API.
|
|
39
39
|
*
|
|
@@ -48,7 +48,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
48
48
|
/**
|
|
49
49
|
* Device service.
|
|
50
50
|
* @module api/DeviceApi
|
|
51
|
-
* @version
|
|
51
|
+
* @version 7.0.0-beta.1
|
|
52
52
|
*/
|
|
53
53
|
var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
54
54
|
/**
|
|
@@ -64,11 +64,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
64
64
|
}
|
|
65
65
|
|
|
66
66
|
/**
|
|
67
|
-
* Add a
|
|
68
|
-
*
|
|
69
|
-
* @param {String}
|
|
70
|
-
* @param {String}
|
|
71
|
-
* @param {String}
|
|
67
|
+
* Add a note to a .db notefile
|
|
68
|
+
* Add a note with the given ID to a database notefile on a device, synced to the Notecard on its next sync. To change an existing note, use `UpdateDbNote`; to queue a note in a `.qi` notefile, use `AddQiNote`. Requires the Owner or Developer role. Returns 400 unless the notefile ends in `.db` or `.dbs`, or if `payload` isn't valid base64.
|
|
69
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
70
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
71
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
72
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
72
73
|
* @param {module:model/NoteInput} noteInput Body or payload of note to be added to the device
|
|
73
74
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
74
75
|
*/
|
|
@@ -113,11 +114,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
113
114
|
}
|
|
114
115
|
|
|
115
116
|
/**
|
|
116
|
-
* Add a
|
|
117
|
-
*
|
|
118
|
-
* @param {String}
|
|
119
|
-
* @param {String}
|
|
120
|
-
* @param {String}
|
|
117
|
+
* Add a note to a .db notefile
|
|
118
|
+
* Add a note with the given ID to a database notefile on a device, synced to the Notecard on its next sync. To change an existing note, use `UpdateDbNote`; to queue a note in a `.qi` notefile, use `AddQiNote`. Requires the Owner or Developer role. Returns 400 unless the notefile ends in `.db` or `.dbs`, or if `payload` isn't valid base64.
|
|
119
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
120
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
121
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
122
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
121
123
|
* @param {module:model/NoteInput} noteInput Body or payload of note to be added to the device
|
|
122
124
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
123
125
|
*/
|
|
@@ -130,10 +132,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
130
132
|
}
|
|
131
133
|
|
|
132
134
|
/**
|
|
133
|
-
*
|
|
134
|
-
*
|
|
135
|
-
* @param {String}
|
|
136
|
-
* @param {String}
|
|
135
|
+
* Queue a note for a Notecard
|
|
136
|
+
* Add a note to an inbound queue (`.qi`) notefile on a device, creating the notefile if needed. The Notecard receives it on its next sync. For a `.db` notefile, use `AddDbNote`; to reach a connected Notecard immediately, use `SignalDevice`. Requires the Owner or Developer role. Returns 400 unless the notefile ends in `.qi` or `.qis`, or if `payload` isn't valid base64.
|
|
137
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
138
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
139
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
137
140
|
* @param {module:model/NoteInput} noteInput Body or payload of note to be added to the device
|
|
138
141
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
139
142
|
*/
|
|
@@ -173,10 +176,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
173
176
|
}
|
|
174
177
|
|
|
175
178
|
/**
|
|
176
|
-
*
|
|
177
|
-
*
|
|
178
|
-
* @param {String}
|
|
179
|
-
* @param {String}
|
|
179
|
+
* Queue a note for a Notecard
|
|
180
|
+
* Add a note to an inbound queue (`.qi`) notefile on a device, creating the notefile if needed. The Notecard receives it on its next sync. For a `.db` notefile, use `AddDbNote`; to reach a connected Notecard immediately, use `SignalDevice`. Requires the Owner or Developer role. Returns 400 unless the notefile ends in `.qi` or `.qis`, or if `payload` isn't valid base64.
|
|
181
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
182
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
183
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
180
184
|
* @param {module:model/NoteInput} noteInput Body or payload of note to be added to the device
|
|
181
185
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
182
186
|
*/
|
|
@@ -189,10 +193,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
189
193
|
}
|
|
190
194
|
|
|
191
195
|
/**
|
|
192
|
-
*
|
|
193
|
-
*
|
|
194
|
-
* @param {String}
|
|
195
|
-
* @param {String}
|
|
196
|
+
* Create an empty notefile
|
|
197
|
+
* Create an empty notefile on a device. `AddQiNote` creates a notefile when needed, so this is only required for an empty one. Requires the Owner or Developer role. Returns 400 if the notefile already exists.
|
|
198
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
199
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
200
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
196
201
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
197
202
|
*/
|
|
198
203
|
}, {
|
|
@@ -227,10 +232,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
227
232
|
}
|
|
228
233
|
|
|
229
234
|
/**
|
|
230
|
-
*
|
|
231
|
-
*
|
|
232
|
-
* @param {String}
|
|
233
|
-
* @param {String}
|
|
235
|
+
* Create an empty notefile
|
|
236
|
+
* Create an empty notefile on a device. `AddQiNote` creates a notefile when needed, so this is only required for an empty one. Requires the Owner or Developer role. Returns 400 if the notefile already exists.
|
|
237
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
238
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
239
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
234
240
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
235
241
|
*/
|
|
236
242
|
}, {
|
|
@@ -242,9 +248,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
242
248
|
}
|
|
243
249
|
|
|
244
250
|
/**
|
|
245
|
-
* Delete
|
|
246
|
-
*
|
|
247
|
-
* @param {String}
|
|
251
|
+
* Delete a device
|
|
252
|
+
* Delete a device and its notefiles from a project. Its events are kept. A Notecard that syncs again is added back as a new device; to block it instead, use `DisableDevice`. Requires the Owner or Developer role.
|
|
253
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
254
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
248
255
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
249
256
|
*/
|
|
250
257
|
}, {
|
|
@@ -274,9 +281,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
274
281
|
}
|
|
275
282
|
|
|
276
283
|
/**
|
|
277
|
-
* Delete
|
|
278
|
-
*
|
|
279
|
-
* @param {String}
|
|
284
|
+
* Delete a device
|
|
285
|
+
* Delete a device and its notefiles from a project. Its events are kept. A Notecard that syncs again is added back as a new device; to block it instead, use `DisableDevice`. Requires the Owner or Developer role.
|
|
286
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
287
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
280
288
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
281
289
|
*/
|
|
282
290
|
}, {
|
|
@@ -288,9 +296,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
288
296
|
}
|
|
289
297
|
|
|
290
298
|
/**
|
|
291
|
-
* Delete environment variable
|
|
292
|
-
*
|
|
293
|
-
* @param {String}
|
|
299
|
+
* Delete a device environment variable
|
|
300
|
+
* Delete one device environment variable and return the ones left. Fleet and project variables with the same name then apply. Deleting a variable that doesn't exist succeeds. Requires the Owner or Developer role.
|
|
301
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
302
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
294
303
|
* @param {String} key The environment variable key to delete.
|
|
295
304
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
|
|
296
305
|
*/
|
|
@@ -326,9 +335,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
326
335
|
}
|
|
327
336
|
|
|
328
337
|
/**
|
|
329
|
-
* Delete environment variable
|
|
330
|
-
*
|
|
331
|
-
* @param {String}
|
|
338
|
+
* Delete a device environment variable
|
|
339
|
+
* Delete one device environment variable and return the ones left. Fleet and project variables with the same name then apply. Deleting a variable that doesn't exist succeeds. Requires the Owner or Developer role.
|
|
340
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
341
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
332
342
|
* @param {String} key The environment variable key to delete.
|
|
333
343
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
|
|
334
344
|
*/
|
|
@@ -341,11 +351,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
341
351
|
}
|
|
342
352
|
|
|
343
353
|
/**
|
|
344
|
-
* Delete a note
|
|
345
|
-
*
|
|
346
|
-
* @param {String}
|
|
347
|
-
* @param {String}
|
|
348
|
-
* @param {String}
|
|
354
|
+
* Delete a note
|
|
355
|
+
* Delete one note from a notefile on a device. To delete whole notefiles, use `DeleteNotefiles`. Requires the Owner or Developer role.
|
|
356
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
357
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
358
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
359
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
349
360
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
350
361
|
*/
|
|
351
362
|
}, {
|
|
@@ -385,11 +396,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
385
396
|
}
|
|
386
397
|
|
|
387
398
|
/**
|
|
388
|
-
* Delete a note
|
|
389
|
-
*
|
|
390
|
-
* @param {String}
|
|
391
|
-
* @param {String}
|
|
392
|
-
* @param {String}
|
|
399
|
+
* Delete a note
|
|
400
|
+
* Delete one note from a notefile on a device. To delete whole notefiles, use `DeleteNotefiles`. Requires the Owner or Developer role.
|
|
401
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
402
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
403
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
404
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
393
405
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
394
406
|
*/
|
|
395
407
|
}, {
|
|
@@ -401,10 +413,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
401
413
|
}
|
|
402
414
|
|
|
403
415
|
/**
|
|
404
|
-
*
|
|
405
|
-
*
|
|
406
|
-
* @param {String}
|
|
407
|
-
* @param {
|
|
416
|
+
* Delete notefiles
|
|
417
|
+
* Delete notefiles and all their notes from a device. To delete one note, use `DeleteNote`. Requires the Owner or Developer role. Returns 400 if `files` is empty.
|
|
418
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
419
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
420
|
+
* @param {module:model/DeleteNotefilesRequest} deleteNotefilesRequest The notefiles to delete.
|
|
408
421
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
409
422
|
*/
|
|
410
423
|
}, {
|
|
@@ -438,10 +451,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
438
451
|
}
|
|
439
452
|
|
|
440
453
|
/**
|
|
441
|
-
*
|
|
442
|
-
*
|
|
443
|
-
* @param {String}
|
|
444
|
-
* @param {
|
|
454
|
+
* Delete notefiles
|
|
455
|
+
* Delete notefiles and all their notes from a device. To delete one note, use `DeleteNote`. Requires the Owner or Developer role. Returns 400 if `files` is empty.
|
|
456
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
457
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
458
|
+
* @param {module:model/DeleteNotefilesRequest} deleteNotefilesRequest The notefiles to delete.
|
|
445
459
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
446
460
|
*/
|
|
447
461
|
}, {
|
|
@@ -453,9 +467,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
453
467
|
}
|
|
454
468
|
|
|
455
469
|
/**
|
|
456
|
-
* Disable
|
|
457
|
-
*
|
|
458
|
-
* @param {String}
|
|
470
|
+
* Disable a device
|
|
471
|
+
* Stop a device from connecting to Notehub, ending any open session. The device and its data stay in the project; undo with `EnableDevice`. Does nothing if it's already disabled. Requires the Owner or Developer role.
|
|
472
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
473
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
459
474
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
460
475
|
*/
|
|
461
476
|
}, {
|
|
@@ -485,9 +500,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
485
500
|
}
|
|
486
501
|
|
|
487
502
|
/**
|
|
488
|
-
* Disable
|
|
489
|
-
*
|
|
490
|
-
* @param {String}
|
|
503
|
+
* Disable a device
|
|
504
|
+
* Stop a device from connecting to Notehub, ending any open session. The device and its data stay in the project; undo with `EnableDevice`. Does nothing if it's already disabled. Requires the Owner or Developer role.
|
|
505
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
506
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
491
507
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
492
508
|
*/
|
|
493
509
|
}, {
|
|
@@ -499,9 +515,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
499
515
|
}
|
|
500
516
|
|
|
501
517
|
/**
|
|
502
|
-
* Enable
|
|
503
|
-
*
|
|
504
|
-
* @param {String}
|
|
518
|
+
* Enable a device
|
|
519
|
+
* Re-enable a device turned off with `DisableDevice`, so it can connect to Notehub again. Does nothing if the device is already enabled. Requires the Owner or Developer role. Returns 409 if the device's cellular service was deactivated; it must be reactivated instead.
|
|
520
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
521
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
505
522
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
506
523
|
*/
|
|
507
524
|
}, {
|
|
@@ -531,9 +548,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
531
548
|
}
|
|
532
549
|
|
|
533
550
|
/**
|
|
534
|
-
* Enable
|
|
535
|
-
*
|
|
536
|
-
* @param {String}
|
|
551
|
+
* Enable a device
|
|
552
|
+
* Re-enable a device turned off with `DisableDevice`, so it can connect to Notehub again. Does nothing if the device is already enabled. Requires the Owner or Developer role. Returns 409 if the device's cellular service was deactivated; it must be reactivated instead.
|
|
553
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
554
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
537
555
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
538
556
|
*/
|
|
539
557
|
}, {
|
|
@@ -545,14 +563,15 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
545
563
|
}
|
|
546
564
|
|
|
547
565
|
/**
|
|
548
|
-
* Get a note
|
|
549
|
-
*
|
|
550
|
-
* @param {String}
|
|
551
|
-
* @param {String}
|
|
552
|
-
* @param {String}
|
|
566
|
+
* Get a note
|
|
567
|
+
* Get one note's body, payload and time from a notefile on a device. To get every note in a notefile, use `GetNotefile`. With `delete=true`, the note is deleted after it is read, which requires the Owner or Developer role.
|
|
568
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
569
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
570
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
571
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
553
572
|
* @param {Object} opts Optional parameters
|
|
554
|
-
* @param {Boolean} opts._delete
|
|
555
|
-
* @param {Boolean} opts.deleted
|
|
573
|
+
* @param {Boolean} opts._delete If true, delete the note after returning it. Requires the Owner or Developer role.
|
|
574
|
+
* @param {Boolean} opts.deleted If true, also return the note if it has been deleted.
|
|
556
575
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDbNote200Response} and HTTP response
|
|
557
576
|
*/
|
|
558
577
|
}, {
|
|
@@ -596,14 +615,15 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
596
615
|
}
|
|
597
616
|
|
|
598
617
|
/**
|
|
599
|
-
* Get a note
|
|
600
|
-
*
|
|
601
|
-
* @param {String}
|
|
602
|
-
* @param {String}
|
|
603
|
-
* @param {String}
|
|
618
|
+
* Get a note
|
|
619
|
+
* Get one note's body, payload and time from a notefile on a device. To get every note in a notefile, use `GetNotefile`. With `delete=true`, the note is deleted after it is read, which requires the Owner or Developer role.
|
|
620
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
621
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
622
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
623
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
604
624
|
* @param {Object} opts Optional parameters
|
|
605
|
-
* @param {Boolean} opts._delete
|
|
606
|
-
* @param {Boolean} opts.deleted
|
|
625
|
+
* @param {Boolean} opts._delete If true, delete the note after returning it. Requires the Owner or Developer role.
|
|
626
|
+
* @param {Boolean} opts.deleted If true, also return the note if it has been deleted.
|
|
607
627
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDbNote200Response}
|
|
608
628
|
*/
|
|
609
629
|
}, {
|
|
@@ -615,9 +635,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
615
635
|
}
|
|
616
636
|
|
|
617
637
|
/**
|
|
618
|
-
* Get
|
|
619
|
-
*
|
|
620
|
-
* @param {String}
|
|
638
|
+
* Get a device
|
|
639
|
+
* Get one device's details: serial number, product, fleets, locations, firmware versions, SIM usage and DFU state. To find devices by tag, serial number or other fields, use `GetDevices`.
|
|
640
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
641
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
621
642
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/Device} and HTTP response
|
|
622
643
|
*/
|
|
623
644
|
}, {
|
|
@@ -647,9 +668,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
647
668
|
}
|
|
648
669
|
|
|
649
670
|
/**
|
|
650
|
-
* Get
|
|
651
|
-
*
|
|
652
|
-
* @param {String}
|
|
671
|
+
* Get a device
|
|
672
|
+
* Get one device's details: serial number, product, fleets, locations, firmware versions, SIM usage and DFU state. To find devices by tag, serial number or other fields, use `GetDevices`.
|
|
673
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
674
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
653
675
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/Device}
|
|
654
676
|
*/
|
|
655
677
|
}, {
|
|
@@ -661,9 +683,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
661
683
|
}
|
|
662
684
|
|
|
663
685
|
/**
|
|
664
|
-
* Get environment
|
|
665
|
-
*
|
|
666
|
-
* @param {String}
|
|
686
|
+
* Get a device's environment hierarchy
|
|
687
|
+
* Get a device's environment variables and the fleet and project variables it inherits, as a tree. Each variable has its precedence and whether it is used or overridden. For just the resolved values, use `GetDeviceEnvironmentVariables`.
|
|
688
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
689
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
667
690
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvTreeJsonNode} and HTTP response
|
|
668
691
|
*/
|
|
669
692
|
}, {
|
|
@@ -693,9 +716,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
693
716
|
}
|
|
694
717
|
|
|
695
718
|
/**
|
|
696
|
-
* Get environment
|
|
697
|
-
*
|
|
698
|
-
* @param {String}
|
|
719
|
+
* Get a device's environment hierarchy
|
|
720
|
+
* Get a device's environment variables and the fleet and project variables it inherits, as a tree. Each variable has its precedence and whether it is used or overridden. For just the resolved values, use `GetDeviceEnvironmentVariables`.
|
|
721
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
722
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
699
723
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvTreeJsonNode}
|
|
700
724
|
*/
|
|
701
725
|
}, {
|
|
@@ -707,9 +731,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
707
731
|
}
|
|
708
732
|
|
|
709
733
|
/**
|
|
710
|
-
* Get environment variables
|
|
711
|
-
*
|
|
712
|
-
* @param {String}
|
|
734
|
+
* Get device environment variables
|
|
735
|
+
* Get a device's own environment variables, its `env.default` values, and its effective values. Effective values merge in project and fleet variables, which device variables override. To see where each value comes from, use `GetDeviceEnvironmentHierarchy`.
|
|
736
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
737
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
713
738
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response} and HTTP response
|
|
714
739
|
*/
|
|
715
740
|
}, {
|
|
@@ -739,9 +764,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
739
764
|
}
|
|
740
765
|
|
|
741
766
|
/**
|
|
742
|
-
* Get environment variables
|
|
743
|
-
*
|
|
744
|
-
* @param {String}
|
|
767
|
+
* Get device environment variables
|
|
768
|
+
* Get a device's own environment variables, its `env.default` values, and its effective values. Effective values merge in project and fleet variables, which device variables override. To see where each value comes from, use `GetDeviceEnvironmentHierarchy`.
|
|
769
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
770
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
745
771
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response}
|
|
746
772
|
*/
|
|
747
773
|
}, {
|
|
@@ -753,10 +779,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
753
779
|
}
|
|
754
780
|
|
|
755
781
|
/**
|
|
756
|
-
* Get environment variables
|
|
757
|
-
*
|
|
758
|
-
* @param {String}
|
|
759
|
-
* @param {String}
|
|
782
|
+
* Get device environment variables using a PIN
|
|
783
|
+
* Get a device's environment variables using its PIN instead of an API token. Pass the PIN in `X-Auth-Token`. Made for device dashboard pages; with a token, use `GetDeviceEnvironmentVariables`, which also returns effective values. Returns 401 if the project's device dashboard URL has no `[pin]`, or the PIN is wrong.
|
|
784
|
+
* @param {String} productUID ProductUID, e.g. `com.blues.bridge:sensors`. List with `GetProducts`.
|
|
785
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
786
|
+
* @param {String} xAuthToken The device's PIN, used instead of an API token.
|
|
760
787
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response} and HTTP response
|
|
761
788
|
*/
|
|
762
789
|
}, {
|
|
@@ -792,10 +819,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
792
819
|
}
|
|
793
820
|
|
|
794
821
|
/**
|
|
795
|
-
* Get environment variables
|
|
796
|
-
*
|
|
797
|
-
* @param {String}
|
|
798
|
-
* @param {String}
|
|
822
|
+
* Get device environment variables using a PIN
|
|
823
|
+
* Get a device's environment variables using its PIN instead of an API token. Pass the PIN in `X-Auth-Token`. Made for device dashboard pages; with a token, use `GetDeviceEnvironmentVariables`, which also returns effective values. Returns 401 if the project's device dashboard URL has no `[pin]`, or the PIN is wrong.
|
|
824
|
+
* @param {String} productUID ProductUID, e.g. `com.blues.bridge:sensors`. List with `GetProducts`.
|
|
825
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
826
|
+
* @param {String} xAuthToken The device's PIN, used instead of an API token.
|
|
799
827
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceEnvironmentVariablesByPin200Response}
|
|
800
828
|
*/
|
|
801
829
|
}, {
|
|
@@ -807,13 +835,14 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
807
835
|
}
|
|
808
836
|
|
|
809
837
|
/**
|
|
810
|
-
* Get
|
|
811
|
-
*
|
|
812
|
-
* @param {String}
|
|
838
|
+
* Get a device's health log
|
|
839
|
+
* Get a device's health log: timestamped status messages such as restarts and completed firmware updates. Only the latest 100 entries are kept. To filter by date, pass both `startDate` and `endDate`; `startDate` alone returns 400, and the same value for both returns every entry.
|
|
840
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
841
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
813
842
|
* @param {Object} opts Optional parameters
|
|
814
843
|
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
815
844
|
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
816
|
-
* @param {Array.<module:model/String>} opts.logType Return only
|
|
845
|
+
* @param {Array.<module:model/String>} opts.logType Return only these kinds of entry. If omitted, all entries are returned. - `boot`: the device restarted - `dfu_completed`: a host firmware update finished
|
|
817
846
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceHealthLog200Response} and HTTP response
|
|
818
847
|
*/
|
|
819
848
|
}, {
|
|
@@ -848,13 +877,14 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
848
877
|
}
|
|
849
878
|
|
|
850
879
|
/**
|
|
851
|
-
* Get
|
|
852
|
-
*
|
|
853
|
-
* @param {String}
|
|
880
|
+
* Get a device's health log
|
|
881
|
+
* Get a device's health log: timestamped status messages such as restarts and completed firmware updates. Only the latest 100 entries are kept. To filter by date, pass both `startDate` and `endDate`; `startDate` alone returns 400, and the same value for both returns every entry.
|
|
882
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
883
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
854
884
|
* @param {Object} opts Optional parameters
|
|
855
885
|
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
856
886
|
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
857
|
-
* @param {Array.<module:model/String>} opts.logType Return only
|
|
887
|
+
* @param {Array.<module:model/String>} opts.logType Return only these kinds of entry. If omitted, all entries are returned. - `boot`: the device restarted - `dfu_completed`: a host firmware update finished
|
|
858
888
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceHealthLog200Response}
|
|
859
889
|
*/
|
|
860
890
|
}, {
|
|
@@ -866,13 +896,14 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
866
896
|
}
|
|
867
897
|
|
|
868
898
|
/**
|
|
869
|
-
* Get a
|
|
870
|
-
*
|
|
871
|
-
* @param {String}
|
|
899
|
+
* Get a journey and its events
|
|
900
|
+
* Get one journey's start and end time and its events, oldest first. Only events with a location are included, and a run of events at the same location is reduced to the first. The events are paginated; `journey.has_more` is true if there are more. Returns 404 if the journey doesn't exist, and 403 if the organization is suspended.
|
|
901
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
902
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
872
903
|
* @param {Number} journeyID Identifier of the journey, taken from the numeric `journey` field in the event body (a Unix timestamp marking the start of the journey).
|
|
873
904
|
* @param {Object} opts Optional parameters
|
|
874
|
-
* @param {Number} opts.pageSize
|
|
875
|
-
* @param {Number} opts.pageNum
|
|
905
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
906
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
876
907
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceJourney200Response} and HTTP response
|
|
877
908
|
*/
|
|
878
909
|
}, {
|
|
@@ -911,13 +942,14 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
911
942
|
}
|
|
912
943
|
|
|
913
944
|
/**
|
|
914
|
-
* Get a
|
|
915
|
-
*
|
|
916
|
-
* @param {String}
|
|
945
|
+
* Get a journey and its events
|
|
946
|
+
* Get one journey's start and end time and its events, oldest first. Only events with a location are included, and a run of events at the same location is reduced to the first. The events are paginated; `journey.has_more` is true if there are more. Returns 404 if the journey doesn't exist, and 403 if the organization is suspended.
|
|
947
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
948
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
917
949
|
* @param {Number} journeyID Identifier of the journey, taken from the numeric `journey` field in the event body (a Unix timestamp marking the start of the journey).
|
|
918
950
|
* @param {Object} opts Optional parameters
|
|
919
|
-
* @param {Number} opts.pageSize
|
|
920
|
-
* @param {Number} opts.pageNum
|
|
951
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
952
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
921
953
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceJourney200Response}
|
|
922
954
|
*/
|
|
923
955
|
}, {
|
|
@@ -929,9 +961,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
929
961
|
}
|
|
930
962
|
|
|
931
963
|
/**
|
|
932
|
-
*
|
|
933
|
-
*
|
|
934
|
-
* @param {String}
|
|
964
|
+
* List a device's journeys
|
|
965
|
+
* List a device's journeys, newest first, without their events. A journey is the events whose body has the same `journey` value and a `jcount` field; one-event journeys are left out. For a journey's events, use `GetDeviceJourney`. Returns at most 100; `has_more` is true if there are more. `startDate` and `endDate` filter on the journey's start. Returns 403 if the organization is suspended.
|
|
966
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
967
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
935
968
|
* @param {Object} opts Optional parameters
|
|
936
969
|
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
937
970
|
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
@@ -968,9 +1001,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
968
1001
|
}
|
|
969
1002
|
|
|
970
1003
|
/**
|
|
971
|
-
*
|
|
972
|
-
*
|
|
973
|
-
* @param {String}
|
|
1004
|
+
* List a device's journeys
|
|
1005
|
+
* List a device's journeys, newest first, without their events. A journey is the events whose body has the same `journey` value and a `jcount` field; one-event journeys are left out. For a journey's events, use `GetDeviceJourney`. Returns at most 100; `has_more` is true if there are more. `startDate` and `endDate` filter on the journey's start. Returns 403 if the organization is suspended.
|
|
1006
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1007
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
974
1008
|
* @param {Object} opts Optional parameters
|
|
975
1009
|
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
976
1010
|
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
@@ -985,9 +1019,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
985
1019
|
}
|
|
986
1020
|
|
|
987
1021
|
/**
|
|
988
|
-
* Get
|
|
989
|
-
*
|
|
990
|
-
* @param {String}
|
|
1022
|
+
* Get a device's latest event per notefile
|
|
1023
|
+
* Get the most recent event from each of a device's notefiles, sorted by notefile name. `_env.qo` is left out. To search a device's event history, use `GetEvents`. Returns 403 if the organization is suspended.
|
|
1024
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1025
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
991
1026
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceLatestEvents200Response} and HTTP response
|
|
992
1027
|
*/
|
|
993
1028
|
}, {
|
|
@@ -1017,9 +1052,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1017
1052
|
}
|
|
1018
1053
|
|
|
1019
1054
|
/**
|
|
1020
|
-
* Get
|
|
1021
|
-
*
|
|
1022
|
-
* @param {String}
|
|
1055
|
+
* Get a device's latest event per notefile
|
|
1056
|
+
* Get the most recent event from each of a device's notefiles, sorted by notefile name. `_env.qo` is left out. To search a device's event history, use `GetEvents`. Returns 403 if the organization is suspended.
|
|
1057
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1058
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1023
1059
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceLatestEvents200Response}
|
|
1024
1060
|
*/
|
|
1025
1061
|
}, {
|
|
@@ -1031,9 +1067,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1031
1067
|
}
|
|
1032
1068
|
|
|
1033
1069
|
/**
|
|
1034
|
-
* Get
|
|
1035
|
-
*
|
|
1036
|
-
* @param {String}
|
|
1070
|
+
* Get a device's cellular data plans
|
|
1071
|
+
* Get the data plan of each cellular SIM in a device: plan type, data used and remaining, and expiry. Covers the built-in SIM and any external SIM, but not satellite plans. Returns 404 if the device has no cellular or satellite SIM.
|
|
1072
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1073
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1037
1074
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePlans200Response} and HTTP response
|
|
1038
1075
|
*/
|
|
1039
1076
|
}, {
|
|
@@ -1063,9 +1100,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1063
1100
|
}
|
|
1064
1101
|
|
|
1065
1102
|
/**
|
|
1066
|
-
* Get
|
|
1067
|
-
*
|
|
1068
|
-
* @param {String}
|
|
1103
|
+
* Get a device's cellular data plans
|
|
1104
|
+
* Get the data plan of each cellular SIM in a device: plan type, data used and remaining, and expiry. Covers the built-in SIM and any external SIM, but not satellite plans. Returns 404 if the device has no cellular or satellite SIM.
|
|
1105
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1106
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1069
1107
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePlans200Response}
|
|
1070
1108
|
*/
|
|
1071
1109
|
}, {
|
|
@@ -1077,9 +1115,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1077
1115
|
}
|
|
1078
1116
|
|
|
1079
1117
|
/**
|
|
1080
|
-
* Get
|
|
1081
|
-
*
|
|
1082
|
-
* @param {String}
|
|
1118
|
+
* Get a device's public key
|
|
1119
|
+
* Get one Notecard's public key, in PEM format. For every device in the project, use `GetDevicePublicKeys`.
|
|
1120
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1121
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1083
1122
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePublicKey200Response} and HTTP response
|
|
1084
1123
|
*/
|
|
1085
1124
|
}, {
|
|
@@ -1109,9 +1148,10 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1109
1148
|
}
|
|
1110
1149
|
|
|
1111
1150
|
/**
|
|
1112
|
-
* Get
|
|
1113
|
-
*
|
|
1114
|
-
* @param {String}
|
|
1151
|
+
* Get a device's public key
|
|
1152
|
+
* Get one Notecard's public key, in PEM format. For every device in the project, use `GetDevicePublicKeys`.
|
|
1153
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1154
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1115
1155
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePublicKey200Response}
|
|
1116
1156
|
*/
|
|
1117
1157
|
}, {
|
|
@@ -1123,11 +1163,13 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1123
1163
|
}
|
|
1124
1164
|
|
|
1125
1165
|
/**
|
|
1126
|
-
*
|
|
1127
|
-
*
|
|
1166
|
+
* List public keys of all devices
|
|
1167
|
+
* List the public key of every device in a project. For one device, use `GetDevicePublicKey`. Paginated. Deleted devices are included only when reading with a `cursor`.
|
|
1168
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1128
1169
|
* @param {Object} opts Optional parameters
|
|
1129
|
-
* @param {Number} opts.pageSize
|
|
1130
|
-
* @param {Number} opts.pageNum
|
|
1170
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1171
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1172
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1131
1173
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevicePublicKeys200Response} and HTTP response
|
|
1132
1174
|
*/
|
|
1133
1175
|
}, {
|
|
@@ -1144,7 +1186,8 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1144
1186
|
};
|
|
1145
1187
|
var queryParams = {
|
|
1146
1188
|
pageSize: opts["pageSize"],
|
|
1147
|
-
pageNum: opts["pageNum"]
|
|
1189
|
+
pageNum: opts["pageNum"],
|
|
1190
|
+
cursor: opts["cursor"]
|
|
1148
1191
|
};
|
|
1149
1192
|
var headerParams = {};
|
|
1150
1193
|
var formParams = {};
|
|
@@ -1156,11 +1199,13 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1156
1199
|
}
|
|
1157
1200
|
|
|
1158
1201
|
/**
|
|
1159
|
-
*
|
|
1160
|
-
*
|
|
1202
|
+
* List public keys of all devices
|
|
1203
|
+
* List the public key of every device in a project. For one device, use `GetDevicePublicKey`. Paginated. Deleted devices are included only when reading with a `cursor`.
|
|
1204
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1161
1205
|
* @param {Object} opts Optional parameters
|
|
1162
|
-
* @param {Number} opts.pageSize
|
|
1163
|
-
* @param {Number} opts.pageNum
|
|
1206
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1207
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1208
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1164
1209
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevicePublicKeys200Response}
|
|
1165
1210
|
*/
|
|
1166
1211
|
}, {
|
|
@@ -1172,15 +1217,17 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1172
1217
|
}
|
|
1173
1218
|
|
|
1174
1219
|
/**
|
|
1175
|
-
*
|
|
1176
|
-
*
|
|
1177
|
-
* @param {String}
|
|
1220
|
+
* List a device's sessions
|
|
1221
|
+
* List a device's sessions, its connections to Notehub. Each shows why it opened and closed, signal strength, location and data usage. `startDate` and `endDate` filter on when the session began. For every device's sessions, use `GetSessions`. Paginated.
|
|
1222
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1223
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1178
1224
|
* @param {Object} opts Optional parameters
|
|
1179
|
-
* @param {Number} opts.pageSize
|
|
1180
|
-
* @param {Number} opts.pageNum
|
|
1225
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1226
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1227
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1181
1228
|
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
1182
1229
|
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
1183
|
-
* @param {Boolean} opts.firstSync
|
|
1230
|
+
* @param {Boolean} opts.firstSync If true, return only sessions whose `why_session_opened` begins with \"first sync\". (default to false)
|
|
1184
1231
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceSessions200Response} and HTTP response
|
|
1185
1232
|
*/
|
|
1186
1233
|
}, {
|
|
@@ -1203,6 +1250,7 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1203
1250
|
var queryParams = {
|
|
1204
1251
|
pageSize: opts["pageSize"],
|
|
1205
1252
|
pageNum: opts["pageNum"],
|
|
1253
|
+
cursor: opts["cursor"],
|
|
1206
1254
|
startDate: opts["startDate"],
|
|
1207
1255
|
endDate: opts["endDate"],
|
|
1208
1256
|
firstSync: opts["firstSync"]
|
|
@@ -1217,15 +1265,17 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1217
1265
|
}
|
|
1218
1266
|
|
|
1219
1267
|
/**
|
|
1220
|
-
*
|
|
1221
|
-
*
|
|
1222
|
-
* @param {String}
|
|
1268
|
+
* List a device's sessions
|
|
1269
|
+
* List a device's sessions, its connections to Notehub. Each shows why it opened and closed, signal strength, location and data usage. `startDate` and `endDate` filter on when the session began. For every device's sessions, use `GetSessions`. Paginated.
|
|
1270
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1271
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1223
1272
|
* @param {Object} opts Optional parameters
|
|
1224
|
-
* @param {Number} opts.pageSize
|
|
1225
|
-
* @param {Number} opts.pageNum
|
|
1273
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1274
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1275
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1226
1276
|
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
1227
1277
|
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
1228
|
-
* @param {Boolean} opts.firstSync
|
|
1278
|
+
* @param {Boolean} opts.firstSync If true, return only sessions whose `why_session_opened` begins with \"first sync\". (default to false)
|
|
1229
1279
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceSessions200Response}
|
|
1230
1280
|
*/
|
|
1231
1281
|
}, {
|
|
@@ -1237,20 +1287,22 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1237
1287
|
}
|
|
1238
1288
|
|
|
1239
1289
|
/**
|
|
1240
|
-
*
|
|
1241
|
-
*
|
|
1290
|
+
* List devices in a project
|
|
1291
|
+
* List the devices in a project, with optional filters such as tag, serial number, fleet, location and firmware version. For one fleet's devices, use `GetFleetDevices`. Paginated.
|
|
1292
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1242
1293
|
* @param {Object} opts Optional parameters
|
|
1243
|
-
* @param {Number} opts.pageSize
|
|
1244
|
-
* @param {Number} opts.pageNum
|
|
1245
|
-
* @param {
|
|
1246
|
-
* @param {Array.<String>} opts.
|
|
1247
|
-
* @param {Array.<String>} opts.
|
|
1248
|
-
* @param {Array.<String>} opts.
|
|
1249
|
-
* @param {Array.<String>} opts.
|
|
1250
|
-
* @param {Array.<String>} opts.
|
|
1251
|
-
* @param {Array.<String>} opts.
|
|
1252
|
-
* @param {Array.<String>} opts.
|
|
1253
|
-
* @param {Array.<String>} opts.
|
|
1294
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1295
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1296
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1297
|
+
* @param {Array.<String>} opts.deviceUID DeviceUIDs to filter by. Device and DFU calls match substrings, any case.
|
|
1298
|
+
* @param {Array.<String>} opts.tag Whole tag, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1299
|
+
* @param {Array.<String>} opts.serialNumber Serial number substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1300
|
+
* @param {Array.<String>} opts.fleetUID Return only devices in these fleets (FleetUIDs). Repeat for more than one.
|
|
1301
|
+
* @param {Array.<String>} opts.notecardFirmware Notecard firmware substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1302
|
+
* @param {Array.<String>} opts.location Location substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1303
|
+
* @param {Array.<String>} opts.hostFirmware Host firmware version substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1304
|
+
* @param {Array.<String>} opts.productUID ProductUID substring, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1305
|
+
* @param {Array.<String>} opts.sku SKU substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1254
1306
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevices200Response} and HTTP response
|
|
1255
1307
|
*/
|
|
1256
1308
|
}, {
|
|
@@ -1268,6 +1320,7 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1268
1320
|
var queryParams = {
|
|
1269
1321
|
pageSize: opts["pageSize"],
|
|
1270
1322
|
pageNum: opts["pageNum"],
|
|
1323
|
+
cursor: opts["cursor"],
|
|
1271
1324
|
deviceUID: this.apiClient.buildCollectionParam(opts["deviceUID"], "multi"),
|
|
1272
1325
|
tag: this.apiClient.buildCollectionParam(opts["tag"], "multi"),
|
|
1273
1326
|
serialNumber: this.apiClient.buildCollectionParam(opts["serialNumber"], "multi"),
|
|
@@ -1288,20 +1341,22 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1288
1341
|
}
|
|
1289
1342
|
|
|
1290
1343
|
/**
|
|
1291
|
-
*
|
|
1292
|
-
*
|
|
1344
|
+
* List devices in a project
|
|
1345
|
+
* List the devices in a project, with optional filters such as tag, serial number, fleet, location and firmware version. For one fleet's devices, use `GetFleetDevices`. Paginated.
|
|
1346
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1293
1347
|
* @param {Object} opts Optional parameters
|
|
1294
|
-
* @param {Number} opts.pageSize
|
|
1295
|
-
* @param {Number} opts.pageNum
|
|
1296
|
-
* @param {
|
|
1297
|
-
* @param {Array.<String>} opts.
|
|
1298
|
-
* @param {Array.<String>} opts.
|
|
1299
|
-
* @param {Array.<String>} opts.
|
|
1300
|
-
* @param {Array.<String>} opts.
|
|
1301
|
-
* @param {Array.<String>} opts.
|
|
1302
|
-
* @param {Array.<String>} opts.
|
|
1303
|
-
* @param {Array.<String>} opts.
|
|
1304
|
-
* @param {Array.<String>} opts.
|
|
1348
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1349
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1350
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1351
|
+
* @param {Array.<String>} opts.deviceUID DeviceUIDs to filter by. Device and DFU calls match substrings, any case.
|
|
1352
|
+
* @param {Array.<String>} opts.tag Whole tag, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1353
|
+
* @param {Array.<String>} opts.serialNumber Serial number substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1354
|
+
* @param {Array.<String>} opts.fleetUID Return only devices in these fleets (FleetUIDs). Repeat for more than one.
|
|
1355
|
+
* @param {Array.<String>} opts.notecardFirmware Notecard firmware substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1356
|
+
* @param {Array.<String>} opts.location Location substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1357
|
+
* @param {Array.<String>} opts.hostFirmware Host firmware version substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1358
|
+
* @param {Array.<String>} opts.productUID ProductUID substring, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1359
|
+
* @param {Array.<String>} opts.sku SKU substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1305
1360
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevices200Response}
|
|
1306
1361
|
*/
|
|
1307
1362
|
}, {
|
|
@@ -1313,20 +1368,22 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1313
1368
|
}
|
|
1314
1369
|
|
|
1315
1370
|
/**
|
|
1316
|
-
*
|
|
1317
|
-
*
|
|
1318
|
-
* @param {String}
|
|
1371
|
+
* List devices in a fleet
|
|
1372
|
+
* List the devices in one fleet, with the same filters as `GetDevices`. To list a device's fleets instead, use `GetDeviceFleets`. Paginated. Returns 404 if the fleet doesn't exist.
|
|
1373
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1374
|
+
* @param {String} fleetUID FleetUID, e.g. `fleet:1042ddc5-3b2c-4cec-b1fb-d3040538094d`. List with `GetFleets`.
|
|
1319
1375
|
* @param {Object} opts Optional parameters
|
|
1320
|
-
* @param {Number} opts.pageSize
|
|
1321
|
-
* @param {Number} opts.pageNum
|
|
1322
|
-
* @param {
|
|
1323
|
-
* @param {Array.<String>} opts.
|
|
1324
|
-
* @param {Array.<String>} opts.
|
|
1325
|
-
* @param {Array.<String>} opts.
|
|
1326
|
-
* @param {Array.<String>} opts.
|
|
1327
|
-
* @param {Array.<String>} opts.
|
|
1328
|
-
* @param {Array.<String>} opts.
|
|
1329
|
-
* @param {Array.<String>} opts.
|
|
1376
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1377
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1378
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1379
|
+
* @param {Array.<String>} opts.deviceUID DeviceUIDs to filter by. Device and DFU calls match substrings, any case.
|
|
1380
|
+
* @param {Array.<String>} opts.tag Whole tag, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1381
|
+
* @param {Array.<String>} opts.serialNumber Serial number substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1382
|
+
* @param {Array.<String>} opts.notecardFirmware Notecard firmware substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1383
|
+
* @param {Array.<String>} opts.location Location substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1384
|
+
* @param {Array.<String>} opts.hostFirmware Host firmware version substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1385
|
+
* @param {Array.<String>} opts.productUID ProductUID substring, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1386
|
+
* @param {Array.<String>} opts.sku SKU substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1330
1387
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDevices200Response} and HTTP response
|
|
1331
1388
|
*/
|
|
1332
1389
|
}, {
|
|
@@ -1349,6 +1406,7 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1349
1406
|
var queryParams = {
|
|
1350
1407
|
pageSize: opts["pageSize"],
|
|
1351
1408
|
pageNum: opts["pageNum"],
|
|
1409
|
+
cursor: opts["cursor"],
|
|
1352
1410
|
deviceUID: this.apiClient.buildCollectionParam(opts["deviceUID"], "multi"),
|
|
1353
1411
|
tag: this.apiClient.buildCollectionParam(opts["tag"], "multi"),
|
|
1354
1412
|
serialNumber: this.apiClient.buildCollectionParam(opts["serialNumber"], "multi"),
|
|
@@ -1368,20 +1426,22 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1368
1426
|
}
|
|
1369
1427
|
|
|
1370
1428
|
/**
|
|
1371
|
-
*
|
|
1372
|
-
*
|
|
1373
|
-
* @param {String}
|
|
1429
|
+
* List devices in a fleet
|
|
1430
|
+
* List the devices in one fleet, with the same filters as `GetDevices`. To list a device's fleets instead, use `GetDeviceFleets`. Paginated. Returns 404 if the fleet doesn't exist.
|
|
1431
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1432
|
+
* @param {String} fleetUID FleetUID, e.g. `fleet:1042ddc5-3b2c-4cec-b1fb-d3040538094d`. List with `GetFleets`.
|
|
1374
1433
|
* @param {Object} opts Optional parameters
|
|
1375
|
-
* @param {Number} opts.pageSize
|
|
1376
|
-
* @param {Number} opts.pageNum
|
|
1377
|
-
* @param {
|
|
1378
|
-
* @param {Array.<String>} opts.
|
|
1379
|
-
* @param {Array.<String>} opts.
|
|
1380
|
-
* @param {Array.<String>} opts.
|
|
1381
|
-
* @param {Array.<String>} opts.
|
|
1382
|
-
* @param {Array.<String>} opts.
|
|
1383
|
-
* @param {Array.<String>} opts.
|
|
1384
|
-
* @param {Array.<String>} opts.
|
|
1434
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1435
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1436
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1437
|
+
* @param {Array.<String>} opts.deviceUID DeviceUIDs to filter by. Device and DFU calls match substrings, any case.
|
|
1438
|
+
* @param {Array.<String>} opts.tag Whole tag, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1439
|
+
* @param {Array.<String>} opts.serialNumber Serial number substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1440
|
+
* @param {Array.<String>} opts.notecardFirmware Notecard firmware substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1441
|
+
* @param {Array.<String>} opts.location Location substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1442
|
+
* @param {Array.<String>} opts.hostFirmware Host firmware version substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1443
|
+
* @param {Array.<String>} opts.productUID ProductUID substring, any case. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1444
|
+
* @param {Array.<String>} opts.sku SKU substring. `*` is a wildcard and `\\*` a literal `*`; `%` and `_` are literal.
|
|
1385
1445
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDevices200Response}
|
|
1386
1446
|
*/
|
|
1387
1447
|
}, {
|
|
@@ -1393,14 +1453,15 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1393
1453
|
}
|
|
1394
1454
|
|
|
1395
1455
|
/**
|
|
1396
|
-
*
|
|
1397
|
-
*
|
|
1398
|
-
* @param {String}
|
|
1399
|
-
* @param {String}
|
|
1456
|
+
* Get the notes in a notefile
|
|
1457
|
+
* Get the notes in one notefile on a device. For a `.qi` notefile, that's the notes still queued; for a `.db` notefile, every note. To list all of a device's notefiles with their notes, use `ListNotefiles`. With `delete=true`, the returned notes are deleted, which requires the Owner or Developer role. Returns 400 if `notefileID` has no valid notefile extension.
|
|
1458
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1459
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1460
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
1400
1461
|
* @param {Object} opts Optional parameters
|
|
1401
|
-
* @param {Number} opts.max The
|
|
1402
|
-
* @param {Boolean} opts.deleted true
|
|
1403
|
-
* @param {Boolean} opts._delete true
|
|
1462
|
+
* @param {Number} opts.max The most notes to return.
|
|
1463
|
+
* @param {Boolean} opts.deleted If true, also return deleted notes.
|
|
1464
|
+
* @param {Boolean} opts._delete If true, delete the notes this request returns. Requires the Owner or Developer role.
|
|
1404
1465
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetNotefile200Response} and HTTP response
|
|
1405
1466
|
*/
|
|
1406
1467
|
}, {
|
|
@@ -1440,14 +1501,15 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1440
1501
|
}
|
|
1441
1502
|
|
|
1442
1503
|
/**
|
|
1443
|
-
*
|
|
1444
|
-
*
|
|
1445
|
-
* @param {String}
|
|
1446
|
-
* @param {String}
|
|
1504
|
+
* Get the notes in a notefile
|
|
1505
|
+
* Get the notes in one notefile on a device. For a `.qi` notefile, that's the notes still queued; for a `.db` notefile, every note. To list all of a device's notefiles with their notes, use `ListNotefiles`. With `delete=true`, the returned notes are deleted, which requires the Owner or Developer role. Returns 400 if `notefileID` has no valid notefile extension.
|
|
1506
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1507
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1508
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
1447
1509
|
* @param {Object} opts Optional parameters
|
|
1448
|
-
* @param {Number} opts.max The
|
|
1449
|
-
* @param {Boolean} opts.deleted true
|
|
1450
|
-
* @param {Boolean} opts._delete true
|
|
1510
|
+
* @param {Number} opts.max The most notes to return.
|
|
1511
|
+
* @param {Boolean} opts.deleted If true, also return deleted notes.
|
|
1512
|
+
* @param {Boolean} opts._delete If true, delete the notes this request returns. Requires the Owner or Developer role.
|
|
1451
1513
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetNotefile200Response}
|
|
1452
1514
|
*/
|
|
1453
1515
|
}, {
|
|
@@ -1459,11 +1521,81 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1459
1521
|
}
|
|
1460
1522
|
|
|
1461
1523
|
/**
|
|
1462
|
-
*
|
|
1463
|
-
*
|
|
1464
|
-
* @param {String}
|
|
1524
|
+
* List sessions in a project
|
|
1525
|
+
* List the sessions of every device in a project, as `GetDeviceSessions` does for one device. `startDate` and `endDate` filter on when the session began. `deviceUID` and `fleetUID` each match any of their values; `fleetUID` matches the fleets recorded on the session. Paginated.
|
|
1526
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1527
|
+
* @param {Object} opts Optional parameters
|
|
1528
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1529
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1530
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1531
|
+
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
1532
|
+
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
1533
|
+
* @param {Boolean} opts.firstSync If true, return only sessions whose `why_session_opened` begins with \"first sync\". (default to false)
|
|
1534
|
+
* @param {Array.<String>} opts.deviceUID DeviceUIDs to filter by. Device and DFU calls match substrings, any case.
|
|
1535
|
+
* @param {Array.<String>} opts.fleetUID Return only devices in these fleets (FleetUIDs). Repeat for more than one.
|
|
1536
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetDeviceSessions200Response} and HTTP response
|
|
1537
|
+
*/
|
|
1538
|
+
}, {
|
|
1539
|
+
key: "getSessionsWithHttpInfo",
|
|
1540
|
+
value: function getSessionsWithHttpInfo(projectOrProductUID, opts) {
|
|
1541
|
+
opts = opts || {};
|
|
1542
|
+
var postBody = null;
|
|
1543
|
+
// verify the required parameter 'projectOrProductUID' is set
|
|
1544
|
+
if (projectOrProductUID === undefined || projectOrProductUID === null) {
|
|
1545
|
+
throw new _Error["default"]("Missing the required parameter 'projectOrProductUID' when calling getSessions");
|
|
1546
|
+
}
|
|
1547
|
+
var pathParams = {
|
|
1548
|
+
projectOrProductUID: projectOrProductUID
|
|
1549
|
+
};
|
|
1550
|
+
var queryParams = {
|
|
1551
|
+
pageSize: opts["pageSize"],
|
|
1552
|
+
pageNum: opts["pageNum"],
|
|
1553
|
+
cursor: opts["cursor"],
|
|
1554
|
+
startDate: opts["startDate"],
|
|
1555
|
+
endDate: opts["endDate"],
|
|
1556
|
+
firstSync: opts["firstSync"],
|
|
1557
|
+
deviceUID: this.apiClient.buildCollectionParam(opts["deviceUID"], "multi"),
|
|
1558
|
+
fleetUID: this.apiClient.buildCollectionParam(opts["fleetUID"], "multi")
|
|
1559
|
+
};
|
|
1560
|
+
var headerParams = {};
|
|
1561
|
+
var formParams = {};
|
|
1562
|
+
var authNames = ["personalAccessToken"];
|
|
1563
|
+
var contentTypes = [];
|
|
1564
|
+
var accepts = ["application/json"];
|
|
1565
|
+
var returnType = _GetDeviceSessions200Response["default"];
|
|
1566
|
+
return this.apiClient.callApi("/v1/projects/{projectOrProductUID}/sessions", "GET", pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
1567
|
+
}
|
|
1568
|
+
|
|
1569
|
+
/**
|
|
1570
|
+
* List sessions in a project
|
|
1571
|
+
* List the sessions of every device in a project, as `GetDeviceSessions` does for one device. `startDate` and `endDate` filter on when the session began. `deviceUID` and `fleetUID` each match any of their values; `fleetUID` matches the fleets recorded on the session. Paginated.
|
|
1572
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1573
|
+
* @param {Object} opts Optional parameters
|
|
1574
|
+
* @param {Number} opts.pageSize How many results to return per page. (default to 1000)
|
|
1575
|
+
* @param {Number} opts.pageNum Page number, starting at 1. Can't be combined with `cursor`. (default to 1)
|
|
1576
|
+
* @param {String} opts.cursor Read in ascending modification order. Start with `0` for the beginning, or a Unix time in microseconds (inclusive), e.g. now minus 30 days. To resume, pass back `next_cursor` or `X-Next-Cursor` unchanged; its `.N` suffix ensures no row repeats or is skipped.
|
|
1577
|
+
* @param {Number} opts.startDate Start date for filtering results, specified as a Unix timestamp
|
|
1578
|
+
* @param {Number} opts.endDate End date for filtering results, specified as a Unix timestamp
|
|
1579
|
+
* @param {Boolean} opts.firstSync If true, return only sessions whose `why_session_opened` begins with \"first sync\". (default to false)
|
|
1580
|
+
* @param {Array.<String>} opts.deviceUID DeviceUIDs to filter by. Device and DFU calls match substrings, any case.
|
|
1581
|
+
* @param {Array.<String>} opts.fleetUID Return only devices in these fleets (FleetUIDs). Repeat for more than one.
|
|
1582
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetDeviceSessions200Response}
|
|
1583
|
+
*/
|
|
1584
|
+
}, {
|
|
1585
|
+
key: "getSessions",
|
|
1586
|
+
value: function getSessions(projectOrProductUID, opts) {
|
|
1587
|
+
return this.getSessionsWithHttpInfo(projectOrProductUID, opts).then(function (response_and_data) {
|
|
1588
|
+
return response_and_data.data;
|
|
1589
|
+
});
|
|
1590
|
+
}
|
|
1591
|
+
|
|
1592
|
+
/**
|
|
1593
|
+
* List a device's notefiles and notes
|
|
1594
|
+
* List a device's notefiles with the notes in each, sorted `.qo`, then `.qi`, then `.db`. `.qo` notefiles are listed without notes, since Notehub empties them as it processes them. Most system notefiles (names starting with `_`) are left out. For one notefile, use `GetNotefile`.
|
|
1595
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1596
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1465
1597
|
* @param {Object} opts Optional parameters
|
|
1466
|
-
* @param {Array.<String>} opts.files
|
|
1598
|
+
* @param {Array.<String>} opts.files Notefiles to include, e.g. `config.db`. If omitted, all are listed.
|
|
1467
1599
|
* @param {Boolean} opts.pending show only files that are pending sync to the Notecard
|
|
1468
1600
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/Notefile>} and HTTP response
|
|
1469
1601
|
*/
|
|
@@ -1498,11 +1630,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1498
1630
|
}
|
|
1499
1631
|
|
|
1500
1632
|
/**
|
|
1501
|
-
*
|
|
1502
|
-
*
|
|
1503
|
-
* @param {String}
|
|
1633
|
+
* List a device's notefiles and notes
|
|
1634
|
+
* List a device's notefiles with the notes in each, sorted `.qo`, then `.qi`, then `.db`. `.qo` notefiles are listed without notes, since Notehub empties them as it processes them. Most system notefiles (names starting with `_`) are left out. For one notefile, use `GetNotefile`.
|
|
1635
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1636
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1504
1637
|
* @param {Object} opts Optional parameters
|
|
1505
|
-
* @param {Array.<String>} opts.files
|
|
1638
|
+
* @param {Array.<String>} opts.files Notefiles to include, e.g. `config.db`. If omitted, all are listed.
|
|
1506
1639
|
* @param {Boolean} opts.pending show only files that are pending sync to the Notecard
|
|
1507
1640
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/Notefile>}
|
|
1508
1641
|
*/
|
|
@@ -1515,10 +1648,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1515
1648
|
}
|
|
1516
1649
|
|
|
1517
1650
|
/**
|
|
1518
|
-
* Provision
|
|
1519
|
-
*
|
|
1520
|
-
* @param {String}
|
|
1521
|
-
* @param {
|
|
1651
|
+
* Provision a Notecard
|
|
1652
|
+
* Add a Notecard to a project before it first connects, with its product, serial number and fleets. A device that already exists isn't reset and keeps its fleets. Requires the Owner or Developer role. Returns 404 if `product_uid` doesn't exist, and 400 if it belongs to another project or `deviceUID` isn't a valid Notecard DeviceUID.
|
|
1653
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1654
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1655
|
+
* @param {module:model/ProvisionDeviceRequest} provisionDeviceRequest The product, serial number and fleets for the device.
|
|
1522
1656
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Object} and HTTP response
|
|
1523
1657
|
*/
|
|
1524
1658
|
}, {
|
|
@@ -1552,10 +1686,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1552
1686
|
}
|
|
1553
1687
|
|
|
1554
1688
|
/**
|
|
1555
|
-
* Provision
|
|
1556
|
-
*
|
|
1557
|
-
* @param {String}
|
|
1558
|
-
* @param {
|
|
1689
|
+
* Provision a Notecard
|
|
1690
|
+
* Add a Notecard to a project before it first connects, with its product, serial number and fleets. A device that already exists isn't reset and keeps its fleets. Requires the Owner or Developer role. Returns 404 if `product_uid` doesn't exist, and 400 if it belongs to another project or `deviceUID` isn't a valid Notecard DeviceUID.
|
|
1691
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1692
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1693
|
+
* @param {module:model/ProvisionDeviceRequest} provisionDeviceRequest The product, serial number and fleets for the device.
|
|
1559
1694
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Object}
|
|
1560
1695
|
*/
|
|
1561
1696
|
}, {
|
|
@@ -1567,10 +1702,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1567
1702
|
}
|
|
1568
1703
|
|
|
1569
1704
|
/**
|
|
1570
|
-
* Set environment variables
|
|
1571
|
-
*
|
|
1572
|
-
* @param {String}
|
|
1573
|
-
* @param {
|
|
1705
|
+
* Set device environment variables
|
|
1706
|
+
* Add or change a device's environment variables; variables you don't send keep their values. A value of `\"\"` or `-` deletes that variable. Setting `_fw`, `_fwc` or `_fwm` starts a host, Notecard or modem firmware update. Requires the Owner or Developer role. Returns 400 if a note's key isn't a variable.
|
|
1707
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1708
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1709
|
+
* @param {module:model/EnvironmentVariables} environmentVariables The variables to add or change, and optional notes.
|
|
1574
1710
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
|
|
1575
1711
|
*/
|
|
1576
1712
|
}, {
|
|
@@ -1604,10 +1740,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1604
1740
|
}
|
|
1605
1741
|
|
|
1606
1742
|
/**
|
|
1607
|
-
* Set environment variables
|
|
1608
|
-
*
|
|
1609
|
-
* @param {String}
|
|
1610
|
-
* @param {
|
|
1743
|
+
* Set device environment variables
|
|
1744
|
+
* Add or change a device's environment variables; variables you don't send keep their values. A value of `\"\"` or `-` deletes that variable. Setting `_fw`, `_fwc` or `_fwm` starts a host, Notecard or modem firmware update. Requires the Owner or Developer role. Returns 400 if a note's key isn't a variable.
|
|
1745
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1746
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1747
|
+
* @param {module:model/EnvironmentVariables} environmentVariables The variables to add or change, and optional notes.
|
|
1611
1748
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
|
|
1612
1749
|
*/
|
|
1613
1750
|
}, {
|
|
@@ -1619,11 +1756,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1619
1756
|
}
|
|
1620
1757
|
|
|
1621
1758
|
/**
|
|
1622
|
-
* Set environment variables
|
|
1623
|
-
*
|
|
1624
|
-
* @param {String}
|
|
1625
|
-
* @param {String}
|
|
1626
|
-
* @param {
|
|
1759
|
+
* Set device environment variables using a PIN
|
|
1760
|
+
* Add or change a device's environment variables using its PIN instead of an API token. Pass the PIN in `X-Auth-Token`. Works like `SetDeviceEnvironmentVariables`: a value of `\"\"` or `-` deletes that variable. Returns 401 if the project's device dashboard URL has no `[pin]`, or the PIN is wrong.
|
|
1761
|
+
* @param {String} productUID ProductUID, e.g. `com.blues.bridge:sensors`. List with `GetProducts`.
|
|
1762
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1763
|
+
* @param {String} xAuthToken The device's PIN, used instead of an API token.
|
|
1764
|
+
* @param {module:model/EnvironmentVariables} environmentVariables The variables to add or change, and optional notes.
|
|
1627
1765
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EnvironmentVariables} and HTTP response
|
|
1628
1766
|
*/
|
|
1629
1767
|
}, {
|
|
@@ -1663,11 +1801,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1663
1801
|
}
|
|
1664
1802
|
|
|
1665
1803
|
/**
|
|
1666
|
-
* Set environment variables
|
|
1667
|
-
*
|
|
1668
|
-
* @param {String}
|
|
1669
|
-
* @param {String}
|
|
1670
|
-
* @param {
|
|
1804
|
+
* Set device environment variables using a PIN
|
|
1805
|
+
* Add or change a device's environment variables using its PIN instead of an API token. Pass the PIN in `X-Auth-Token`. Works like `SetDeviceEnvironmentVariables`: a value of `\"\"` or `-` deletes that variable. Returns 401 if the project's device dashboard URL has no `[pin]`, or the PIN is wrong.
|
|
1806
|
+
* @param {String} productUID ProductUID, e.g. `com.blues.bridge:sensors`. List with `GetProducts`.
|
|
1807
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1808
|
+
* @param {String} xAuthToken The device's PIN, used instead of an API token.
|
|
1809
|
+
* @param {module:model/EnvironmentVariables} environmentVariables The variables to add or change, and optional notes.
|
|
1671
1810
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EnvironmentVariables}
|
|
1672
1811
|
*/
|
|
1673
1812
|
}, {
|
|
@@ -1679,10 +1818,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1679
1818
|
}
|
|
1680
1819
|
|
|
1681
1820
|
/**
|
|
1682
|
-
* Send a signal
|
|
1683
|
-
*
|
|
1684
|
-
* @param {String}
|
|
1685
|
-
* @param {
|
|
1821
|
+
* Send a signal to a connected Notecard
|
|
1822
|
+
* Send a JSON object straight to a Notecard, which the host can read with `hub.signal`. It's delivered only if the Notecard is connected to Notehub at that moment, and is never queued; `connected` in the response says whether it was. To queue data for the next sync, use `AddQiNote` instead. Requires the Owner or Developer role. Returns 400 if the body has a `type` field.
|
|
1823
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1824
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1825
|
+
* @param {module:model/Body} body The signal to send.
|
|
1686
1826
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/SignalDevice200Response} and HTTP response
|
|
1687
1827
|
*/
|
|
1688
1828
|
}, {
|
|
@@ -1716,10 +1856,11 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1716
1856
|
}
|
|
1717
1857
|
|
|
1718
1858
|
/**
|
|
1719
|
-
* Send a signal
|
|
1720
|
-
*
|
|
1721
|
-
* @param {String}
|
|
1722
|
-
* @param {
|
|
1859
|
+
* Send a signal to a connected Notecard
|
|
1860
|
+
* Send a JSON object straight to a Notecard, which the host can read with `hub.signal`. It's delivered only if the Notecard is connected to Notehub at that moment, and is never queued; `connected` in the response says whether it was. To queue data for the next sync, use `AddQiNote` instead. Requires the Owner or Developer role. Returns 400 if the body has a `type` field.
|
|
1861
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1862
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1863
|
+
* @param {module:model/Body} body The signal to send.
|
|
1723
1864
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/SignalDevice200Response}
|
|
1724
1865
|
*/
|
|
1725
1866
|
}, {
|
|
@@ -1731,11 +1872,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1731
1872
|
}
|
|
1732
1873
|
|
|
1733
1874
|
/**
|
|
1734
|
-
* Update a note in a .db
|
|
1735
|
-
*
|
|
1736
|
-
* @param {String}
|
|
1737
|
-
* @param {String}
|
|
1738
|
-
* @param {String}
|
|
1875
|
+
* Update a note in a .db notefile
|
|
1876
|
+
* Replace the body and payload of a note in a database notefile on a device, synced to the Notecard on its next sync. To add a new note, use `AddDbNote`. Requires the Owner or Developer role. Returns 400 unless the notefile ends in `.db` or `.dbs`, or if `payload` isn't valid base64.
|
|
1877
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1878
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1879
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
1880
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
1739
1881
|
* @param {module:model/NoteInput} noteInput Body or payload of note to be added to the device
|
|
1740
1882
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
1741
1883
|
*/
|
|
@@ -1780,11 +1922,12 @@ var DeviceApi = exports["default"] = /*#__PURE__*/function () {
|
|
|
1780
1922
|
}
|
|
1781
1923
|
|
|
1782
1924
|
/**
|
|
1783
|
-
* Update a note in a .db
|
|
1784
|
-
*
|
|
1785
|
-
* @param {String}
|
|
1786
|
-
* @param {String}
|
|
1787
|
-
* @param {String}
|
|
1925
|
+
* Update a note in a .db notefile
|
|
1926
|
+
* Replace the body and payload of a note in a database notefile on a device, synced to the Notecard on its next sync. To add a new note, use `AddDbNote`. Requires the Owner or Developer role. Returns 400 unless the notefile ends in `.db` or `.dbs`, or if `payload` isn't valid base64.
|
|
1927
|
+
* @param {String} projectOrProductUID ProjectUID, e.g. `app:2606f411-dea6-44a0-9743-1130f57d77d8`, or one of the project's ProductUIDs.
|
|
1928
|
+
* @param {String} deviceUID DeviceUID, e.g. `dev:864475040509284`. List with `GetDevices`.
|
|
1929
|
+
* @param {String} notefileID Notefile name, including its extension, e.g. `config.db` or `commands.qi`.
|
|
1930
|
+
* @param {String} noteID Note ID within the notefile, e.g. `my_note`. Notes in a `.qi` notefile have IDs like `1:435`.
|
|
1788
1931
|
* @param {module:model/NoteInput} noteInput Body or payload of note to be added to the device
|
|
1789
1932
|
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
1790
1933
|
*/
|