I've following list of attachments to send in mail
- 210KBPDF.pdf
- 1MBPDF.pdf
- 4MBPDF.pdf
To send total file size under 4 MB(1MBPDF, 210KBPDF) I can use this approach and To send large file (4MBPDF) I'm using solution provided here
But when I'm trying to send three files (1MBPDF, 210KBPDF, 4MBPDF) together using large file approach (Sample code) I'm getting following error...
com.microsoft.graph.http.GraphServiceException: Error code: ErrorAttachmentSizeShouldNotBeLessThanMinimumSize Error message: Attachment size must be greater than the minimum size.
POST https://graph.microsoft.com/v1.0/me/messages/AAMkAGNhNWJlNjdkLWNkZTUtNDE1Yy1hYzkxLTkyOWI1M2U3NGQzOABGAAAAAAASIVxVSsS8RI-T3F73mdJZBwANqxyKMlQbSqZO439E21_mAAAAAAEPAAANqxyKMlQbSqZO439E21_mAAAVRY2dAAA=/attachments/microsoft.graph.createUploadSession SdkVersion : graph-java/v2.3.2 Authorization : [PII_REDACTED] {"attachmentItem":{"attachmentType":"file","conten[...]
400 : Bad Request [...]
Please let me know if I'm making any mistakes to implement the approach or suggest me any work-around to send multiple attachments mixed in size.
Thanks