Files
Giancarlo Buomprisco f3ac595d06 MCP Server 2.0 (#452)
* MCP Server 2.0

- Updated application version from 2.23.14 to 2.24.0 in package.json.
- MCP Server improved with new features
- Migrated functionality from Dev Tools to MCP Server
- Improved getMonitoringProvider not to crash application when misconfigured
2026-02-11 20:42:01 +01:00

40 lines
1.0 KiB
TypeScript

import { renderAccountDeleteEmail } from './emails/account-delete.email';
import { renderInviteEmail } from './emails/invite.email';
import { renderOtpEmail } from './emails/otp.email';
/**
* Registry of email template renderers.
*
* This is used to render email templates dynamically. Ex. list all available email templates in the MCP server.
*
* @example
*
* const { html, subject } = await renderAccountDeleteEmail({
* userDisplayName: 'John Doe',
* productName: 'My SaaS App',
* });
*
* await mailer.sendEmail({
* to: 'user@example.com',
* from: 'noreply@yourdomain.com',
* subject,
* html,
* });
*
* @example
*
* const { html, subject } = await renderAccountDeleteEmail({
* userDisplayName: 'John Doe',
* productName: 'My SaaS App',
* });
*
*/
export const EMAIL_TEMPLATE_RENDERERS = {
'account-delete-email': renderAccountDeleteEmail,
'invite-email': renderInviteEmail,
'otp-email': renderOtpEmail,
};
export type EmailTemplateRenderer =
(typeof EMAIL_TEMPLATE_RENDERERS)[keyof typeof EMAIL_TEMPLATE_RENDERERS];