diff --git a/REST-GET-message.md b/REST-GET-message.md index 9448abf..6caf1bb 100644 --- a/REST-GET-message.md +++ b/REST-GET-message.md @@ -13,7 +13,9 @@ Retrieve message body ### Output -The Inbucket version of the message headers (same as returned by [GET /mailbox/{name}](https://github.com/jhillyerd/inbucket/wiki/REST-GET-mailbox)), plus the Text and HTML portions of the MIME body of the email. +* The Inbucket version of the message headers (same as returned by [GET /mailbox/{name}](https://github.com/jhillyerd/inbucket/wiki/REST-GET-mailbox)) +* The decoded Text and HTML portions of the MIME body of the email +* The parsed SMTP headers (not converted to UTF-8) ### Example @@ -22,16 +24,33 @@ Request: `curl -i -H "Accept: application/json" http://localhost:9000/mailbox/sw Response: (JSON reformatted for readability) { - "Body":{ - "Text":"This is a test mailing.\r\n\r\nThis should be clickable: http://google.com/\r\n", - "Html":"\u003chtml\u003e\n\u003cbody\u003e\n\u003cp\u003eThis is a test mailing [...]" - }, - "Header":{ - "Mailbox":"swaks", - "Id":"20131016T164638-0001", - "From":"jamehi03@server.com", - "Subject":"Swaks HTML", - "Date":"2013-10-16T16:46:38.646370568-07:00", - "Size":705 - } + "Mailbox": "swaks", + "Id": "20131016T164638-0001", + "From": "jamehi03@jamehi03lx.noa.com", + "Subject": "Swaks HTML", + "Date": "2013-10-16T16:46:38.646370568-07:00", + "Size": 705, + "Body": { + "Text": "This is a test mailing.\r\n\r\nThis should be clickable: http://google.com/\r\n", + "Html": "\n
\nThis is a test mailing in HTML
\n\nThis should be clickable: [...]" }, + "Header": { + "Content-Type": [ + "multipart/alternative; boundary=\"----=_MIME_BOUNDARY_000_62717\"" + ], + "Date": [ + "Wed, 16 Oct 2013 16:46:38 -0700" + ], + "From": [ + "jamehi03@jamehi03lx.noa.com" + ], + "Mime-Version": [ + "1.0" + ], + "Subject": [ + "Swaks HTML" + ], + "To": [ + "swaks@inbucket.local" + ] + } } \ No newline at end of file