How to exclude respondents based on their past activity
This guide shows you how to configure a target group to exclude respondents based on their past interactions with previous surveys you've fielded. This will exclude Completed or In-client survey respondents who has taken the survey related to the target groups or projects you provide.
To learn about respondent activity exclusions and respondent exclusions in general, see respondent exclusions in the deep dives section.
Prerequisites:
- You have an existing target group.
- You have a list of projects and target group ids that have fielded respondents whom you'd like to exclude from your current survey.
Step 1: Provide the IDs of Projects and Target Groups you want to exclude
Call Set respondent activity exclusions endpoint with your IDs to exclude. The exclusion list in your request fully replaces the current list of IDs. Always include every project and target group you want to exclude in each request, not just additions:
Think of each request as setting the complete list, not appending to it. If you omit an existing ID, it will be removed.
{
"respondent_activity_exclusions": [
{
"type": "project",
"id": "01HF6ZBAYT1M9N8EJX2Z3K1P7V"
},
{
"type": "target-group",
"id": "01HF6ZDW9J3X7H5T4R9C6M1Q2A"
}
]
}
If the target group is already live, updating its respondent activity exclusions will only affect future respondent traffic. Any respondents who have already entered or completed the target group under the previous exclusion settings cannot be retroactively changed. Please review your changes carefully before applying them to a live target group.
To remove all respondent exclusions from a target group, send an empty array:
{
"respondent_activity_exclusions": []
}
Step 2: Review the response
Use the Retrieve respondent activity exclusions endpoint to get the full list of projects and target groups currently configured for your source target group.
The response will look very similar to the request, and will include an a duration field per element in the list.
{
"respondent_activity_exclusions": [
{
"type": "target-group",
"id": "01KH2714RHRTGCGQV47FHHY8S8",
"duration": "P90D"
}
]
}
There is a default 90 day duration for how long respondents can be excluded. After an ID expires respondents will no longer be excluded. Currently, duration is not configurable.
Step 3: Update respondent exclusions (optional)
The process to update respondent activity exclusions is the same as setting the values shown in step one.
Troubleshooting
HTTP 400 Bad Request: Double-check your list of IDs to ensure they are valid and your project and target group you are actively manipulating isn't in the list.- Ensure all included target groups and projects are included in the array on every update call. Once saved the previous list of IDs are deleted.
401 Unauthorized: Your token is either missing, invalid, or expired.403 Forbidden: You don't have the necessary permissions to perform this action.