A Command Line Interface email client written in python.
Project description
CLImail
An CLI email client written in python. Should support different email providers such as outlook, gmail, hotmail etc.
Install with - python -m pip install climail
Start the CLI with - python -m climail [-smtp_server server] [-imap_server server] [-smtp_port port] [-imap_port port]
The default server it uses is gmail, if you want to use any other email provider, make sure to enter the correct server, ports and address.
EXAMPLES:
Normal login:
user = User('password', 'email')
Customized login:
user = User('password', 'email', smtp_server='smtp-mail.outlook.com', imap_server='imap-mail.outlook.com', smtp_port=587, imap_port=993)
Ports for SMTP and IMAP servers can be found at https://www.systoolsgroup.com/imap/.
Getting the latest mail:
user.mail_from_template(user.mail_from_id(user.mail_ids_as_str(1)[0]))
Sending an email:
user.sendmail('to_address', 'content', subject='subject', cc=[ 'cc_address1', 'cc_address2'], attachments=['file1.txt', 'file2.txt'])
Deleting 10 of the latest messages:
user.delete_mail(10)
Selecting a mailbox(mailboxes can be found from the User.list_mailboxes method):
user.select_mailbox('INBOX')
NOTE: to select mailboxes other than INBOX, you must select exactly how they are shown in the User.list_mailboxes method. Sent mailbox for example is shown as "[Gmail]/Sent Mail".
user.select_mailbox('"[Gmail]/Sent Mail"')
Saving all attachments from the latest message:
user.save_attachments(user.mail_from_id(user.mail_ids_as_str(1)[0]))
The rest of the methods are quite self-explanatory, if you need help DM me at HRLO77#3508 (discord) or hrlo.77 (Instagram)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file climail-2.1.5.tar.gz.
File metadata
- Download URL: climail-2.1.5.tar.gz
- Upload date:
- Size: 11.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
aff9c890f14a7497065c3eba8ce6113ee82aa72e230c0e47ed01d2b4739c0f41
|
|
| MD5 |
b906d07decb0e3a1fc01b3b65c96d99a
|
|
| BLAKE2b-256 |
aed61116fa976c083ae97c9bbc086d597bb7f4732ca5c7b47520af8356f2bc3a
|
File details
Details for the file climail-2.1.5-py3-none-any.whl.
File metadata
- Download URL: climail-2.1.5-py3-none-any.whl
- Upload date:
- Size: 12.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4f5e6c6dcfebfdd5d6430876cc6f3402ea73d56d71c465ea51c78574c579608f
|
|
| MD5 |
bf9368c17624cb93c864dd9fcbabdf00
|
|
| BLAKE2b-256 |
f707fb7885058d6829c562b13a2ecfc50c82c2f44fa6739bf844fc9684017296
|