@blues-inc/notehub-js 1.0.29-beta.4 → 1.0.29-beta.5
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 +12 -2
- package/dist/ApiClient.js +2 -2
- package/dist/api/AlertApi.js +1 -1
- package/dist/api/AuthorizationApi.js +1 -1
- package/dist/api/BillingAccountApi.js +1 -1
- package/dist/api/DeviceApi.js +1 -1
- package/dist/api/EventApi.js +1 -1
- package/dist/api/ExternalDevicesApi.js +202 -0
- package/dist/api/MonitorApi.js +1 -1
- package/dist/api/ProjectApi.js +1 -1
- package/dist/api/RepositoryApi.js +1 -1
- package/dist/api/RouteApi.js +1 -1
- package/dist/api/WebhookApi.js +312 -0
- package/dist/index.js +28 -7
- package/dist/model/Alert.js +1 -1
- package/dist/model/AlertDataInner.js +1 -1
- package/dist/model/AlertNotificationsInner.js +1 -1
- package/dist/model/Aws.js +1 -1
- package/dist/model/Azure.js +1 -1
- package/dist/model/BillingAccount.js +1 -1
- package/dist/model/Body.js +1 -1
- package/dist/model/CloneProjectRequest.js +1 -1
- package/dist/model/Contact.js +1 -1
- package/dist/model/CreateFleetRequest.js +1 -1
- package/dist/model/CreateMonitor.js +1 -1
- package/dist/model/CreateProductRequest.js +1 -1
- package/dist/model/CreateProjectRequest.js +1 -1
- package/dist/model/CreateUpdateRepository.js +1 -1
- package/dist/model/CurrentFirmware.js +1 -1
- package/dist/model/DFUEnv.js +1 -1
- package/dist/model/DFUState.js +1 -1
- package/dist/model/DataField.js +1 -1
- package/dist/model/DataSet.js +1 -1
- package/dist/model/DataSetField.js +1 -1
- package/dist/model/DeleteDeviceFleetsRequest.js +1 -1
- package/dist/model/Device.js +1 -31
- package/dist/model/DeviceDfuHistory.js +1 -1
- package/dist/model/DeviceDfuHistoryPage.js +1 -1
- package/dist/model/DeviceDfuStateMachine.js +1 -1
- package/dist/model/DeviceDfuStateMachineNode.js +1 -1
- package/dist/model/DeviceDfuStatus.js +1 -1
- package/dist/model/DeviceDfuStatusCurrent.js +1 -1
- package/dist/model/DeviceDfuStatusPage.js +1 -1
- package/dist/model/DeviceSession.js +1 -1
- package/dist/model/DeviceTowerInfo.js +1 -1
- package/dist/model/DeviceUsage.js +1 -1
- package/dist/model/DfuActionRequest.js +1 -1
- package/dist/model/EmailNotification.js +1 -1
- package/dist/model/EnvironmentVariables.js +1 -1
- package/dist/model/Error.js +1 -1
- package/dist/model/Event.js +1 -1
- package/dist/model/ExtDeviceSession.js +617 -0
- package/dist/model/Firmware.js +1 -1
- package/dist/model/FirmwareInfo.js +1 -1
- package/dist/model/Fleet.js +1 -1
- package/dist/model/GetAlerts200Response.js +1 -1
- package/dist/model/GetBillingAccounts200Response.js +1 -1
- package/dist/model/GetDeviceEnvironmentVariables200Response.js +1 -1
- package/dist/model/GetDeviceHealthLog200Response.js +1 -1
- package/dist/model/GetDeviceHealthLog200ResponseHealthLogInner.js +1 -1
- package/dist/model/GetDeviceLatest200Response.js +1 -1
- package/dist/model/GetDevicePublicKey200Response.js +1 -1
- package/dist/model/GetDeviceSessions200Response.js +1 -1
- package/dist/model/GetProjectDevicePublicKeys200Response.js +1 -1
- package/dist/model/GetProjectDevicePublicKeys200ResponseDevicePublicKeysInner.js +1 -1
- package/dist/model/GetProjectDevices200Response.js +1 -1
- package/dist/model/GetProjectEvents200Response.js +1 -1
- package/dist/model/GetProjectEventsByCursor200Response.js +1 -1
- package/dist/model/GetProjectFleets200Response.js +1 -1
- package/dist/model/GetProjectMembers200Response.js +1 -1
- package/dist/model/GetProjectProducts200Response.js +1 -1
- package/dist/model/GetProjects200Response.js +1 -1
- package/dist/model/GetRouteLogsByRoute200ResponseInner.js +1 -1
- package/dist/model/Google.js +1 -1
- package/dist/model/HandleNoteChanges200Response.js +1 -1
- package/dist/model/HandleNoteGet200Response.js +1 -1
- package/dist/model/HandleNoteSignal200Response.js +1 -1
- package/dist/model/HandleNotefileChanges200Response.js +1 -1
- package/dist/model/HandleNotefileChangesPending200Response.js +1 -1
- package/dist/model/HandleNotefileDeleteRequest.js +1 -1
- package/dist/model/Http.js +1 -1
- package/dist/model/HttpFilter.js +1 -1
- package/dist/model/HttpTransform.js +1 -1
- package/dist/model/Location.js +1 -1
- package/dist/model/Login200Response.js +1 -1
- package/dist/model/LoginRequest.js +1 -1
- package/dist/model/Monitor.js +1 -1
- package/dist/model/MonitorAlertRoutesInner.js +1 -1
- package/dist/model/Mqtt.js +1 -1
- package/dist/model/Note.js +1 -1
- package/dist/model/NotehubRoute.js +1 -1
- package/dist/model/NotehubRouteSchema.js +1 -1
- package/dist/model/PostProvisionProjectDeviceRequest.js +1 -1
- package/dist/model/Product.js +1 -1
- package/dist/model/Project.js +1 -1
- package/dist/model/ProjectMember.js +1 -1
- package/dist/model/Proxy.js +1 -1
- package/dist/model/PutDeviceFleetsRequest.js +1 -1
- package/dist/model/QuestionDataResponseLineChart.js +1 -1
- package/dist/model/QuestionDataResponseMap.js +1 -1
- package/dist/model/Radresponder.js +1 -1
- package/dist/model/Repository.js +1 -1
- package/dist/model/Slack.js +1 -1
- package/dist/model/SlackBearerNotification.js +1 -1
- package/dist/model/SlackWebHookNotification.js +1 -1
- package/dist/model/Snowflake.js +1 -1
- package/dist/model/SnowflakeTransform.js +1 -1
- package/dist/model/Thingworx.js +1 -1
- package/dist/model/TowerLocation.js +10 -2
- package/dist/model/Twilio.js +1 -1
- package/dist/model/UpdateFleetRequest.js +1 -1
- package/dist/model/UploadMetadata.js +1 -1
- package/dist/model/UserDbRoute.js +1 -1
- package/dist/model/UserDfuStateMachine.js +1 -1
- package/dist/model/UserDfuStateMachineStatus.js +1 -1
- package/dist/model/UserFirmwareInfo.js +1 -1
- package/dist/model/{SimUsage.js → WebhookSettings.js} +47 -48
- package/package.json +1 -1
|
@@ -0,0 +1,312 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
var _Event = _interopRequireDefault(require("../model/Event"));
|
|
9
|
+
var _WebhookSettings = _interopRequireDefault(require("../model/WebhookSettings"));
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
11
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
12
|
+
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
13
|
+
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); } }
|
|
14
|
+
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
15
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
16
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
|
|
17
|
+
* Notehub API
|
|
18
|
+
* The OpenAPI definition for the Notehub.io API.
|
|
19
|
+
*
|
|
20
|
+
* The version of the OpenAPI document: 1.2.0
|
|
21
|
+
* Contact: engineering@blues.io
|
|
22
|
+
*
|
|
23
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
24
|
+
* https://openapi-generator.tech
|
|
25
|
+
* Do not edit the class manually.
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
28
|
+
/**
|
|
29
|
+
* Webhook service.
|
|
30
|
+
* @module api/WebhookApi
|
|
31
|
+
* @version 1.0.29-beta.5
|
|
32
|
+
*/
|
|
33
|
+
var WebhookApi = exports["default"] = /*#__PURE__*/function () {
|
|
34
|
+
/**
|
|
35
|
+
* Constructs a new WebhookApi.
|
|
36
|
+
* @alias module:api/WebhookApi
|
|
37
|
+
* @class
|
|
38
|
+
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
|
|
39
|
+
* default to {@link module:ApiClient#instance} if unspecified.
|
|
40
|
+
*/
|
|
41
|
+
function WebhookApi(apiClient) {
|
|
42
|
+
_classCallCheck(this, WebhookApi);
|
|
43
|
+
this.apiClient = apiClient || _ApiClient["default"].instance;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Creates an event using specified webhook
|
|
48
|
+
* @param {String} productUID
|
|
49
|
+
* @param {String} deviceUID
|
|
50
|
+
* @param {String} webhookUID Webhook UID
|
|
51
|
+
* @param {module:model/Event} event Event Object
|
|
52
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
53
|
+
*/
|
|
54
|
+
return _createClass(WebhookApi, [{
|
|
55
|
+
key: "createEventWithHttpInfo",
|
|
56
|
+
value: function createEventWithHttpInfo(productUID, deviceUID, webhookUID, event) {
|
|
57
|
+
var postBody = event;
|
|
58
|
+
// verify the required parameter 'productUID' is set
|
|
59
|
+
if (productUID === undefined || productUID === null) {
|
|
60
|
+
throw new Error("Missing the required parameter 'productUID' when calling createEvent");
|
|
61
|
+
}
|
|
62
|
+
// verify the required parameter 'deviceUID' is set
|
|
63
|
+
if (deviceUID === undefined || deviceUID === null) {
|
|
64
|
+
throw new Error("Missing the required parameter 'deviceUID' when calling createEvent");
|
|
65
|
+
}
|
|
66
|
+
// verify the required parameter 'webhookUID' is set
|
|
67
|
+
if (webhookUID === undefined || webhookUID === null) {
|
|
68
|
+
throw new Error("Missing the required parameter 'webhookUID' when calling createEvent");
|
|
69
|
+
}
|
|
70
|
+
// verify the required parameter 'event' is set
|
|
71
|
+
if (event === undefined || event === null) {
|
|
72
|
+
throw new Error("Missing the required parameter 'event' when calling createEvent");
|
|
73
|
+
}
|
|
74
|
+
var pathParams = {
|
|
75
|
+
'productUID': productUID,
|
|
76
|
+
'deviceUID': deviceUID,
|
|
77
|
+
'webhookUID': webhookUID
|
|
78
|
+
};
|
|
79
|
+
var queryParams = {};
|
|
80
|
+
var headerParams = {};
|
|
81
|
+
var formParams = {};
|
|
82
|
+
var authNames = ['api_key'];
|
|
83
|
+
var contentTypes = ['application/json'];
|
|
84
|
+
var accepts = [];
|
|
85
|
+
var returnType = null;
|
|
86
|
+
return this.apiClient.callApi('/v1/products/{productUID}/webhooks/{webhookUID}/event', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Creates an event using specified webhook
|
|
91
|
+
* @param {String} productUID
|
|
92
|
+
* @param {String} deviceUID
|
|
93
|
+
* @param {String} webhookUID Webhook UID
|
|
94
|
+
* @param {module:model/Event} event Event Object
|
|
95
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
96
|
+
*/
|
|
97
|
+
}, {
|
|
98
|
+
key: "createEvent",
|
|
99
|
+
value: function createEvent(productUID, deviceUID, webhookUID, event) {
|
|
100
|
+
return this.createEventWithHttpInfo(productUID, deviceUID, webhookUID, event).then(function (response_and_data) {
|
|
101
|
+
return response_and_data.data;
|
|
102
|
+
});
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* Creates a webhook for the specified product with the given name. The name | must be unique within the project.
|
|
107
|
+
* @param {String} webhookUID Webhook UID
|
|
108
|
+
* @param {module:model/WebhookSettings} webhookSettings
|
|
109
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
110
|
+
*/
|
|
111
|
+
}, {
|
|
112
|
+
key: "createWebhookWithHttpInfo",
|
|
113
|
+
value: function createWebhookWithHttpInfo(webhookUID, webhookSettings) {
|
|
114
|
+
var postBody = webhookSettings;
|
|
115
|
+
// verify the required parameter 'webhookUID' is set
|
|
116
|
+
if (webhookUID === undefined || webhookUID === null) {
|
|
117
|
+
throw new Error("Missing the required parameter 'webhookUID' when calling createWebhook");
|
|
118
|
+
}
|
|
119
|
+
// verify the required parameter 'webhookSettings' is set
|
|
120
|
+
if (webhookSettings === undefined || webhookSettings === null) {
|
|
121
|
+
throw new Error("Missing the required parameter 'webhookSettings' when calling createWebhook");
|
|
122
|
+
}
|
|
123
|
+
var pathParams = {
|
|
124
|
+
'webhookUID': webhookUID
|
|
125
|
+
};
|
|
126
|
+
var queryParams = {};
|
|
127
|
+
var headerParams = {};
|
|
128
|
+
var formParams = {};
|
|
129
|
+
var authNames = ['api_key'];
|
|
130
|
+
var contentTypes = ['application/json'];
|
|
131
|
+
var accepts = [];
|
|
132
|
+
var returnType = null;
|
|
133
|
+
return this.apiClient.callApi('/v1/products/{productUID}/webhooks/{webhookUID}', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
* Creates a webhook for the specified product with the given name. The name | must be unique within the project.
|
|
138
|
+
* @param {String} webhookUID Webhook UID
|
|
139
|
+
* @param {module:model/WebhookSettings} webhookSettings
|
|
140
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
141
|
+
*/
|
|
142
|
+
}, {
|
|
143
|
+
key: "createWebhook",
|
|
144
|
+
value: function createWebhook(webhookUID, webhookSettings) {
|
|
145
|
+
return this.createWebhookWithHttpInfo(webhookUID, webhookSettings).then(function (response_and_data) {
|
|
146
|
+
return response_and_data.data;
|
|
147
|
+
});
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* Deletes the specified webhook
|
|
152
|
+
* @param {String} webhookUID Webhook UID
|
|
153
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
154
|
+
*/
|
|
155
|
+
}, {
|
|
156
|
+
key: "deleteWebhookWithHttpInfo",
|
|
157
|
+
value: function deleteWebhookWithHttpInfo(webhookUID) {
|
|
158
|
+
var postBody = null;
|
|
159
|
+
// verify the required parameter 'webhookUID' is set
|
|
160
|
+
if (webhookUID === undefined || webhookUID === null) {
|
|
161
|
+
throw new Error("Missing the required parameter 'webhookUID' when calling deleteWebhook");
|
|
162
|
+
}
|
|
163
|
+
var pathParams = {
|
|
164
|
+
'webhookUID': webhookUID
|
|
165
|
+
};
|
|
166
|
+
var queryParams = {};
|
|
167
|
+
var headerParams = {};
|
|
168
|
+
var formParams = {};
|
|
169
|
+
var authNames = ['api_key'];
|
|
170
|
+
var contentTypes = [];
|
|
171
|
+
var accepts = [];
|
|
172
|
+
var returnType = null;
|
|
173
|
+
return this.apiClient.callApi('/v1/products/{productUID}/webhooks/{webhookUID}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* Deletes the specified webhook
|
|
178
|
+
* @param {String} webhookUID Webhook UID
|
|
179
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
180
|
+
*/
|
|
181
|
+
}, {
|
|
182
|
+
key: "deleteWebhook",
|
|
183
|
+
value: function deleteWebhook(webhookUID) {
|
|
184
|
+
return this.deleteWebhookWithHttpInfo(webhookUID).then(function (response_and_data) {
|
|
185
|
+
return response_and_data.data;
|
|
186
|
+
});
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
/**
|
|
190
|
+
* Retrieves the configuration settings for the specified webhook
|
|
191
|
+
* @param {String} webhookUID Webhook UID
|
|
192
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/WebhookSettings} and HTTP response
|
|
193
|
+
*/
|
|
194
|
+
}, {
|
|
195
|
+
key: "getWebhookSettingsWithHttpInfo",
|
|
196
|
+
value: function getWebhookSettingsWithHttpInfo(webhookUID) {
|
|
197
|
+
var postBody = null;
|
|
198
|
+
// verify the required parameter 'webhookUID' is set
|
|
199
|
+
if (webhookUID === undefined || webhookUID === null) {
|
|
200
|
+
throw new Error("Missing the required parameter 'webhookUID' when calling getWebhookSettings");
|
|
201
|
+
}
|
|
202
|
+
var pathParams = {
|
|
203
|
+
'webhookUID': webhookUID
|
|
204
|
+
};
|
|
205
|
+
var queryParams = {};
|
|
206
|
+
var headerParams = {};
|
|
207
|
+
var formParams = {};
|
|
208
|
+
var authNames = ['api_key'];
|
|
209
|
+
var contentTypes = [];
|
|
210
|
+
var accepts = ['application/json'];
|
|
211
|
+
var returnType = _WebhookSettings["default"];
|
|
212
|
+
return this.apiClient.callApi('/v1/products/{productUID}/webhooks/{webhookUID}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
/**
|
|
216
|
+
* Retrieves the configuration settings for the specified webhook
|
|
217
|
+
* @param {String} webhookUID Webhook UID
|
|
218
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/WebhookSettings}
|
|
219
|
+
*/
|
|
220
|
+
}, {
|
|
221
|
+
key: "getWebhookSettings",
|
|
222
|
+
value: function getWebhookSettings(webhookUID) {
|
|
223
|
+
return this.getWebhookSettingsWithHttpInfo(webhookUID).then(function (response_and_data) {
|
|
224
|
+
return response_and_data.data;
|
|
225
|
+
});
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
/**
|
|
229
|
+
* Retrieves all webhooks for the specified project
|
|
230
|
+
* @param {String} productUID
|
|
231
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/WebhookSettings>} and HTTP response
|
|
232
|
+
*/
|
|
233
|
+
}, {
|
|
234
|
+
key: "getWebhooksWithHttpInfo",
|
|
235
|
+
value: function getWebhooksWithHttpInfo(productUID) {
|
|
236
|
+
var postBody = null;
|
|
237
|
+
// verify the required parameter 'productUID' is set
|
|
238
|
+
if (productUID === undefined || productUID === null) {
|
|
239
|
+
throw new Error("Missing the required parameter 'productUID' when calling getWebhooks");
|
|
240
|
+
}
|
|
241
|
+
var pathParams = {
|
|
242
|
+
'productUID': productUID
|
|
243
|
+
};
|
|
244
|
+
var queryParams = {};
|
|
245
|
+
var headerParams = {};
|
|
246
|
+
var formParams = {};
|
|
247
|
+
var authNames = ['api_key'];
|
|
248
|
+
var contentTypes = [];
|
|
249
|
+
var accepts = ['application/json'];
|
|
250
|
+
var returnType = [_WebhookSettings["default"]];
|
|
251
|
+
return this.apiClient.callApi('/v1/products/{productUID}/webhooks', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* Retrieves all webhooks for the specified project
|
|
256
|
+
* @param {String} productUID
|
|
257
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/WebhookSettings>}
|
|
258
|
+
*/
|
|
259
|
+
}, {
|
|
260
|
+
key: "getWebhooks",
|
|
261
|
+
value: function getWebhooks(productUID) {
|
|
262
|
+
return this.getWebhooksWithHttpInfo(productUID).then(function (response_and_data) {
|
|
263
|
+
return response_and_data.data;
|
|
264
|
+
});
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* Updates the configuration settings for the specified webhook. | Webhook will be created if it does not exist. Update body will completely replace the existing settings.
|
|
269
|
+
* @param {String} webhookUID Webhook UID
|
|
270
|
+
* @param {module:model/WebhookSettings} webhookSettings
|
|
271
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing HTTP response
|
|
272
|
+
*/
|
|
273
|
+
}, {
|
|
274
|
+
key: "updateWebhookWithHttpInfo",
|
|
275
|
+
value: function updateWebhookWithHttpInfo(webhookUID, webhookSettings) {
|
|
276
|
+
var postBody = webhookSettings;
|
|
277
|
+
// verify the required parameter 'webhookUID' is set
|
|
278
|
+
if (webhookUID === undefined || webhookUID === null) {
|
|
279
|
+
throw new Error("Missing the required parameter 'webhookUID' when calling updateWebhook");
|
|
280
|
+
}
|
|
281
|
+
// verify the required parameter 'webhookSettings' is set
|
|
282
|
+
if (webhookSettings === undefined || webhookSettings === null) {
|
|
283
|
+
throw new Error("Missing the required parameter 'webhookSettings' when calling updateWebhook");
|
|
284
|
+
}
|
|
285
|
+
var pathParams = {
|
|
286
|
+
'webhookUID': webhookUID
|
|
287
|
+
};
|
|
288
|
+
var queryParams = {};
|
|
289
|
+
var headerParams = {};
|
|
290
|
+
var formParams = {};
|
|
291
|
+
var authNames = ['api_key'];
|
|
292
|
+
var contentTypes = ['application/json'];
|
|
293
|
+
var accepts = [];
|
|
294
|
+
var returnType = null;
|
|
295
|
+
return this.apiClient.callApi('/v1/products/{productUID}/webhooks/{webhookUID}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
/**
|
|
299
|
+
* Updates the configuration settings for the specified webhook. | Webhook will be created if it does not exist. Update body will completely replace the existing settings.
|
|
300
|
+
* @param {String} webhookUID Webhook UID
|
|
301
|
+
* @param {module:model/WebhookSettings} webhookSettings
|
|
302
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}
|
|
303
|
+
*/
|
|
304
|
+
}, {
|
|
305
|
+
key: "updateWebhook",
|
|
306
|
+
value: function updateWebhook(webhookUID, webhookSettings) {
|
|
307
|
+
return this.updateWebhookWithHttpInfo(webhookUID, webhookSettings).then(function (response_and_data) {
|
|
308
|
+
return response_and_data.data;
|
|
309
|
+
});
|
|
310
|
+
}
|
|
311
|
+
}]);
|
|
312
|
+
}();
|
package/dist/index.js
CHANGED
|
@@ -267,6 +267,18 @@ Object.defineProperty(exports, "EventApi", {
|
|
|
267
267
|
return _EventApi["default"];
|
|
268
268
|
}
|
|
269
269
|
});
|
|
270
|
+
Object.defineProperty(exports, "ExtDeviceSession", {
|
|
271
|
+
enumerable: true,
|
|
272
|
+
get: function get() {
|
|
273
|
+
return _ExtDeviceSession["default"];
|
|
274
|
+
}
|
|
275
|
+
});
|
|
276
|
+
Object.defineProperty(exports, "ExternalDevicesApi", {
|
|
277
|
+
enumerable: true,
|
|
278
|
+
get: function get() {
|
|
279
|
+
return _ExternalDevicesApi["default"];
|
|
280
|
+
}
|
|
281
|
+
});
|
|
270
282
|
Object.defineProperty(exports, "Firmware", {
|
|
271
283
|
enumerable: true,
|
|
272
284
|
get: function get() {
|
|
@@ -597,12 +609,6 @@ Object.defineProperty(exports, "RouteApi", {
|
|
|
597
609
|
return _RouteApi["default"];
|
|
598
610
|
}
|
|
599
611
|
});
|
|
600
|
-
Object.defineProperty(exports, "SimUsage", {
|
|
601
|
-
enumerable: true,
|
|
602
|
-
get: function get() {
|
|
603
|
-
return _SimUsage["default"];
|
|
604
|
-
}
|
|
605
|
-
});
|
|
606
612
|
Object.defineProperty(exports, "Slack", {
|
|
607
613
|
enumerable: true,
|
|
608
614
|
get: function get() {
|
|
@@ -687,6 +693,18 @@ Object.defineProperty(exports, "UserFirmwareInfo", {
|
|
|
687
693
|
return _UserFirmwareInfo["default"];
|
|
688
694
|
}
|
|
689
695
|
});
|
|
696
|
+
Object.defineProperty(exports, "WebhookApi", {
|
|
697
|
+
enumerable: true,
|
|
698
|
+
get: function get() {
|
|
699
|
+
return _WebhookApi["default"];
|
|
700
|
+
}
|
|
701
|
+
});
|
|
702
|
+
Object.defineProperty(exports, "WebhookSettings", {
|
|
703
|
+
enumerable: true,
|
|
704
|
+
get: function get() {
|
|
705
|
+
return _WebhookSettings["default"];
|
|
706
|
+
}
|
|
707
|
+
});
|
|
690
708
|
var _ApiClient = _interopRequireDefault(require("./ApiClient"));
|
|
691
709
|
var _Alert = _interopRequireDefault(require("./model/Alert"));
|
|
692
710
|
var _AlertDataInner = _interopRequireDefault(require("./model/AlertDataInner"));
|
|
@@ -726,6 +744,7 @@ var _EmailNotification = _interopRequireDefault(require("./model/EmailNotificati
|
|
|
726
744
|
var _EnvironmentVariables = _interopRequireDefault(require("./model/EnvironmentVariables"));
|
|
727
745
|
var _Error = _interopRequireDefault(require("./model/Error"));
|
|
728
746
|
var _Event = _interopRequireDefault(require("./model/Event"));
|
|
747
|
+
var _ExtDeviceSession = _interopRequireDefault(require("./model/ExtDeviceSession"));
|
|
729
748
|
var _Firmware = _interopRequireDefault(require("./model/Firmware"));
|
|
730
749
|
var _FirmwareInfo = _interopRequireDefault(require("./model/FirmwareInfo"));
|
|
731
750
|
var _Fleet = _interopRequireDefault(require("./model/Fleet"));
|
|
@@ -777,7 +796,6 @@ var _QuestionDataResponseMap = _interopRequireDefault(require("./model/QuestionD
|
|
|
777
796
|
var _Radresponder = _interopRequireDefault(require("./model/Radresponder"));
|
|
778
797
|
var _Repository = _interopRequireDefault(require("./model/Repository"));
|
|
779
798
|
var _Role = _interopRequireDefault(require("./model/Role"));
|
|
780
|
-
var _SimUsage = _interopRequireDefault(require("./model/SimUsage"));
|
|
781
799
|
var _Slack = _interopRequireDefault(require("./model/Slack"));
|
|
782
800
|
var _SlackBearerNotification = _interopRequireDefault(require("./model/SlackBearerNotification"));
|
|
783
801
|
var _SlackWebHookNotification = _interopRequireDefault(require("./model/SlackWebHookNotification"));
|
|
@@ -792,13 +810,16 @@ var _UserDbRoute = _interopRequireDefault(require("./model/UserDbRoute"));
|
|
|
792
810
|
var _UserDfuStateMachine = _interopRequireDefault(require("./model/UserDfuStateMachine"));
|
|
793
811
|
var _UserDfuStateMachineStatus = _interopRequireDefault(require("./model/UserDfuStateMachineStatus"));
|
|
794
812
|
var _UserFirmwareInfo = _interopRequireDefault(require("./model/UserFirmwareInfo"));
|
|
813
|
+
var _WebhookSettings = _interopRequireDefault(require("./model/WebhookSettings"));
|
|
795
814
|
var _AlertApi = _interopRequireDefault(require("./api/AlertApi"));
|
|
796
815
|
var _AuthorizationApi = _interopRequireDefault(require("./api/AuthorizationApi"));
|
|
797
816
|
var _BillingAccountApi = _interopRequireDefault(require("./api/BillingAccountApi"));
|
|
798
817
|
var _DeviceApi = _interopRequireDefault(require("./api/DeviceApi"));
|
|
799
818
|
var _EventApi = _interopRequireDefault(require("./api/EventApi"));
|
|
819
|
+
var _ExternalDevicesApi = _interopRequireDefault(require("./api/ExternalDevicesApi"));
|
|
800
820
|
var _MonitorApi = _interopRequireDefault(require("./api/MonitorApi"));
|
|
801
821
|
var _ProjectApi = _interopRequireDefault(require("./api/ProjectApi"));
|
|
802
822
|
var _RepositoryApi = _interopRequireDefault(require("./api/RepositoryApi"));
|
|
803
823
|
var _RouteApi = _interopRequireDefault(require("./api/RouteApi"));
|
|
824
|
+
var _WebhookApi = _interopRequireDefault(require("./api/WebhookApi"));
|
|
804
825
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
package/dist/model/Alert.js
CHANGED
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The AlertDataInner model module.
|
|
28
28
|
* @module model/AlertDataInner
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var AlertDataInner = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The AlertNotificationsInner model module.
|
|
28
28
|
* @module model/AlertNotificationsInner
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var AlertNotificationsInner = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
package/dist/model/Aws.js
CHANGED
package/dist/model/Azure.js
CHANGED
|
@@ -30,7 +30,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
30
30
|
/**
|
|
31
31
|
* The BillingAccount model module.
|
|
32
32
|
* @module model/BillingAccount
|
|
33
|
-
* @version 1.0.29-beta.
|
|
33
|
+
* @version 1.0.29-beta.5
|
|
34
34
|
*/
|
|
35
35
|
var BillingAccount = /*#__PURE__*/function () {
|
|
36
36
|
/**
|
package/dist/model/Body.js
CHANGED
|
@@ -29,7 +29,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
29
29
|
/**
|
|
30
30
|
* The CloneProjectRequest model module.
|
|
31
31
|
* @module model/CloneProjectRequest
|
|
32
|
-
* @version 1.0.29-beta.
|
|
32
|
+
* @version 1.0.29-beta.5
|
|
33
33
|
*/
|
|
34
34
|
var CloneProjectRequest = /*#__PURE__*/function () {
|
|
35
35
|
/**
|
package/dist/model/Contact.js
CHANGED
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The CreateFleetRequest model module.
|
|
28
28
|
* @module model/CreateFleetRequest
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var CreateFleetRequest = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
|
@@ -31,7 +31,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
31
31
|
/**
|
|
32
32
|
* The CreateMonitor model module.
|
|
33
33
|
* @module model/CreateMonitor
|
|
34
|
-
* @version 1.0.29-beta.
|
|
34
|
+
* @version 1.0.29-beta.5
|
|
35
35
|
*/
|
|
36
36
|
var CreateMonitor = /*#__PURE__*/function () {
|
|
37
37
|
/**
|
|
@@ -29,7 +29,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
29
29
|
/**
|
|
30
30
|
* The CreateProductRequest model module.
|
|
31
31
|
* @module model/CreateProductRequest
|
|
32
|
-
* @version 1.0.29-beta.
|
|
32
|
+
* @version 1.0.29-beta.5
|
|
33
33
|
*/
|
|
34
34
|
var CreateProductRequest = /*#__PURE__*/function () {
|
|
35
35
|
/**
|
|
@@ -29,7 +29,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
29
29
|
/**
|
|
30
30
|
* The CreateProjectRequest model module.
|
|
31
31
|
* @module model/CreateProjectRequest
|
|
32
|
-
* @version 1.0.29-beta.
|
|
32
|
+
* @version 1.0.29-beta.5
|
|
33
33
|
*/
|
|
34
34
|
var CreateProjectRequest = /*#__PURE__*/function () {
|
|
35
35
|
/**
|
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The CreateUpdateRepository model module.
|
|
28
28
|
* @module model/CreateUpdateRepository
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var CreateUpdateRepository = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
|
@@ -27,7 +27,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
27
27
|
/**
|
|
28
28
|
* The CurrentFirmware model module.
|
|
29
29
|
* @module model/CurrentFirmware
|
|
30
|
-
* @version 1.0.29-beta.
|
|
30
|
+
* @version 1.0.29-beta.5
|
|
31
31
|
*/
|
|
32
32
|
var CurrentFirmware = /*#__PURE__*/function () {
|
|
33
33
|
/**
|
package/dist/model/DFUEnv.js
CHANGED
package/dist/model/DFUState.js
CHANGED
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The DFUState model module.
|
|
28
28
|
* @module model/DFUState
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var DFUState = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
package/dist/model/DataField.js
CHANGED
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The DataField model module.
|
|
28
28
|
* @module model/DataField
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var DataField = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
package/dist/model/DataSet.js
CHANGED
|
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
26
26
|
/**
|
|
27
27
|
* The DataSetField model module.
|
|
28
28
|
* @module model/DataSetField
|
|
29
|
-
* @version 1.0.29-beta.
|
|
29
|
+
* @version 1.0.29-beta.5
|
|
30
30
|
*/
|
|
31
31
|
var DataSetField = /*#__PURE__*/function () {
|
|
32
32
|
/**
|
|
@@ -29,7 +29,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
29
29
|
/**
|
|
30
30
|
* The DeleteDeviceFleetsRequest model module.
|
|
31
31
|
* @module model/DeleteDeviceFleetsRequest
|
|
32
|
-
* @version 1.0.29-beta.
|
|
32
|
+
* @version 1.0.29-beta.5
|
|
33
33
|
*/
|
|
34
34
|
var DeleteDeviceFleetsRequest = /*#__PURE__*/function () {
|
|
35
35
|
/**
|