> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reachedapp.com/llms.txt
> Use this file to discover all available pages before exploring further.

# API Reference

> Complete reference for all Reached API endpoints.

# API Reference

The Reached API provides a set of RESTful endpoints to manage your outbound calling workflow. All endpoints accept and return JSON.

## Base URL

```text theme={null}
https://kdjmltmhxvvmiuehafgl.supabase.co/functions/v1/api-gateway/v1
```

## Authentication

All requests must include a valid API key in the `Authorization` header:

```text theme={null}
Authorization: Bearer rchd_live_xxxxxxxxxxxx
```

<Card title="Learn more about authentication" icon="key" href="/authentication">
  See the full authentication guide for details on generating and managing API keys.
</Card>

## Available Resources

<CardGroup cols={2}>
  <Card title="Leads" icon="user" href="/rest-api/leads/create-lead">
    Create, list, get, and update leads in your workspace.
  </Card>

  <Card title="Campaigns" icon="bullhorn" href="/rest-api/campaigns/list-campaigns">
    Access calling campaigns and add leads for parallel dialing.
  </Card>

  <Card title="Call Logs" icon="phone" href="/rest-api/call-logs/list-call-logs">
    Retrieve call history with recordings, transcripts, and dispositions.
  </Card>

  <Card title="Agents" icon="users" href="/rest-api/agents/list-agents">
    List active users and resolve agent\_id values from call logs.
  </Card>

  <Card title="Webhooks" icon="webhook" href="/rest-api/webhooks/create-webhook">
    Subscribe to real-time event deliveries as an alternative to polling.
  </Card>

  <Card title="Workspaces" icon="layout" href="/rest-api/workspaces/list-workspaces">
    List workspaces and map workspace\_id values from leads and call logs.
  </Card>

  <Card title="Dispositions" icon="list" href="/rest-api/dispositions/list-dispositions">
    List all call dispositions including built-in and custom ones.
  </Card>

  <Card title="Tasks" icon="list-check" href="/rest-api/tasks/create-task">
    Create and manage follow-up tasks linked to leads.
  </Card>
</CardGroup>

## Endpoint Summary

### Leads

| Method | Endpoint | Description |
| - | - | - |
| `POST` | `/v1/leads` | Create a lead |
| `GET` | `/v1/leads` | List leads (supports batch retrieval via `ids`) |
| `GET` | `/v1/leads/:id` | Get a lead |
| `PUT` | `/v1/leads/:id` | Update a lead |
| `POST` | `/v1/leads/:id/enrich` | Enrich a lead |

### Campaigns

| Method | Endpoint | Description |
| - | - | - |
| `GET` | `/v1/campaigns` | List campaigns |
| `GET` | `/v1/campaigns/:id` | Get a campaign |
| `GET` | `/v1/campaigns/:id/stats` | Get campaign statistics |
| `POST` | `/v1/campaigns/:id/leads` | Add leads to a campaign |
| `DELETE` | `/v1/campaigns/:id/leads/:lead_id` | Remove a lead from a campaign |

### Call Logs

| Method | Endpoint | Description |
| - | - | - |
| `GET` | `/v1/call-logs` | List call logs (supports `updated_since`, `include`, `is_conversation`) |
| `GET` | `/v1/call-logs/:id` | Get a call log (includes transcript, summary, notes) |
| `GET` | `/v1/call-logs/:id/recording` | Get a fresh presigned recording URL |

### Agents

| Method | Endpoint | Description |
| - | - | - |
| `GET` | `/v1/agents` | List agents (active users) |

### Webhooks

| Method | Endpoint | Description |
| - | - | - |
| `POST` | `/v1/webhooks` | Create a webhook subscription |
| `GET` | `/v1/webhooks` | List webhooks |
| `DELETE` | `/v1/webhooks/:id` | Delete a webhook |
| `POST` | `/v1/webhooks/:id/rotate-secret` | Rotate a webhook signing secret |

### Workspaces

| Method | Endpoint | Description |
| - | - | - |
| `GET` | `/v1/workspaces` | List workspaces |

### Dispositions

| Method | Endpoint | Description |
| - | - | - |
| `GET` | `/v1/dispositions` | List all dispositions (built-in + custom) |

### Tasks

| Method | Endpoint | Description |
| - | - | - |
| `POST` | `/v1/tasks` | Create a task |
| `GET` | `/v1/tasks` | List tasks |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.