@kohost/api-client 3.1.13 → 3.1.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/dist/cjs/Errors/AppError.js +1 -0
  2. package/dist/cjs/Errors/AuthenticationError.js +1 -0
  3. package/dist/cjs/Errors/AuthorizationError.js +1 -0
  4. package/dist/cjs/Errors/ConflictError.js +1 -0
  5. package/dist/cjs/Errors/DeviceCommError.js +1 -0
  6. package/dist/cjs/Errors/LoginError.js +1 -0
  7. package/dist/cjs/Errors/NotFoundError.js +1 -0
  8. package/dist/cjs/Errors/RequestError.js +1 -0
  9. package/dist/cjs/Errors/SystemCommError.js +1 -0
  10. package/dist/cjs/Errors/TokenExpiredError.js +1 -0
  11. package/dist/cjs/Errors/UnprocessableRequestError.js +1 -0
  12. package/dist/cjs/Errors/ValidationError.js +1 -0
  13. package/dist/cjs/schemas/AlarmSchema.d.ts +5 -2
  14. package/dist/cjs/schemas/CameraSchema.d.ts +5 -2
  15. package/dist/cjs/schemas/CourtesySchema.d.ts +5 -2
  16. package/dist/cjs/schemas/DimmerSchema.d.ts +5 -2
  17. package/dist/cjs/schemas/GatewaySchema.d.ts +5 -2
  18. package/dist/cjs/schemas/LockSchema.d.ts +5 -2
  19. package/dist/cjs/schemas/MediaSourceSchema.d.ts +5 -2
  20. package/dist/cjs/schemas/MotionSensorSchema.d.ts +5 -2
  21. package/dist/cjs/schemas/RoomSchema.d.ts +23 -11
  22. package/dist/cjs/schemas/SwitchSchema.d.ts +5 -2
  23. package/dist/cjs/schemas/ThermostatSchema.d.ts +5 -2
  24. package/dist/cjs/schemas/WindowCoveringSchema.d.ts +5 -2
  25. package/dist/cjs/schemas/definitions.json +2 -1
  26. package/dist/esm/Commands.js +12 -0
  27. package/dist/esm/Commands.js.map +2 -2
  28. package/dist/esm/Errors.js +12 -0
  29. package/dist/esm/Errors.js.map +2 -2
  30. package/dist/esm/Models.js +14 -1
  31. package/dist/esm/Models.js.map +2 -2
  32. package/dist/esm/utils.js +14 -1
  33. package/dist/esm/utils.js.map +2 -2
  34. package/package.json +1 -1
@@ -3,6 +3,7 @@ module.exports = class AppError extends Error {
3
3
  super(message, options);
4
4
  this.type = this.constructor.name;
5
5
  this.statusCode = 500;
6
+ this.name = "AppError";
6
7
  Object.setPrototypeOf(this, AppError.prototype);
7
8
  }
8
9
  };
@@ -4,6 +4,7 @@ module.exports = class AuthenticationError extends AppError {
4
4
  constructor(message = "Authentication Error", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 401;
7
+ this.name = "AuthenticationError";
7
8
  Object.setPrototypeOf(this, AuthenticationError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class AuthorizationError extends AppError {
4
4
  constructor(message = "Authorization Error", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 403;
7
+ this.name = "AuthorizationError";
7
8
  Object.setPrototypeOf(this, AuthorizationError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class ConflictError extends AppError {
4
4
  constructor(message = "Bad Request", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 409;
7
+ this.name = "ConflictError";
7
8
  Object.setPrototypeOf(this, ConflictError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class DeviceCommError extends AppError {
4
4
  constructor(message = "Device Communication Error", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 503;
7
+ this.name = "DeviceCommError";
7
8
  Object.setPrototypeOf(this, DeviceCommError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class LoginError extends AppError {
4
4
  constructor(message = "Invalid Login information provided", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 401;
7
+ this.name = "LoginError";
7
8
  Object.setPrototypeOf(this, LoginError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class NotFoundError extends AppError {
4
4
  constructor(message = "Resource Not Found", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 404;
7
+ this.name = "NotFoundError";
7
8
  Object.setPrototypeOf(this, NotFoundError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class RequestError extends AppError {
4
4
  constructor(message = "Bad Request", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 400;
7
+ this.name = "RequestError";
7
8
  Object.setPrototypeOf(this, RequestError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class SystemCommError extends AppError {
4
4
  constructor(message = "System Communication Error", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 503;
7
+ this.name = "SystemCommError";
7
8
  Object.setPrototypeOf(this, SystemCommError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class TokenExpiredError extends AppError {
4
4
  constructor(message = "Token Expired", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 401;
7
+ this.name = "TokenExpiredError";
7
8
  Object.setPrototypeOf(this, TokenExpiredError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class UnprocessableRequestError extends AppError {
4
4
  constructor(message = "Unprocessable Request Error", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 422;
7
+ this.name = "UnprocessableRequestError";
7
8
  Object.setPrototypeOf(this, UnprocessableRequestError.prototype);
8
9
  }
9
10
  };
@@ -4,6 +4,7 @@ module.exports = class ValidationError extends AppError {
4
4
  constructor(message = "Validation Error", options = {}) {
5
5
  super(message, options);
6
6
  this.statusCode = 400;
7
+ this.name = "ValidationError";
7
8
  Object.setPrototypeOf(this, ValidationError.prototype);
8
9
  }
9
10
  };
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -232,7 +235,8 @@ export interface Switch {
232
235
  | "outsideSafeTemperatureRange"
233
236
  | "outsideSafeHumidityRange"
234
237
  | "scheduleMaintenance"
235
- | "doorAjar";
238
+ | "doorAjar"
239
+ | "communicationFailure";
236
240
  timestamp?: number;
237
241
  description?: string;
238
242
  [k: string]: unknown;
@@ -355,7 +359,8 @@ export interface Thermostat {
355
359
  | "outsideSafeTemperatureRange"
356
360
  | "outsideSafeHumidityRange"
357
361
  | "scheduleMaintenance"
358
- | "doorAjar";
362
+ | "doorAjar"
363
+ | "communicationFailure";
359
364
  timestamp?: number;
360
365
  description?: string;
361
366
  [k: string]: unknown;
@@ -444,7 +449,8 @@ export interface Lock {
444
449
  | "outsideSafeTemperatureRange"
445
450
  | "outsideSafeHumidityRange"
446
451
  | "scheduleMaintenance"
447
- | "doorAjar";
452
+ | "doorAjar"
453
+ | "communicationFailure";
448
454
  timestamp?: number;
449
455
  description?: string;
450
456
  [k: string]: unknown;
@@ -540,7 +546,8 @@ export interface WindowCovering {
540
546
  | "outsideSafeTemperatureRange"
541
547
  | "outsideSafeHumidityRange"
542
548
  | "scheduleMaintenance"
543
- | "doorAjar";
549
+ | "doorAjar"
550
+ | "communicationFailure";
544
551
  timestamp?: number;
545
552
  description?: string;
546
553
  [k: string]: unknown;
@@ -631,7 +638,8 @@ export interface Courtesy {
631
638
  | "outsideSafeTemperatureRange"
632
639
  | "outsideSafeHumidityRange"
633
640
  | "scheduleMaintenance"
634
- | "doorAjar";
641
+ | "doorAjar"
642
+ | "communicationFailure";
635
643
  timestamp?: number;
636
644
  description?: string;
637
645
  [k: string]: unknown;
@@ -723,7 +731,8 @@ export interface Camera {
723
731
  | "outsideSafeTemperatureRange"
724
732
  | "outsideSafeHumidityRange"
725
733
  | "scheduleMaintenance"
726
- | "doorAjar";
734
+ | "doorAjar"
735
+ | "communicationFailure";
727
736
  timestamp?: number;
728
737
  description?: string;
729
738
  [k: string]: unknown;
@@ -950,7 +959,8 @@ export interface MediaSource {
950
959
  | "outsideSafeTemperatureRange"
951
960
  | "outsideSafeHumidityRange"
952
961
  | "scheduleMaintenance"
953
- | "doorAjar";
962
+ | "doorAjar"
963
+ | "communicationFailure";
954
964
  timestamp?: number;
955
965
  description?: string;
956
966
  [k: string]: unknown;
@@ -1038,7 +1048,8 @@ export interface MotionSensor {
1038
1048
  | "outsideSafeTemperatureRange"
1039
1049
  | "outsideSafeHumidityRange"
1040
1050
  | "scheduleMaintenance"
1041
- | "doorAjar";
1051
+ | "doorAjar"
1052
+ | "communicationFailure";
1042
1053
  timestamp?: number;
1043
1054
  description?: string;
1044
1055
  [k: string]: unknown;
@@ -1096,7 +1107,8 @@ export interface Alarm {
1096
1107
  | "outsideSafeTemperatureRange"
1097
1108
  | "outsideSafeHumidityRange"
1098
1109
  | "scheduleMaintenance"
1099
- | "doorAjar";
1110
+ | "doorAjar"
1111
+ | "communicationFailure";
1100
1112
  timestamp?: number;
1101
1113
  description?: string;
1102
1114
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -29,6 +29,7 @@ export type SupportedNotifications = (
29
29
  | "outsideSafeHumidityRange"
30
30
  | "scheduleMaintenance"
31
31
  | "doorAjar"
32
+ | "communicationFailure"
32
33
  )[];
33
34
  export type Notification = {
34
35
  name?:
@@ -54,7 +55,8 @@ export type Notification = {
54
55
  | "outsideSafeTemperatureRange"
55
56
  | "outsideSafeHumidityRange"
56
57
  | "scheduleMaintenance"
57
- | "doorAjar";
58
+ | "doorAjar"
59
+ | "communicationFailure";
58
60
  timestamp?: number;
59
61
  description?: string;
60
62
  [k: string]: unknown;
@@ -82,7 +84,8 @@ export type Notification = {
82
84
  | "outsideSafeTemperatureRange"
83
85
  | "outsideSafeHumidityRange"
84
86
  | "scheduleMaintenance"
85
- | "doorAjar";
87
+ | "doorAjar"
88
+ | "communicationFailure";
86
89
  timestamp?: number;
87
90
  description?: string;
88
91
  [k: string]: unknown;
@@ -170,7 +170,8 @@
170
170
  "outsideSafeTemperatureRange",
171
171
  "outsideSafeHumidityRange",
172
172
  "scheduleMaintenance",
173
- "doorAjar"
173
+ "doorAjar",
174
+ "communicationFailure"
174
175
  ]
175
176
  }
176
177
  },
@@ -277,6 +277,7 @@ var require_AppError = __commonJS({
277
277
  super(message, options);
278
278
  this.type = this.constructor.name;
279
279
  this.statusCode = 500;
280
+ this.name = "AppError";
280
281
  Object.setPrototypeOf(this, AppError.prototype);
281
282
  }
282
283
  };
@@ -294,6 +295,7 @@ var require_RequestError = __commonJS({
294
295
  constructor(message = "Bad Request", options = {}) {
295
296
  super(message, options);
296
297
  this.statusCode = 400;
298
+ this.name = "RequestError";
297
299
  Object.setPrototypeOf(this, RequestError.prototype);
298
300
  }
299
301
  };
@@ -445,6 +447,7 @@ var require_AuthenticationError = __commonJS({
445
447
  constructor(message = "Authentication Error", options = {}) {
446
448
  super(message, options);
447
449
  this.statusCode = 401;
450
+ this.name = "AuthenticationError";
448
451
  Object.setPrototypeOf(this, AuthenticationError.prototype);
449
452
  }
450
453
  };
@@ -462,6 +465,7 @@ var require_AuthorizationError = __commonJS({
462
465
  constructor(message = "Authorization Error", options = {}) {
463
466
  super(message, options);
464
467
  this.statusCode = 403;
468
+ this.name = "AuthorizationError";
465
469
  Object.setPrototypeOf(this, AuthorizationError.prototype);
466
470
  }
467
471
  };
@@ -479,6 +483,7 @@ var require_ConflictError = __commonJS({
479
483
  constructor(message = "Bad Request", options = {}) {
480
484
  super(message, options);
481
485
  this.statusCode = 409;
486
+ this.name = "ConflictError";
482
487
  Object.setPrototypeOf(this, ConflictError.prototype);
483
488
  }
484
489
  };
@@ -496,6 +501,7 @@ var require_DeviceCommError = __commonJS({
496
501
  constructor(message = "Device Communication Error", options = {}) {
497
502
  super(message, options);
498
503
  this.statusCode = 503;
504
+ this.name = "DeviceCommError";
499
505
  Object.setPrototypeOf(this, DeviceCommError.prototype);
500
506
  }
501
507
  };
@@ -513,6 +519,7 @@ var require_LoginError = __commonJS({
513
519
  constructor(message = "Invalid Login information provided", options = {}) {
514
520
  super(message, options);
515
521
  this.statusCode = 401;
522
+ this.name = "LoginError";
516
523
  Object.setPrototypeOf(this, LoginError.prototype);
517
524
  }
518
525
  };
@@ -530,6 +537,7 @@ var require_NotFoundError = __commonJS({
530
537
  constructor(message = "Resource Not Found", options = {}) {
531
538
  super(message, options);
532
539
  this.statusCode = 404;
540
+ this.name = "NotFoundError";
533
541
  Object.setPrototypeOf(this, NotFoundError.prototype);
534
542
  }
535
543
  };
@@ -547,6 +555,7 @@ var require_SystemCommError = __commonJS({
547
555
  constructor(message = "System Communication Error", options = {}) {
548
556
  super(message, options);
549
557
  this.statusCode = 503;
558
+ this.name = "SystemCommError";
550
559
  Object.setPrototypeOf(this, SystemCommError.prototype);
551
560
  }
552
561
  };
@@ -564,6 +573,7 @@ var require_TokenExpiredError = __commonJS({
564
573
  constructor(message = "Token Expired", options = {}) {
565
574
  super(message, options);
566
575
  this.statusCode = 401;
576
+ this.name = "TokenExpiredError";
567
577
  Object.setPrototypeOf(this, TokenExpiredError.prototype);
568
578
  }
569
579
  };
@@ -581,6 +591,7 @@ var require_UnprocessableRequestError = __commonJS({
581
591
  constructor(message = "Unprocessable Request Error", options = {}) {
582
592
  super(message, options);
583
593
  this.statusCode = 422;
594
+ this.name = "UnprocessableRequestError";
584
595
  Object.setPrototypeOf(this, UnprocessableRequestError.prototype);
585
596
  }
586
597
  };
@@ -598,6 +609,7 @@ var require_ValidationError = __commonJS({
598
609
  constructor(message = "Validation Error", options = {}) {
599
610
  super(message, options);
600
611
  this.statusCode = 400;
612
+ this.name = "ValidationError";
601
613
  Object.setPrototypeOf(this, ValidationError.prototype);
602
614
  }
603
615
  };