gmail

SmtpClient in C# using smtp.Gmail.com:857 with Google's 2 Step Verification activated

♀尐吖头ヾ 提交于 2019-12-04 20:29:52
I'm having trouble with sending an email using the Gmail SMTP Server in C#. There is plenty of subjects about this matter in StackOverflow, but none of the solutions around there are working with my specifities. My specificities are : App Specific Password generated and very strong password originally Double Auth (2 Step Verification) activated and required because of some other app "Allow Less Secure Apps" parameter is unavailable from Google's UI Can someone propose a solution ? The solution "Disable 2 Step Verification" is not a valid solution are we are looking for a solution that respects

How to detect that i have received an email/gmail on my Android Device?

流过昼夜 提交于 2019-12-04 20:27:23
Is there a way to detect or an event being triggered when i receive a gmail/email on my android device. Basically i would like my application to read the email notification when i receive it. Could you kindly tell me if there is way to do this ? Alex Davis You need to register a content observer (not broadcast receiver) contentResolver.registerContentObserver(Uri.parse("content://gmail-ls"), true, gmailObserver); gmailObserver is your own ContentObserver object. ContentObserver.onChange is going to be called every time something changes in Gmail. Here you get all conversations like so: Cursor

regex like gmail search operators - PHP preg_match

雨燕双飞 提交于 2019-12-04 20:15:52
I'm trying to implement a system similar to gmail search operators using function preg_match from PHP to split the input string . Example: input string => command1:word1 word2 command2:word3 command3:word4 wordN output array => ( command1:word1 word2, command2:word3, command3:word4 wordN ) The following post explains how to do it: Implementing Google search operators I already test it using preg_match but doesn't match. I think regular expressions may change a bit from system to system. Any guess how regex in PHP would match this problem? preg_match('/\s+(?=\w+:)/i','command1:word1 word2

Gmail Notification自动Gmail未读检查和短信提醒

半腔热情 提交于 2019-12-04 19:55:48
何时应该检查Gmail邮箱有没有未读邮件,大概都要不停的登陆刷新。 怎么能让新邮件到达给个主动提醒,是我最近一直思考的问题。 于是查了Google的接口,非常丰富非常丰满,不愧是业界第一邮箱服务。 所以就诞生这个项目Gmail Notification https://github.com/spance/Gmail-Notification Gmail Notification 对已许可的Gmail邮箱进行检查,发现新邮件后通过已配置的短信接口发送未读邮件的提醒短信。 利用Google oauth接口访问已授权用户的收件箱,对未读邮件进行分析并发送提醒,同一未读邮件在6小时内不会提醒超过2次(未来这些策略参数可调整),避免长时间未读邮件造成大量短信的骚扰。 目前,通过console交互方式配置许可授权,在.conf文件中定义接口参数,自动通过cron-job做定时检查。 每5分钟检查一次,支持多账户,理论上最多可以配置3472222个用户,因为Google API允许每个Client每天可调用1亿次。 扫描和通信日志在logs目录下,请定时检查并反馈错误。 关于隐私和安全性 邮箱账户通常是私密性的,因此不建议使用第三方服务,应该将程序部署到可信服务器上,专属的为自己或朋友私密的运行。 Google oauth接口是安全、可靠的,程序通过Google接口获得用户授权,不接触密码

Connection could not be established with host smtp.gmail.com [Operation timed out #60]

送分小仙女□ 提交于 2019-12-04 19:22:02
问题 I can't sent out any email in my local environment. I keep getting : _ .env file. MAIL_DRIVER=smtp MAIL_HOST=smtp.gmail.com MAIL_PORT=465 MAIL_USERNAME=my-email@gmail.com MAIL_PASSWORD=***** Note : Surprisingly - I have the same setting in my production server, and it works perfectly. Any hints / suggestions ? 回答1: Update my driver line to MAIL_DRIVER=sendmail It works on the first try. Final .env file should look like this MAIL_DRIVER=sendmail MAIL_HOST=smtp.gmail.com MAIL_PORT=465 MAIL

Sending Email via GMail and .NET 4

南笙酒味 提交于 2019-12-04 18:30:03
Does .NET 4 has any problems in sending emails? I had a .NET 3.5 solution and it was working then migrated the solution to .NET 4 and It does not works; nothing changed! Notes: I get this exception: System.Net.Mail.SmtpException: The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1 Authentication Required. Learn more at at System.Net.Mail.MailCommand.CheckResponse(SmtpStatusCode statusCode, String response) at System.Net.Mail.MailCommand.Send(SmtpConnection conn, Byte[] command, String from) at System.Net.Mail.SmtpTransport.SendMail

PHP Mailer - SMTP GMAIL AUTHENTICATION

落花浮王杯 提交于 2019-12-04 17:23:38
I have problem with the PHP MAILER function. I am using GMAIL SMTP Authentication for sending email and also its working perfectly but i want to set "From" email like "myid@domainname.com" but it doesn't working properly. I used below code to set "From" email $mail = new PHPMailer(); $mail->IsSMTP(); // telling the class to use SMTP $mail->Host = "mail.gmail.com"; // SMTP server $mail->SMTPDebug = 0; // enables SMTP debug information (for testing) $mail->SMTPAuth = true; // enable SMTP authentication $mail->SMTPSecure = "ssl"; // sets the prefix to the servier $mail->Host = "smtp.gmail.com"; /

Get contact list from gmail, yahoo, hotmail

ぐ巨炮叔叔 提交于 2019-12-04 17:19:53
I wish to write an API that can get the contacts list from Gmail, Yahoo and other e-mails. How can this be done? Are there already existing APIs for them or do I need to write PHP code to extract information? I need a referral system like DropBox has. Has anyone coded it themselves or is it available as open source? https://www.dropbox.com/referrals Please guide me in this regard. Any link or explanation will do the job. Thanks :) Joachim Rohde Google has an API: http://code.google.com/intl/en/apis/contacts/ And Yahoo also has an API: http://developer.yahoo.com/social/contacts/ There exists

How to access a gmail account I own using Gmail API?

[亡魂溺海] 提交于 2019-12-04 17:07:31
问题 I want to run a node script as a cronjob which uses Gmail's API to poll a gmail account I own. I am following these quickstart instructions: I'm stuck on the first step. When requesting credentials for a cron script it tells me that "User data cannot be accessed from a platform without a UI because it requires user interaction for sign-in": The docs are confusing in general, and mention "service accounts," "OAuth," and other things -- I cannot tell which apply to my use-case and which don't.

Swiftmailer config : send mail using gmail

放肆的年华 提交于 2019-12-04 16:42:19
I can send email from my pc using swiftmailer, but mail not sending in server. I'm using swiftmailer 5.0.1. Project details are, A simple php project in netbeans swiftmailer 5.0.1 twig 1.13.1 My code is public function init() { $this->username = 'username@gmail.com'; $this->password = 'password'; $this->host = 'ssl://smtp.gmail.com'; $this->port = 465; $this->from = 'username@gmail.com'; $this->subject = 'Company - contact'; $this->body_part_type = 'text/html'; } public function send_email($from_name_add, $to_add, $fullname, $email, $mobile, $content) { $this->init(); $transport = Swift