Receiving emails with attachments

Gerard Flanagan grflanagan at yahoo.co.uk
Sat Apr 8 16:59:45 EDT 2006


tomer.ha at gmail.com wrote:

> Hi there,
>
> I'm new to Python, but know other scripting and programming languages.
> I
> want to develop a script which will receive emails with attachments
> from my POP3 account, perform certain actions on it and email it back
> to someone else.
>
> However, I'm not familiar with any Python library which does it. Could
> you a guide me to a relevant library which can handle emails?
>
> I haven't decided yet what scripting language I will use, so a nice
> module for Python will probably make me choose it over Perl. :)
>
> Thanks in advance. :)

poplib module:

    http://docs.python.org/lib/pop3-example.html

some example code that I wrote when I was starting Python:

    http://gflanagan.net/site/python/pagliacci/PopClient.html

( YMMV with this - it works for me but the emails I handle with it are
mostly from a single company and attachments are only ever MS Word or
MS Excel )

I don't know about sending mails.

Gerard




More information about the Python-list mailing list