python-o365
python-o365 copied to clipboard
Sending multipart emails?
Is it possible to send multipart emails, namely emails with both a body in text only and a body in html?
Thanks
Not currently, but check the Ms graph docs
Do you have a link to the relevant documentation?
No... but check this as a start
The docs claim it is possible:
When getting a message, you can specify the following request header to return the body and uniqueBody properties in text format: HTTP
Prefer: outlook.body-content-type="text"
The docs claim it is possible:
When getting a message, you can specify the following request header to return the body and uniqueBody properties in text format: HTTP
Prefer: outlook.body-content-type="text"
I'm not sure but setting this header only converts the body property of a message into plain text. You still don't have access to MIME Multipart emails.
And this still does not solve the issue of sending MIME Multipart Messages.
Indeed, the message would not be multipart, but at least it should be possible to send text-only messages, right? (although that was not my initial question).
thanks!
@johanovic sorry for this late response... I don't have time right know to check if setting the header when sending an email will send the email just as plain text. If you can you try it setting the boy with some html tags would be great.