From c5bb37e0d513ca3ed97c11192318599c8a8ca1ae Mon Sep 17 00:00:00 2001 From: KofaxRPA <47416964+KofaxRPA@users.noreply.github.com> Date: Thu, 13 Jun 2019 17:13:54 +0200 Subject: [PATCH] Send Email via Exchange WebServices --- EWS_SendEMail.robot | 485 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 485 insertions(+) create mode 100644 EWS_SendEMail.robot diff --git a/EWS_SendEMail.robot b/EWS_SendEMail.robot new file mode 100644 index 0000000..c690970 --- /dev/null +++ b/EWS_SendEMail.robot @@ -0,0 +1,485 @@ + + + + + 10.4.0.0 + 10.5.0.0 + + + + + + + + + + + + + + + + + WEBKIT + + + + LOG + + + 13 + + + + + credentials + + + Credentials + + + + mail.kofax.com + true + kapow.robot.plugin.common.domain.StringAttributeType + + + david.wright@kofax.com + true + + + + + + + out + + + + + + SOAP_Body + + + 151 + + + + <?xml version="1.0" encoding="UTF-8"?><soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> + <soap:Header> + <t:RequestServerVersion Version="Exchange2010_SP2"/> + </soap:Header> + <soap:Body> + <m:CreateItem MessageDisposition="SendAndSaveCopy"> + <m:SavedItemFolderId> + <t:DistinguishedFolderId Id="sentitems"/> + </m:SavedItemFolderId> + <m:Items> + <t:Message> + <t:Subject>****SUBJECT****</t:Subject> + <t:Body BodyType="HTML">****BODY****</t:Body> + <t:ToRecipients> + <t:Mailbox> + <t:EmailAddress>****SENDER*****</t:EmailAddress> + </t:Mailbox> + </t:ToRecipients> + </t:Message> + </m:Items> + </m:CreateItem> + </soap:Body> +</soap:Envelope> + true + kapow.robot.plugin.common.domain.XML2AttributeType + + + + + + OutboundEmail + + + Email + + + + abc.txt + true + + + + <html> +<body> +Dear $FirstName$,<br/> +Hi from me +</body> +</html> + true + kapow.robot.plugin.common.domain.HTMLCodeAttributeType + + + Email subject + true + + + + david.wright@kofax.com + true + + + + + + + ExecutionMessage + + + 12 + + + + + FirstName + + + + + Tom + true + + + + + + + + + WEBKIT + + + STANDARD + + false + 10000 + + true + 2048 + + + + + DIRECT + + + + + + + Open EWS Message + + + SOAP_Body + + + + + + + + + + name + + + + To + + + + + OutboundEmail.To + + + + + + + .*.t:emailaddress + + + + + + + + + + name + + + + Subject + + + + + OutboundEmail.Subject + + + + + + + .*.t:subject + + + + + + + + + + name + + + + Body + + + + + + + OutboundEmail.Message + + + + + replaceText(INPUT,"$FirstName$",FirstName) + + + &rsquo; + &#8217; + + + &bull; + + + + &copy; + © + + + + + + + + .*.t:body + + + + + + + + + + + + + + EWS - Send Email + + + + https://mail2.kofax.com/ews/exchange.asmx + + + FindFolders + + + + SOAP_Body + + + SOAP 1.2 + + + + + + credentials.username + + + + + credentials.password + + + + + + + + + Content-Type: text/xml; charset=utf-8 + + + + + + + out + + true + + + ignoreLoadErrors + responseHeadersAttributeName + headerProvider + credentialsProvider + + + + + + + + + + + name + + + + View as XML + + + + + + + + + + + + Email Sent? + + + .*ResponseClass="Success".* + + true + + + + + .*.m:createitemresponsemessage + + + + + false + false + + + + + + + + name + + + + success log + + + OutboundEmail.To + ";success" + + + + + + + + + + + + + + + fail log + + + OutboundEmail.To + ";fail" + + + + + + + + + + name + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +