You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
GET /me/messages/{id}/attachments/{id}
GET /users/{id | userPrincipalName}/messages/{id}/attachments/{id}
GET /me/messages/{id}/attachments/{id}/$value
GET /users/{id | userPrincipalName}/messages/{id}/attachments/{id}/$value
GET https://graph.microsoft.com/v1.0/me/messages/AAMkADVIOAAA=/attachments/AAMkADVIOAAABEgAQACvkutl6c4FMifPyS6NvXsM=/$value
The issue is $value seems not to be implemented.
classAttachmentItemRequestBuilderGetQueryParameters""" The fileAttachment and itemAttachment attachments for the message. """# Expand related entitiesexpand: Optional[List[str]] =None# Select properties to be returnedselect: Optional[List[str]] =None
The class AttachmentItemRequestBuilderGetQueryParameters does not contain value : Optional[bool] = None
frommsgraph.generated.models.attachment_itemimportAttachmentItem# attachment is of type AttachmentItemcontent=attachment.additional_data['content_bytes']
content=base64.b64decode(content)
content=content.decode('ascii')
With the last version of your SDK, my workaround does not work anymore:
frommsgraph.generated.models.attachment_itemimportAttachmentItem# attachment is of type AttachmentItemcontent=attachment.additional_data['content_bytes']
content=base64.b64decode(content)
content=content.decode('ascii')
content_bytes does not exist anymore.
I can not find any documentation to download mail attachments.
I think I am not alone, see #110
Activity
Renji-FR commentedon Feb 20, 2023
I use that as workaround:
Renji-FR commentedon May 2, 2023
Samwel K. (@samwelkanda) Vincent Biret (@baywet) Hi
With the last version of your SDK, my workaround does not work anymore:
content_bytesdoes not exist anymore.I can not find any documentation to download mail attachments.
I think I am not alone, see #110
Renji-FR commentedon May 2, 2023
Ok found how to download a message attachment: