Suppress and delete user data in accordance with your user suppression policies.
Available Plans
enterprise
7 minute read
This guide explains how to use the User Suppression API to suppress and delete user data in accordance with the compliance and user suppression policies of your organization.
Overview
With RudderStack’s User Suppression API, you can create regulations to suspend data collection and delete data for specific users. You can apply these regulations across multiple destination integrations simultaneously, simplifying the process of implementing compliance requests.
With these APIs, you can:
Add a suppression regulation to drop user events at the source. These events will not be available for debugging, replay, or forwarded to destinations.
The User Suppression API is a part of RudderStack’s Data Governance toolkit that ensures the quality and integrity of your data in a secure and compliant manner.
How is the User Suppression API helpful?
You can use the User Suppression API to comply with data regulation statutes and users’ privacy choices by:
Suppressing incoming source data for a user or list of users.
Deleting the collected user data in a given downstream destination or across multiple destinations.
For example, if a user updates their preferences to opt-out of being tracked, you can implement a regulation in the User Suppression API that stops RudderStack from collecting their data at the source, and ensuring no data is sent to downstream destinations. Also, if the user requests to be forgotten, you can delete their data from multiple downstream destinations like Amplitude and Braze with one API call.
Authorization
The User Suppression API uses Bearer Authentication in the format Authorization: Bearer <SERVICE_ACCESS_TOKEN>.
For production use cases, RudderStack recommends using a Service Access Token instead of Personal Access Token.
Base URL
Use the base URL for your API requests depending on your region:
https://api.rudderstack.com
https://api.eu.rudderstack.com
Specify source and destination IDs in your regulation
To name specific sources for your Suppress regulation, or specific destinations for your Suppress with Delete regulation, you will first need to obtain the respective source and destination IDs.
Retrieve source ID
You can review the source ID of a particular source from your RudderStack dashboard, as shown:
Alternatively, you can retrieve the source ID by using the /v2/sources endpoint of the API:
Add a new user suppression regulation to suppress a given user’s data at the source.
RudderStack processes most suppression requests within 24 hours. However, in some cases, it may take up to 30 days depending on the number of requests in the queue for your workspace.
POST
/v2/regulations
Request body:
See Request body for details on the request parameters.
A successful request returns a 201 response status.
Suppression across multiple sources
You can leverage the User Suppression API to suppress all incoming data for a given user. RudderStack drops the events for that user at the source of collection. Suppression applies across all sources, however you can also specify the sources you want to suppress by specifying the source IDs in the request body.
You can delete a user for these destinations by specifying the userId in the event. Except for Redis and S3 destinations, you can also specify a custom identifier (optional) in the event along with the userId.
The RudderStack team is actively working on adding more destinations supported for the Deletion regulation. You can contact the team if you need a destination that is not yet supported.
Deletion across multiple destinations
When a user requests that their data be deleted, you can leverage the User Suppression API to delete user data across multiple downstream destinations.
The User Suppression API can delete data only for destinations connected to RudderStack in cloud mode.
Limitations
Before using the Suppression with Delete regulation, note that:
While RudderStack forwards the deletion request, it does not guarantee deletion within a 30-day window. You will need to check with the respective destination provider if the request is fulfilled.
The requests made to the User Suppression API are rate-limited. See Rate limits for more details.
Request body
regulationType
required
string
Defines the user suppression type. Can be one of suppress, which suppresses incoming user data or suppress_with_delete which suppresses and deletes events from your specified destinations.
Possible Values: suppress, suppress_with_delete
sourceIds
optional
array
Specify only sourceIds with the suppress regulation. If no sourceIds are specified, RudderStack will suppress data from all sources in the workspace associated with your access token.
destinationIds
optional
array
Specify only destinationIds with the suppress_with_delete regulation. Otherwise, RudderStack throws an error.
users
required
array
An array of user objects identifying users to be suppressed. The userId field is mandatory for all users. You can pass additional custom identifiers such as email in the users object.
Specify either sourceIds or destinationIds in your request body — do not specify both.
A successful response returns a 204 No Content status.
Rate limits
Requests to the User Suppression API are rate-limited:
Type
Limit (tokens per hour)
Suppression
4,000
Deletion
200,000
Note that:
In case of user suppression, 1 user is equivalent to 1 token.
For deletion, RudderStack calculates the number of tokens by multiplying the number of users with the number of destinations. For example, if there are m users with n destinations, the total number of tokens would be m * n.
This site uses cookies to improve your experience while you navigate through the website. Out of
these
cookies, the cookies that are categorized as necessary are stored on your browser as they are as
essential
for the working of basic functionalities of the website. We also use third-party cookies that
help
us
analyze and understand how you use this website. These cookies will be stored in your browser
only
with
your
consent. You also have the option to opt-out of these cookies. But opting out of some of these
cookies
may
have an effect on your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This
category only includes cookies that ensures basic functionalities and security
features of the website. These cookies do not store any personal information.
This site uses cookies to improve your experience. If you want to
learn more about cookies and why we use them, visit our cookie
policy. We'll assume you're ok with this, but you can opt-out if you wish Cookie Settings.