Send SMTP Mail Message - Using Gmail

Hi all!

I am trying to send an email using the “Send SMTP Mail Message” activity and I am having trouble finding the right configs for it. The official Gmail’s configurations can be obtained here:
POP: Read Gmail messages on other email clients using POP - Gmail Help
IMAP: Check Gmail through other email platforms - Gmail Help

First of all, I tried to configure my own Outlook application to access Gmail through POP or IMAP, and failed in both cases. The configurations for SMTP were done using SSL or TLS, with the right ports, according to Gmail’s helps above.
(I think the failure may be due to my company’s network. But still, I am able to access Gmail through the website).

So, I kindly ask you for some enlightenment about this.
Can someone send an email through Gmail account using this activity, and post here the configs?

Here is one of my many config attempts:

Thank you so much,

3 Likes

You Had already given permission on that account to connect by imap?

Look in definitions / forwarding and imap/pop / imap access, if it is enabled.

1 Like

Hi @Filipe_Ferreira !

Already done the POP/IMAP settings in Gmail.
(You can check that I posted the links for these configs above).

Also, a colleague of mine sent me this UIPath article:

I have done this, but it still not working. I remain searching for the cause of this issue.

Regards

1 Like

To conclude this thread: the problem I was facing back then was related to my corporate network.
(The network blocks any mail packages that are not originated from an Outlook or Lotus client).

If you configure UiPath accordingly (see the tutorial) it can send emails through any mail server.

2 Likes

I’m facing the same issue frequently within the corporate network. I don’t know what’s wrong. Please share the solution if you have had done it ever.

Error :

Main has thrown an exception

Source: Send SMTP Mail Message

Message: Unable to read data from the transport connection: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

Exception Type: IOException

System.IO.IOException: Unable to read data from the transport connection: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. —> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond
at System.Net.Sockets.Socket.Receive(Byte buffer, Int32 offset, Int32 size, SocketFlags socketFlags)
at System.Net.Sockets.NetworkStream.Read(Byte buffer, Int32 offset, Int32 size)
— End of inner exception stack trace —
at UiPath.Mail.Activities.SendMailActivity.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.System.Activities.IAsyncCodeActivity.FinishExecution(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

Hi
Below the tutorial

5 Likes

Nice tutorial! I’ve made the mail send flow using gmail.

1 Like

HI , i am getting below error while sending email , using correct user id and password.

image

alternative activity to send email with gmail , try this activity integration for gmail

1 Like