reply message gmail

how can I respond to a message in gmail using smtp, but do not go as a new message but respond within the message read through IMAP?

Check this. This was done for Outlook. You can do something similar for SMTP.

Thanks,
Rammohan B.

Ok, thanks for your answer I will try to see what happens :slight_smile: :slightly_smiling_face:

what happends, it was successful ?

Well, it did not work for me, I tried to do with the forward but it did not mean the expected results. :no_mouth:

Hai @Rammohan91, can you once explain the “Assign Activity” in the given ‘replymail’ xaml and attached the screenshot.!
replymail|690x387

Thanks,
Sushmitha.

Hi, @Rammohan91

This workflow wont attach existing body of the mail on which we want to reply , this will send mail as new outlook mail.
Is there any way to also get body of the original email on which we want to reply.

Regards,
Sayali

Any one who is still reading thread, may look for solution here:

1 Like

At present, we do not have inbuilt UiPath [activities]that allow us to reply to a specific email on Gmail. The existing ‘Reply All’ functionality is limited to specific emails within our UiPath integration services only. Furthermore, our Automation Suite or standalone UiPath does not currently offer integration solutions for this requirement.

However, I have developed an App Script as a workaround. This script is designed to reply to a specific email based on the email subject. It identifies the most recent email thread and sends a ‘Reply All’ to that thread. I have attached sample email as well.

function replayTo_SpecificEmail() {

// Define the subject you are looking for. This will fetch the email details based on the Subject you are passing.
var subject = “Hello from Reply to Specifi Email Latest”;

// Search for threads with the specific subject
var threads = GmailApp.search(‘subject:’ + subject);

Logger.log("Number of threads: " + threads.length);

// Initialize a counter for the messages
var messageCount = 0;

// Loop through each thread
for (var i = 0; i < threads.length; i++) {
// Add the number of messages in the current thread to the counter
messageCount += threads[i].getMessageCount();
}

// Log the number of messages
Logger.log("Number of messages: " + messageCount);

var lastMesssage = messageCount-1;
Logger.log(“Last Message Count :”+lastMesssage)

// Loop through each thread
for (var i = 0; i < threads.length; i++) {
// Get the first message in the thread
var message = threads[i].getMessages()[lastMesssage];

// Reply to the message
message.replyAll(“Email Body”);
}

}