USERS
EVENTS
OBJECTS
PREFERENCE
- Update User Preferences
- Get User Preferences
- Manage Tenant Preferences
- Update Object Preferences
- Get Object Preferences
LISTS
BROADCAST
Manage Tenant Preferences
Get Tenant Default Preference
Manage Tenant Preferences
Get Tenant Default Preference
API to get Tenant categories
GET
/
v1
/
tenant
/
{tenant_id}
/
category
curl --request GET \
--url https://hub.suprsend.com/v1/tenant/{tenant_id}/category/ \
--header 'Authorization: Bearer <token>'
{
"meta": {
"count": 12,
"limit": 10,
"offset": 0
},
"results": [
{
"name": "Status Update Alert",
"category": "status-update-alert",
"description": "Send me updates when account status changes",
"root_category": "transactional",
"default_preference": "opt_in",
"default_mandatory_channels": null,
"visible_to_subscriber": true,
"preference": "opt_in",
"mandatory_channels": null,
"blocked_channels": null
}
]
}
Authorizations
Pass as Bearer <API_KEY>
. Get API Key from SuprSend dashboard Developers -> API Keys section.
Path Parameters
unique identifier of the tenant you want to get default preferences for
Response
200
application/json
200
preference category name
unique preference category slug. You can get it by clicking on category name on SuprSend dashboard -> preference page
root category this sub-category belongs to
Example:
"transactional"
default preference of the category
Available options:
cant_unsubscribe
, opt_in
, opt_out
mandatory channels in case default preference is can't unsubscribe
set it false
to hide a category from user's preference page
Available options:
opt_in
, opt_out
channels blocked in the category from SuprSend dashboard -> tenants page
curl --request GET \
--url https://hub.suprsend.com/v1/tenant/{tenant_id}/category/ \
--header 'Authorization: Bearer <token>'
{
"meta": {
"count": 12,
"limit": 10,
"offset": 0
},
"results": [
{
"name": "Status Update Alert",
"category": "status-update-alert",
"description": "Send me updates when account status changes",
"root_category": "transactional",
"default_preference": "opt_in",
"default_mandatory_channels": null,
"visible_to_subscriber": true,
"preference": "opt_in",
"mandatory_channels": null,
"blocked_channels": null
}
]
}