@transai/connector-runner-ai-agent 0.19.0 → 0.20.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.
- package/CHANGELOG.md +12 -0
- package/index.cjs +141 -141
- package/index.cjs.map +3 -3
- package/libs/types/src/lib/management-api/connector/connector.interface.d.ts +5 -0
- package/libs/types/src/lib/management-api/connector/connectors.interface.d.ts +5 -0
- package/libs/types/src/lib/management-api/semantic-trigger/semantic-trigger-record.interface.d.ts +4 -2
- package/libs/types/src/lib/management-api/semantic-trigger/semantic-trigger.interface.d.ts +25 -2
- package/libs/types/src/lib/management-api/semantic-trigger/semantic-triggers.interface.d.ts +1 -1
- package/libs/types/src/lib/management-api/template-implementation-overrides.interface.d.ts +6 -1
- package/libs/types/src/lib/management-api/template-implementation.interface.d.ts +12 -2
- package/libs/types/src/lib/management-api/template.interface.d.ts +6 -1
- package/libs/types/src/lib/management-api/webhook/webhook.interface.d.ts +34 -0
- package/libs/types/src/lib/types.d.ts +2 -1
- package/package.json +1 -1
|
@@ -46,6 +46,11 @@ export declare const ConnectorSchema: z.ZodObject<{
|
|
|
46
46
|
description: z.ZodOptional<z.ZodString>;
|
|
47
47
|
actionIdentifier: z.ZodString;
|
|
48
48
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
49
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
50
|
+
selector: z.ZodString;
|
|
51
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof import("../webhook").WebhookValidationOperator>>>;
|
|
52
|
+
value: z.ZodString;
|
|
53
|
+
}, z.core.$strip>>>;
|
|
49
54
|
}, z.core.$strip>>>;
|
|
50
55
|
createdAt: z.ZodOptional<z.ZodDate>;
|
|
51
56
|
updatedAt: z.ZodOptional<z.ZodDate>;
|
|
@@ -43,6 +43,11 @@ export declare const ConnectorsSchema: z.ZodRecord<z.ZodString, z.ZodUnion<[z.Zo
|
|
|
43
43
|
description: z.ZodOptional<z.ZodString>;
|
|
44
44
|
actionIdentifier: z.ZodString;
|
|
45
45
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
46
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
47
|
+
selector: z.ZodString;
|
|
48
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof import("../index").WebhookValidationOperator>>>;
|
|
49
|
+
value: z.ZodString;
|
|
50
|
+
}, z.core.$strip>>>;
|
|
46
51
|
}, z.core.$strip>>>;
|
|
47
52
|
createdAt: z.ZodOptional<z.ZodDate>;
|
|
48
53
|
updatedAt: z.ZodOptional<z.ZodDate>;
|
package/libs/types/src/lib/management-api/semantic-trigger/semantic-trigger-record.interface.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface SemanticTriggerRecordInterface extends
|
|
1
|
+
import { StoredSemanticTriggerInterface } from './semantic-trigger.interface';
|
|
2
|
+
export interface SemanticTriggerRecordInterface extends StoredSemanticTriggerInterface {
|
|
3
3
|
id: string;
|
|
4
4
|
tenantId: string;
|
|
5
5
|
}
|
|
6
|
+
export declare const GloballyUniqueTriggerIdentifier: (trigger: SemanticTriggerRecordInterface) => string;
|
|
6
7
|
export declare const SemanticTriggerIdentifier: (trigger: SemanticTriggerRecordInterface) => string;
|
|
8
|
+
export declare const DeprecatedSemanticTriggerIdentifier: (trigger: SemanticTriggerRecordInterface) => string;
|
|
@@ -3,7 +3,7 @@ import { SemanticTriggerFiltersInterface } from './semantic-trigger-filters.inte
|
|
|
3
3
|
export declare const SemanticTriggerSchema: z.ZodObject<{
|
|
4
4
|
name: z.ZodOptional<z.ZodString>;
|
|
5
5
|
description: z.ZodOptional<z.ZodString>;
|
|
6
|
-
eventType: z.ZodString
|
|
6
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
7
7
|
dataset: z.ZodString;
|
|
8
8
|
dimensions: z.ZodArray<z.ZodString>;
|
|
9
9
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -17,10 +17,29 @@ export declare const SemanticTriggerSchema: z.ZodObject<{
|
|
|
17
17
|
incrementalField: z.ZodOptional<z.ZodString>;
|
|
18
18
|
ungrouped: z.ZodOptional<z.ZodBoolean>;
|
|
19
19
|
}, z.core.$strip>;
|
|
20
|
+
export declare const StoredSemanticTriggerSchema: z.ZodObject<{
|
|
21
|
+
name: z.ZodOptional<z.ZodString>;
|
|
22
|
+
description: z.ZodOptional<z.ZodString>;
|
|
23
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
24
|
+
dataset: z.ZodString;
|
|
25
|
+
dimensions: z.ZodArray<z.ZodString>;
|
|
26
|
+
limit: z.ZodOptional<z.ZodNumber>;
|
|
27
|
+
filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
|
|
28
|
+
dimension: z.ZodString;
|
|
29
|
+
operator: z.ZodEnum<typeof import("..").SemanticTriggerFilterOperatorsEnum>;
|
|
30
|
+
values: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>;
|
|
31
|
+
}, z.core.$strip>, z.ZodLiteral<false>]>>>;
|
|
32
|
+
cron: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
33
|
+
tz: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
34
|
+
incrementalField: z.ZodOptional<z.ZodString>;
|
|
35
|
+
ungrouped: z.ZodOptional<z.ZodBoolean>;
|
|
36
|
+
identifier: z.ZodString;
|
|
37
|
+
key: z.ZodString;
|
|
38
|
+
}, z.core.$strip>;
|
|
20
39
|
export interface SemanticTriggerInterface {
|
|
21
40
|
name?: string;
|
|
22
41
|
description?: string;
|
|
23
|
-
eventType
|
|
42
|
+
eventType?: string;
|
|
24
43
|
dataset: string;
|
|
25
44
|
dimensions: Array<string>;
|
|
26
45
|
measures?: Array<string>;
|
|
@@ -33,3 +52,7 @@ export interface SemanticTriggerInterface {
|
|
|
33
52
|
keyField?: string;
|
|
34
53
|
ungrouped?: boolean;
|
|
35
54
|
}
|
|
55
|
+
export interface StoredSemanticTriggerInterface extends SemanticTriggerInterface {
|
|
56
|
+
identifier: string;
|
|
57
|
+
key: string;
|
|
58
|
+
}
|
|
@@ -3,7 +3,7 @@ import { SemanticTriggerInterface } from './semantic-trigger.interface';
|
|
|
3
3
|
export declare const SemanticTriggersSchema: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
|
|
4
4
|
name: z.ZodOptional<z.ZodString>;
|
|
5
5
|
description: z.ZodOptional<z.ZodString>;
|
|
6
|
-
eventType: z.ZodString
|
|
6
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
7
7
|
dataset: z.ZodString;
|
|
8
8
|
dimensions: z.ZodArray<z.ZodString>;
|
|
9
9
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -95,7 +95,7 @@ export declare const TemplateImplementationOverridesSchema: z.ZodObject<{
|
|
|
95
95
|
semanticTriggers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
|
|
96
96
|
name: z.ZodOptional<z.ZodString>;
|
|
97
97
|
description: z.ZodOptional<z.ZodString>;
|
|
98
|
-
eventType: z.ZodString
|
|
98
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
99
99
|
dataset: z.ZodString;
|
|
100
100
|
dimensions: z.ZodArray<z.ZodString>;
|
|
101
101
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -152,6 +152,11 @@ export declare const TemplateImplementationOverridesSchema: z.ZodObject<{
|
|
|
152
152
|
description: z.ZodOptional<z.ZodString>;
|
|
153
153
|
actionIdentifier: z.ZodString;
|
|
154
154
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
155
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
156
|
+
selector: z.ZodString;
|
|
157
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof import("./index").WebhookValidationOperator>>>;
|
|
158
|
+
value: z.ZodString;
|
|
159
|
+
}, z.core.$strip>>>;
|
|
155
160
|
}, z.core.$strip>>>;
|
|
156
161
|
createdAt: z.ZodOptional<z.ZodDate>;
|
|
157
162
|
updatedAt: z.ZodOptional<z.ZodDate>;
|
|
@@ -100,7 +100,7 @@ export declare const TemplateImplementationSchema: z.ZodObject<{
|
|
|
100
100
|
semanticTriggers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
|
|
101
101
|
name: z.ZodOptional<z.ZodString>;
|
|
102
102
|
description: z.ZodOptional<z.ZodString>;
|
|
103
|
-
eventType: z.ZodString
|
|
103
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
104
104
|
dataset: z.ZodString;
|
|
105
105
|
dimensions: z.ZodArray<z.ZodString>;
|
|
106
106
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -157,6 +157,11 @@ export declare const TemplateImplementationSchema: z.ZodObject<{
|
|
|
157
157
|
description: z.ZodOptional<z.ZodString>;
|
|
158
158
|
actionIdentifier: z.ZodString;
|
|
159
159
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
160
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
161
|
+
selector: z.ZodString;
|
|
162
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof import("./webhook").WebhookValidationOperator>>>;
|
|
163
|
+
value: z.ZodString;
|
|
164
|
+
}, z.core.$strip>>>;
|
|
160
165
|
}, z.core.$strip>>>;
|
|
161
166
|
createdAt: z.ZodOptional<z.ZodDate>;
|
|
162
167
|
updatedAt: z.ZodOptional<z.ZodDate>;
|
|
@@ -262,7 +267,7 @@ export declare const TemplateImplementationCreateSchema: z.ZodObject<{
|
|
|
262
267
|
semanticTriggers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
|
|
263
268
|
name: z.ZodOptional<z.ZodString>;
|
|
264
269
|
description: z.ZodOptional<z.ZodString>;
|
|
265
|
-
eventType: z.ZodString
|
|
270
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
266
271
|
dataset: z.ZodString;
|
|
267
272
|
dimensions: z.ZodArray<z.ZodString>;
|
|
268
273
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -319,6 +324,11 @@ export declare const TemplateImplementationCreateSchema: z.ZodObject<{
|
|
|
319
324
|
description: z.ZodOptional<z.ZodString>;
|
|
320
325
|
actionIdentifier: z.ZodString;
|
|
321
326
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
327
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
328
|
+
selector: z.ZodString;
|
|
329
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof import("./webhook").WebhookValidationOperator>>>;
|
|
330
|
+
value: z.ZodString;
|
|
331
|
+
}, z.core.$strip>>>;
|
|
322
332
|
}, z.core.$strip>>>;
|
|
323
333
|
createdAt: z.ZodOptional<z.ZodDate>;
|
|
324
334
|
updatedAt: z.ZodOptional<z.ZodDate>;
|
|
@@ -108,7 +108,7 @@ export declare const TemplateSchema: z.ZodObject<{
|
|
|
108
108
|
semanticTriggers: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
|
|
109
109
|
name: z.ZodOptional<z.ZodString>;
|
|
110
110
|
description: z.ZodOptional<z.ZodString>;
|
|
111
|
-
eventType: z.ZodString
|
|
111
|
+
eventType: z.ZodOptional<z.ZodString>;
|
|
112
112
|
dataset: z.ZodString;
|
|
113
113
|
dimensions: z.ZodArray<z.ZodString>;
|
|
114
114
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -165,6 +165,11 @@ export declare const TemplateSchema: z.ZodObject<{
|
|
|
165
165
|
description: z.ZodOptional<z.ZodString>;
|
|
166
166
|
actionIdentifier: z.ZodString;
|
|
167
167
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
168
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
169
|
+
selector: z.ZodString;
|
|
170
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof import("./index").WebhookValidationOperator>>>;
|
|
171
|
+
value: z.ZodString;
|
|
172
|
+
}, z.core.$strip>>>;
|
|
168
173
|
}, z.core.$strip>>>;
|
|
169
174
|
createdAt: z.ZodOptional<z.ZodDate>;
|
|
170
175
|
updatedAt: z.ZodOptional<z.ZodDate>;
|
|
@@ -1,17 +1,45 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { ConnectorInterface } from '../connector/connector.interface';
|
|
2
3
|
import { ConnectorOrigin } from '../type-enums';
|
|
4
|
+
import { ActionInterface } from '../workflow';
|
|
3
5
|
export type WebhookInputParameterSelectors = {
|
|
4
6
|
selector: string;
|
|
5
7
|
items?: WebhookInputParameters;
|
|
6
8
|
};
|
|
7
9
|
export type WebhookInputParameters = Record<string, string | WebhookInputParameterSelectors>;
|
|
8
10
|
export declare const WebhookInputParametersSchema: z.ZodRecord<z.ZodString, z.ZodUnion>;
|
|
11
|
+
export declare enum WebhookValidationOperator {
|
|
12
|
+
equals = "equals",
|
|
13
|
+
contains = "contains",
|
|
14
|
+
startsWith = "startsWith",
|
|
15
|
+
endsWith = "endsWith"
|
|
16
|
+
}
|
|
17
|
+
export type WebhookValidationParameter = {
|
|
18
|
+
selector: string;
|
|
19
|
+
operator?: WebhookValidationOperator;
|
|
20
|
+
value: string;
|
|
21
|
+
};
|
|
22
|
+
export declare const WebhookValidationParameterSchema: z.ZodObject<{
|
|
23
|
+
selector: z.ZodString;
|
|
24
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof WebhookValidationOperator>>>;
|
|
25
|
+
value: z.ZodString;
|
|
26
|
+
}, z.core.$strip>;
|
|
27
|
+
export declare const WebhookValidationSchema: z.ZodArray<z.ZodObject<{
|
|
28
|
+
selector: z.ZodString;
|
|
29
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof WebhookValidationOperator>>>;
|
|
30
|
+
value: z.ZodString;
|
|
31
|
+
}, z.core.$strip>>;
|
|
9
32
|
export declare const WebhookSchema: z.ZodObject<{
|
|
10
33
|
identifier: z.ZodString;
|
|
11
34
|
name: z.ZodString;
|
|
12
35
|
description: z.ZodOptional<z.ZodString>;
|
|
13
36
|
actionIdentifier: z.ZodString;
|
|
14
37
|
inputParameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly z.core.$ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>[]>>>;
|
|
38
|
+
validation: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
39
|
+
selector: z.ZodString;
|
|
40
|
+
operator: z.ZodDefault<z.ZodOptional<z.ZodEnum<typeof WebhookValidationOperator>>>;
|
|
41
|
+
value: z.ZodString;
|
|
42
|
+
}, z.core.$strip>>>;
|
|
15
43
|
}, z.core.$strip>;
|
|
16
44
|
export interface WebhookInterface {
|
|
17
45
|
connectorIdentifier: string;
|
|
@@ -20,6 +48,7 @@ export interface WebhookInterface {
|
|
|
20
48
|
description?: string;
|
|
21
49
|
actionIdentifier: string;
|
|
22
50
|
inputParameters?: WebhookInputParameters;
|
|
51
|
+
validation?: Array<WebhookValidationParameter>;
|
|
23
52
|
}
|
|
24
53
|
export interface WebhookRecordInterface extends WebhookInterface {
|
|
25
54
|
id: string;
|
|
@@ -28,3 +57,8 @@ export interface WebhookRecordInterface extends WebhookInterface {
|
|
|
28
57
|
createdAt: Date;
|
|
29
58
|
updatedAt: Date;
|
|
30
59
|
}
|
|
60
|
+
export type WebhookDetailConnectorType = Omit<ConnectorInterface, 'actions' | 'webhooks' | 'config'>;
|
|
61
|
+
export interface WebhookDetailInterface extends WebhookRecordInterface {
|
|
62
|
+
action: ActionInterface;
|
|
63
|
+
connector: WebhookDetailConnectorType;
|
|
64
|
+
}
|
|
@@ -32,7 +32,8 @@ export declare enum ConfiguredConnectorTypes {
|
|
|
32
32
|
ONSHAPE = "onshape",
|
|
33
33
|
OROOX = "oroox",
|
|
34
34
|
GPMS = "gpms",
|
|
35
|
-
KEIZERSMETAAL_TRUMPF_API = "keizersmetaal-trumpf-api"
|
|
35
|
+
KEIZERSMETAAL_TRUMPF_API = "keizersmetaal-trumpf-api",
|
|
36
|
+
HP_INDIGO = "hp-indigo"
|
|
36
37
|
}
|
|
37
38
|
export interface ConnectorConfig {
|
|
38
39
|
type: ConfiguredConnectorTypes;
|