@atom8n/api-types 1.4.3 → 1.5.1
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/dist/build.tsbuildinfo +1 -1
- package/dist/chat-hub.d.ts +12 -12
- package/dist/dto/ai/ai-build-request.dto.d.ts +2 -2
- package/dist/dto/node-types/get-node-types-by-identifier.dto.d.ts +8 -0
- package/dist/dto/node-types/get-node-types-by-identifier.dto.js +13 -0
- package/dist/dto/project/create-project.dto.d.ts +2 -2
- package/dist/dto/project/update-project.dto.d.ts +4 -4
- package/dist/dto/source-control/push-work-folder-request.dto.d.ts +2 -2
- package/dist/dto/source-control/push-work-folder-response.dto.d.ts +5 -0
- package/dist/dto/source-control/push-work-folder-response.dto.js +2 -0
- package/dist/dto/variables/create-variable-request.dto.d.ts +1 -1
- package/dist/dto/workflows/base-workflow.dto.d.ts +50 -0
- package/dist/dto/workflows/base-workflow.dto.js +64 -0
- package/dist/dto/workflows/create-workflow.dto.d.ts +47 -0
- package/dist/dto/workflows/create-workflow.dto.js +14 -0
- package/dist/dto/workflows/update-workflow.dto.d.ts +44 -0
- package/dist/dto/workflows/update-workflow.dto.js +9 -0
- package/dist/schemas/project.schema.d.ts +2 -2
- package/dist/schemas/source-controlled-file.schema.d.ts +2 -2
- package/dist/schemas/user.schema.d.ts +12 -12
- package/package.json +5 -5
package/dist/chat-hub.d.ts
CHANGED
|
@@ -8,20 +8,20 @@ export declare const agentIconOrEmojiSchema: z.ZodDiscriminatedUnion<"type", [z.
|
|
|
8
8
|
type: z.ZodLiteral<"icon">;
|
|
9
9
|
value: z.ZodString;
|
|
10
10
|
}, "strip", z.ZodTypeAny, {
|
|
11
|
-
type: "icon";
|
|
12
11
|
value: string;
|
|
13
|
-
}, {
|
|
14
12
|
type: "icon";
|
|
13
|
+
}, {
|
|
15
14
|
value: string;
|
|
15
|
+
type: "icon";
|
|
16
16
|
}>, z.ZodObject<{
|
|
17
17
|
type: z.ZodLiteral<"emoji">;
|
|
18
18
|
value: z.ZodString;
|
|
19
19
|
}, "strip", z.ZodTypeAny, {
|
|
20
|
-
type: "emoji";
|
|
21
20
|
value: string;
|
|
22
|
-
}, {
|
|
23
21
|
type: "emoji";
|
|
22
|
+
}, {
|
|
24
23
|
value: string;
|
|
24
|
+
type: "emoji";
|
|
25
25
|
}>]>;
|
|
26
26
|
export type AgentIconOrEmoji = z.infer<typeof agentIconOrEmojiSchema>;
|
|
27
27
|
export declare const chatHubProviderSchema: z.ZodEnum<["openai", "anthropic", "google", "azureOpenAi", "azureEntraId", "ollama", "awsBedrock", "vercelAiGateway", "xAiGrok", "groq", "openRouter", "deepSeek", "cohere", "mistralCloud", "n8n", "custom-agent"]>;
|
|
@@ -1252,20 +1252,20 @@ declare const ChatHubCreateAgentRequest_base: Z.Class<{
|
|
|
1252
1252
|
type: z.ZodLiteral<"icon">;
|
|
1253
1253
|
value: z.ZodString;
|
|
1254
1254
|
}, "strip", z.ZodTypeAny, {
|
|
1255
|
-
type: "icon";
|
|
1256
1255
|
value: string;
|
|
1257
|
-
}, {
|
|
1258
1256
|
type: "icon";
|
|
1257
|
+
}, {
|
|
1259
1258
|
value: string;
|
|
1259
|
+
type: "icon";
|
|
1260
1260
|
}>, z.ZodObject<{
|
|
1261
1261
|
type: z.ZodLiteral<"emoji">;
|
|
1262
1262
|
value: z.ZodString;
|
|
1263
1263
|
}, "strip", z.ZodTypeAny, {
|
|
1264
|
-
type: "emoji";
|
|
1265
1264
|
value: string;
|
|
1266
|
-
}, {
|
|
1267
1265
|
type: "emoji";
|
|
1266
|
+
}, {
|
|
1268
1267
|
value: string;
|
|
1268
|
+
type: "emoji";
|
|
1269
1269
|
}>]>;
|
|
1270
1270
|
systemPrompt: z.ZodString;
|
|
1271
1271
|
credentialId: z.ZodString;
|
|
@@ -1282,20 +1282,20 @@ declare const ChatHubUpdateAgentRequest_base: Z.Class<{
|
|
|
1282
1282
|
type: z.ZodLiteral<"icon">;
|
|
1283
1283
|
value: z.ZodString;
|
|
1284
1284
|
}, "strip", z.ZodTypeAny, {
|
|
1285
|
-
type: "icon";
|
|
1286
1285
|
value: string;
|
|
1287
|
-
}, {
|
|
1288
1286
|
type: "icon";
|
|
1287
|
+
}, {
|
|
1289
1288
|
value: string;
|
|
1289
|
+
type: "icon";
|
|
1290
1290
|
}>, z.ZodObject<{
|
|
1291
1291
|
type: z.ZodLiteral<"emoji">;
|
|
1292
1292
|
value: z.ZodString;
|
|
1293
1293
|
}, "strip", z.ZodTypeAny, {
|
|
1294
|
-
type: "emoji";
|
|
1295
1294
|
value: string;
|
|
1296
|
-
}, {
|
|
1297
1295
|
type: "emoji";
|
|
1296
|
+
}, {
|
|
1298
1297
|
value: string;
|
|
1298
|
+
type: "emoji";
|
|
1299
1299
|
}>]>>;
|
|
1300
1300
|
systemPrompt: z.ZodOptional<z.ZodString>;
|
|
1301
1301
|
credentialId: z.ZodOptional<z.ZodString>;
|
|
@@ -65,9 +65,9 @@ declare const AiBuilderChatRequestDto_base: Z.Class<{
|
|
|
65
65
|
}>>;
|
|
66
66
|
}, "strip", z.ZodTypeAny, {
|
|
67
67
|
type: "message";
|
|
68
|
-
id: string;
|
|
69
68
|
text: string;
|
|
70
69
|
role: "user";
|
|
70
|
+
id: string;
|
|
71
71
|
workflowContext: {
|
|
72
72
|
currentWorkflow?: Partial<IWorkflowBase> | undefined;
|
|
73
73
|
executionData?: {
|
|
@@ -87,9 +87,9 @@ declare const AiBuilderChatRequestDto_base: Z.Class<{
|
|
|
87
87
|
} | undefined;
|
|
88
88
|
}, {
|
|
89
89
|
type: "message";
|
|
90
|
-
id: string;
|
|
91
90
|
text: string;
|
|
92
91
|
role: "user";
|
|
92
|
+
id: string;
|
|
93
93
|
workflowContext: {
|
|
94
94
|
currentWorkflow?: Partial<IWorkflowBase> | undefined;
|
|
95
95
|
executionData?: {
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { Z } from 'zod-class';
|
|
3
|
+
declare const GetNodeTypesByIdentifierRequestDto_base: Z.Class<{
|
|
4
|
+
identifiers: z.ZodArray<z.ZodString, "many">;
|
|
5
|
+
}>;
|
|
6
|
+
export declare class GetNodeTypesByIdentifierRequestDto extends GetNodeTypesByIdentifierRequestDto_base {
|
|
7
|
+
}
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetNodeTypesByIdentifierRequestDto = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const zod_class_1 = require("zod-class");
|
|
6
|
+
const nodeTypeIdentifierSchema = zod_1.z
|
|
7
|
+
.string()
|
|
8
|
+
.regex(/^[\w.-]+@\d+(\.\d+)?(\.\d+)?$/, 'Invalid node type identifier format. Expected "name@version"');
|
|
9
|
+
class GetNodeTypesByIdentifierRequestDto extends zod_class_1.Z.class({
|
|
10
|
+
identifiers: zod_1.z.array(nodeTypeIdentifierSchema).min(1).max(1000),
|
|
11
|
+
}) {
|
|
12
|
+
}
|
|
13
|
+
exports.GetNodeTypesByIdentifierRequestDto = GetNodeTypesByIdentifierRequestDto;
|
|
@@ -6,11 +6,11 @@ declare const CreateProjectDto_base: Z.Class<{
|
|
|
6
6
|
type: z.ZodEnum<["emoji", "icon"]>;
|
|
7
7
|
value: z.ZodString;
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
|
-
type: "icon" | "emoji";
|
|
10
9
|
value: string;
|
|
11
|
-
}, {
|
|
12
10
|
type: "icon" | "emoji";
|
|
11
|
+
}, {
|
|
13
12
|
value: string;
|
|
13
|
+
type: "icon" | "emoji";
|
|
14
14
|
}>>;
|
|
15
15
|
uiContext: z.ZodOptional<z.ZodString>;
|
|
16
16
|
}>;
|
|
@@ -6,11 +6,11 @@ declare const UpdateProjectDto_base: Z.Class<{
|
|
|
6
6
|
type: z.ZodEnum<["emoji", "icon"]>;
|
|
7
7
|
value: z.ZodString;
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
|
-
type: "icon" | "emoji";
|
|
10
9
|
value: string;
|
|
11
|
-
}, {
|
|
12
10
|
type: "icon" | "emoji";
|
|
11
|
+
}, {
|
|
13
12
|
value: string;
|
|
13
|
+
type: "icon" | "emoji";
|
|
14
14
|
}>>;
|
|
15
15
|
description: z.ZodOptional<z.ZodString>;
|
|
16
16
|
}>;
|
|
@@ -32,11 +32,11 @@ declare const UpdateProjectWithRelationsDto_base: Z.Class<{
|
|
|
32
32
|
type: z.ZodEnum<["emoji", "icon"]>;
|
|
33
33
|
value: z.ZodString;
|
|
34
34
|
}, "strip", z.ZodTypeAny, {
|
|
35
|
-
type: "icon" | "emoji";
|
|
36
35
|
value: string;
|
|
37
|
-
}, {
|
|
38
36
|
type: "icon" | "emoji";
|
|
37
|
+
}, {
|
|
39
38
|
value: string;
|
|
39
|
+
type: "icon" | "emoji";
|
|
40
40
|
}>>;
|
|
41
41
|
description: z.ZodOptional<z.ZodString>;
|
|
42
42
|
}>;
|
|
@@ -29,10 +29,10 @@ declare const PushWorkFolderRequestDto_base: Z.Class<{
|
|
|
29
29
|
}, "strip", z.ZodTypeAny, {
|
|
30
30
|
type: "workflow" | "project" | "credential" | "file" | "tags" | "variables" | "folders";
|
|
31
31
|
status: "unknown" | "new" | "modified" | "deleted" | "created" | "renamed" | "conflicted" | "ignored" | "staged";
|
|
32
|
+
file: string;
|
|
32
33
|
id: string;
|
|
33
34
|
name: string;
|
|
34
35
|
updatedAt: string;
|
|
35
|
-
file: string;
|
|
36
36
|
location: "local" | "remote";
|
|
37
37
|
conflict: boolean;
|
|
38
38
|
pushed?: boolean | undefined;
|
|
@@ -44,10 +44,10 @@ declare const PushWorkFolderRequestDto_base: Z.Class<{
|
|
|
44
44
|
}, {
|
|
45
45
|
type: "workflow" | "project" | "credential" | "file" | "tags" | "variables" | "folders";
|
|
46
46
|
status: "unknown" | "new" | "modified" | "deleted" | "created" | "renamed" | "conflicted" | "ignored" | "staged";
|
|
47
|
+
file: string;
|
|
47
48
|
id: string;
|
|
48
49
|
name: string;
|
|
49
50
|
updatedAt: string;
|
|
50
|
-
file: string;
|
|
51
51
|
location: "local" | "remote";
|
|
52
52
|
conflict: boolean;
|
|
53
53
|
pushed?: boolean | undefined;
|
|
@@ -19,8 +19,8 @@ declare const CreateVariableRequestDto_base: {
|
|
|
19
19
|
} & import("zod-class").ZodClass<{} & {
|
|
20
20
|
projectId?: string | undefined;
|
|
21
21
|
} & {
|
|
22
|
-
type: "string" | undefined;
|
|
23
22
|
value: string;
|
|
23
|
+
type: "string" | undefined;
|
|
24
24
|
key: string;
|
|
25
25
|
} & {}, {} & {
|
|
26
26
|
projectId?: string | undefined;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import type { IPinData, IConnections, IDataObject, INode, IWorkflowSettings } from 'n8n-workflow';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export declare const WORKFLOW_NAME_MAX_LENGTH = 128;
|
|
4
|
+
export declare const workflowNameSchema: z.ZodString;
|
|
5
|
+
export declare const workflowDescriptionSchema: z.ZodNullable<z.ZodString>;
|
|
6
|
+
export declare const workflowNodesSchema: z.ZodType<INode[], z.ZodTypeDef, INode[]>;
|
|
7
|
+
export declare const workflowConnectionsSchema: z.ZodType<IConnections, z.ZodTypeDef, IConnections>;
|
|
8
|
+
export declare const workflowSettingsSchema: z.ZodType<IWorkflowSettings, z.ZodTypeDef, IWorkflowSettings>;
|
|
9
|
+
export declare const workflowStaticDataSchema: z.ZodEffects<z.ZodType<IDataObject | null, z.ZodTypeDef, IDataObject | null>, IDataObject | null, unknown>;
|
|
10
|
+
export declare const workflowPinDataSchema: z.ZodType<IPinData | null, z.ZodTypeDef, IPinData | null>;
|
|
11
|
+
export declare const workflowMetaSchema: z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
12
|
+
export declare const baseWorkflowShape: {
|
|
13
|
+
readonly name: z.ZodString;
|
|
14
|
+
readonly description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
15
|
+
readonly nodes: z.ZodType<INode[], z.ZodTypeDef, INode[]>;
|
|
16
|
+
readonly connections: z.ZodType<IConnections, z.ZodTypeDef, IConnections>;
|
|
17
|
+
readonly settings: z.ZodOptional<z.ZodType<IWorkflowSettings, z.ZodTypeDef, IWorkflowSettings>>;
|
|
18
|
+
readonly staticData: z.ZodOptional<z.ZodEffects<z.ZodType<IDataObject | null, z.ZodTypeDef, IDataObject | null>, IDataObject | null, unknown>>;
|
|
19
|
+
readonly meta: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
20
|
+
readonly pinData: z.ZodOptional<z.ZodType<IPinData | null, z.ZodTypeDef, IPinData | null>>;
|
|
21
|
+
readonly hash: z.ZodOptional<z.ZodString>;
|
|
22
|
+
readonly parentFolderId: z.ZodOptional<z.ZodString>;
|
|
23
|
+
readonly parentFolder: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
24
|
+
id: z.ZodString;
|
|
25
|
+
name: z.ZodString;
|
|
26
|
+
}, "strip", z.ZodTypeAny, {
|
|
27
|
+
id: string;
|
|
28
|
+
name: string;
|
|
29
|
+
}, {
|
|
30
|
+
id: string;
|
|
31
|
+
name: string;
|
|
32
|
+
}>>>;
|
|
33
|
+
readonly tags: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
34
|
+
id: z.ZodString;
|
|
35
|
+
name: z.ZodString;
|
|
36
|
+
}, "strip", z.ZodTypeAny, {
|
|
37
|
+
id: string;
|
|
38
|
+
name: string;
|
|
39
|
+
}, {
|
|
40
|
+
id: string;
|
|
41
|
+
name: string;
|
|
42
|
+
}>, "many">]>, string[], string[] | {
|
|
43
|
+
id: string;
|
|
44
|
+
name: string;
|
|
45
|
+
}[]>>;
|
|
46
|
+
readonly uiContext: z.ZodOptional<z.ZodString>;
|
|
47
|
+
readonly aiBuilderAssisted: z.ZodOptional<z.ZodBoolean>;
|
|
48
|
+
readonly expectedChecksum: z.ZodOptional<z.ZodString>;
|
|
49
|
+
readonly autosaved: z.ZodOptional<z.ZodBoolean>;
|
|
50
|
+
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.baseWorkflowShape = exports.workflowMetaSchema = exports.workflowPinDataSchema = exports.workflowStaticDataSchema = exports.workflowSettingsSchema = exports.workflowConnectionsSchema = exports.workflowNodesSchema = exports.workflowDescriptionSchema = exports.workflowNameSchema = exports.WORKFLOW_NAME_MAX_LENGTH = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.WORKFLOW_NAME_MAX_LENGTH = 128;
|
|
6
|
+
exports.workflowNameSchema = zod_1.z
|
|
7
|
+
.string()
|
|
8
|
+
.min(1, { message: 'Workflow name is required' })
|
|
9
|
+
.max(exports.WORKFLOW_NAME_MAX_LENGTH, {
|
|
10
|
+
message: `Workflow name must be ${exports.WORKFLOW_NAME_MAX_LENGTH} characters or less`,
|
|
11
|
+
});
|
|
12
|
+
exports.workflowDescriptionSchema = zod_1.z.string().nullable();
|
|
13
|
+
exports.workflowNodesSchema = zod_1.z.custom((val) => Array.isArray(val), {
|
|
14
|
+
message: 'Nodes must be an array',
|
|
15
|
+
});
|
|
16
|
+
exports.workflowConnectionsSchema = zod_1.z.custom((val) => typeof val === 'object' && val !== null && !Array.isArray(val), {
|
|
17
|
+
message: 'Connections must be an object',
|
|
18
|
+
});
|
|
19
|
+
exports.workflowSettingsSchema = zod_1.z.custom((val) => val === null || (typeof val === 'object' && val !== null && !Array.isArray(val)), {
|
|
20
|
+
message: 'Settings must be an object or null',
|
|
21
|
+
});
|
|
22
|
+
exports.workflowStaticDataSchema = zod_1.z.preprocess((val) => {
|
|
23
|
+
if (typeof val === 'string') {
|
|
24
|
+
try {
|
|
25
|
+
return JSON.parse(val);
|
|
26
|
+
}
|
|
27
|
+
catch {
|
|
28
|
+
throw new Error('Static data string must be valid JSON');
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
return val;
|
|
32
|
+
}, zod_1.z.custom((val) => val === null || (typeof val === 'object' && val !== null && !Array.isArray(val)), {
|
|
33
|
+
message: 'Static data must be an object or null',
|
|
34
|
+
}));
|
|
35
|
+
exports.workflowPinDataSchema = zod_1.z.custom((val) => val === null || (typeof val === 'object' && val !== null && !Array.isArray(val)), {
|
|
36
|
+
message: 'Pin data must be an object or null',
|
|
37
|
+
});
|
|
38
|
+
exports.workflowMetaSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.unknown()).nullable();
|
|
39
|
+
exports.baseWorkflowShape = {
|
|
40
|
+
name: exports.workflowNameSchema,
|
|
41
|
+
description: exports.workflowDescriptionSchema.optional(),
|
|
42
|
+
nodes: exports.workflowNodesSchema,
|
|
43
|
+
connections: exports.workflowConnectionsSchema,
|
|
44
|
+
settings: exports.workflowSettingsSchema.optional(),
|
|
45
|
+
staticData: exports.workflowStaticDataSchema.optional(),
|
|
46
|
+
meta: exports.workflowMetaSchema.optional(),
|
|
47
|
+
pinData: exports.workflowPinDataSchema.optional(),
|
|
48
|
+
hash: zod_1.z.string().optional(),
|
|
49
|
+
parentFolderId: zod_1.z.string().optional(),
|
|
50
|
+
parentFolder: zod_1.z.object({ id: zod_1.z.string(), name: zod_1.z.string() }).nullable().optional(),
|
|
51
|
+
tags: zod_1.z
|
|
52
|
+
.union([zod_1.z.array(zod_1.z.string()), zod_1.z.array(zod_1.z.object({ id: zod_1.z.string(), name: zod_1.z.string() }))])
|
|
53
|
+
.transform((val) => {
|
|
54
|
+
if (val.length > 0 && typeof val[0] === 'object' && 'id' in val[0]) {
|
|
55
|
+
return val.map((tag) => tag.id);
|
|
56
|
+
}
|
|
57
|
+
return val;
|
|
58
|
+
})
|
|
59
|
+
.optional(),
|
|
60
|
+
uiContext: zod_1.z.string().optional(),
|
|
61
|
+
aiBuilderAssisted: zod_1.z.boolean().optional(),
|
|
62
|
+
expectedChecksum: zod_1.z.string().optional(),
|
|
63
|
+
autosaved: zod_1.z.boolean().optional(),
|
|
64
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { Z } from 'zod-class';
|
|
3
|
+
export declare const workflowIdSchema: z.ZodString;
|
|
4
|
+
declare const CreateWorkflowDto_base: Z.Class<{
|
|
5
|
+
id: z.ZodOptional<z.ZodString>;
|
|
6
|
+
projectId: z.ZodOptional<z.ZodString>;
|
|
7
|
+
name: z.ZodString;
|
|
8
|
+
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
9
|
+
nodes: z.ZodType<import("n8n-workflow").INode[], z.ZodTypeDef, import("n8n-workflow").INode[]>;
|
|
10
|
+
connections: z.ZodType<import("n8n-workflow").IConnections, z.ZodTypeDef, import("n8n-workflow").IConnections>;
|
|
11
|
+
settings: z.ZodOptional<z.ZodType<import("n8n-workflow").IWorkflowSettings, z.ZodTypeDef, import("n8n-workflow").IWorkflowSettings>>;
|
|
12
|
+
staticData: z.ZodOptional<z.ZodEffects<z.ZodType<import("n8n-workflow").IDataObject | null, z.ZodTypeDef, import("n8n-workflow").IDataObject | null>, import("n8n-workflow").IDataObject | null, unknown>>;
|
|
13
|
+
meta: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
14
|
+
pinData: z.ZodOptional<z.ZodType<import("n8n-workflow").IPinData | null, z.ZodTypeDef, import("n8n-workflow").IPinData | null>>;
|
|
15
|
+
hash: z.ZodOptional<z.ZodString>;
|
|
16
|
+
parentFolderId: z.ZodOptional<z.ZodString>;
|
|
17
|
+
parentFolder: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
18
|
+
id: z.ZodString;
|
|
19
|
+
name: z.ZodString;
|
|
20
|
+
}, "strip", z.ZodTypeAny, {
|
|
21
|
+
id: string;
|
|
22
|
+
name: string;
|
|
23
|
+
}, {
|
|
24
|
+
id: string;
|
|
25
|
+
name: string;
|
|
26
|
+
}>>>;
|
|
27
|
+
tags: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
28
|
+
id: z.ZodString;
|
|
29
|
+
name: z.ZodString;
|
|
30
|
+
}, "strip", z.ZodTypeAny, {
|
|
31
|
+
id: string;
|
|
32
|
+
name: string;
|
|
33
|
+
}, {
|
|
34
|
+
id: string;
|
|
35
|
+
name: string;
|
|
36
|
+
}>, "many">]>, string[], string[] | {
|
|
37
|
+
id: string;
|
|
38
|
+
name: string;
|
|
39
|
+
}[]>>;
|
|
40
|
+
uiContext: z.ZodOptional<z.ZodString>;
|
|
41
|
+
aiBuilderAssisted: z.ZodOptional<z.ZodBoolean>;
|
|
42
|
+
expectedChecksum: z.ZodOptional<z.ZodString>;
|
|
43
|
+
autosaved: z.ZodOptional<z.ZodBoolean>;
|
|
44
|
+
}>;
|
|
45
|
+
export declare class CreateWorkflowDto extends CreateWorkflowDto_base {
|
|
46
|
+
}
|
|
47
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CreateWorkflowDto = exports.workflowIdSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const zod_class_1 = require("zod-class");
|
|
6
|
+
const base_workflow_dto_1 = require("./base-workflow.dto");
|
|
7
|
+
exports.workflowIdSchema = zod_1.z.string();
|
|
8
|
+
class CreateWorkflowDto extends zod_class_1.Z.class({
|
|
9
|
+
...base_workflow_dto_1.baseWorkflowShape,
|
|
10
|
+
id: exports.workflowIdSchema.optional(),
|
|
11
|
+
projectId: zod_1.z.string().optional(),
|
|
12
|
+
}) {
|
|
13
|
+
}
|
|
14
|
+
exports.CreateWorkflowDto = CreateWorkflowDto;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { Z } from 'zod-class';
|
|
3
|
+
declare const UpdateWorkflowDto_base: Z.Class<{
|
|
4
|
+
readonly name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
readonly description: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
6
|
+
readonly nodes: z.ZodOptional<z.ZodType<import("n8n-workflow").INode[], z.ZodTypeDef, import("n8n-workflow").INode[]>>;
|
|
7
|
+
readonly connections: z.ZodOptional<z.ZodType<import("n8n-workflow").IConnections, z.ZodTypeDef, import("n8n-workflow").IConnections>>;
|
|
8
|
+
readonly settings: z.ZodOptional<z.ZodOptional<z.ZodType<import("n8n-workflow").IWorkflowSettings, z.ZodTypeDef, import("n8n-workflow").IWorkflowSettings>>>;
|
|
9
|
+
readonly staticData: z.ZodOptional<z.ZodOptional<z.ZodEffects<z.ZodType<import("n8n-workflow").IDataObject | null, z.ZodTypeDef, import("n8n-workflow").IDataObject | null>, import("n8n-workflow").IDataObject | null, unknown>>>;
|
|
10
|
+
readonly meta: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>>;
|
|
11
|
+
readonly pinData: z.ZodOptional<z.ZodOptional<z.ZodType<import("n8n-workflow").IPinData | null, z.ZodTypeDef, import("n8n-workflow").IPinData | null>>>;
|
|
12
|
+
readonly hash: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
13
|
+
readonly parentFolderId: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
14
|
+
readonly parentFolder: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
15
|
+
id: z.ZodString;
|
|
16
|
+
name: z.ZodString;
|
|
17
|
+
}, "strip", z.ZodTypeAny, {
|
|
18
|
+
id: string;
|
|
19
|
+
name: string;
|
|
20
|
+
}, {
|
|
21
|
+
id: string;
|
|
22
|
+
name: string;
|
|
23
|
+
}>>>>;
|
|
24
|
+
readonly tags: z.ZodOptional<z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodArray<z.ZodObject<{
|
|
25
|
+
id: z.ZodString;
|
|
26
|
+
name: z.ZodString;
|
|
27
|
+
}, "strip", z.ZodTypeAny, {
|
|
28
|
+
id: string;
|
|
29
|
+
name: string;
|
|
30
|
+
}, {
|
|
31
|
+
id: string;
|
|
32
|
+
name: string;
|
|
33
|
+
}>, "many">]>, string[], string[] | {
|
|
34
|
+
id: string;
|
|
35
|
+
name: string;
|
|
36
|
+
}[]>>>;
|
|
37
|
+
readonly uiContext: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
38
|
+
readonly aiBuilderAssisted: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
39
|
+
readonly expectedChecksum: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
40
|
+
readonly autosaved: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
41
|
+
}>;
|
|
42
|
+
export declare class UpdateWorkflowDto extends UpdateWorkflowDto_base {
|
|
43
|
+
}
|
|
44
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UpdateWorkflowDto = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const zod_class_1 = require("zod-class");
|
|
6
|
+
const base_workflow_dto_1 = require("./base-workflow.dto");
|
|
7
|
+
class UpdateWorkflowDto extends zod_class_1.Z.class(zod_1.z.object(base_workflow_dto_1.baseWorkflowShape).partial().shape) {
|
|
8
|
+
}
|
|
9
|
+
exports.UpdateWorkflowDto = UpdateWorkflowDto;
|
|
@@ -6,11 +6,11 @@ export declare const projectIconSchema: z.ZodObject<{
|
|
|
6
6
|
type: z.ZodEnum<["emoji", "icon"]>;
|
|
7
7
|
value: z.ZodString;
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
|
-
type: "icon" | "emoji";
|
|
10
9
|
value: string;
|
|
11
|
-
}, {
|
|
12
10
|
type: "icon" | "emoji";
|
|
11
|
+
}, {
|
|
13
12
|
value: string;
|
|
13
|
+
type: "icon" | "emoji";
|
|
14
14
|
}>;
|
|
15
15
|
export type ProjectIcon = z.infer<typeof projectIconSchema>;
|
|
16
16
|
export declare const projectDescriptionSchema: z.ZodString;
|
|
@@ -31,10 +31,10 @@ export declare const SourceControlledFileSchema: z.ZodObject<{
|
|
|
31
31
|
}, "strip", z.ZodTypeAny, {
|
|
32
32
|
type: "workflow" | "project" | "credential" | "file" | "tags" | "variables" | "folders";
|
|
33
33
|
status: "unknown" | "new" | "modified" | "deleted" | "created" | "renamed" | "conflicted" | "ignored" | "staged";
|
|
34
|
+
file: string;
|
|
34
35
|
id: string;
|
|
35
36
|
name: string;
|
|
36
37
|
updatedAt: string;
|
|
37
|
-
file: string;
|
|
38
38
|
location: "local" | "remote";
|
|
39
39
|
conflict: boolean;
|
|
40
40
|
pushed?: boolean | undefined;
|
|
@@ -46,10 +46,10 @@ export declare const SourceControlledFileSchema: z.ZodObject<{
|
|
|
46
46
|
}, {
|
|
47
47
|
type: "workflow" | "project" | "credential" | "file" | "tags" | "variables" | "folders";
|
|
48
48
|
status: "unknown" | "new" | "modified" | "deleted" | "created" | "renamed" | "conflicted" | "ignored" | "staged";
|
|
49
|
+
file: string;
|
|
49
50
|
id: string;
|
|
50
51
|
name: string;
|
|
51
52
|
updatedAt: string;
|
|
52
|
-
file: string;
|
|
53
53
|
location: "local" | "remote";
|
|
54
54
|
conflict: boolean;
|
|
55
55
|
pushed?: boolean | undefined;
|
|
@@ -13,13 +13,13 @@ export declare const userProjectSchema: z.ZodObject<{
|
|
|
13
13
|
role: z.ZodUnion<[z.ZodUnion<[z.ZodEnum<["project:personalOwner"]>, z.ZodEnum<["project:admin", "project:editor", "project:viewer", "project:chatUser"]>]>, z.ZodEffects<z.ZodString, string, string>]>;
|
|
14
14
|
name: z.ZodString;
|
|
15
15
|
}, "strip", z.ZodTypeAny, {
|
|
16
|
+
role: string;
|
|
16
17
|
id: string;
|
|
17
18
|
name: string;
|
|
18
|
-
role: string;
|
|
19
19
|
}, {
|
|
20
|
+
role: string;
|
|
20
21
|
id: string;
|
|
21
22
|
name: string;
|
|
22
|
-
role: string;
|
|
23
23
|
}>;
|
|
24
24
|
export declare const userBaseSchema: z.ZodObject<{
|
|
25
25
|
id: z.ZodString;
|
|
@@ -122,13 +122,13 @@ export declare const userDetailSchema: z.ZodObject<{
|
|
|
122
122
|
role: z.ZodUnion<[z.ZodUnion<[z.ZodEnum<["project:personalOwner"]>, z.ZodEnum<["project:admin", "project:editor", "project:viewer", "project:chatUser"]>]>, z.ZodEffects<z.ZodString, string, string>]>;
|
|
123
123
|
name: z.ZodString;
|
|
124
124
|
}, "strip", z.ZodTypeAny, {
|
|
125
|
+
role: string;
|
|
125
126
|
id: string;
|
|
126
127
|
name: string;
|
|
127
|
-
role: string;
|
|
128
128
|
}, {
|
|
129
|
+
role: string;
|
|
129
130
|
id: string;
|
|
130
131
|
name: string;
|
|
131
|
-
role: string;
|
|
132
132
|
}>, "many">>>;
|
|
133
133
|
mfaEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
134
134
|
lastActiveAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -160,9 +160,9 @@ export declare const userDetailSchema: z.ZodObject<{
|
|
|
160
160
|
mfaEnabled?: boolean | undefined;
|
|
161
161
|
isOwner?: boolean | undefined;
|
|
162
162
|
projectRelations?: {
|
|
163
|
+
role: string;
|
|
163
164
|
id: string;
|
|
164
165
|
name: string;
|
|
165
|
-
role: string;
|
|
166
166
|
}[] | null | undefined;
|
|
167
167
|
isPending?: boolean | undefined;
|
|
168
168
|
signInType?: string | undefined;
|
|
@@ -196,9 +196,9 @@ export declare const userDetailSchema: z.ZodObject<{
|
|
|
196
196
|
mfaEnabled?: boolean | undefined;
|
|
197
197
|
isOwner?: boolean | undefined;
|
|
198
198
|
projectRelations?: {
|
|
199
|
+
role: string;
|
|
199
200
|
id: string;
|
|
200
201
|
name: string;
|
|
201
|
-
role: string;
|
|
202
202
|
}[] | null | undefined;
|
|
203
203
|
isPending?: boolean | undefined;
|
|
204
204
|
signInType?: string | undefined;
|
|
@@ -290,13 +290,13 @@ export declare const usersListSchema: z.ZodObject<{
|
|
|
290
290
|
role: z.ZodUnion<[z.ZodUnion<[z.ZodEnum<["project:personalOwner"]>, z.ZodEnum<["project:admin", "project:editor", "project:viewer", "project:chatUser"]>]>, z.ZodEffects<z.ZodString, string, string>]>;
|
|
291
291
|
name: z.ZodString;
|
|
292
292
|
}, "strip", z.ZodTypeAny, {
|
|
293
|
+
role: string;
|
|
293
294
|
id: string;
|
|
294
295
|
name: string;
|
|
295
|
-
role: string;
|
|
296
296
|
}, {
|
|
297
|
+
role: string;
|
|
297
298
|
id: string;
|
|
298
299
|
name: string;
|
|
299
|
-
role: string;
|
|
300
300
|
}>, "many">>>;
|
|
301
301
|
mfaEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
302
302
|
lastActiveAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -328,9 +328,9 @@ export declare const usersListSchema: z.ZodObject<{
|
|
|
328
328
|
mfaEnabled?: boolean | undefined;
|
|
329
329
|
isOwner?: boolean | undefined;
|
|
330
330
|
projectRelations?: {
|
|
331
|
+
role: string;
|
|
331
332
|
id: string;
|
|
332
333
|
name: string;
|
|
333
|
-
role: string;
|
|
334
334
|
}[] | null | undefined;
|
|
335
335
|
isPending?: boolean | undefined;
|
|
336
336
|
signInType?: string | undefined;
|
|
@@ -364,9 +364,9 @@ export declare const usersListSchema: z.ZodObject<{
|
|
|
364
364
|
mfaEnabled?: boolean | undefined;
|
|
365
365
|
isOwner?: boolean | undefined;
|
|
366
366
|
projectRelations?: {
|
|
367
|
+
role: string;
|
|
367
368
|
id: string;
|
|
368
369
|
name: string;
|
|
369
|
-
role: string;
|
|
370
370
|
}[] | null | undefined;
|
|
371
371
|
isPending?: boolean | undefined;
|
|
372
372
|
signInType?: string | undefined;
|
|
@@ -403,9 +403,9 @@ export declare const usersListSchema: z.ZodObject<{
|
|
|
403
403
|
mfaEnabled?: boolean | undefined;
|
|
404
404
|
isOwner?: boolean | undefined;
|
|
405
405
|
projectRelations?: {
|
|
406
|
+
role: string;
|
|
406
407
|
id: string;
|
|
407
408
|
name: string;
|
|
408
|
-
role: string;
|
|
409
409
|
}[] | null | undefined;
|
|
410
410
|
isPending?: boolean | undefined;
|
|
411
411
|
signInType?: string | undefined;
|
|
@@ -442,9 +442,9 @@ export declare const usersListSchema: z.ZodObject<{
|
|
|
442
442
|
mfaEnabled?: boolean | undefined;
|
|
443
443
|
isOwner?: boolean | undefined;
|
|
444
444
|
projectRelations?: {
|
|
445
|
+
role: string;
|
|
445
446
|
id: string;
|
|
446
447
|
name: string;
|
|
447
|
-
role: string;
|
|
448
448
|
}[] | null | undefined;
|
|
449
449
|
isPending?: boolean | undefined;
|
|
450
450
|
signInType?: string | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atom8n/api-types",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.1",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"clean": "rimraf dist .turbo",
|
|
6
6
|
"dev": "pnpm watch",
|
|
@@ -22,14 +22,14 @@
|
|
|
22
22
|
"dist/**/*"
|
|
23
23
|
],
|
|
24
24
|
"devDependencies": {
|
|
25
|
-
"@n8n/typescript-config": "npm:@atom8n/typescript-config@1.
|
|
26
|
-
"@n8n/config": "npm:@atom8n/config@2.
|
|
25
|
+
"@n8n/typescript-config": "npm:@atom8n/typescript-config@1.6.1",
|
|
26
|
+
"@n8n/config": "npm:@atom8n/config@2.4.1"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"n8n-workflow": "npm:@atom8n/n8n-workflow@2.
|
|
29
|
+
"n8n-workflow": "npm:@atom8n/n8n-workflow@2.5.1",
|
|
30
30
|
"xss": "1.0.15",
|
|
31
31
|
"zod": "3.25.67",
|
|
32
32
|
"zod-class": "0.0.16",
|
|
33
|
-
"@n8n/permissions": "npm:@atom8n/permissions@0.
|
|
33
|
+
"@n8n/permissions": "npm:@atom8n/permissions@0.48.1"
|
|
34
34
|
}
|
|
35
35
|
}
|