@edgeiq/edgeiq-api-js 1.9.1 → 1.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,7 @@ import { BulkActionResponse, PaginationFilter } from '../models';
4
4
  import { DeviceType, DeviceTypeInput, DeviceTypesFilters, PaginatedDeviceTypes } from './models';
5
5
  interface DeviceTypesInterface extends BaseModelInterface<DeviceType, DeviceTypeInput, DeviceTypesFilters, PaginatedDeviceTypes> {
6
6
  update(deviceType: DeviceType): Promise<DeviceType>;
7
+ deleteMetadata(id: string): Promise<DeviceType>;
7
8
  deleteMultiple(ids: string[]): Promise<BulkActionResponse>;
8
9
  attachIngestor(id: string, ingestorId: string): Promise<string>;
9
10
  detachIngestor(id: string, ingestorId: string): Promise<string>;
@@ -47,6 +47,24 @@ export const DeviceTypes = class extends BaseModelClass {
47
47
  }
48
48
  });
49
49
  }
50
+ static deleteMetadata(id) {
51
+ return __awaiter(this, void 0, void 0, function* () {
52
+ try {
53
+ this.logAction(`Delete device type metadata with ID: ${id}`);
54
+ const axios = EdgeIQAPI.getAxios();
55
+ const result = yield axios.put(`${Endpoints.deviceType}/${id}`, {
56
+ metadata: {},
57
+ });
58
+ return result === null || result === void 0 ? void 0 : result.data;
59
+ }
60
+ catch (error) {
61
+ if (isApiError(error)) {
62
+ throw error;
63
+ }
64
+ throw error;
65
+ }
66
+ });
67
+ }
50
68
  static list(filters, pagination) {
51
69
  var _a, _b, _c, _d;
52
70
  return __awaiter(this, void 0, void 0, function* () {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edgeiq/edgeiq-api-js",
3
- "version": "1.9.1",
3
+ "version": "1.9.2",
4
4
  "author": "EdgeIQ",
5
5
  "license": "ISC",
6
6
  "description": "This project presents EdgeIQ API SDK.",