@hawk.so/types 0.1.13 → 0.1.17

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/build/index.d.ts CHANGED
@@ -26,4 +26,5 @@ export * from "./src/notifications/createProjectNotifications";
26
26
  export * from "./src/notifications/receiveTypes";
27
27
  export * from "./src/notifications/updateProjectNotifications";
28
28
  export * from "./src/notifications/userNotification";
29
+ export * from "./src/catchers/catcher-message";
29
30
  export * from './src/utils';
package/build/index.js CHANGED
@@ -38,4 +38,5 @@ __exportStar(require("./src/notifications/createProjectNotifications"), exports)
38
38
  __exportStar(require("./src/notifications/receiveTypes"), exports);
39
39
  __exportStar(require("./src/notifications/updateProjectNotifications"), exports);
40
40
  __exportStar(require("./src/notifications/userNotification"), exports);
41
+ __exportStar(require("./src/catchers/catcher-message"), exports);
41
42
  __exportStar(require("./src/utils"), exports);
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This interface represents data that can be additionally collected by Default Catcher
3
+ */
4
+ export interface DefaultAddons {
5
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -3,8 +3,9 @@ import { PhpAddons } from './php';
3
3
  import { NodeJSAddons } from './nodejs';
4
4
  import { GoAddons } from './go';
5
5
  import { PythonAddons } from './python';
6
+ import { DefaultAddons } from './default';
6
7
  /**
7
8
  * Union Type describing all catcher-specific additional data
8
9
  */
9
- declare type EventAddons = JavaScriptAddons | PhpAddons | NodeJSAddons | GoAddons | PythonAddons;
10
- export { WindowData, VueIntegrationAddons, BeautifiedUserAgent, EventAddons, JavaScriptAddons, PhpAddons, NodeJSAddons, GoAddons, PythonAddons };
10
+ declare type EventAddons = JavaScriptAddons | PhpAddons | NodeJSAddons | GoAddons | PythonAddons | DefaultAddons;
11
+ export { WindowData, VueIntegrationAddons, BeautifiedUserAgent, EventAddons, JavaScriptAddons, PhpAddons, NodeJSAddons, GoAddons, PythonAddons, DefaultAddons };
@@ -0,0 +1,19 @@
1
+ import { EventData } from "../base/event/event";
2
+ import { EventAddons } from "../base/event/addons";
3
+ /**
4
+ * Structure describing a message sending by Catcher
5
+ */
6
+ export default interface CatcherMessage<CatcherAddons extends EventAddons> {
7
+ /**
8
+ * User project's Integration Token
9
+ */
10
+ token: string;
11
+ /**
12
+ * Hawk Catcher name
13
+ */
14
+ catcherType: string;
15
+ /**
16
+ * All information about the event
17
+ */
18
+ payload: EventData<CatcherAddons>;
19
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -23,4 +23,9 @@ export interface PlanDBScheme {
23
23
  * Is this plan used by default?
24
24
  */
25
25
  isDefault: boolean;
26
+ /**
27
+ * Special plans to be selected manually
28
+ * No one cannot be switched to this plan by api
29
+ */
30
+ isHidden: boolean;
26
31
  }
package/index.ts CHANGED
@@ -33,4 +33,6 @@ export * from "./src/notifications/receiveTypes";
33
33
  export * from "./src/notifications/updateProjectNotifications";
34
34
  export * from "./src/notifications/userNotification";
35
35
 
36
+ export * from "./src/catchers/catcher-message";
37
+
36
38
  export * from './src/utils';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hawk.so/types",
3
- "version": "0.1.13",
3
+ "version": "0.1.17",
4
4
  "description": "TypeScript definitions for Hawk",
5
5
  "types": "build/index.d.ts",
6
6
  "main": "build/index.js",
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This interface represents data that can be additionally collected by Default Catcher
3
+ */
4
+ export interface DefaultAddons {}
@@ -3,6 +3,7 @@ import { PhpAddons } from './php';
3
3
  import { NodeJSAddons } from './nodejs';
4
4
  import { GoAddons } from './go';
5
5
  import { PythonAddons } from './python';
6
+ import { DefaultAddons } from './default';
6
7
 
7
8
  /**
8
9
  * Union Type describing all catcher-specific additional data
@@ -13,6 +14,7 @@ type EventAddons =
13
14
  | NodeJSAddons
14
15
  | GoAddons
15
16
  | PythonAddons
17
+ | DefaultAddons
16
18
  ;
17
19
 
18
20
  export {
@@ -24,5 +26,6 @@ export {
24
26
  PhpAddons,
25
27
  NodeJSAddons,
26
28
  GoAddons,
27
- PythonAddons
29
+ PythonAddons,
30
+ DefaultAddons
28
31
  }
@@ -0,0 +1,22 @@
1
+ import { EventData } from "../base/event/event";
2
+ import { EventAddons } from "../base/event/addons";
3
+
4
+ /**
5
+ * Structure describing a message sending by Catcher
6
+ */
7
+ export default interface CatcherMessage<CatcherAddons extends EventAddons> {
8
+ /**
9
+ * User project's Integration Token
10
+ */
11
+ token: string;
12
+
13
+ /**
14
+ * Hawk Catcher name
15
+ */
16
+ catcherType: string;
17
+
18
+ /**
19
+ * All information about the event
20
+ */
21
+ payload: EventData<CatcherAddons>;
22
+ }
@@ -28,4 +28,10 @@ export interface PlanDBScheme {
28
28
  * Is this plan used by default?
29
29
  */
30
30
  isDefault: boolean;
31
+
32
+ /**
33
+ * Special plans to be selected manually
34
+ * No one cannot be switched to this plan by api
35
+ */
36
+ isHidden: boolean;
31
37
  }