changemaker.lite/api/dist/modules/email-templates/email-templates.schemas.d.ts

327 lines
11 KiB
TypeScript

import { z } from 'zod';
export declare const EmailTemplateVariableTypeSchema: z.ZodEnum<["TEXT", "VIDEO"]>;
export type EmailTemplateVariableTypeType = z.infer<typeof EmailTemplateVariableTypeSchema>;
export declare const emailTemplateVariableSchema: z.ZodEffects<z.ZodObject<{
key: z.ZodString;
label: z.ZodString;
description: z.ZodOptional<z.ZodString>;
type: z.ZodDefault<z.ZodEnum<["TEXT", "VIDEO"]>>;
videoId: z.ZodOptional<z.ZodNumber>;
isRequired: z.ZodDefault<z.ZodBoolean>;
isConditional: z.ZodDefault<z.ZodBoolean>;
sampleValue: z.ZodOptional<z.ZodString>;
sortOrder: z.ZodDefault<z.ZodNumber>;
}, "strip", z.ZodTypeAny, {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}, {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}>, {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}, {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}>;
export declare const listEmailTemplatesSchema: z.ZodObject<{
page: z.ZodDefault<z.ZodNumber>;
limit: z.ZodDefault<z.ZodNumber>;
search: z.ZodOptional<z.ZodString>;
category: z.ZodOptional<z.ZodNativeEnum<{
INFLUENCE: "INFLUENCE";
MAP: "MAP";
SYSTEM: "SYSTEM";
PAYMENT: "PAYMENT";
}>>;
isActive: z.ZodOptional<z.ZodBoolean>;
}, "strip", z.ZodTypeAny, {
limit: number;
page: number;
search?: string | undefined;
category?: "INFLUENCE" | "MAP" | "SYSTEM" | "PAYMENT" | undefined;
isActive?: boolean | undefined;
}, {
search?: string | undefined;
category?: "INFLUENCE" | "MAP" | "SYSTEM" | "PAYMENT" | undefined;
limit?: number | undefined;
isActive?: boolean | undefined;
page?: number | undefined;
}>;
export type ListEmailTemplatesDto = z.infer<typeof listEmailTemplatesSchema>;
export declare const createEmailTemplateSchema: z.ZodObject<{
key: z.ZodString;
name: z.ZodString;
description: z.ZodOptional<z.ZodString>;
category: z.ZodNativeEnum<{
INFLUENCE: "INFLUENCE";
MAP: "MAP";
SYSTEM: "SYSTEM";
PAYMENT: "PAYMENT";
}>;
subjectLine: z.ZodString;
htmlContent: z.ZodString;
textContent: z.ZodString;
isActive: z.ZodDefault<z.ZodBoolean>;
variables: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
key: z.ZodString;
label: z.ZodString;
description: z.ZodOptional<z.ZodString>;
type: z.ZodDefault<z.ZodEnum<["TEXT", "VIDEO"]>>;
videoId: z.ZodOptional<z.ZodNumber>;
isRequired: z.ZodDefault<z.ZodBoolean>;
isConditional: z.ZodDefault<z.ZodBoolean>;
sampleValue: z.ZodOptional<z.ZodString>;
sortOrder: z.ZodDefault<z.ZodNumber>;
}, "strip", z.ZodTypeAny, {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}, {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}>, {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}, {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}>, "many">>;
}, "strip", z.ZodTypeAny, {
name: string;
category: "INFLUENCE" | "MAP" | "SYSTEM" | "PAYMENT";
key: string;
isActive: boolean;
subjectLine: string;
htmlContent: string;
textContent: string;
description?: string | undefined;
variables?: {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}[] | undefined;
}, {
name: string;
category: "INFLUENCE" | "MAP" | "SYSTEM" | "PAYMENT";
key: string;
subjectLine: string;
htmlContent: string;
textContent: string;
isActive?: boolean | undefined;
description?: string | undefined;
variables?: {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}[] | undefined;
}>;
export type CreateEmailTemplateDto = z.infer<typeof createEmailTemplateSchema>;
export declare const updateEmailTemplateSchema: z.ZodObject<{
name: z.ZodOptional<z.ZodString>;
description: z.ZodNullable<z.ZodOptional<z.ZodString>>;
category: z.ZodOptional<z.ZodNativeEnum<{
INFLUENCE: "INFLUENCE";
MAP: "MAP";
SYSTEM: "SYSTEM";
PAYMENT: "PAYMENT";
}>>;
subjectLine: z.ZodOptional<z.ZodString>;
htmlContent: z.ZodOptional<z.ZodString>;
textContent: z.ZodOptional<z.ZodString>;
isActive: z.ZodOptional<z.ZodBoolean>;
variables: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
key: z.ZodString;
label: z.ZodString;
description: z.ZodOptional<z.ZodString>;
type: z.ZodDefault<z.ZodEnum<["TEXT", "VIDEO"]>>;
videoId: z.ZodOptional<z.ZodNumber>;
isRequired: z.ZodDefault<z.ZodBoolean>;
isConditional: z.ZodDefault<z.ZodBoolean>;
sampleValue: z.ZodOptional<z.ZodString>;
sortOrder: z.ZodDefault<z.ZodNumber>;
}, "strip", z.ZodTypeAny, {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}, {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}>, {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}, {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}>, "many">>;
}, "strip", z.ZodTypeAny, {
name?: string | undefined;
category?: "INFLUENCE" | "MAP" | "SYSTEM" | "PAYMENT" | undefined;
isActive?: boolean | undefined;
description?: string | null | undefined;
subjectLine?: string | undefined;
htmlContent?: string | undefined;
textContent?: string | undefined;
variables?: {
type: "VIDEO" | "TEXT";
key: string;
sortOrder: number;
label: string;
isRequired: boolean;
isConditional: boolean;
videoId?: number | undefined;
description?: string | undefined;
sampleValue?: string | undefined;
}[] | undefined;
}, {
name?: string | undefined;
category?: "INFLUENCE" | "MAP" | "SYSTEM" | "PAYMENT" | undefined;
isActive?: boolean | undefined;
description?: string | null | undefined;
subjectLine?: string | undefined;
htmlContent?: string | undefined;
textContent?: string | undefined;
variables?: {
key: string;
label: string;
type?: "VIDEO" | "TEXT" | undefined;
videoId?: number | undefined;
description?: string | undefined;
sortOrder?: number | undefined;
isRequired?: boolean | undefined;
isConditional?: boolean | undefined;
sampleValue?: string | undefined;
}[] | undefined;
}>;
export type UpdateEmailTemplateDto = z.infer<typeof updateEmailTemplateSchema>;
export declare const rollbackToVersionSchema: z.ZodObject<{
versionNumber: z.ZodNumber;
changeNotes: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
versionNumber: number;
changeNotes?: string | undefined;
}, {
versionNumber: number;
changeNotes?: string | undefined;
}>;
export type RollbackToVersionDto = z.infer<typeof rollbackToVersionSchema>;
export declare const validateTemplateSchema: z.ZodObject<{
htmlContent: z.ZodString;
textContent: z.ZodString;
subjectLine: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
htmlContent: string;
textContent: string;
subjectLine?: string | undefined;
}, {
htmlContent: string;
textContent: string;
subjectLine?: string | undefined;
}>;
export type ValidateTemplateDto = z.infer<typeof validateTemplateSchema>;
export declare const sendTestEmailSchema: z.ZodObject<{
recipientEmail: z.ZodString;
testData: z.ZodRecord<z.ZodString, z.ZodString>;
}, "strip", z.ZodTypeAny, {
recipientEmail: string;
testData: Record<string, string>;
}, {
recipientEmail: string;
testData: Record<string, string>;
}>;
export type SendTestEmailDto = z.infer<typeof sendTestEmailSchema>;
//# sourceMappingURL=email-templates.schemas.d.ts.map