New: meet Clu, and send email, LinkedIn and call steps with Sequences. Watch the videos →
Legacy API (v1)
OpenAPI Spec
🔌

Audience: developers. API keys and the REST API are included on Pro and Enterprise (and legacy Pro and Scale plans) and on AppSumo Tiers 5 to 7. They are not available on Free, Starter, AppSumo Tiers 1 to 4 or during the Pro trial. Support agent: confirm the user's plan includes API access before giving API advice.

TL;DR: The v1 spec (/openapi-public.json) lists the five legacy endpoints. The v2 spec is /openapi-public-v2.json. Swagger UI at /docs opens on v2 (latest) and switches to v1 from the dropdown. Redoc at /redoc shows v2 only.

OpenAPI specification

Cleanlist publishes live OpenAPI documents generated from the production API.

URLWhat it is
https://api.cleanlist.ai/openapi-public.jsonv1 spec: the five legacy endpoints
https://api.cleanlist.ai/openapi-public-v2.jsonv2 spec
https://api.cleanlist.ai/docsSwagger UI with a version switcher: v2 (latest) by default, v1 in the dropdown
https://api.cleanlist.ai/redocRedoc for v2

The specs need no API key to download.

What the v1 spec contains

MethodPath
GET/api/v1/public/auth/validate-key
POST/api/v1/public/enrich/bulk
GET/api/v1/public/enrich/status
GET/api/v1/public/webhooks/deliveries
POST/api/v1/public/folders

Lead lists, search, credit balance, enrichment of single people and companies, skills and smart agents, sync and export are in the v2 spec. See the v2 OpenAPI page.

Browsing interactively

Swagger UI

Open api.cleanlist.ai/docs (opens in a new tab). It loads v2 (latest); choose v1 in the spec dropdown at the top to see the legacy endpoints. To try calls, click Authorize and paste your clapi_ key (HTTP Bearer). Requests made from Swagger UI are real: they use your credits and count toward your rate limit.

Redoc

api.cleanlist.ai/redoc (opens in a new tab) renders the v2 spec as a read-only reference.

Downloading the v1 spec

curl https://api.cleanlist.ai/openapi-public.json -o cleanlist-openapi-v1.json

Generating a client

These commands generate a client for the five v1 endpoints. For anything else, generate from the v2 spec instead (see v2 SDKs).

TypeScript (openapi-typescript)

npx openapi-typescript https://api.cleanlist.ai/openapi-public.json -o ./cleanlist-v1-types.ts
import type { paths } from "./cleanlist-v1-types";
 
type EnrichBulkRequest =
  paths["/api/v1/public/enrich/bulk"]["post"]["requestBody"]["content"]["application/json"];
type EnrichBulkResponse =
  paths["/api/v1/public/enrich/bulk"]["post"]["responses"]["200"]["content"]["application/json"];

Python (openapi-python-client)

pipx install openapi-python-client
openapi-python-client generate --url https://api.cleanlist.ai/openapi-public.json

Other languages

npm install -g @openapitools/openapi-generator-cli
openapi-generator-cli generate \
  -i https://api.cleanlist.ai/openapi-public.json \
  -g go \
  -o ./cleanlist-client

Replace go with any generator from the OpenAPI Generator project (opens in a new tab).

Versioning

The v1 API is frozen: its five endpoints keep working, and new endpoints are added only to v2. See API versions and migration.

Related