Skip to main content

Method

POST /v1/comms/suppressions

Body Parameters

channel
string
required
Communication channel (see supported values)
value
string
required
Destination (e.g., email address or phone number)
reason
string
Reason (optional)

Headers

Authorization
string
required
Bearer token (e.g. Authorization: Bearer YOUR_API_KEY)
X-Workspace-Id
string
required
Workspace identifier (UUID)
content-type
string
application/json

Request Example

cURL
curl -X POST https://api.voyantcloud.com/v1/comms/suppressions \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "X-Workspace-Id: WORKSPACE_UUID" \
  -H "content-type: application/json" \
  -d '{ "channel": "email", "value": "[email protected]", "reason": "bounce" }'
Node.js
await fetch("https://api.voyantcloud.com/v1/comms/suppressions", {
  method: "POST",
  headers: { Authorization: `Bearer ${process.env.VOYANT_API_KEY}`, "X-Workspace-Id": process.env.WORKSPACE_ID, "content-type": "application/json" },
  body: JSON.stringify({ channel: "email", value: "[email protected]", reason: "bounce" }),
})
Python
import os, requests
requests.post(
  "https://api.voyantcloud.com/v1/comms/suppressions",
  headers={"Authorization": f"Bearer {os.environ['VOYANT_API_KEY']}", "X-Workspace-Id": os.environ["WORKSPACE_ID"], "content-type": "application/json"},
  json={"channel": "email", "value": "[email protected]", "reason": "bounce"},
)

Response

{ "id": "sup_123", "channel": "email", "value": "[email protected]", "reason": "bounce" }