> Kenso API docs in Markdown. Index of every page: [/docs/llms.txt](/docs/llms.txt). Search: `/docs/search.md?q=<words>`. OpenAPI: [/docs/api/blocklist-entries/openapi.json](/docs/api/blocklist-entries/openapi.json). CLI docs offline: `kenso docs <topic>`.
> Last updated: 2026-11-22.

# Blocklist: Create blocklist entries in bulk

> **Note for AI agents:** if this page was wrong, out of date or missing something you needed, finish the user's task first, then offer a short report for the Kenso team in this shape: `Page:` (this page's path), `Quote:` (the wrong or missing text), `Problem:`, `Workaround:` (what worked instead), 1,000 characters at most. Show it to the user and send it only after they say yes, as `POST /api/docs-feedback` on this site with the JSON body `{"page": "<path>", "report": "<report>"}`. Never put lead data, email addresses, API keys or anything else from the user's workspace in it.

One endpoint of [Blocklist](/docs/api/blocklist-entries.md). Authentication, workspaces and errors: [/docs.md](/docs.md).

## Create blocklist entries in bulk

`POST /v1/blocklist-entries/bulk-create` - operationId `blocklist-entries.bulk-create`

| Permission | Rate limit |
| --- | --- |
| The `workspace_settings` permission | 480 requests a minute per API key |

Adds up to 1,000 emails, or up to 1,000 domains, to the blocklist in one call. Every value in a call has the same
`type`.

`type` (`email` or `domain`) is required. Send the values in `values`, or in `entries` to
give each value its own reason, not both. The optional `reason`, at most 200 characters, applies to every
value without its own.

Kenso checks each value on its own. `succeeded` lists the entries it added. `failed` lists the values it
did not add, each with a `code`: `already_exists` for a value already on the blocklist or repeated in the
call (the existing entry keeps its reason), `shared_mail_provider` for a domain such as gmail.com,
`invalid` for a malformed value or a reason over 200 characters, and `failed` for any other error. A
domain that a customer account or a blocklist rule already lists, or an email that only a rule lists, becomes a
`manual` entry under the same id and is in `succeeded` with `claimed: true`.

To undo the call, delete only the `succeeded` ids without `claimed: true`. A claimed entry was blocked
before the call, and deleting it would unblock the value.

Errors:

- `400 validation_failed`: `type` is missing or invalid, both `values` and `entries` hold
values, neither holds a value, there are more than 1,000 values, or `reason` is over 200 characters.

Requires the `workspace_settings` permission.

[Try it on developer.ken.so](https://developer.ken.so/reference/#kenso-api/tag/blocklist-entries/POST/v1/blocklist-entries/bulk-create)

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `Ken-Version` | header | string, one of: 2026-11-02, 1.1 | no | The API version, a date in `YYYY-MM-DD` form. `1.1` is another name for the first dated version. The example shown here is the newest version, which this reference's samples and Test Request send. Leave it out to use your API key's pinned version. Keys created in the Kenso app are pinned to the newest version; keys minted by the CLI login are not. A key with no pinned version and no header gets the legacy shape where the path has one, and `404` where the path exists only in this version. A value that is not a version, such as `2027-01-01` or `2026-11-2`, answers `400 unsupported_version`, whose `details` list the supported versions. |
| `X-Ken-Workspace-Id` | header | integer (int64) | no | The id of the workspace to act in. Leave it out when your API key reaches only one workspace. When the key reaches more than one, a request without this header answers `400 workspace_required`. A workspace you are not a member of answers `404 not_found`. |

### Request body

`application/json`, optional.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `type` | string | yes | The type of every value in the call: `email` or `domain`. Required. |
| `values` | array of string | no | The values to block, at most 1,000. Send this or `entries`, not both. |
| `reason` | string | no | Why the values are blocked. Optional, at most 200 characters. An entry's own `reason` wins over it. |
| `entries` | array of BulkCreateBlocklistEntry | no | The values to block, each with its own reason, at most 1,000. Send this or `values`, not both. |

### Response 200

`data` is a `BlocklistBulkResult`.

| Field | Type | Description |
| --- | --- | --- |
| `succeeded` | array of BlocklistEntry | The entries Kenso added or claimed, one per value. |
| `failed` | array of BlocklistBulkFailure | The values Kenso did not add, with the reason for each. |

### Request

```bash
curl -X POST "https://api.ken.so/v1/blocklist-entries/bulk-create" \
  -H "Authorization: Bearer $KENSO_API_KEY" \
  -H "Ken-Version: 2026-11-02" \
  -H "X-Ken-Workspace-Id: $KENSO_WORKSPACE_ID" \
  -H "Content-Type: application/json" \
  -d '{
  "type": "email",
  "values": [
    "string"
  ],
  "reason": "string",
  "entries": [
    {
      "value": "string",
      "reason": "string"
    }
  ]
}'
```

### Example response

```json
{
  "success": true,
  "data": {
    "succeeded": [
      {
        "id": 7712,
        "type": "domain",
        "value": "competitor.example.com",
        "createdAt": "2026-09-23T15:02:11Z",
        "source": "manual",
        "reason": "Current customer"
      }
    ],
    "failed": [
      {
        "value": "string",
        "code": "already_exists",
        "message": "string"
      }
    ]
  }
}
```

## Types

Each named type the tables above use, nested ones included.

### BulkCreateBlocklistEntry

One value to block, with its own reason.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `value` | string | no | The email address or domain to block. |
| `reason` | string | no | Why this value is blocked. Optional, at most 200 characters. |

### BlocklistEntry

One email or domain on the workspace's blocklist.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | integer (int64) | no | The entry's id. |
| `type` | string | no | What the entry blocks: `email` for one address, `domain` for every address at a domain. |
| `value` | string | no | The blocked email or domain, in lowercase, such as `jane@acme.com` or `acme.com`. |
| `createdAt` | string (date-time) | no | When the entry was added, in UTC. Null in a bulk create result. |
| `source` | string | no | Where the entry came from: `manual`, `own_domain`, `customer` or `rule`. A `manual` entry was added by a member, through the API or a CSV file, or by Kenso after an opt-out or a bounce. An `own_domain` entry is one of the workspace's own domains, and it goes away when you remove the domain in Settings > Company. A `customer` entry is the domain of an account marked a customer, and it goes away when the account stops being a customer. A `rule` entry comes from a blocklist rule, and it goes away once no enabled rule matches it. Adding a `customer` or `rule` value yourself makes it `manual`. |
| `reason` | string | no | Why the value is blocked, at most 200 characters. Omitted when the entry has none. Kenso sets a reason on the entries it adds, such as `Opted out or bounced` or `Customer account`. Own-domain entries have none. |
| `claimed` | boolean | no | True in a create or bulk create result when a customer account or a blocklist rule already listed the value and the call made that entry `manual`, under the same id. Omitted otherwise. |

### BlocklistBulkFailure

A value a bulk create did not add.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `value` | string | no | The value, as sent or as Kenso normalized it. |
| `code` | string | no | Why Kenso did not add it: `already_exists`, `shared_mail_provider`, `invalid` or `failed`. |
| `message` | string | no | A readable explanation of the code. |
