Loading
Slack製品の問い合わせ先はSalesforce Helpへ統合・変更されます続きを読む

Email-to-Case: Extra .txt and .html Attachments Created When Receiving .eml File Attachments

公開日: Jul 21, 2026
説明

When an email containing a .eml or .msg file attachment is sent to an Email-to-Case routing address in Salesforce, the platform may generate additional .txt and .html attachment records alongside the original .eml file. This article explains why this occurs, how Salesforce Email-to-Case processes nested email MIME types, and how file naming is determined based on the original email headers.

解決策

How Salesforce Email-to-Case Processes .eml Attachments

When an email containing a .eml or .msg attachment is processed by the Salesforce Email-to-Case service, the platform's behavior depends on the Content-Type header of the attached file, as set by the originating email client.
When the attached .eml file has a Content-Type header value of "message/rfc822", Salesforce Email-to-Case identifies it as a nested email object (RFC 822 is the standard format for Internet email messages). The service then parses the nested email into its component parts and creates separate child attachment records. This typically results in three attachments:

  1. A .txt attachment for the plain text body of the nested email.
  2. An .html attachment for the HTML body of the nested email.
  3. The original .eml file itself.

Filename Behavior: When the .eml Attachment Has a Filename

When the Content-Disposition header includes a filename attribute, Salesforce uses that filename as the base for all generated attachments.
Example headers:
Content-Type: message/rfc822
Content-Disposition: attachment; filename="Testemail.eml"
Resulting attachments:

  1. Testemail.eml
  2. Testemail_Attachment_1.txt
  3. Testemail_Attachment_2.html

Filename Behavior: When the .eml Attachment Has No Filename

When the Content-Disposition header does not include a filename attribute, Salesforce uses the subject line of the received email as the base name for the .txt and .html files, and generates a default name for the .eml file.
Example headers:
Content-Type: message/rfc822; subject name="Welcome to your new Outlook.com account (1).eml"
Content-Disposition: attachment; creation-date="Mon, 22 Sep 2025 11:12:38 GMT"
Resulting attachments:

  1. Attachment_1.eml
  2. Welcome to your new Outlook.com account (1)_Attachment_1.txt
  3. Welcome to your new Outlook.com account (1)_Attachment_2.html

Expected Behavior Summary

This behavior is by design. The Salesforce Email-to-Case service uses MIME type-aware processing logic to parse nested email objects (Content-Type: message/rfc822) into their component parts. The generation of multiple attachment records is not an error — it is a feature of the platform's email processing architecture.

ナレッジ記事番号

005101786

 
読み込み中
Salesforce Help | Article