Skip to main content
POST
Create / Update Tenants

Authorizations

Authorization
string
header
required

Pass as Bearer <API_KEY>. Get API Key from SuprSend dashboard Developers -> API Keys section.

Path Parameters

tenant_id
string
required

Tenant identifier to create or update. Max 64 chars; allowed characters [a-z0-9_.-].

Maximum string length: 64
Pattern: ^[a-z0-9_.-]+$

Body

application/json
name
string
default:Awesome Tenant
required

Tenant display name. Replaces the legacy tenant_name field; both are accepted.

tenant_name
string

Will be deprecated in future. Use name instead.

parent_id
string | null

ID of the parent tenant if you want to add this tenant as a sub-tenant. Skip this field, or pass null or "" to create the tenant as a root. Setting it on an existing tenant re-parents it or leave it null to delink existing parent. Must reference an existing tenant. See Sub-tenants.

Example:

"acme-corp"

blocked_channels
string[] | null

Channels turned off for this tenant. Notifications on these channels won't be sent to any user of the tenant — including on root categories (which users normally can't unsubscribe from) — and users can't override this. If sub-tenants are used, a block set here also applies to every sub-tenant below and can't be removed lower down. Allowed: email, sms, whatsapp, androidpush, iospush, webpush, slack, ms_teams, inbox.

Example:

Tenant logo URL.

primary_color
string
default:#ff0000

Primary brand color, used in the tenant's email header, buttons, and footer. If left empty on create, it's copied from the default tenant.

secondary_color
string

Secondary brand color. Not part of the default tenant component but can be used in templates as {{$tenant.secondary_color}}. If left empty on create, it's copied from the default tenant.

Example:

"#00ff00"

tertiary_color
string

Tertiary brand color. Not part of the default tenant component but can be used in templates as {{$tenant.tertiary_color}}. If left empty on create, it's copied from the default tenant.

Example:

"#0000ff"

preference_page_url
string

URL of your product's preference page.

Tenant's social media URLs. Pass "" to clear a link (not null).

properties
object

Custom tenant properties. Merged per top-level key on update — keys not in the payload are kept as-is.

Response

201 - Created

Tenant object returned. Fields hold the tenant's own local values — values not set on this tenant come back as null (or as empty objects/arrays). For flat tenants (no sub-tenants), unset fields stay unresolved and the tenant simply has no value for them. For sub-tenants, unset fields still return null here, but are resolved from the closest ancestor that has a value set at trigger time.