gmail
gmail copied to clipboard
Get Date, Sender info from a message
Hello,
How is it possible to get the sender Info to a string in format Some Name <[email protected]>
, the date it was sent and if there any other recipients (cc)? I tried the following but it din't worked:
inbox = g.inbox().mail(sender="[email protected]")
for msg in inbox:
msg.fetch()
print msg.body, msg.subject, msg.date, msg.cc