# Workspace API

**The Workspace API is for system integrations only.** It's designed for admins who are connecting CTD to an internal tool, data warehouse, or CRM. It is not intended for individual use. Requires a workspace-level API key.

Full API reference: [app.ctd.ai/account/api-access/documentation?type=workspace](https://app.ctd.ai/account/api-access/documentation?type=workspace). Generate a workspace API key at [app.ctd.ai/account/api-access/api-keys](https://app.ctd.ai/account/api-access/api-keys).

## Global vs. standard paths

The Workspace API has two views. The standard view returns paths scoped to the requesting user. The global view returns paths across all team members and external members — this is the view you want for integrations.

## People & companies

### Reachability Data for a Specific Person
**GET** `/enterprise/atc-paths-api/public/v1/reachable-person`

Returns reachability data for a specific person through the workspace network.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/reachable-person?email=jane@acme.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Global Reachability Data
**GET** `/enterprise/atc-paths-api/public/v1/global/reachable-person`

Returns reachability across the entire workspace (all team members + external members).

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/global/reachable-person?email=jane@acme.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Reachability of All People
**GET** `/enterprise/atc-paths-api/public/v1/reachable-people`

Returns all people reachable through the workspace network.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/reachable-people" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Reachability Data for a Company
**GET** `/enterprise/atc-paths-api/public/v1/company`

Returns reachability data for a company through the workspace network.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/company?domain=acme.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Reachability of All Companies
**GET** `/enterprise/atc-paths-api/public/v1/reachable-companies`

Returns all companies reachable through the workspace network.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/reachable-companies" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Reachable Employees at a Company
**GET** `/enterprise/atc-paths-api/public/v1/people`

Returns reachable employees at a specific company.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/people?domain=acme.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

## Paths

### Warm Intro Paths
**GET** `/enterprise/atc-paths-api/public/v2/paths`

Returns warm intro paths to a person or company through the workspace network.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v2/paths?company_domain=acme.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Global Paths
**GET** `/enterprise/atc-paths-api/public/v2/global/paths`

Returns paths across the entire workspace — all team members and external members combined.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v2/global/paths?company_domain=acme.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Paths through a Specific Connector
**GET** `/enterprise/atc-paths-api/public/v2/paths/connector`

Returns all paths through a specific connector.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v2/paths/connector?connector_email=jane@example.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Global Paths through a Specific Connector
**GET** `/enterprise/atc-paths-api/public/v2/global/paths/connector`

Returns paths through a specific connector across the entire workspace.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v2/global/paths/connector?connector_email=jane@example.com" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Paths Filtered by Stage
**GET** `/enterprise/atc-paths-api/public/v2/paths/by-stage`

Returns paths filtered by stage.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v2/paths/by-stage?stage=intro_requested" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Update Path Stage
**PATCH** `/enterprise/atc-paths-api/public/v2/paths/{pathId}/stage`

Update the stage of a path.

```bash
curl -X PATCH "http://api.ctd.ai/enterprise/atc-paths-api/public/v2/paths/PATH_ID/stage" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com" \
  -H "Content-Type: application/json" \
  -d '{"stage": "intro_made"}'
```

### Natural Language Path Search
**GET** `/enterprise/atc-paths-api/public/v1/paths/search`

Natural language path search across the workspace.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/paths/search?q=VP+of+Sales+at+enterprise+software" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

## Job Changes

### Get Job Changes
**GET** `/enterprise/atc-paths-api/public/v1/job-changes`

Returns job changes across all tracked accounts in the workspace.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/job-changes" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

## Activities

### Get Activity Data
**GET** `/enterprise/asks-api/public/v1/activities`

Returns ghost email and outreach activity across the entire workspace.

```bash
curl "http://api.ctd.ai/enterprise/asks-api/public/v1/activities" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

## Target Accounts

### Import Target Accounts
**POST** `/enterprise/atc-paths-api/public/v1/target-accounts/imports`

Create a new target accounts import job.

```bash
curl -X POST "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/target-accounts/imports" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Check Import Status
**GET** `/enterprise/atc-paths-api/public/v1/target-accounts/imports/{import_id}`

Check the status of a target accounts import.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/target-accounts/imports/IMPORT_ID" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Add Companies to Import
**POST** `/enterprise/atc-paths-api/public/v1/target-accounts`

Add a batch of companies to an existing import.

```bash
curl -X POST "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/target-accounts" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com" \
  -H "Content-Type: application/json" \
  -d '{"import_id": "IMPORT_ID", "accounts": [{"domain": "acme.com"}]}''
```

### Delete All Target Accounts
**DELETE** `/enterprise/atc-paths-api/public/v1/target-accounts`

Delete all target accounts in the workspace.

```bash
curl -X DELETE "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/target-accounts" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

## Custom Columns

### Get Custom Column Names
**GET** `/enterprise/atc-paths-api/public/v1/custom-columns-names`

Returns the display names for custom columns in your workspace.

```bash
curl "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/custom-columns-names" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com"
```

### Rename Custom Columns
**PATCH** `/enterprise/atc-paths-api/public/v1/rename-custom-columns`

Rename custom column display names.

```bash
curl -X PATCH "http://api.ctd.ai/enterprise/atc-paths-api/public/v1/rename-custom-columns" \
  -H "ctd-api-key: YOUR_API_KEY" \
  -H "ctd-client-id: you@yourcompany.com" \
  -H "Content-Type: application/json" \
  -d '{"columns": {"col_1": "Priority"}}'
```

Have a question or running into an issue? Email us at [support@ctd.ai](mailto:support@ctd.ai) — we're happy to help.
