
Is there a way to automatically resolve an unresolved email address, either programmatically or via a workflow/power automate?
For example, if you enter an unresolved email address into the To/CC/BCC field on an email and click save, it automatically creates a new Contact for that email address?
Looking for a way to avoid having to manually resolve email addresses.
Hi Inksrm,
You can create a flow to achieve it, the following is the overview of the flow. (In my example, the field that insert unresolvesd email address is ‘to’ field)
Here are detailed steps of the flow.
1.Go Power Automate(https://us.flow.microsoft.com/en-us/ ) to create an Automated flow.
2.Create the Trigger event – in this case I have set the trigger to fire when an Email record is created.
3.Add ‘compose’ step, it can get ‘to’ field value of the email created.
4.Add ‘compose’ step, it can remove ‘;’ symbol from the value.
replace(outputs('Get_To_field_value'),';','')
5.Add ‘List Records’ step, retrieve contacts records to check that the address inputed in the created email exists in the contact records.
6.Add ‘compose’ step, get contact counts of the previous step.
length(body('List_records')?['value'])
7.Add ‘condition’ step, if count is 0, go ‘Yes’ branch.
In ‘Yes’ branch, do this steps:
(1) Add ‘compose’ step, intercept the string before the @ symbol in the address field as contact name, also you can set contact name with the value you need.
split(outputs('Remove_semicolon'),'@')[0]
(2) Add ‘Create a new record’ step, create a new contact with the name and the email address.
8.Save and test the flow.
Regards,
Leah Ju
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.