Email::Send::Gmail

acme on 2007-11-04T21:33:11

Sending mail is too hard. You have to know what kind of machine you are on and what the sysadmins might have set up. It's even more of a pain if your code might run in a few places. That's why I've written Email::Send::Gmail so you can send email programmatically using a Gmail account. Simple but good.


why a new module? why not Mail-Webmail-Gmail-1.09?

mw487 on 2007-11-05T13:13:53


http://search.cpan.org/user/mincus/Mail-Webmail-Gmail-1.09/

SAMPLE USAGE

        my ( $gmail ) = Mail::Webmail::Gmail->new(
                        username => 'username', password => 'password', );

        ### Test Sending Message ####
        my $msgid = $gmail->send_message( to => 'testuser@test.com', subject => time(), msgbody => 'Test' );

Re:why a new module? why not Mail-Webmail-Gmail-1.

acme on 2007-11-05T14:39:26

It uses the nice set of Email:: modules and uses authenticated SSL SMTP, a supported feature by Google. That module is a great hack, but still a hack, and will break whenever Google change anything - see the CHANGES: http://search.cpan.org/src/MINCUS/Mail-Webmail-Gmail-1.09/Changes

Re:why a new module? why not Mail-Webmail-Gmail-1.

mw487 on 2007-11-05T16:56:28

I got a bit confused by "it" and "that", but I think I see that Mail-Webmail-Gmail-1.09 relies on http traffic and fragile HTML for login, but does support file attachments for sending. Email-Send-Gmail supports an SSL connection for login/sending; does it support attachments?

Maybe the authors of the two modules could put their heads together and improve each other's code? I think for most of GMail, you might need a screen scraper, and sending mail over SSL would be nice.