Skip to content

AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents

539 B
Raw Blame
import { FastifyBaseLogger } from 'fastify'
import { EmailSender } from './email-sender'

/**
 * Logs sent emails to the console
 */
export const logEmailSender = (log: FastifyBaseLogger): EmailSender => {
    return {
        async send({ emails, platformId, templateData, replyTo }) {
            log.debug({
                name: 'LogEmailSender#send',
                emails,
                platform: { id: platformId },
                templateData,
                ...(replyTo ? { replyTo } : {}),
            })
        },
    }
}