JavaメールAPIを使用して、Amazon SESから返送されたメールをGmail IDで読み取っています。JavaメールAPIを使用してメールを返送する方法を教えてください。
これは、Amazon SESからバウンスメールを受信する方法です。
<email content start>
An error occurred while trying to deliver the mail to the following recipients:
[email protected]
Action: failed
Final-Recipient: rfc822; [email protected]
Diagnostic-Code: smtp; 550 5.1.1 user unknown
Status: 5.1.1
---------- Forwarded message ----------
From: [email protected]
To: [email protected]
Cc:
Bcc:
Date: Sun, 17 Dec 2017 15:27:30 +0000
Subject: [email protected]
[email protected]
<email content end>
私の質問は、Java電子メールAPIを使用しています。私はにコンテンツを読むことができる午前:
An error occurred while trying to deliver the mail to the following recipients:
[email protected]
しかし、私は、JavaのメールAPIの助けを借りて、以下の内容を読み取ることができないです私は上記の内容を読むことができますどのように
Action: failed
Final-Recipient: rfc822; [email protected]
Diagnostic-Code: smtp; 550 5.1.1 user unknown
Status: 5.1.1
Eメール?
バウンスメッセージは、[RFC 6533](https://tools.ietf.org/html/rfc6533)で定義されていますが、すべてのサーバは、すべてのルールに従っていません。バウンスメッセージのMIME構造を見て、実際のDelivery Status Notfication(DSN)である「添付」を探してみてください。さまざまな種類のメールサーバーと構成に対してこれを行う準備が必要です。 – Robert
[com.sun.mail.dsnパッケージ](https://javaee.github.io/javamail/docs/api/com/sun/mail/dsn/package-summary.html)も参照してください。 –