@betterview/integration-toolkit 4.2.0 → 5.0.0
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.
|
@@ -3,10 +3,11 @@ import { IntegrationEventName, Storage } from '.';
|
|
|
3
3
|
* Base class for integrations. All integrations should default export a class that extends this class.
|
|
4
4
|
*/
|
|
5
5
|
export declare class Integration {
|
|
6
|
-
protected credentials: Record<string,
|
|
6
|
+
protected credentials: Record<string, string>;
|
|
7
|
+
protected options: Record<string, string>;
|
|
7
8
|
protected storage: Storage;
|
|
8
9
|
private events;
|
|
9
|
-
constructor(credentials: Record<string,
|
|
10
|
+
constructor(credentials: Record<string, string>, options: Record<string, string>, storage: Storage);
|
|
10
11
|
/**
|
|
11
12
|
* Initializer for the class. This will be called once per instance of the integration. Multiple instances
|
|
12
13
|
* of an integration may be loaded throughout the system. Integrations should override this method if they
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Integration.d.ts","sourceRoot":"","sources":["../../src/types/Integration.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC;AAElD;;GAEG;AACH,qBAAa,WAAW;
|
|
1
|
+
{"version":3,"file":"Integration.d.ts","sourceRoot":"","sources":["../../src/types/Integration.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC;AAElD;;GAEG;AACH,qBAAa,WAAW;IAIpB,SAAS,CAAC,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAC7C,SAAS,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IACzC,SAAS,CAAC,OAAO,EAAE,OAAO;IAL5B,OAAO,CAAC,MAAM,CAAe;gBAGjB,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EACnC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC/B,OAAO,EAAE,OAAO;IAI5B;;;;OAIG;IACU,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAI3B,EAAE,CAAC,SAAS,EAAE,oBAAoB,CAAC,cAAc,EAAE,OAAO,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,KAAK,IAAI,GAAG,IAAI;IACrG,EAAE,CAAC,SAAS,EAAE,oBAAoB,CAAC,cAAc,EAAE,OAAO,EAAE,CAAC,IAAI,EAAE,GAAG,EAAE,UAAU,CAAC,EAAE,MAAM,KAAK,IAAI,GAAG,IAAI;IAC3G,EAAE,CAAC,SAAS,EAAE,oBAAoB,CAAC,OAAO,EAAE,OAAO,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,GAAG,IAAI;IAMnF,IAAI,CAAC,SAAS,EAAE,oBAAoB,CAAC,cAAc,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,GAAG,OAAO;IACvF,IAAI,CAAC,SAAS,EAAE,oBAAoB,CAAC,cAAc,EAAE,IAAI,EAAE,GAAG,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO;IAC7F,IAAI,CAAC,SAAS,EAAE,oBAAoB,CAAC,OAAO,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO;CAI7E"}
|
package/lib/types/Integration.js
CHANGED
|
@@ -6,8 +6,9 @@ const events_1 = require("events");
|
|
|
6
6
|
* Base class for integrations. All integrations should default export a class that extends this class.
|
|
7
7
|
*/
|
|
8
8
|
class Integration {
|
|
9
|
-
constructor(credentials, storage) {
|
|
9
|
+
constructor(credentials, options, storage) {
|
|
10
10
|
this.credentials = credentials;
|
|
11
|
+
this.options = options;
|
|
11
12
|
this.storage = storage;
|
|
12
13
|
this.events = new events_1.EventEmitter();
|
|
13
14
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Integration.js","sourceRoot":"","sources":["../../src/types/Integration.ts"],"names":[],"mappings":";;;AAAA,mCAAsC;AAGtC;;GAEG;AACH,MAAa,WAAW;IAGtB,
|
|
1
|
+
{"version":3,"file":"Integration.js","sourceRoot":"","sources":["../../src/types/Integration.ts"],"names":[],"mappings":";;;AAAA,mCAAsC;AAGtC;;GAEG;AACH,MAAa,WAAW;IAGtB,YACY,WAAmC,EACnC,OAA+B,EAC/B,OAAgB;QAFhB,gBAAW,GAAX,WAAW,CAAwB;QACnC,YAAO,GAAP,OAAO,CAAwB;QAC/B,YAAO,GAAP,OAAO,CAAS;QAE1B,IAAI,CAAC,MAAM,GAAG,IAAI,qBAAY,EAAE,CAAC;IACnC,CAAC;IACD;;;;OAIG;IACI,KAAK,CAAC,IAAI;QACf,OAAO;IACT,CAAC;IAKM,EAAE,CAAC,SAA+B,EAAE,OAAiC;QAC1E,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;QACnC,OAAO,IAAI,CAAC;IACd,CAAC;IAKM,IAAI,CAAC,SAA+B,EAAE,GAAG,IAAW;QACzD,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,GAAG,IAAI,CAAC,CAAC;IAC9C,CAAC;CACF;AAjCD,kCAiCC"}
|
|
@@ -40,6 +40,10 @@ export declare type IntegrationManifest = {
|
|
|
40
40
|
display: string;
|
|
41
41
|
sensitive?: boolean;
|
|
42
42
|
}>;
|
|
43
|
+
options_schema?: Record<string, {
|
|
44
|
+
display: string;
|
|
45
|
+
required?: boolean;
|
|
46
|
+
}>;
|
|
43
47
|
};
|
|
44
48
|
declare type Cadence = {
|
|
45
49
|
schedule: 'daily' | 'weekly' | 'monthly';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IntegrationManifest.d.ts","sourceRoot":"","sources":["../../src/types/IntegrationManifest.ts"],"names":[],"mappings":"AAAA,oBAAY,mBAAmB,GAAG;IAChC,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,C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YAAY,EAAE;QACZ,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,EAAE,CAAC;QAC9B,OAAO,CAAC,EAAE,OAAO,CAAC;QAElB,UAAU,CAAC,EAAE;YAKX,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;YAEpB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;YACpB;;;;eAIG;YACH,QAAQ,CAAC,EAAE,OAAO,CAAC;SACpB,CAAC;KACH,CAAC;IACF;;;;OAIG;IACH,QAAQ,CAAC,EAAE;QAET,KAAK,EAAE,MAAM,CAAC;KACf,EAAE,CAAC;IACJ;;OAEG;IACH,UAAU,CAAC,EAAE;QACX,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;KACd,EAAE,CAAC;IACJ,kBAAkB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,SAAS,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC,CAAC;IAC9E,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC,CAAC;CAC1E,CAAC;AAEF,aAAK,OAAO,GAAG;IACb,QAAQ,EAAE,OAAO,GAAG,QAAQ,GAAG,SAAS,CAAC;IAEzC,KAAK,EAAE,MAAM,CAAC;CACf,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@betterview/integration-toolkit",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"description": "Supports integration packages. This should be the only import from our integrations",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"prebuild": "rm -rf ./lib",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"typescript": "4.3.2"
|
|
45
45
|
},
|
|
46
46
|
"engines": {
|
|
47
|
-
"node": "^14 || ^16"
|
|
47
|
+
"node": "^14 || ^16 || ^18"
|
|
48
48
|
},
|
|
49
49
|
"files": [
|
|
50
50
|
"lib/**"
|