Skip to content

API reference/suppressions

Remove addresses from the suppression list

DELETE/api/v1/email/suppressions

authentication
Secret API key as a bearer token
billing
Free.

Removes up to 1,000 addresses per request by the address itself, for a caller that knows the address but not the id it was filed under. Each value is normalized the way the list stores it first, so [email protected] removes the entry filed as [email protected].

The answer names every address it was given, spelled the way you sent it: removed are the ones that were on the list and no longer are, not_found the ones that were not on it — including an address that does not parse, and one that is on another account's list. Two spellings of one mailbox both count as removed.

The cap is 1,000 rather than the import's 10,000 because the answer names every value back: a request over the cap is a 422 and removes nothing. Removing an entry means the address is verified fresh the next time a list, bulk or monitor run meets it.

Request body

field type description
valuesrequiredstring[]1 to 1,000 addresses, in any spelling of each.

Example request

curl -X DELETE https://spaw.co/api/v1/email/suppressions \
  -H "Authorization: Bearer sk_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "values": [
    "[email protected]",
    "[email protected]"
  ]
}'
const response = await fetch('https://spaw.co/api/v1/email/suppressions', {
  method: 'DELETE',
  headers: {
    'Authorization': 'Bearer sk_live_…',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    "values": [
      "[email protected]",
      "[email protected]"
    ]
  }),
});
const result = await response.json();
import requests

response = requests.delete(
    'https://spaw.co/api/v1/email/suppressions',
    headers={'Authorization': 'Bearer sk_live_…'},
    json={
        'values': [
            '[email protected]',
            '[email protected]'
        ]
    },
)
result = response.json()
$ch = curl_init('https://spaw.co/api/v1/email/suppressions');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => 'DELETE',
    CURLOPT_HTTPHEADER => ['Authorization: Bearer sk_live_…', 'Content-Type: application/json'],
    CURLOPT_POSTFIELDS => json_encode([
        'values' => [
            '[email protected]',
            '[email protected]'
        ]
    ]),
]);
$result = json_decode(curl_exec($ch), true);
from spaw import Client

client = Client('sk_live_…')
result = client.remove_suppressions([
    '[email protected]',
    '[email protected]'
])
import Spaw from 'spaw';

const spaw = new Spaw({ apiKey: 'sk_live_…' });
const result = await spaw.removeSuppressions([
    '[email protected]',
    '[email protected]'
]);
use Spaw\Client;

$spaw = new Client('sk_live_…');
$result = $spaw->removeSuppressions([
    '[email protected]',
    '[email protected]'
]);

This endpoint has no console on its page. It writes to your account. A documentation page can show you the request; making the change is for the dashboard or for a call you make yourself.

Responses

200Which of the addresses were on the list and which were not.

{
    "success": true,
    "data": {
        "removed": [
            "[email protected]"
        ],
        "not_found": [
            "[email protected]"
        ]
    }
}

401The key is missing, malformed, or revoked.

{
    "success": false,
    "error": {
        "code": "UNAUTHENTICATED",
        "message": "Provide a valid API key as a bearer token.",
        "request_id": "req_01m1kgdm4xngzmbmff68g94w0c"
    }
}

422The request body could not be validated; `error.errors` lists the fields.

{
    "success": false,
    "error": {
        "code": "VALIDATION_FAILED",
        "message": "The email field is required.",
        "errors": {
            "email": [
                "The email field is required."
            ]
        },
        "request_id": "req_01m1kgdm4xngzmbmff68g94w0c"
    }
}

429Over 5 requests per second for the key. Retry after the limit resets.

{
    "success": false,
    "error": {
        "code": "RATE_LIMITED",
        "message": "Too many requests. Retry after the limit resets.",
        "request_id": "req_01m1kgdm4xngzmbmff68g94w0c"
    }
}

Error codes

Failures answer { success: false, error: { code, message, request_id } }. Each code has its own page.

markdown version·openapi.json