set_content(msg, <'EmailMessage'>, cte=None, \
disposition=None, filename=None, cid=None, \
params=None, headers=None)
- set_content(msg, <'list'>, subtype='mixed', \
- disposition=None, filename=None, cid=None, \
- params=None, headers=None)
Add headers and payload to *msg*:
specified or ``rfc822`` if it is not. If *subtype* is
``partial``, raise an error (``bytes`` objects must be used to
construct ``message/partial`` parts).
- * For *<'list'>*, which should be a list of
- :class:`~email.message.EmailMessage` objects, set the ``maintype``
- to ``multipart``, and the ``subtype`` to *subtype* if it is
- specified, and ``mixed`` if it is not. If the message parts in
- the *<'list'>* have :mailheader:`MIME-Version` headers, remove
- them.
If *charset* is provided (which is valid only for ``str``), encode the
string to bytes using the specified character set. The default is