Skip to main content

How SuprSend identifies a User

SuprSend identifies users with immutable distinct_id. It’s best to map the same identifier in your DB with distinct_id in SuprSend. Do not use identifiers that can be changed like email or phone number. You can view synced users by searching distinct_id on Users page.

Create User

To create a new user or to update an existing user, you’ll have to fetch user instance. Call supr_client.user.get_instance to instantiate user object.

Edit User

To Edit user, you need to first fetch user instance, call all the update methods and save changes using user.save() method.
Here’s a list of all edit methods:
Use user.add_* method to add user channels.
Use user.remove_* method(s) to remove user channels. These methods will detach provided value from the user profile in specified channel.
This method will delete/unset all values in specified channel for user (ex: remove all emails attached to user).
If you want to send notification in user’s preferred language, you can set it by passing language code in this method. This is useful especially for the applications which offer vernacular or multi-lingual support.
You can set timezone of user using this method. Value for timezone must be from amongst the IANA timezones.
Set is used to set the custom user property or properties. The given key and value will be assigned to the user, overwriting an existing property with the same key if present.
Works just like user.set, except it will not override already existing property values. This is useful for properties like first_login_date.
This method will append a value to the list for a given property.
This method will remove a value from the list for a given property.
Add the given number to an existing property on the user. If the user does not already have the associated property, the amount will be added to zero. To reduce a property, provide a negative number for the value.
This will remove a property permanently from user properties.
After calling add*/remove*/unset methods, don’t forget to call the user.save() request. the changes will be sent to SuprSend only after calling this method.

Bulk Update Users

Bulk operations use UPSERT to create or update users. There isn’t any limit on number-of-records that can be added to bulk_users instance. Use .append() on bulk_users instance to add however-many-records to call in bulk.
Rate limit: 1000 requests per second. The SDK automatically chunks requests based on the size of the payload. So, you don’t need to worry about these rate limits while using bulk operations.

Get user details

Delete user

Get list of objects subscribed by user

You can pass optional query parameters - limit,before,after.

Get lists subscribed by user

You can pass optional query parameters - limit,before,after.