Skip to main content
Use the Public API when you want Clay behind a backend service, queue, webhook, custom app, or batch job. If you are testing from a terminal or working with an AI coding agent, start with the CLI quickstart instead.

Prefer the CLI?

The CLI is the quickest path for most first-time users and agent workflows.

URLs and paths

Use these path types consistently:
TypeExampleMeaning
Runtime API URLhttps://api.clay.com/public/v0/meThe URL your code calls
Runtime endpoint pathPOST /routines/{routine_id}/runThe API path relative to /public/v0
Guide page/searches, /routines, /tablesHuman and agent-readable concept docs
Generated API reference/api-reference/searches/...Mintlify docs for schemas and try-it UI
Do not call /api-reference/... from code. It is a docs URL, not a Clay API endpoint.

1. Set your API key

Create an API key in Account settings. Then store it in your environment.
export CLAY_API_KEY="your_api_key"

2. Call the API

Use GET /me to verify that your key works.
curl https://api.clay.com/public/v0/me \
  -H "clay-api-key: $CLAY_API_KEY"

3. Run useful Clay work

After your key is verified, choose what you want Clay to do:
  • Use Searches to find companies, people, and jobs.
  • Use Routines to run Clay-managed functions, custom functions, or Workflows.
  • Use Tables to query existing table data. Tables are Enterprise only.

4. Use the API reference

Use the API reference for endpoint paths, request bodies, and response schemas.