Mark email as read with exchangelib
Asked Answered
C

3

9

I am using Pythons exchangelib package. How can I mark an e-mail as read with exchangelib?

I have had a look at the official GitHub exchangelib page for my query, but didn't find the answer.

Chasechaser answered 11/7, 2017 at 14:25 Comment(0)
B
14

To add to joe's comment, you must also 'save' the item for the flag to be permanent.

item.is_read = True
item.save()
Bouillon answered 26/12, 2017 at 23:49 Comment(0)
S
6

To add to HeroicOlive's comment, if you specifically want to save the is_read value only, try:

item.is_read = True
item.save(update_fields=['is_read'])
Stretcherbearer answered 25/3, 2019 at 3:14 Comment(0)
D
2

item.is_read = True should do the trick where item is the message you want to mark read

Doubleacting answered 21/7, 2017 at 15:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.