What happened?
SMTP currently don't support sending attachments
The SMTP server drops attachments on the floor before forwarding to the useSend API.
When mailparser's simpleParser parses the incoming email stream, it returns a ParsedMail object that does include an attachments array (each with filename, content Buffer, contentType, etc.). However, the code constructs the payload for the API like this:
const emailObject = {
to: ...,
from: ...,
subject: parsed.subject,
text: parsed.text,
html: parsed.html,
replyTo: parsed.replyTo?.text,
};
attachments is never referenced, so anything attached to the SMTP message is silently discarded.
What happened?
SMTP currently don't support sending attachments
The SMTP server drops attachments on the floor before forwarding to the useSend API.
When mailparser's simpleParser parses the incoming email stream, it returns a ParsedMail object that does include an attachments array (each with filename, content Buffer, contentType, etc.). However, the code constructs the payload for the API like this:
attachments is never referenced, so anything attached to the SMTP message is silently discarded.