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

# Quickstart

> From an API key to a placed call and its transcript in five requests.

This walkthrough uses the Voice API to place an outbound call with one of your voice agents and read the transcript afterwards. You need an [organization API key](/authentication.md) and a voice agent that has been published in the Clarity app, with an outbound phone number configured for your project.

**1. Store your key**

```bash theme={null}
export CLARITY_API_KEY="anek_org_..."
```

**2. Find your project**

```bash theme={null}
curl https://voice-api.onclarity.com/v1/projects \
  -H "Authorization: Bearer $CLARITY_API_KEY"
```

Note the `id` of the project your agent belongs to.

```bash theme={null}
export PROJECT_ID="..."
```

**3. Find your agent**

```bash theme={null}
curl https://voice-api.onclarity.com/v1/projects/$PROJECT_ID/agents \
  -H "Authorization: Bearer $CLARITY_API_KEY"
```

Pick the agent and note its `id`.

```bash theme={null}
export AGENT_ID="..."
```

**4. Place a call**

```bash theme={null}
curl -X POST https://voice-api.onclarity.com/v1/projects/$PROJECT_ID/agents/$AGENT_ID/dispatch-call \
  -H "Authorization: Bearer $CLARITY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "to": "+15551234567" }'
```

The call starts ringing straight away. The response carries the conversation's id:

```json theme={null}
{
  "callId": "…",
  "roomName": "…",
  "status": "dialing",
  "conversationId": "…"
}
```

```bash theme={null}
export CONVERSATION_ID="..."
```

Add `"on_call_ended_url": "https://your-server.example.com/clarity/call-ended"` to have the full call record posted to you when the call ends. See [Call-ended webhook](/voice/call-ended-webhook.md).

**5. Read the transcript**

After the call ends:

```bash theme={null}
curl -G https://voice-api.onclarity.com/v1/projects/$PROJECT_ID/conversations/$CONVERSATION_ID/artifacts \
  -H "Authorization: Bearer $CLARITY_API_KEY" \
  --data-urlencode "include_recording=true"
```

`merged.transcript` holds the whole call as text, and each session's `recording_signed_url` is a download link for its audio, valid for one hour. Until the call's files are stored the request answers `404` with `ARTIFACTS_NOT_READY`; retry after a minute. See [Conversations](/voice/conversations.md).

## Next steps

> **[Outbound calls](/voice/outbound-calls.md)**
>
> Caller ids, errors, and following a call to the end.

> **[Campaigns](/voice/campaigns.md)**
>
> Call a list of numbers on a schedule.

> **[Support API](/support/overview.md)**
>
> Tickets, customers, messages, and webhooks.

> **[API reference](/api-reference/introduction.md)**
>
> Every endpoint, with a live playground.


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