@lucidcms/core
Version:
The core of the Lucid CMS. It's responsible for spinning up the API and serving the CMS.
1 lines • 16.6 kB
Source Map (JSON)
{"version":3,"file":"email.mjs","names":[],"sources":["../../src/schemas/email.ts"],"sourcesContent":["import z from \"zod\";\nimport type { ControllerSchema } from \"../types.js\";\nimport { queryFormatted, queryString } from \"./helpers/querystring.js\";\n\nexport const emailDeliveryStatusSchema = z.union([\n\tz.literal(\"sent\"),\n\tz.literal(\"delivered\"),\n\tz.literal(\"delayed\"),\n\tz.literal(\"complained\"),\n\tz.literal(\"bounced\"),\n\tz.literal(\"clicked\"),\n\tz.literal(\"failed\"),\n\tz.literal(\"opened\"),\n\tz.literal(\"scheduled\"),\n]);\n\nexport const emailTypeSchema = z.union([\n\tz.literal(\"external\"),\n\tz.literal(\"internal\"),\n]);\n\nexport const emailPrioritySchema = z.union([\n\tz.literal(\"low\"),\n\tz.literal(\"normal\"),\n\tz.literal(\"high\"),\n]);\n\nconst emailResponseSchema = z.object({\n\tid: z.number().meta({\n\t\tdescription: \"The email ID\",\n\t\texample: 1,\n\t}),\n\tmailDetails: z.object({\n\t\tfrom: z.object({\n\t\t\taddress: z.email().meta({\n\t\t\t\tdescription: \"The sender's email address\",\n\t\t\t\texample: \"admin@lucidcms.io\",\n\t\t\t}),\n\t\t\tname: z.string().meta({\n\t\t\t\tdescription: \"The sender's name\",\n\t\t\t\texample: \"Admin\",\n\t\t\t}),\n\t\t}),\n\t\tto: z.string().meta({\n\t\t\tdescription: \"The recipient's email address\",\n\t\t\texample: \"user@example.com\",\n\t\t}),\n\t\tsubject: z.string().meta({\n\t\t\tdescription: \"The email subject line\",\n\t\t\texample: \"Welcome to Lucid CMS\",\n\t\t}),\n\t\tcc: z.string().nullable().meta({\n\t\t\tdescription: \"Carbon copy recipients (comma-separated)\",\n\t\t\texample: \"manager@example.com,team@example.com\",\n\t\t}),\n\t\tbcc: z.string().nullable().meta({\n\t\t\tdescription: \"Blind carbon copy recipients (comma-separated)\",\n\t\t\texample: \"logs@example.com\",\n\t\t}),\n\t\ttemplate: z.string().meta({\n\t\t\tdescription:\n\t\t\t\t\"The template identifier used for generating the email content\",\n\t\t\texample: \"welcome-email\",\n\t\t}),\n\t\tpriority: emailPrioritySchema.meta({\n\t\t\tdescription: \"The priority hint supplied to the email adapter\",\n\t\t\texample: \"high\",\n\t\t}),\n\t}),\n\tdata: z\n\t\t.record(z.any(), z.any())\n\t\t.nullable()\n\t\t.meta({\n\t\t\tdescription: \"Custom data passed to the email template for rendering\",\n\t\t\texample: {\n\t\t\t\tusername: \"JohnDoe\",\n\t\t\t\taccountType: \"premium\",\n\t\t\t\tverificationUrl: \"https://example.com/verify/token123\",\n\t\t\t},\n\t\t}),\n\tattachments: z.array(\n\t\tz.object({\n\t\t\ttype: z.literal(\"url\").meta({\n\t\t\t\tdescription: \"The attachment source type\",\n\t\t\t\texample: \"url\",\n\t\t\t}),\n\t\t\turl: z.url().meta({\n\t\t\t\tdescription: \"The HTTP/S URL used as the attachment source\",\n\t\t\t\texample: \"https://example.com/invoice.pdf\",\n\t\t\t}),\n\t\t\tfilename: z.string().meta({\n\t\t\t\tdescription: \"The filename shown for the attachment\",\n\t\t\t\texample: \"invoice.pdf\",\n\t\t\t}),\n\t\t\tcontentType: z.string().nullable().meta({\n\t\t\t\tdescription: \"The MIME type of the attachment, if supplied\",\n\t\t\t\texample: \"application/pdf\",\n\t\t\t}),\n\t\t\tdisposition: z\n\t\t\t\t.union([z.literal(\"attachment\"), z.literal(\"inline\")])\n\t\t\t\t.meta({\n\t\t\t\t\tdescription:\n\t\t\t\t\t\t\"Whether the attachment is displayed inline or as an attachment\",\n\t\t\t\t\texample: \"attachment\",\n\t\t\t\t}),\n\t\t\tcontentId: z.string().nullable().meta({\n\t\t\t\tdescription: \"The optional CID used for inline attachments\",\n\t\t\t\texample: \"invoice-logo\",\n\t\t\t}),\n\t\t}),\n\t),\n\ttype: emailTypeSchema.meta({\n\t\tdescription:\n\t\t\t\"Whether the email was triggered internally from Lucid, or externally via an endpoint\",\n\t\texample: \"internal\",\n\t}),\n\tcurrentStatus: emailDeliveryStatusSchema.meta({\n\t\tdescription: \"The current delivery status of the email\",\n\t\texample: \"sent\",\n\t}),\n\tattemptCount: z.number().meta({\n\t\tdescription: \"The number of attempts to send the email\",\n\t\texample: 1,\n\t}),\n\thtml: z.string().nullable().meta({\n\t\tdescription: \"The rendered HTML content of the email template\",\n\t}),\n\tresend: z.object({\n\t\tenabled: z.boolean().meta({\n\t\t\tdescription: \"Whether this email can currently be resent\",\n\t\t\texample: true,\n\t\t}),\n\t\treason: z.enum([\"outsideResendWindow\", \"unstoredData\"]).optional().meta({\n\t\t\tdescription: \"Why resend is disabled, if unavailable\",\n\t\t\texample: \"outsideResendWindow\",\n\t\t}),\n\t}),\n\ttransactions: z.array(\n\t\tz.object({\n\t\t\tdeliveryStatus: emailDeliveryStatusSchema.meta({\n\t\t\t\tdescription: \"The current delivery status of the email\",\n\t\t\t\texample: \"sent\",\n\t\t\t}),\n\t\t\tmessage: z.string().nullable().meta({\n\t\t\t\tdescription: \"The message associated with the email delivery\",\n\t\t\t\texample: \"Email sent successfully\",\n\t\t\t}),\n\t\t\tstrategyIdentifier: z.string().meta({\n\t\t\t\tdescription: \"The identifier of the strategy used to send the email\",\n\t\t\t\texample: \"smtp\",\n\t\t\t}),\n\t\t\tstrategyData: z\n\t\t\t\t.record(z.string(), z.any())\n\t\t\t\t.nullable()\n\t\t\t\t.meta({\n\t\t\t\t\tdescription: \"The data associated with the email delivery\",\n\t\t\t\t\texample: {\n\t\t\t\t\t\tusername: \"JohnDoe\",\n\t\t\t\t\t\taccountType: \"premium\",\n\t\t\t\t\t\tverificationUrl: \"https://example.com/verify/token123\",\n\t\t\t\t\t},\n\t\t\t\t}),\n\t\t\texternalMessageId: z.string().nullable().meta({\n\t\t\t\tdescription:\n\t\t\t\t\t\"The external message ID of the email. Used for tracking the email in the provider's system.\",\n\t\t\t\texample: \"1234567890\",\n\t\t\t}),\n\t\t\tsimulate: z.boolean().meta({\n\t\t\t\tdescription: \"Whether the email was simulated and not actually sent\",\n\t\t\t\texample: true,\n\t\t\t}),\n\t\t\tcreatedAt: z.string().nullable().meta({\n\t\t\t\tdescription: \"Timestamp when the email was created\",\n\t\t\t\texample: \"2024-04-25T14:30:00.000Z\",\n\t\t\t}),\n\t\t\tupdatedAt: z.string().nullable().meta({\n\t\t\t\tdescription: \"Timestamp of the most recent delivery attempt\",\n\t\t\t\texample: \"2024-04-25T14:31:10.000Z\",\n\t\t\t}),\n\t\t}),\n\t),\n\tlastAttemptedAt: z.string().nullable().meta({\n\t\tdescription: \"The timestamp of the last attempt to send the email\",\n\t\texample: \"2024-04-25T14:30:00.000Z\",\n\t}),\n\tcreatedAt: z.string().nullable().meta({\n\t\tdescription: \"Timestamp when the email was created\",\n\t\texample: \"2024-04-25T14:30:00.000Z\",\n\t}),\n\tupdatedAt: z.string().nullable().meta({\n\t\tdescription: \"Timestamp of the most recent delivery attempt\",\n\t\texample: \"2024-04-25T14:31:10.000Z\",\n\t}),\n});\n\nexport const controllerSchemas = {\n\tgetMultiple: {\n\t\tbody: undefined,\n\t\tquery: {\n\t\t\tstring: z\n\t\t\t\t.object({\n\t\t\t\t\t\"filter[fromAddress]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"noreply@lucidcms.io\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[toAddress]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"admin@lucidcms.io\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[subject]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"Welcome To Lucid\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[currentStatus]\": queryString.schema.filter(true, {\n\t\t\t\t\t\texample: \"sent\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[type]\": queryString.schema.filter(true, {\n\t\t\t\t\t\texample: \"internal\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[template]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"password-reset\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[priority]\": queryString.schema.filter(true, {\n\t\t\t\t\t\texample: \"high\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[attemptCount]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"2\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[lastAttemptedAt]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"2026-01-01T00:00:00Z\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[createdAt]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"2026-01-01T00:00:00Z\",\n\t\t\t\t\t}),\n\t\t\t\t\t\"filter[updatedAt]\": queryString.schema.filter(false, {\n\t\t\t\t\t\texample: \"2026-01-01T00:00:00Z\",\n\t\t\t\t\t}),\n\t\t\t\t\tsort: queryString.schema.sort(\n\t\t\t\t\t\t\"lastAttemptedAt,attemptCount,createdAt,updatedAt\",\n\t\t\t\t\t),\n\t\t\t\t\tpage: queryString.schema.page,\n\t\t\t\t\tperPage: queryString.schema.perPage,\n\t\t\t\t})\n\t\t\t\t.meta(queryString.meta),\n\t\t\tformatted: z.object({\n\t\t\t\tfilter: z\n\t\t\t\t\t.object({\n\t\t\t\t\t\tfromAddress: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\ttoAddress: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\tsubject: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\tcurrentStatus: queryFormatted.schema.filters.union.optional(),\n\t\t\t\t\t\ttype: queryFormatted.schema.filters.union.optional(), // internal | external\n\t\t\t\t\t\ttemplate: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\tpriority: queryFormatted.schema.filters.union.optional(),\n\t\t\t\t\t\tattemptCount: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\tlastAttemptedAt: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\tcreatedAt: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t\tupdatedAt: queryFormatted.schema.filters.single.optional(),\n\t\t\t\t\t})\n\t\t\t\t\t.optional(),\n\t\t\t\tfilterOr: queryFormatted.schema.filterOr,\n\t\t\t\tsort: z\n\t\t\t\t\t.array(\n\t\t\t\t\t\tz.object({\n\t\t\t\t\t\t\tkey: z.enum([\n\t\t\t\t\t\t\t\t\"lastAttemptedAt\",\n\t\t\t\t\t\t\t\t\"attemptCount\",\n\t\t\t\t\t\t\t\t\"createdAt\",\n\t\t\t\t\t\t\t\t\"updatedAt\",\n\t\t\t\t\t\t\t]),\n\t\t\t\t\t\t\tdirection: z.enum([\"asc\", \"desc\"]),\n\t\t\t\t\t\t}),\n\t\t\t\t\t)\n\t\t\t\t\t.optional(),\n\t\t\t\tpage: queryFormatted.schema.page,\n\t\t\t\tperPage: queryFormatted.schema.perPage,\n\t\t\t}),\n\t\t},\n\t\tparams: undefined,\n\t\tresponse: z.array(emailResponseSchema),\n\t} satisfies ControllerSchema,\n\tgetSingle: {\n\t\tbody: undefined,\n\t\tquery: {\n\t\t\tstring: undefined,\n\t\t\tformatted: undefined,\n\t\t},\n\t\tparams: z.object({\n\t\t\tid: z.string().trim().meta({\n\t\t\t\tdescription: \"The email ID\",\n\t\t\t\texample: 1,\n\t\t\t}),\n\t\t}),\n\t\tresponse: emailResponseSchema,\n\t} satisfies ControllerSchema,\n\tdeleteSingle: {\n\t\tbody: undefined,\n\t\tquery: {\n\t\t\tstring: undefined,\n\t\t\tformatted: undefined,\n\t\t},\n\t\tparams: z.object({\n\t\t\tid: z.string().trim().meta({\n\t\t\t\tdescription: \"The email ID\",\n\t\t\t\texample: 1,\n\t\t\t}),\n\t\t}),\n\t\tresponse: undefined,\n\t} satisfies ControllerSchema,\n\tresendSingle: {\n\t\tbody: undefined,\n\t\tquery: {\n\t\t\tstring: undefined,\n\t\t\tformatted: undefined,\n\t\t},\n\t\tparams: z.object({\n\t\t\tid: z.string().trim().meta({\n\t\t\t\tdescription: \"The email ID\",\n\t\t\t\texample: 1,\n\t\t\t}),\n\t\t}),\n\t\tresponse: z.object({\n\t\t\tjobId: z.string().meta({\n\t\t\t\tdescription: \"The job ID\",\n\t\t\t\texample: \"1234567890\",\n\t\t\t}),\n\t\t}),\n\t} satisfies ControllerSchema,\n};\n\nexport type GetMultipleQueryParams = z.infer<\n\ttypeof controllerSchemas.getMultiple.query.formatted\n>;\n"],"mappings":"+FAIA,MAAa,EAA4B,EAAE,MAAM,CAChD,EAAE,QAAQ,MAAM,EAChB,EAAE,QAAQ,WAAW,EACrB,EAAE,QAAQ,SAAS,EACnB,EAAE,QAAQ,YAAY,EACtB,EAAE,QAAQ,SAAS,EACnB,EAAE,QAAQ,SAAS,EACnB,EAAE,QAAQ,QAAQ,EAClB,EAAE,QAAQ,QAAQ,EAClB,EAAE,QAAQ,WAAW,CACtB,CAAC,EAEY,EAAkB,EAAE,MAAM,CACtC,EAAE,QAAQ,UAAU,EACpB,EAAE,QAAQ,UAAU,CACrB,CAAC,EAEY,EAAsB,EAAE,MAAM,CAC1C,EAAE,QAAQ,KAAK,EACf,EAAE,QAAQ,QAAQ,EAClB,EAAE,QAAQ,MAAM,CACjB,CAAC,EAEK,EAAsB,EAAE,OAAO,CACpC,GAAI,EAAE,OAAO,CAAC,CAAC,KAAK,CACnB,YAAa,eACb,QAAS,CACV,CAAC,EACD,YAAa,EAAE,OAAO,CACrB,KAAM,EAAE,OAAO,CACd,QAAS,EAAE,MAAM,CAAC,CAAC,KAAK,CACvB,YAAa,6BACb,QAAS,mBACV,CAAC,EACD,KAAM,EAAE,OAAO,CAAC,CAAC,KAAK,CACrB,YAAa,oBACb,QAAS,OACV,CAAC,CACF,CAAC,EACD,GAAI,EAAE,OAAO,CAAC,CAAC,KAAK,CACnB,YAAa,gCACb,QAAS,kBACV,CAAC,EACD,QAAS,EAAE,OAAO,CAAC,CAAC,KAAK,CACxB,YAAa,yBACb,QAAS,sBACV,CAAC,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