I’m not certain exactly what you are looking for, but this is the first
result I got on google. I didn’t try it, but it’s looking good and
includes many code samples:
IMAP:
Incoming Mail (IMAP) Server - Requires SSL: imap.gmail.com
Port: 993
Requires SSL:Yes
Outgoing Mail (SMTP) Server - Requires TLS: smtp.gmail.com
Port: 465 or 587
Requires SSL: Yes
Requires authentication: Yes
Use same settings as incoming mail server
Full Name or Display Name: [your name]
Account Name or User Name: your full Gmail address ([email protected]). >
Google Apps users, please enter username@your_domain.com
Email address: your full Gmail address ([email protected])
Google Apps users, please enter username@your_domain.com
Password: your Gmail password
POP:
Incoming Mail (POP3) Server - requires SSL: pop.gmail.com
Use SSL: Yes
Port: 995
Outgoing Mail (SMTP) Server - requires TLS or SSL: smtp.gmail.com
Use Authentication: Yes
Port for TLS/STARTTLS: 587
Port for SSL: 465
Server timeouts Greater than 1 minute, we recommend 5
Full Name or Display Name: [your name]
Account Name or User Name: your full email address
(including @gmail.com or @your_domain.com)
Email Address: your email address
([email protected] or username@your_domain.com)
Password: your Gmail password