@m5kdev/commons 0.8.6 → 0.8.8
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/src/modules/ai/ai.constants.cjs +329 -0
- package/dist/src/modules/ai/ai.constants.cjs.map +1 -0
- package/dist/src/modules/ai/ai.constants.d.cts +58 -0
- package/dist/src/modules/ai/ai.utils.cjs +9 -0
- package/dist/src/modules/ai/ai.utils.cjs.map +1 -0
- package/dist/src/modules/ai/ai.utils.d.cts +5 -0
- package/dist/src/modules/auth/auth.schema.cjs +25 -0
- package/dist/src/modules/auth/auth.schema.cjs.map +1 -0
- package/dist/src/modules/auth/auth.schema.d.cts +25 -0
- package/dist/src/modules/base/base.schema.cjs +18 -0
- package/dist/src/modules/base/base.schema.cjs.map +1 -0
- package/dist/src/modules/base/base.schema.d.cts +30 -0
- package/dist/src/modules/billing/billing.schema.cjs +27 -0
- package/dist/src/modules/billing/billing.schema.cjs.map +1 -0
- package/dist/src/modules/billing/billing.schema.d.cts +27 -0
- package/dist/src/modules/billing/billing.types.cjs +0 -0
- package/dist/src/modules/billing/billing.types.d.cts +21 -0
- package/dist/src/modules/billing/billing.utils.cjs +13 -0
- package/dist/src/modules/billing/billing.utils.cjs.map +1 -0
- package/dist/src/modules/billing/billing.utils.d.cts +10 -0
- package/dist/src/modules/file/file.constants.cjs +51 -0
- package/dist/src/modules/file/file.constants.cjs.map +1 -0
- package/dist/src/modules/file/file.constants.d.cts +8 -0
- package/dist/src/modules/recurrence/recurrence.schema.cjs +70 -0
- package/dist/src/modules/recurrence/recurrence.schema.cjs.map +1 -0
- package/dist/src/modules/recurrence/recurrence.schema.d.cts +103 -0
- package/dist/src/modules/schemas/query.schema.cjs +54 -0
- package/dist/src/modules/schemas/query.schema.cjs.map +1 -0
- package/dist/src/modules/schemas/query.schema.d.cts +116 -0
- package/dist/src/modules/schemas/query.schema.d.mts +1 -0
- package/dist/src/modules/schemas/query.schema.mjs +2 -1
- package/dist/src/modules/schemas/query.schema.mjs.map +1 -1
- package/dist/src/modules/table/filter.types.cjs +0 -0
- package/dist/src/modules/table/filter.types.d.cts +15 -0
- package/dist/src/modules/tag/tag.schema.cjs +65 -0
- package/dist/src/modules/tag/tag.schema.cjs.map +1 -0
- package/dist/src/modules/tag/tag.schema.d.cts +122 -0
- package/dist/src/modules/tag/tag.schema.d.mts +1 -0
- package/dist/src/modules/workflow/workflow.constants.cjs +12 -0
- package/dist/src/modules/workflow/workflow.constants.cjs.map +1 -0
- package/dist/src/modules/workflow/workflow.constants.d.cts +6 -0
- package/dist/src/modules/workflow/workflow.schema.cjs +40 -0
- package/dist/src/modules/workflow/workflow.schema.cjs.map +1 -0
- package/dist/src/modules/workflow/workflow.schema.d.cts +97 -0
- package/dist/src/utils/json.cjs +13 -0
- package/dist/src/utils/json.cjs.map +1 -0
- package/dist/src/utils/json.d.cts +6 -0
- package/dist/src/utils/timezones.cjs +5646 -0
- package/dist/src/utils/timezones.cjs.map +1 -0
- package/dist/src/utils/timezones.d.cts +18 -0
- package/dist/src/utils/trpc.cjs +11 -0
- package/dist/src/utils/trpc.cjs.map +1 -0
- package/dist/src/utils/trpc.d.cts +8 -0
- package/package.json +98 -26
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/modules/tag/tag.schema.d.ts
|
|
4
|
+
declare const tagSchema: z.ZodObject<{
|
|
5
|
+
id: z.ZodString;
|
|
6
|
+
organizationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
7
|
+
teamId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
8
|
+
createdAt: z.ZodDate;
|
|
9
|
+
updatedAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
10
|
+
deletedAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
11
|
+
userId: z.ZodString;
|
|
12
|
+
name: z.ZodString;
|
|
13
|
+
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
14
|
+
type: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
15
|
+
isEnabled: z.ZodBoolean;
|
|
16
|
+
parentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
17
|
+
assignableTo: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>>;
|
|
18
|
+
}, z.core.$strip>;
|
|
19
|
+
declare const taggingSchema: z.ZodObject<{
|
|
20
|
+
id: z.ZodString;
|
|
21
|
+
createdAt: z.ZodDate;
|
|
22
|
+
tagId: z.ZodString;
|
|
23
|
+
resourceType: z.ZodString;
|
|
24
|
+
resourceId: z.ZodString;
|
|
25
|
+
}, z.core.$strip>;
|
|
26
|
+
declare const tagListInputSchema: z.ZodObject<{
|
|
27
|
+
page: z.ZodOptional<z.ZodNumber>;
|
|
28
|
+
limit: z.ZodOptional<z.ZodNumber>;
|
|
29
|
+
sort: z.ZodOptional<z.ZodString>;
|
|
30
|
+
order: z.ZodOptional<z.ZodEnum<{
|
|
31
|
+
asc: "asc";
|
|
32
|
+
desc: "desc";
|
|
33
|
+
}>>;
|
|
34
|
+
filters: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
35
|
+
columnId: z.ZodString;
|
|
36
|
+
type: z.ZodEnum<{
|
|
37
|
+
string: "string";
|
|
38
|
+
number: "number";
|
|
39
|
+
boolean: "boolean";
|
|
40
|
+
date: "date";
|
|
41
|
+
enum: "enum";
|
|
42
|
+
}>;
|
|
43
|
+
method: z.ZodEnum<{
|
|
44
|
+
contains: "contains";
|
|
45
|
+
equals: "equals";
|
|
46
|
+
starts_with: "starts_with";
|
|
47
|
+
ends_with: "ends_with";
|
|
48
|
+
greater_than: "greater_than";
|
|
49
|
+
less_than: "less_than";
|
|
50
|
+
on: "on";
|
|
51
|
+
between: "between";
|
|
52
|
+
before: "before";
|
|
53
|
+
after: "after";
|
|
54
|
+
oneOf: "oneOf";
|
|
55
|
+
intersect: "intersect";
|
|
56
|
+
isEmpty: "isEmpty";
|
|
57
|
+
isNotEmpty: "isNotEmpty";
|
|
58
|
+
is_null: "is_null";
|
|
59
|
+
is_not_null: "is_not_null";
|
|
60
|
+
}>;
|
|
61
|
+
value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodString>]>;
|
|
62
|
+
valueTo: z.ZodOptional<z.ZodString>;
|
|
63
|
+
endColumnId: z.ZodOptional<z.ZodString>;
|
|
64
|
+
}, z.core.$strip>>>;
|
|
65
|
+
q: z.ZodOptional<z.ZodString>;
|
|
66
|
+
}, z.core.$strip>;
|
|
67
|
+
declare const tagListOutputSchema: z.ZodObject<{
|
|
68
|
+
rows: z.ZodArray<z.ZodObject<{
|
|
69
|
+
id: z.ZodString;
|
|
70
|
+
organizationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
71
|
+
teamId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
72
|
+
createdAt: z.ZodDate;
|
|
73
|
+
updatedAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
74
|
+
deletedAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
75
|
+
userId: z.ZodString;
|
|
76
|
+
name: z.ZodString;
|
|
77
|
+
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
78
|
+
type: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
79
|
+
isEnabled: z.ZodBoolean;
|
|
80
|
+
parentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
81
|
+
assignableTo: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>>;
|
|
82
|
+
}, z.core.$strip>>;
|
|
83
|
+
total: z.ZodNumber;
|
|
84
|
+
}, z.core.$strip>;
|
|
85
|
+
declare const tagListSchema: z.ZodObject<{
|
|
86
|
+
assignableTo: z.ZodOptional<z.ZodString>;
|
|
87
|
+
}, z.core.$strip>;
|
|
88
|
+
declare const tagCreateSchema: z.ZodObject<{
|
|
89
|
+
organizationId: z.ZodOptional<z.ZodString>;
|
|
90
|
+
teamId: z.ZodOptional<z.ZodString>;
|
|
91
|
+
name: z.ZodString;
|
|
92
|
+
color: z.ZodString;
|
|
93
|
+
assignableTo: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
94
|
+
resourceType: z.ZodOptional<z.ZodString>;
|
|
95
|
+
resourceId: z.ZodOptional<z.ZodString>;
|
|
96
|
+
}, z.core.$strip>;
|
|
97
|
+
declare const tagUpdateSchema: z.ZodObject<{
|
|
98
|
+
id: z.ZodString;
|
|
99
|
+
name: z.ZodOptional<z.ZodString>;
|
|
100
|
+
color: z.ZodOptional<z.ZodString>;
|
|
101
|
+
assignableTo: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
102
|
+
}, z.core.$strip>;
|
|
103
|
+
declare const tagLinkSchema: z.ZodObject<{
|
|
104
|
+
tagId: z.ZodString;
|
|
105
|
+
resourceType: z.ZodString;
|
|
106
|
+
resourceId: z.ZodString;
|
|
107
|
+
}, z.core.$strip>;
|
|
108
|
+
declare const tagDeleteSchema: z.ZodObject<{
|
|
109
|
+
id: z.ZodString;
|
|
110
|
+
}, z.core.$strip>;
|
|
111
|
+
type TagSchema = z.infer<typeof tagSchema>;
|
|
112
|
+
type TaggingSchema = z.infer<typeof taggingSchema>;
|
|
113
|
+
type TagListSchema = z.infer<typeof tagListSchema>;
|
|
114
|
+
type TagCreateSchema = z.infer<typeof tagCreateSchema>;
|
|
115
|
+
type TagUpdateSchema = z.infer<typeof tagUpdateSchema>;
|
|
116
|
+
type TagLinkSchema = z.infer<typeof tagLinkSchema>;
|
|
117
|
+
type TagDeleteSchema = z.infer<typeof tagDeleteSchema>;
|
|
118
|
+
type TagListOutputSchema = z.infer<typeof tagListOutputSchema>;
|
|
119
|
+
type TagListInputSchema = z.infer<typeof tagListInputSchema>;
|
|
120
|
+
//#endregion
|
|
121
|
+
export { TagCreateSchema, TagDeleteSchema, TagLinkSchema, TagListInputSchema, TagListOutputSchema, TagListSchema, TagSchema, TagUpdateSchema, TaggingSchema, tagCreateSchema, tagDeleteSchema, tagLinkSchema, tagListInputSchema, tagListOutputSchema, tagListSchema, tagSchema, tagUpdateSchema, taggingSchema };
|
|
122
|
+
//# sourceMappingURL=tag.schema.d.cts.map
|
|
@@ -62,6 +62,7 @@ declare const tagListInputSchema: z.ZodObject<{
|
|
|
62
62
|
valueTo: z.ZodOptional<z.ZodString>;
|
|
63
63
|
endColumnId: z.ZodOptional<z.ZodString>;
|
|
64
64
|
}, z.core.$strip>>>;
|
|
65
|
+
q: z.ZodOptional<z.ZodString>;
|
|
65
66
|
}, z.core.$strip>;
|
|
66
67
|
declare const tagListOutputSchema: z.ZodObject<{
|
|
67
68
|
rows: z.ZodArray<z.ZodObject<{
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
//#region src/modules/workflow/workflow.constants.ts
|
|
3
|
+
const WORFLOW_STATUSES = [
|
|
4
|
+
"queued",
|
|
5
|
+
"running",
|
|
6
|
+
"completed",
|
|
7
|
+
"failed"
|
|
8
|
+
];
|
|
9
|
+
//#endregion
|
|
10
|
+
exports.WORFLOW_STATUSES = WORFLOW_STATUSES;
|
|
11
|
+
|
|
12
|
+
//# sourceMappingURL=workflow.constants.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workflow.constants.cjs","names":[],"sources":["../../../../src/modules/workflow/workflow.constants.ts"],"sourcesContent":["export const WORFLOW_STATUSES = [\"queued\", \"running\", \"completed\", \"failed\"] as const;\r\nexport type WorkflowStatus = (typeof WORFLOW_STATUSES)[number];\r\n"],"mappings":";;AAAA,MAAa,mBAAmB;CAAC;CAAU;CAAW;CAAa;CAAS"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
//#region src/modules/workflow/workflow.constants.d.ts
|
|
2
|
+
declare const WORFLOW_STATUSES: readonly ["queued", "running", "completed", "failed"];
|
|
3
|
+
type WorkflowStatus = (typeof WORFLOW_STATUSES)[number];
|
|
4
|
+
//#endregion
|
|
5
|
+
export { WORFLOW_STATUSES, WorkflowStatus };
|
|
6
|
+
//# sourceMappingURL=workflow.constants.d.cts.map
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
const require_src_modules_workflow_workflow_constants = require("./workflow.constants.cjs");
|
|
3
|
+
let zod = require("zod");
|
|
4
|
+
//#region src/modules/workflow/workflow.schema.ts
|
|
5
|
+
const workflowSelectSchema = zod.z.object({
|
|
6
|
+
id: zod.z.uuid(),
|
|
7
|
+
userId: zod.z.string().nullable(),
|
|
8
|
+
jobId: zod.z.string(),
|
|
9
|
+
jobName: zod.z.string(),
|
|
10
|
+
queueName: zod.z.string(),
|
|
11
|
+
tags: zod.z.array(zod.z.string()).nullable(),
|
|
12
|
+
input: zod.z.unknown(),
|
|
13
|
+
output: zod.z.unknown(),
|
|
14
|
+
status: zod.z.enum(require_src_modules_workflow_workflow_constants.WORFLOW_STATUSES),
|
|
15
|
+
error: zod.z.string().nullable(),
|
|
16
|
+
retries: zod.z.number(),
|
|
17
|
+
finishedAt: zod.z.date().nullable(),
|
|
18
|
+
processedAt: zod.z.date().nullable(),
|
|
19
|
+
createdAt: zod.z.date(),
|
|
20
|
+
updatedAt: zod.z.date()
|
|
21
|
+
});
|
|
22
|
+
const workflowReadInputSchema = zod.z.object({ jobId: zod.z.string() });
|
|
23
|
+
const workflowListInputSchema = zod.z.object({
|
|
24
|
+
status: zod.z.enum(require_src_modules_workflow_workflow_constants.WORFLOW_STATUSES).array().optional(),
|
|
25
|
+
jobName: zod.z.string().optional()
|
|
26
|
+
});
|
|
27
|
+
const workflowTriggerOutputSchema = zod.z.object({ jobId: zod.z.string() });
|
|
28
|
+
const workflowTriggerManyOutputSchema = zod.z.object({ jobIds: zod.z.array(zod.z.string()) });
|
|
29
|
+
const workflowReadOutputSchema = workflowSelectSchema;
|
|
30
|
+
const workflowListOutputSchema = workflowSelectSchema.array();
|
|
31
|
+
//#endregion
|
|
32
|
+
exports.workflowListInputSchema = workflowListInputSchema;
|
|
33
|
+
exports.workflowListOutputSchema = workflowListOutputSchema;
|
|
34
|
+
exports.workflowReadInputSchema = workflowReadInputSchema;
|
|
35
|
+
exports.workflowReadOutputSchema = workflowReadOutputSchema;
|
|
36
|
+
exports.workflowSelectSchema = workflowSelectSchema;
|
|
37
|
+
exports.workflowTriggerManyOutputSchema = workflowTriggerManyOutputSchema;
|
|
38
|
+
exports.workflowTriggerOutputSchema = workflowTriggerOutputSchema;
|
|
39
|
+
|
|
40
|
+
//# sourceMappingURL=workflow.schema.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workflow.schema.cjs","names":["z","WORFLOW_STATUSES"],"sources":["../../../../src/modules/workflow/workflow.schema.ts"],"sourcesContent":["import { z } from \"zod\";\r\nimport { WORFLOW_STATUSES } from \"./workflow.constants\";\r\n\r\nexport const workflowSelectSchema = z.object({\r\n id: z.uuid(),\r\n userId: z.string().nullable(),\r\n jobId: z.string(),\r\n jobName: z.string(),\r\n queueName: z.string(),\r\n tags: z.array(z.string()).nullable(),\r\n input: z.unknown(),\r\n output: z.unknown(),\r\n status: z.enum(WORFLOW_STATUSES),\r\n error: z.string().nullable(),\r\n retries: z.number(),\r\n finishedAt: z.date().nullable(),\r\n processedAt: z.date().nullable(),\r\n createdAt: z.date(),\r\n updatedAt: z.date(),\r\n});\r\n\r\nexport const workflowReadInputSchema = z.object({\r\n jobId: z.string(),\r\n});\r\n\r\nexport const workflowListInputSchema = z.object({\r\n status: z.enum(WORFLOW_STATUSES).array().optional(),\r\n jobName: z.string().optional(),\r\n});\r\n\r\nexport const workflowTriggerOutputSchema = z.object({\r\n jobId: z.string(),\r\n});\r\n\r\nexport const workflowTriggerManyOutputSchema = z.object({\r\n jobIds: z.array(z.string()),\r\n});\r\n\r\nexport const workflowReadOutputSchema = workflowSelectSchema;\r\nexport const workflowListOutputSchema = workflowSelectSchema.array();\r\n\r\nexport type WorkflowSelectSchema = z.infer<typeof workflowSelectSchema>;\r\nexport type WorkflowReadInputSchema = z.infer<typeof workflowReadInputSchema>;\r\nexport type WorkflowListInputSchema = z.infer<typeof workflowListInputSchema>;\r\nexport type WorkflowReadOutputSchema = z.infer<typeof workflowReadOutputSchema>;\r\nexport type WorkflowListOutputSchema = z.infer<typeof workflowListOutputSchema>;\r\nexport type WorkflowTriggerOutputSchema = z.infer<typeof workflowTriggerOutputSchema>;\r\nexport type WorkflowTriggerManyOutputSchema = z.infer<typeof workflowTriggerManyOutputSchema>;\r\n"],"mappings":";;;;AAGA,MAAa,uBAAuBA,IAAAA,EAAE,OAAO;CAC3C,IAAIA,IAAAA,EAAE,MAAM;CACZ,QAAQA,IAAAA,EAAE,QAAQ,CAAC,UAAU;CAC7B,OAAOA,IAAAA,EAAE,QAAQ;CACjB,SAASA,IAAAA,EAAE,QAAQ;CACnB,WAAWA,IAAAA,EAAE,QAAQ;CACrB,MAAMA,IAAAA,EAAE,MAAMA,IAAAA,EAAE,QAAQ,CAAC,CAAC,UAAU;CACpC,OAAOA,IAAAA,EAAE,SAAS;CAClB,QAAQA,IAAAA,EAAE,SAAS;CACnB,QAAQA,IAAAA,EAAE,KAAKC,gDAAAA,iBAAiB;CAChC,OAAOD,IAAAA,EAAE,QAAQ,CAAC,UAAU;CAC5B,SAASA,IAAAA,EAAE,QAAQ;CACnB,YAAYA,IAAAA,EAAE,MAAM,CAAC,UAAU;CAC/B,aAAaA,IAAAA,EAAE,MAAM,CAAC,UAAU;CAChC,WAAWA,IAAAA,EAAE,MAAM;CACnB,WAAWA,IAAAA,EAAE,MAAM;CACpB,CAAC;AAEF,MAAa,0BAA0BA,IAAAA,EAAE,OAAO,EAC9C,OAAOA,IAAAA,EAAE,QAAQ,EAClB,CAAC;AAEF,MAAa,0BAA0BA,IAAAA,EAAE,OAAO;CAC9C,QAAQA,IAAAA,EAAE,KAAKC,gDAAAA,iBAAiB,CAAC,OAAO,CAAC,UAAU;CACnD,SAASD,IAAAA,EAAE,QAAQ,CAAC,UAAU;CAC/B,CAAC;AAEF,MAAa,8BAA8BA,IAAAA,EAAE,OAAO,EAClD,OAAOA,IAAAA,EAAE,QAAQ,EAClB,CAAC;AAEF,MAAa,kCAAkCA,IAAAA,EAAE,OAAO,EACtD,QAAQA,IAAAA,EAAE,MAAMA,IAAAA,EAAE,QAAQ,CAAC,EAC5B,CAAC;AAEF,MAAa,2BAA2B;AACxC,MAAa,2BAA2B,qBAAqB,OAAO"}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/modules/workflow/workflow.schema.d.ts
|
|
4
|
+
declare const workflowSelectSchema: z.ZodObject<{
|
|
5
|
+
id: z.ZodUUID;
|
|
6
|
+
userId: z.ZodNullable<z.ZodString>;
|
|
7
|
+
jobId: z.ZodString;
|
|
8
|
+
jobName: z.ZodString;
|
|
9
|
+
queueName: z.ZodString;
|
|
10
|
+
tags: z.ZodNullable<z.ZodArray<z.ZodString>>;
|
|
11
|
+
input: z.ZodUnknown;
|
|
12
|
+
output: z.ZodUnknown;
|
|
13
|
+
status: z.ZodEnum<{
|
|
14
|
+
queued: "queued";
|
|
15
|
+
running: "running";
|
|
16
|
+
completed: "completed";
|
|
17
|
+
failed: "failed";
|
|
18
|
+
}>;
|
|
19
|
+
error: z.ZodNullable<z.ZodString>;
|
|
20
|
+
retries: z.ZodNumber;
|
|
21
|
+
finishedAt: z.ZodNullable<z.ZodDate>;
|
|
22
|
+
processedAt: z.ZodNullable<z.ZodDate>;
|
|
23
|
+
createdAt: z.ZodDate;
|
|
24
|
+
updatedAt: z.ZodDate;
|
|
25
|
+
}, z.core.$strip>;
|
|
26
|
+
declare const workflowReadInputSchema: z.ZodObject<{
|
|
27
|
+
jobId: z.ZodString;
|
|
28
|
+
}, z.core.$strip>;
|
|
29
|
+
declare const workflowListInputSchema: z.ZodObject<{
|
|
30
|
+
status: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
31
|
+
queued: "queued";
|
|
32
|
+
running: "running";
|
|
33
|
+
completed: "completed";
|
|
34
|
+
failed: "failed";
|
|
35
|
+
}>>>;
|
|
36
|
+
jobName: z.ZodOptional<z.ZodString>;
|
|
37
|
+
}, z.core.$strip>;
|
|
38
|
+
declare const workflowTriggerOutputSchema: z.ZodObject<{
|
|
39
|
+
jobId: z.ZodString;
|
|
40
|
+
}, z.core.$strip>;
|
|
41
|
+
declare const workflowTriggerManyOutputSchema: z.ZodObject<{
|
|
42
|
+
jobIds: z.ZodArray<z.ZodString>;
|
|
43
|
+
}, z.core.$strip>;
|
|
44
|
+
declare const workflowReadOutputSchema: z.ZodObject<{
|
|
45
|
+
id: z.ZodUUID;
|
|
46
|
+
userId: z.ZodNullable<z.ZodString>;
|
|
47
|
+
jobId: z.ZodString;
|
|
48
|
+
jobName: z.ZodString;
|
|
49
|
+
queueName: z.ZodString;
|
|
50
|
+
tags: z.ZodNullable<z.ZodArray<z.ZodString>>;
|
|
51
|
+
input: z.ZodUnknown;
|
|
52
|
+
output: z.ZodUnknown;
|
|
53
|
+
status: z.ZodEnum<{
|
|
54
|
+
queued: "queued";
|
|
55
|
+
running: "running";
|
|
56
|
+
completed: "completed";
|
|
57
|
+
failed: "failed";
|
|
58
|
+
}>;
|
|
59
|
+
error: z.ZodNullable<z.ZodString>;
|
|
60
|
+
retries: z.ZodNumber;
|
|
61
|
+
finishedAt: z.ZodNullable<z.ZodDate>;
|
|
62
|
+
processedAt: z.ZodNullable<z.ZodDate>;
|
|
63
|
+
createdAt: z.ZodDate;
|
|
64
|
+
updatedAt: z.ZodDate;
|
|
65
|
+
}, z.core.$strip>;
|
|
66
|
+
declare const workflowListOutputSchema: z.ZodArray<z.ZodObject<{
|
|
67
|
+
id: z.ZodUUID;
|
|
68
|
+
userId: z.ZodNullable<z.ZodString>;
|
|
69
|
+
jobId: z.ZodString;
|
|
70
|
+
jobName: z.ZodString;
|
|
71
|
+
queueName: z.ZodString;
|
|
72
|
+
tags: z.ZodNullable<z.ZodArray<z.ZodString>>;
|
|
73
|
+
input: z.ZodUnknown;
|
|
74
|
+
output: z.ZodUnknown;
|
|
75
|
+
status: z.ZodEnum<{
|
|
76
|
+
queued: "queued";
|
|
77
|
+
running: "running";
|
|
78
|
+
completed: "completed";
|
|
79
|
+
failed: "failed";
|
|
80
|
+
}>;
|
|
81
|
+
error: z.ZodNullable<z.ZodString>;
|
|
82
|
+
retries: z.ZodNumber;
|
|
83
|
+
finishedAt: z.ZodNullable<z.ZodDate>;
|
|
84
|
+
processedAt: z.ZodNullable<z.ZodDate>;
|
|
85
|
+
createdAt: z.ZodDate;
|
|
86
|
+
updatedAt: z.ZodDate;
|
|
87
|
+
}, z.core.$strip>>;
|
|
88
|
+
type WorkflowSelectSchema = z.infer<typeof workflowSelectSchema>;
|
|
89
|
+
type WorkflowReadInputSchema = z.infer<typeof workflowReadInputSchema>;
|
|
90
|
+
type WorkflowListInputSchema = z.infer<typeof workflowListInputSchema>;
|
|
91
|
+
type WorkflowReadOutputSchema = z.infer<typeof workflowReadOutputSchema>;
|
|
92
|
+
type WorkflowListOutputSchema = z.infer<typeof workflowListOutputSchema>;
|
|
93
|
+
type WorkflowTriggerOutputSchema = z.infer<typeof workflowTriggerOutputSchema>;
|
|
94
|
+
type WorkflowTriggerManyOutputSchema = z.infer<typeof workflowTriggerManyOutputSchema>;
|
|
95
|
+
//#endregion
|
|
96
|
+
export { WorkflowListInputSchema, WorkflowListOutputSchema, WorkflowReadInputSchema, WorkflowReadOutputSchema, WorkflowSelectSchema, WorkflowTriggerManyOutputSchema, WorkflowTriggerOutputSchema, workflowListInputSchema, workflowListOutputSchema, workflowReadInputSchema, workflowReadOutputSchema, workflowSelectSchema, workflowTriggerManyOutputSchema, workflowTriggerOutputSchema };
|
|
97
|
+
//# sourceMappingURL=workflow.schema.d.cts.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
//#region src/utils/json.ts
|
|
3
|
+
function safeParseJson(json, fallback) {
|
|
4
|
+
try {
|
|
5
|
+
return JSON.parse(json);
|
|
6
|
+
} catch {
|
|
7
|
+
return fallback;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
exports.safeParseJson = safeParseJson;
|
|
12
|
+
|
|
13
|
+
//# sourceMappingURL=json.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"json.cjs","names":[],"sources":["../../../src/utils/json.ts"],"sourcesContent":["export function safeParseJson<T>(json: string, fallback: T): T;\r\nexport function safeParseJson<T>(json: string): T | undefined;\r\nexport function safeParseJson<T>(json: string, fallback?: T): T | undefined {\r\n try {\r\n return JSON.parse(json);\r\n } catch {\r\n return fallback;\r\n }\r\n}\r\n"],"mappings":";;AAEA,SAAgB,cAAiB,MAAc,UAA6B;AAC1E,KAAI;AACF,SAAO,KAAK,MAAM,KAAK;SACjB;AACN,SAAO"}
|