Skip to content

Commit

Permalink
essages.deleteAttachments()
Browse files Browse the repository at this point in the history
  • Loading branch information
jobisoft committed Feb 14, 2024
1 parent 9fd0484 commit 54db879
Showing 1 changed file with 37 additions and 1 deletion.
38 changes: 37 additions & 1 deletion messages.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@ Permissions

Change properties and tags of your email messages

.. api-member::
:name: :permission:`messagesModifyPermanent`

Permanently modify the source of your messages (including headers, body and attachments)

.. api-member::
:name: :permission:`sensitiveDataUpload`

Expand Down Expand Up @@ -181,6 +186,37 @@ Deletes messages permanently, or moves them to the trash folder (honoring the ac
- :permission:`messagesRead`
- :permission:`messagesDelete`

.. _messages.deleteAttachments:

deleteAttachments(messageId, partNames)
---------------------------------------

.. api-section-annotation-hack::

Deletes the specified attachments and replaces them by placeholder text attachments with meta information about the original attachments and a :value:`text/x-moz-deleted` content type. This permanently modifies the message.

.. api-header::
:label: Parameters


.. api-member::
:name: ``messageId``
:type: (integer)


.. api-member::
:name: ``partNames``
:type: (array of string)

An array of attachments, identifiying the to be detached attachments by their :value:`partName`.


.. api-header::
:label: Required permissions

- :permission:`messagesRead`
- :permission:`messagesModifyPermanent`

.. _messages.get:

get(messageId)
Expand Down Expand Up @@ -1054,7 +1090,7 @@ Represents an attachment in a message.
:name: ``contentType``
:type: (string)

The content type of the attachment.
The content type of the attachment. A value of :value:`text/x-moz-deleted` indicates that the original attachment was permanently deleted and replaced by a placeholder text attachment with some meta information about the original attachment.


.. api-member::
Expand Down

0 comments on commit 54db879

Please sign in to comment.