In this article, we will go through the steps that will need to be taken to achieve the following scenario: when a tag is applied to a user in ActiveCampaign, they will be granted access to one of your courses.
When the same tag is removed, the user will lose their permission to access the course.
This scenario can now be achieved by connecting automations created in both Thrive Automator and ActiveCampaign using webhooks.
To break this down, the ActiveCampaign automation will:
start when a tag is added to a user;
send the user data over to Thrive Automator through a webhook;
And the Thrive Automator automation will:
receive the user data from ActiveCampaign;
check whether the user exists on our site and:
if the user exists, meaning that the person who has been assigned the tag in ActiveCampaign already has an account on our site, they will be granted access to the course in the next step of the automation;
if the user does not exist, an account will be created and they will be granted access to the course in the next step of the automation;
The first part of this article will show you how to create the Thrive Automator and ActiveCampaign automations that will enrol users in a course when the tag has been assigned to them in ActiveCampaign, and the second part will show you how to create similar automations that will revoke their access.
Enrolling users in a course
Note: As we will have to interconnect the two automations (the Thrive Automator one & the ActiveCampaign one), we will have to work in both automations at the same time.
The ActiveCampaign Automation
We'll start by creating an automation in ActiveCampaign which will use a "Tag is added" start trigger.
Access your ActiveCampaign account and go to the "Automations" section of the left sidebar:
Then, click on "Create an automation" from the top right corner of the automations dashboard:
A pop-up opens, and you can choose the "Start from scratch" option":
Choose the start trigger - "Tag is added"
Once the canvas opens, you will have to choose the start trigger for the automation. In this case, I will choose the "Tag is added" start trigger:
And next, a pop-up will open and we'll have to choose which tag should be applied:
Note: Make sure the tag has been added to ActiveCampaign from the "Contacts" -> "Manage Tags" section:
Choose the action - "Webhook"
Right away, a pop-up opens and you will be asked to choose the action to happen right after the start trigger event occurs (the tag is added). Here, go to the "Conditions and Workflows" section of the pop-up and we will choose the "Webhook" action:
As you do this, you will be asked to add the webhook URL to post to:
Even though we haven't finished setting up the ActiveCampaign automation, we need to head over to Thrive Automator and start with our automation from there as well, as we will use the incoming webhook URL to add it into this field.
The Thrive Automator Automation
Even though we haven't finished setting up the ActiveCampaign automation, we need to head over to Thrive Automator and start with our automation from there as well, as we will use the incoming webhook URL in ActiveCampaign.
To begin, access your Thrive Automator dashboard:
This opens the Thrive Automator dashboard, with a list of all of your previously created automations. Click on the "Add new" button from the top right side of the dashboard to start creating a new automation:
Choose the start trigger - "Incoming Webhook"
We are going to start by naming the automation and clicking on the start trigger dropdown:
We will choose the "Incoming Webhook" start trigger from this list:
Right away, we will be granted the Webhook URL:
An important step here, however, is to make sure the data that will be received by the webhook will be correctly set up.
This means that we will have to make sure that the correct fields will be mapped in the "Incoming data" section.
For this, we can do a short test and use the "Listen" mode from Thrive Automator to populate the Incoming data key-value pairs.
Using the Listen Option
Here's how to do that:
add the Incoming Webhook URL in the ActiveCampaign Webhook URL pop-up:
make sure that the ActiveCampaign automation is set to "Active":
open one of your contacts from ActiveCampaign and go to the "Tags" section:
go back to the Thrive Automator automation and click on "Listen":
The webhook will start listening, to populate the fields:
go back to the ActiveCampaign contact and assign the tag (that we've set up in the automation) to it:
This will auto-populate the incoming data fields in a matter of seconds, as seen in this animation:
It is then up to you which fields you want to keep and which ones you should remove:
And also, don't forget to check if the correct field type has been assigned to your values, to make sure that the mapping will be performed correctly.
For example, in my case, the type of field has to be changed for the "Email" as seen below:
Additionally, you can also set up security settings, in the form of incoming data key-value pairs:
The security settings represent an additional layer of security.
If you add key-value pairs here, when the Incoming Webhook does not receive these values in the header, it will be rejected and the automation will not fire.
Once the fields have been populated, we can save the "Incoming Webhook" start trigger and continue with our automation:
Choose the next action - "Find or create user"
To continue setting up the automation, click on the plus sign:
And as a next action, we will choose the "Find or create user" one:
This way we can ensure that, regardless of the situation of the person that has been assigned the tag (whether they have an account created on our site or not), the automation will either find the user and grant them access, or they will create a new user.
We will have to choose the role to be assigned to the new user, and you can also map out the first and last name. Click on "Done" to save the action.
Choose the next action - "Grant access to product"
It is time to choose the next and last action here. This should be the "Grant access to course" action, that will become available once you've added the "Find or create user" action:
All there's left to do here is choose the Thrive Apprentice product that the users will get access to:
Click on "Done" when finished:
The automation is now ready and you can publish it and click on "Save and finish".
As a result, with both these automations published, each time a contact from your ActiveCampaign account is provided with the tag of your choice, they are granted access to the Thrive Apprentice product.
Similarly, you can do the same and create two more automations, one in Thrive Automator and one in ActiveCampaign, with the help of which the user will have their access revoked once the tag has been removed from their contact in ActiveCampaign.
In this second part of the article, I will show you how to do that, as well, but we will not go into that many details, as the setups are very similar.
The only differences are that the start trigger from the ActiveCampaign automation will be the "Tag is removed" one, and the Thrive Automator automation will have the "Remove access from course" action as the last one.
Removing users from a course
The ActiveCampaign Automation
I will start with the ActiveCampaign automation, that will look like this:
Start trigger - Tag is removed
Action - Webhook
The Thrive Automator Automation
In Thrive Automator, I will create a new automation that looks like this:
Start trigger - Incoming Webhook
Action 1 - Find or create user
Action 2 - Remove access from product
Note: To auto-populate the Incoming Data fields of the Incoming Webhook trigger, you can use the "Listen" feature and remove a tag from one of your contacts, as shown here:
With these four automations, we have achieved this very convenient situation:
a tag is assigned to a contact -> they are granted to one of our Thrive Apprentice products;
the same tag is removed -> they are revoked their access;
And, of course, the tag does not have to be manually added to the customer, as you can create and customize the way the tag is assigned to a contact (for example: when they fill in a form, etc.)
I really hope this article was useful. If you need more information or examples of such automations, make sure to check out the Thrive Automator knowledge base section.
Don't forget to leave a smile below 😄