@rudderhq/cli 0.3.2-canary.0 → 0.3.2-canary.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/index.js +9 -3
- package/dist/index.js.map +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1920,6 +1920,11 @@ var init_approval = __esm({
|
|
|
1920
1920
|
|
|
1921
1921
|
// ../packages/shared/dist/validators/automation.js
|
|
1922
1922
|
import { z as z20 } from "zod";
|
|
1923
|
+
function normalizeAutomationNotifications(value) {
|
|
1924
|
+
if (value.outputMode !== "chat_output" || !value.notifyOnIssueCreated)
|
|
1925
|
+
return value;
|
|
1926
|
+
return { ...value, notifyOnIssueCreated: false };
|
|
1927
|
+
}
|
|
1923
1928
|
var automationBodySchema, createAutomationSchema, updateAutomationSchema, baseTriggerSchema, createAutomationTriggerSchema, updateAutomationTriggerSchema, runAutomationSchema, rotateAutomationTriggerSecretSchema;
|
|
1924
1929
|
var init_automation = __esm({
|
|
1925
1930
|
"../packages/shared/dist/validators/automation.js"() {
|
|
@@ -1937,7 +1942,8 @@ var init_automation = __esm({
|
|
|
1937
1942
|
concurrencyPolicy: z20.enum(AUTOMATION_CONCURRENCY_POLICIES).optional().default("coalesce_if_active"),
|
|
1938
1943
|
catchUpPolicy: z20.enum(AUTOMATION_CATCH_UP_POLICIES).optional().default("skip_missed"),
|
|
1939
1944
|
outputMode: z20.enum(AUTOMATION_OUTPUT_MODES).optional().default("track_issue"),
|
|
1940
|
-
chatConversationId: z20.string().uuid().optional().nullable().default(null)
|
|
1945
|
+
chatConversationId: z20.string().uuid().optional().nullable().default(null),
|
|
1946
|
+
notifyOnIssueCreated: z20.boolean().optional().default(false)
|
|
1941
1947
|
});
|
|
1942
1948
|
createAutomationSchema = automationBodySchema.superRefine((value, ctx) => {
|
|
1943
1949
|
if (value.chatConversationId) {
|
|
@@ -1947,7 +1953,7 @@ var init_automation = __esm({
|
|
|
1947
1953
|
message: "Chat output creates an automation-owned conversation; existing chats cannot be selected"
|
|
1948
1954
|
});
|
|
1949
1955
|
}
|
|
1950
|
-
});
|
|
1956
|
+
}).transform(normalizeAutomationNotifications);
|
|
1951
1957
|
updateAutomationSchema = automationBodySchema.partial().superRefine((value, ctx) => {
|
|
1952
1958
|
if (value.chatConversationId) {
|
|
1953
1959
|
ctx.addIssue({
|
|
@@ -1956,7 +1962,7 @@ var init_automation = __esm({
|
|
|
1956
1962
|
message: "Chat output creates an automation-owned conversation; existing chats cannot be selected"
|
|
1957
1963
|
});
|
|
1958
1964
|
}
|
|
1959
|
-
});
|
|
1965
|
+
}).transform(normalizeAutomationNotifications);
|
|
1960
1966
|
baseTriggerSchema = z20.object({
|
|
1961
1967
|
label: z20.string().trim().max(120).optional().nullable(),
|
|
1962
1968
|
enabled: z20.boolean().optional().default(true)
|