{"id":2969,"date":"2019-05-09T09:28:18","date_gmt":"2019-05-09T16:28:18","guid":{"rendered":"https:\/\/developer.microsoft.com\/en-us\/office\/blogs\/?p=2969"},"modified":"2019-05-09T09:28:18","modified_gmt":"2019-05-09T16:28:18","slug":"mime-format-support-for-microsoft-graph-apis-preview","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/mime-format-support-for-microsoft-graph-apis-preview\/","title":{"rendered":"MIME format support for Outlook mail and attachments in Microsoft Graph (preview)"},"content":{"rendered":"<p>Today we\u2019re excited to announce the release of two highly requested APIs to the Microsoft Graph beta endpoint. These allow you to retrieve the <a href=\"https:\/\/docs.microsoft.com\/en-us\/graph\/outlook-get-mime-message\">contents of an email message in MIME format<\/a> and to <a href=\"https:\/\/docs.microsoft.com\/en-us\/graph\/api\/attachment-get?view=graph-rest-beta&amp;tabs=cs#get-the-raw-contents-of-a-file-or-item-attachment\">download file, item attachments in their raw format<\/a>.<\/p>\n<p>Many scenarios require an app to download and store the raw contents of an email. Imagine a service desk application that creates a service ticket for every new email received from users. In addition to monitoring for new emails via change notifications, the application can now download the email in MIME format, including attachments, and attach it to the service ticket. Note that this feature adds support for MIME export only for messages, not other item types like events or contacts. If you need MIME export for events or contacts, let us know by <a href=\"https:\/\/microsoftgraph.uservoice.com\/forums\/920506-microsoft-graph-feature-requests\/suggestions\/37560772-export-the-event-contact-items-in-vcf-ical-forma\">voting up this request on our UserVoice forum.<\/a> If you\u2019re looking for the ability to upload MIME to create or edit an email message, vote up <a href=\"https:\/\/microsoftgraph.uservoice.com\/forums\/920506-microsoft-graph-feature-requests\/suggestions\/35049175-put-edit-mime-email-content-with-microsoft-graph\">this feature request on User Voice<\/a>.<\/p>\n<p>You can now download file attachments in binary format, allowing for faster, more efficient downloads compared to base64 format. You can also download item attachment content in MIME format, and use it to get details of nested attachments.<\/p>\n<p>We\u2019ve had a number of requests for these APIs, and we can\u2019t wait to see what you\u2019ll create with them. These features are available today on the beta endpoint as <a href=\"https:\/\/docs.microsoft.com\/en-us\/graph\/outlook-get-mime-message\">\/me\/messages\/{message-id}\/$value<\/a> and <a href=\"https:\/\/docs.microsoft.com\/en-us\/graph\/api\/attachment-get?view=graph-rest-beta&amp;tabs=cs#get-the-raw-contents-of-a-file-or-item-attachment\">\/me\/messages\/{message-id}\/attachments\/{attachment-id}\/$value<\/a>. You can try them out using <a href=\"https:\/\/developer.microsoft.com\/en-us\/graph\/graph-explorer\">Microsoft Graph Explorer<\/a>.<\/p>\n<p>Please <a href=\"https:\/\/microsoftgraph.uservoice.com\/forums\/920506-microsoft-graph-feature-requests\">let us know<\/a> if you have additional feedback or suggestions for new functionality. Happy coding!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today we\u2019re excited to announce the release of two highly requested APIs to the Microsoft Graph beta endpoint. These allow you to retrieve the contents of an email message in MIME format and to download file, item attachments in their raw format.<\/p>\n","protected":false},"author":69107,"featured_media":25159,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[3],"tags":[12],"class_list":["post-2969","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-microsoft-graph","tag-outlook"],"acf":[],"blog_post_summary":"<p>Today we\u2019re excited to announce the release of two highly requested APIs to the Microsoft Graph beta endpoint. These allow you to retrieve the contents of an email message in MIME format and to download file, item attachments in their raw format.<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/2969","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/users\/69107"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/comments?post=2969"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/2969\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media\/25159"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media?parent=2969"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/categories?post=2969"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/tags?post=2969"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}