*** NOTE: ALL INFORMATION IS ACCURATE AT DATE OF PUBLISHING ***
If you are responsible for communications sent to your customers by your organisation, making sure people’s communication preferences are adhered to is likely top of mind. At the bottom of every Forms Pro survey email that goes out is an Unsubscribe link. This allows the recipient to stop receiving emails requesting them to complete a survey. What happens when it’s clicked on? Let’s find out!
First, they are taken to a browser which asks them to confirm if they wish to unsubscribe and stop receiving emails. They then need to click again to unsubscribe.
This will then show that they have successfully unsubscribed. They have the option to subscribe again if they wish.
In CDS a new Unsubscribe record is created for the email address (not the Contact/Lead). If the same person is sent a survey invite (either directly from Forms Pro or via a Microsoft Flow) the email will not be sent and the Survey Invite activity status will be set to Unsubscribed. However, we can improve on this and make it clearer to users of a CDS App (Dynamics 365 Customer Engagement or otherwise) what the situation is.
First on the Contact entity we add a new two option field similar to the other Contact Preferences fields. I’ve called it Survey Invites and set the values to Allow and Do Not Allow to fit in with the other fields in this section.
Now let’s look at the Flow. We trigger it when a Survey Invite record is created. Then we add a condition and check to see if the Survey Invite Status is Unsubscribed. This value is 647390001.
If it is, we will do a few things to help update that Survey Invite record. Let’s get the name of the survey that was sent. We can do that with a Get record step and get the Forms Pro Survey using the Survey id field from the Survey Invite trigger. Next we will add an Update record step and update the Survey Invite record using the activity id from the Survey Invite trigger. You can put what makes sense for you but in this example I have updated the subject to show UNSUBSCRIBED – INVITE NOT SENT – and then added the name of the survey. I’ve also set the Activity Status Value to Canceled so we know it didn’t ever go out.
Now let’s update the Contact record so we can indicate they have opted out of surveys. Use a List records action from the CDS connector. We are going to use the activityparties entity. However, you can’t find that in the Entity name dropdown. Instead, scroll to the bottom and click on enter custom value, then type it in like you see below. The filter query will be _activityid_value eq and then the Activity id from the original trigger step. The survey invite will only be linked to one record which should be your contact.
Now we will use a Get record step and get the Contact using the Party value from the list activity parties step above. Then we use an update record step and update the Contact record using the Contact Id from the get Contact step. Set the Survey Invite field you added to the Contact and set it to Do Not Allow (or Yes depending on how you set up your field). This will now show that the Contact has opted out of getting surveys.
Ok, so that’s taken care of if someone has unsubscribed… but what if they resubscribe? The Unsubscribe record is just deleted. So although any new survey invites will be sent, the Contact record will still have Survey Invites set to Do Not Allow. So our No condition will take care of that. We will do the same thing again and do a Get Activity parties action, then a Get Contact action using the Party value.
Our next step is to add a condition and check to see if the Survey Invites field is set to true – meaning it’s been set to Do Not Allow. If yes, we will update the Contact record and change it back to Allow. If no, we won’t do anything.
So now we get a nice looking survey invite when someone has unsubscribed. It’s clear and obvious to see what has happened.
This then shows up on a timeline, so again it is clear and obvious what happened with this survey invite.
And finally, we can see the Contact has their preferences updated accordingly!
Want to just watch how to do this? Check out the video below:
Check out the latest post:
Tasks & Phone Calls In A Real Time Marketing Journey
This is just 1 of 385 articles. You can browse through all of them by going to the main blog page, or navigate through different categories to find more content you are interested in. You can also subscribe and get new blog posts emailed to you directly.
9 thoughts on “Managing Survey Unsubscribes In Forms Pro”
Great Job as always…very informative and helpful. Also, your inclusion of little tweaks (like the ability to access unlisted entities like ‘activityparties’ by entering a custom value) is very helpful to the Flow community. Thanks so much!
Thanks Jim! I appreciate the feedback. That is part of the fun of figuring this all out is learning more about FLOW.
Hi Megan ,
we would like to check if the contact has unsubscribed and then decide whether to send survey or not, is that possible.
Hi Manish. If you are setting a field on a Contact record (using the method I outlined in the post), then when you send out your survey invites you could use Power Automate, and have that be one of the checks before the invitation is created and sent.
Hi Megan, Thanks for clarifying on this. On the post related to this as you mentioned that unsubscribe works for the next survey invite that is being created and it does the work internally to send or not send the invite again , so basically we would like to know if on unsubscribe is there any way to update contact Survey Invite field to No and then later on in flow check if the contact has Survey Invite to Yes then send survey otherwise stop there.
Hi Manish, you could follow the flow outlined in this post, but change the trigger to use the Common Data Service (current environment) connector, and run when the status of the Survey Invitation has changed. That way it would trigger if someone unsubscribed at any time from a specific invitation.
Unfortunately it does not change when someone clicks on unsubscribe link and it does show as unsubscribed on the next survey invite, correct me If I am wrong here.
Ah yes, you are correct in terms of the invite. So you would need to use the Unsubscribe record when it is first created, then adjust the Contact record to change the custom field to indicate they had unsubscribed. Then use THAT field in our flow in Power Automate as a check when figuring out if a new survey invitation should be created and sent to them in the future.
Comments are closed for this post.