Hi,
I am using an Email tool to send emails upon certain conditions. I am able to achieve that.
However, I want to maintain a daily log of recipients that my workflow is sending mail to!!
E.g. if my workflow sends 3 emails to abc@gmail.com, xyz@gmail.com, asd@gmail.com, then I want to maintain a csv/Excel file with following structure :-
Date Email send to
01/04/2020 abc@gmail.com
01/04/2020 xyz@gmail.com
01/04/2020 asd@gmail.com
How do I achieve this? @patrick_digan @MarqueeCrew
Thanks in advance.
Regards,
Shreyansh Rathod
The answer to this question is pretty much that it depends on the structure of your data going into the email tool, so I think we need to know that before we can truly answer your question.
For example, if your recipients are physically listed in the email tool, we'll have to approach solving this problem in a very different way than if they are referenced dynamically from a field.
In the latter scenario you would do some basic transformation to bring the data into the structure you require, as shown below and in the attached example.
The comma seperated list is a way of sending the same email to different recipients so we must then split these up using a text to columns tool, then it's a case of using a formula tool to generate todays date.
Ben
Hi @BenMoss ,
Thank you for sharing your expertise!!
I have already implemented the transformation logic that you have mentioned (latter).
However, I believe it is fundamentally flawed because it will add all email id's in the email column irrespective of the fact that the mail was sent or not.
If my workflow (Email Tool) was not able to send email to any one/multiple recipients, it will still log those email id's into the output.
E.g, In the above scenario, if Email Tool could not send an email to 'abc@gmail.com' for xyz reasons (authentication, invalid ID, etc), I don't want that email id in my log.
So, essentially, I want to maintain a log of those emails which were successfully sent out by the Email Tool.
I hope I am able to explain my thought process.
Thank you in advance.
Regards,
Shreyansh Rathod
Yes that's a fair response, this was something I was thinking about; when the email doesn't send does the Email tool produce a red (i.e. fatal) error, or does it just give a soft warning in the results window?
If it's the former, we should be able to build in some logic to our current workflow, if it's the latter then we may need to make use of the 'CReW macros' in order to execute the email workflow and then run a second workflow which reads the log of the first workflow, and parses out any information regarding emails not sending.
Ben
Well, the Email Tool neither generates an error nor does it give a warning.
I tested with 4 dummy emails via Text Input.
Strangely, the result window displays that the Messages have been sent to all 4 emails.
However, since the sending email id is mine, I got 4 mails in my inbox stating that the email address could not be found!!
Also, even if everything was going alright, the log file does not capture the email id's, it simply states : 'Tool id () : Messages sent - 4'.
Attaching the screenshots for your reference
a) Dummy emails for testing
b) Result window despite fake dummy emails
c) log file capture
Regards,
Shreyansh Rathod
I guess in this case the emails are sent, so I would agree with Alteryx on this front, the messages were sent you just got a bounce back. Unless you create a way of monitoring your inbox (which is possible with Alteryx, check out some macros on the Alteryx Gallery), then I'm not sure what you can do, nor expect Alteryx to do in this case.
Sometimes the tool will fail to send emails within Alteryx, say for example, you have no internet connection, or something like that, you'll be able to catch these cases with the logic shared above, in this scenario I guess either all the emails are sent (unless the internet connection drops mid-way through sending them), or no emails are sent, in which case you can just remove all records from your workflow.
You can break your piece into two workflows...
1. Send emails and generate table of 'emails I think I have sent'
2. workflow that gets information from logs to find out if the tool did send all/no emails, pull records out if so, also monitors inbox to check if you have any bounce backs, if so pulls those specific records out of the input generated in step 1.
Ben
Hi @BenMoss ,
Thank you for the direction. Good suggestion on the internet connectivity failure.
For the logging, I am still looking out for it!!
If it's convenient, can you share the link for the macros that you mentioned on monitoring the Inbox.
That would be helpful.
Thanks,
Shreyansh Rathod
User | Count |
---|---|
18 | |
14 | |
13 | |
9 | |
8 |