jeremyephron / simplegmail

A simple Gmail API client for applications in Python
MIT License
336 stars 73 forks source link

Add CC & BCC to message object #63

Closed rasa closed 1 year ago

rasa commented 2 years ago

Example usage:

from simplegmail import Gmail

gmail = Gmail()

# Unread messages in your inbox
messages = gmail.get_unread_inbox()

# Starred messages
messages = gmail.get_starred_messages()

# ...and many more easy to use functions can be found in gmail.py!

# Print them out!
for message in messages:
    print("To: " + message.recipient)
    print("From: " + message.sender)
    print("Cc: " + message.cc)
    print("Bcc: " + message.bcc)
    print("Subject: " + message.subject)
    print("Date: " + message.date)
    print("Preview: " + message.snippet)

    print("Message Body: " + message.plain)  # or message.html
jeremyephron commented 1 year ago

Thanks @rasa, your commit has been merged. You can see the edits I made here: 963a4b37f904321d836fe3a2a06c22d8f05eaec4. Github cannot understand that the rebased commit has been merged, so closing.