API reference
Suppressions
The suppression list holds addresses your company never sends to. Addresses that bounce permanently or whose recipients report an email as spam are added automatically; you can add and remove addresses yourself.
All endpoints need a full-access key whose creator holds the API controls privilege in the console. They can also return the common errors listed in the overview. For how bounces and suppressions work together see Bounces and suppressions.
| Endpoint | Node.js | Python | CLI |
|---|---|---|---|
| GET /suppressions | suppressions.list | suppressions.list | tsmart suppressions list |
| POST /suppressions | suppressions.create | suppressions.create | tsmart suppressions add |
| GET /suppressions/{id_or_email} | suppressions.get | suppressions.get | tsmart suppressions get |
| DELETE /suppressions/{id_or_email} | suppressions.remove | suppressions.remove | tsmart suppressions remove |
The suppression object
| Name | Type | Description |
|---|---|---|
object | string | Always "suppression". |
id | string | Suppression id (UUID). |
email | string | The suppressed address, lowercase. |
reason | string | bounce: added automatically after a permanent bounce. complaint: added automatically after a spam complaint. manual: added by you, in the console or with POST /suppressions. |
email_id | string | null | For bounce and complaint entries, the id of the email that bounced or was reported as spam; otherwise null. |
created_at | string | When the address was added. |
When an email is sent, suppressed recipients are left out and each gets an email.suppressed event. If no
recipient is left, nothing is sent. An address is added automatically when delivery to it fails permanently (a 5.x.x
status from the receiving server); temporary failures never add it. It is also added when its recipient reports an
email as spam and the mailbox provider sends us the complaint (see Spam
complaints).
GET /suppressions
Lists the suppressed addresses, newest first.
Permission: full access; the key's creator needs the API controls privilege.
Query
| Name | Type | Description |
|---|---|---|
limit | integer | 1 to 100, default 20. |
after | string | A suppression id: return older entries. |
before | string | A suppression id: return newer entries. Use either after or before. |
Request
curl https://send.tsmart.ai/suppressions \
-H "Authorization: Bearer $TSMART_API_KEY" Response
{
"object": "list",
"has_more": false,
"data": [
{
"object": "suppression",
"id": "e2a4c6d8-1b3f-4a5c-8e7d-9f0b1c2d3e4f",
"email": "old-address@example.com",
"reason": "bounce",
"email_id": "4ef9a417-02e9-4d39-ad75-9611e0fa6f60",
"created_at": "2026-10-12 09:15:05.882140+00"
},
{
"object": "suppression",
"id": "5b7d9f1a-3c5e-4f7a-9b1d-2e4f6a8c0d1e",
"email": "unsubscribed@example.com",
"reason": "manual",
"email_id": null,
"created_at": "2026-10-11 13:48:30.210554+00"
}
]
} Errors
| Status | Name | When |
|---|---|---|
| 401 | restricted_api_key | A sending-access key. |
| 403 | invalid_permission | The key's creator lacks the API controls privilege. |
| 422 | validation_error | limit out of range, both after and before, or an invalid cursor. |
POST /suppressions
Adds an address to the suppression list: emails to it are skipped until it is removed.
Permission: full access; the key's creator needs the API controls privilege.
Body
| Name | Type | Description |
|---|---|---|
email required | string | A plain email address (no display name), at most 320 characters. Stored in lowercase. |
Request
curl -X POST https://send.tsmart.ai/suppressions \
-H "Authorization: Bearer $TSMART_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "email": "unsubscribed@example.com" }' const { data, error } = await tsmart.suppressions.create({ email: "unsubscribed@example.com" }); client.suppressions.create({"email": "unsubscribed@example.com"}) Response
{
"object": "suppression",
"id": "5b7d9f1a-3c5e-4f7a-9b1d-2e4f6a8c0d1e"
} Adding an address that is already on the list is not an error: the response carries the id of the existing entry, which keeps its reason.
Errors
| Status | Name | When |
|---|---|---|
| 401 | restricted_api_key | A sending-access key. |
| 403 | invalid_permission | The key's creator lacks the API controls privilege. |
| 422 | validation_error | email is missing or not a valid address ("`email` must be a valid email address"). |
GET /suppressions/{id_or_email}
Returns one entry, looked up by its id or by the address.
Permission: full access; the key's creator needs the API controls privilege.
Path
| Name | Type | Description |
|---|---|---|
id_or_email required | string | The suppression id, or the address (URL-encoded; case does not matter). |
Request
curl https://send.tsmart.ai/suppressions/unsubscribed%40example.com \
-H "Authorization: Bearer $TSMART_API_KEY" Response
{
"object": "suppression",
"id": "5b7d9f1a-3c5e-4f7a-9b1d-2e4f6a8c0d1e",
"email": "unsubscribed@example.com",
"reason": "manual",
"email_id": null,
"created_at": "2026-10-11 13:48:30.210554+00"
} Errors
| Status | Name | When |
|---|---|---|
| 401 | restricted_api_key | A sending-access key. |
| 403 | invalid_permission | The key's creator lacks the API controls privilege. |
| 404 | not_found | The id or address is not on your list ("Suppression not found"). |
DELETE /suppressions/{id_or_email}
Removes an entry, so the address can receive email again.
Permission: full access; the key's creator needs the API controls privilege.
Path
| Name | Type | Description |
|---|---|---|
id_or_email required | string | The suppression id, or the address (URL-encoded; case does not matter). |
Request
curl -X DELETE https://send.tsmart.ai/suppressions/unsubscribed%40example.com \
-H "Authorization: Bearer $TSMART_API_KEY" Response
{
"object": "suppression",
"id": "5b7d9f1a-3c5e-4f7a-9b1d-2e4f6a8c0d1e",
"deleted": true
} Errors
| Status | Name | When |
|---|---|---|
| 401 | restricted_api_key | A sending-access key. |
| 403 | invalid_permission | The key's creator lacks the API controls privilege. |
| 404 | not_found | The id or address is not on your list. |