Delete companies in bulk
POST /v2/companies/batch-delete
Parameters
Header parameters
apps/rest-api/src/shared/idempotency.ts for the full contract. Missing → 400 BadRequest; same key + different body → 409 Conflict.Request body
Content-Type: application/json
POST /v2/companies/selections.next_offset of the previous page.Example
{
"company_ids": [
"00000000-0000-0000-0000-000000000000"
],
"selection_id": "string"
}
Responses
200 — Successful response
Content-Type: application/json
Example
{
"data": {
"affected": 0
}
}
400 — Request body failed validation.
Content-Type: application/json
401 — Missing or invalid API key.
Content-Type: application/json
403 — Valid key, insufficient permission.
Content-Type: application/json
404 — Resource does not exist.
Content-Type: application/json
409 — Request conflicts with the current state of the resource.
Content-Type: application/json
429 — Rate limit exceeded.
Content-Type: application/json
500 — Unexpected server error.
Content-Type: application/json
Code samples
curl https://api.prod.getdex.com/v2/companies/batch-delete \
--request POST \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header "Idempotency-Key: $(uuidgen 2>/dev/null || python3 -c 'import uuid;print(uuid.uuid4())')" \
--header 'Content-Type: application/json' \
--data '{
"company_ids": [
"00000000-0000-0000-0000-000000000000"
],
"selection_id": "string"
}'
fetch('https://api.prod.getdex.com/v2/companies/batch-delete', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Idempotency-Key': crypto.randomUUID(),
'Content-Type': 'application/json'
},
body: JSON.stringify({
company_ids: ['00000000-0000-0000-0000-000000000000'],
selection_id: 'string'
})
})
import uuid
requests.post(
"https://api.prod.getdex.com/v2/companies/batch-delete",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Idempotency-Key": str(uuid.uuid4()),
"Content-Type": "application/json"
},
json={
"company_ids": [
"00000000-0000-0000-0000-000000000000"
],
"selection_id": "string"
}
)
Search companies
Typeahead over the workspace's active companies: matches `query` (required, trimmed, 1-100 characters; 400 when blank) accent-insensitively against the name, the website's domain (scheme, `www.` and p
Set one custom field on companies in bulk
Write one value (`custom_field_id` and exactly one value key) to up to 100 companies (`company_ids`) or one page of a frozen selection. A selection page is `{ selection_id, offset, limit? }` from `POS

