# CRM call transcripts

`GET /v1/activities/:activityId/transcript`

Returns the completed AI transcript of a client call logged in CRM as a Call activity and processed in your Bitrix24 account by CoPilot. The method only reads an existing transcript — it does not trigger generation.

Bitrix24 API: `crm.activity.call.getTranscript`
Scope: `crm`

## Parameters

| Parameter | Type | Required | Description |
|----------|------|:--------:|-------------|
| `activityId` (path) | number | yes | ID of the call activity. List: [`GET /v1/activities`](/docs/entities/activities/list) |

## Examples

### curl — personal key

```bash
curl "https://vibecode.bitrix24.com/v1/activities/12345/transcript" \
  -H "X-Api-Key: YOUR_API_KEY"
```

### curl — OAuth application

```bash
curl "https://vibecode.bitrix24.com/v1/activities/12345/transcript" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"
```

### JavaScript — personal key

```javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/activities/12345/transcript', {
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
  },
})

const { data } = await res.json()
if (data.transcription === null) {
  // no transcript yet — this is not an error
} else {
  console.log(data.transcription)
}
```

### JavaScript — OAuth application

```javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/activities/12345/transcript', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})

const { data } = await res.json()
```

## Response fields

| Field | Type | Description |
|------|------|-------------|
| `success` | boolean | `true` on a successful request |
| `data` | object | Result of the transcript request |
| `data.transcription` | string \| null | The full transcript text. A `null` value comes back with status `200` when there is no transcript for the call yet — the call has not been processed or processing has not finished. Check `data.transcription === null` |

## Response example

Transcript is ready:

```json
{
  "success": true,
  "data": {
    "transcription": "Hello, how can I help you?"
  }
}
```

No transcript yet — `transcription` is `null`, the status stays `200`:

```json
{
  "success": true,
  "data": {
    "transcription": null
  }
}
```

## Error response example

403 — no access to the transcript:

```json
{
  "success": false,
  "error": {
    "code": "BITRIX_ACCESS_DENIED",
    "message": "Access denied",
    "hint": "Access denied to this call transcript. Two possible causes: (1) the Bitrix24 user this call runs as lacks read access to a CRM entity bound to this call activity, or (2) AI call processing is not enabled on this portal. The cause is not determined; check the user's CRM permissions and whether AI call processing (transcription) is turned on.",
    "cause": "unknown",
    "method": "crm.activity.call.getTranscript",
    "fix": { "action": "none" }
  }
}
```

## Errors

| HTTP | Code | Description |
|------|------|-------------|
| 403 | `BITRIX_ACCESS_DENIED` | One code for two causes: no read access to any of the CRM entities the call is bound to — a deal, lead, contact or company — or AI call processing is disabled on the portal. The `hint` field names both |
| 404 | `ENTITY_NOT_FOUND` | No activity with this `activityId`, or it has no CRM bindings |
| 400 | `INVALID_PARAMS` | `activityId` is not a positive integer. Message: `activityId must be a positive integer` |
| 422 | `BITRIX_ERROR` | Bitrix24 refused to read the transcript for another reason. The refusal text is in `message` |
| 403 | `SCOPE_DENIED` | The API key has no `crm` scope |
| 401 | `TOKEN_MISSING` | The API key has no tokens configured |

Full list of common API errors — [Errors](/docs/errors).

## Known specifics

**The transcript does not appear instantly.** Bitrix24 builds it after the call ends. Retry the request later.

## See also

- [Get activity](/docs/entities/activities/get)
- [List activities](/docs/entities/activities/list)
- [Activity bindings](/docs/entities/activities/bindings)
- [Limits and optimization](/docs/optimization)
