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

# Contact Trace Records

> The Contact Trace Record (CTR) fields the Cloud Collector ingests from the Amazon Connect Kinesis stream and maps onto Operata contact records — account, contact, agent, and queue data.

Amazon Connect emits a Contact Trace Record (CTR) for every Contact. The Cloud Collector reads CTRs from your Amazon Connect Kinesis stream, merges them with Agent Experience Collector telemetry, and ships the result to Operata. CTR collection is optional and requires the [CTR installation](/docs/ctr-installation).

<Info>
  Use [Privacy Controls](/docs/api-data-redaction) to redact CTR fields at ingest. AWS publishes the full CTR schema in the [Amazon Connect CTR data model](https://docs.aws.amazon.com/connect/latest/adminguide/ctr-data-model.html).
</Info>

## Schema

CTR fields land inside the top-level `accountProperties`, `contact`, `serviceAgent`, and `queue` objects on the Operata record. The CTR-derived projection looks like this:

```json theme={null}
{
  "accountProperties": {
    "service": "Amazon Connect",
    "serviceAccountNumber": "012345678910",
    "serviceInstanceId": "62e2306a-aaaa-bbbb-cccc-5a1508195aa5",
    "region": "ap-southeast-2"
  },
  "contact": {
    "id": {
      "current": "b0c9d4d1-aaaa-bbbb-cccc-ee75d4240340",
      "previous": "",
      "next": ""
    },
    "type": "VOICE",
    "direction": "Inbound",
    "initiation": "INBOUND",
    "callerId": "+61402960149",
    "recordingUrl": "op.performance.sampling/connect/operata-prod/2026/05/18/b0c9d4d1_20260518T1014_UTC.wav",
    "connectedToAgent": "2026-05-18T10:14:43Z",
    "disconnectReason": "AGENT_DISCONNECT",
    "durationSec": 71
  },
  "serviceAgent": {
    "serviceId": "23aca65c-7bc8-4ead-b9e5-9df15f06b8af",
    "username": "agent_42",
    "hierarchyGroups": ["Sydney", "Tier 1"]
  },
  "queue": {
    "arn": "arn:aws:connect:ap-southeast-2:012345678910:instance/62e2306a-aaaa-bbbb-cccc-5a1508195aa5/queue/8092a344-02bb-4fba-ac74-2176c5aa0afe",
    "name": "Operata Prod Default Queue",
    "duration": 21
  }
}
```

## Fields

Every field below comes from the AWS CTR. Operata renames a small number of them for consistency with the rest of the data model; the **CTR source** column shows the original AWS field name.

| Name                                     | Type              | Required | Description                                                                                                                                                                         | CTR source                                      |
| ---------------------------------------- | ----------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------- |
| `accountProperties.service`              | string            | yes      | Always `Amazon Connect`.                                                                                                                                                            | —                                               |
| `accountProperties.serviceAccountNumber` | string            | yes      | AWS account ID that owns the Amazon Connect instance.                                                                                                                               | `AWSAccountId`                                  |
| `accountProperties.serviceInstanceId`    | string (UUID)     | yes      | Amazon Connect instance ID.                                                                                                                                                         | `InstanceARN` (parsed)                          |
| `accountProperties.region`               | string            | yes      | AWS region the instance runs in.                                                                                                                                                    | `InstanceARN` (parsed)                          |
| `contact.id.current`                     | string (UUID)     | yes      | Contact ID for this leg.                                                                                                                                                            | `ContactId`                                     |
| `contact.id.previous`                    | string (UUID)     | no       | Previous Contact ID when the Contact was transferred in.                                                                                                                            | `PreviousContactId`                             |
| `contact.id.next`                        | string (UUID)     | no       | Next Contact ID when the Contact was transferred out.                                                                                                                               | `NextContactId`                                 |
| `contact.type`                           | string            | yes      | One of `VOICE`, `CHAT`, `TASK`.                                                                                                                                                     | `Channel`                                       |
| `contact.direction`                      | string            | yes      | Contact direction from the agent's perspective.                                                                                                                                     | derived from `InitiationMethod`                 |
| `contact.initiation`                     | string            | yes      | How the Contact entered Amazon Connect. One of `INBOUND`, `OUTBOUND`, `TRANSFER`, `CALLBACK`, `API`, `QUEUE_TRANSFER`, `DISCONNECT`, `MONITOR`, `EXTERNAL_OUTBOUND`.                | `InitiationMethod`                              |
| `contact.callerId`                       | string (E.164)    | no       | Caller's phone number. Redacted when the caller-ID privacy control is enabled.                                                                                                      | `CustomerEndpoint.Address`                      |
| `contact.systemEndpoint`                 | string (E.164)    | no       | The Amazon Connect DID the caller dialled, for inbound Contacts.                                                                                                                    | `SystemEndpoint.Address`                        |
| `contact.recordingUrl`                   | string            | no       | S3 key of the call recording.                                                                                                                                                       | `Recording.Location`                            |
| `contact.recordingStatus`                | string            | no       | Recording status. One of `AVAILABLE`, `DELETED`, `FAILED`.                                                                                                                          | `Recording.Status`                              |
| `contact.initiationTime`                 | string (ISO 8601) | yes      | When the Contact entered Amazon Connect.                                                                                                                                            | `InitiationTimestamp`                           |
| `contact.connectedToAgent`               | string (ISO 8601) | no       | When the Contact connected to an agent.                                                                                                                                             | `ConnectedToAgentTimestamp`                     |
| `contact.connectedToSystem`              | string (ISO 8601) | no       | When the Contact connected to Amazon Connect.                                                                                                                                       | `ConnectedToSystemTimestamp`                    |
| `contact.disconnectTime`                 | string (ISO 8601) | yes      | When the Contact disconnected.                                                                                                                                                      | `DisconnectTimestamp`                           |
| `contact.disconnectReason`               | string            | no       | How the Contact ended. Common values: `AGENT_DISCONNECT`, `CUSTOMER_DISCONNECT`, `THIRD_PARTY_DISCONNECT`, `TELECOM_PROBLEM`, `CONTACT_FLOW_DISCONNECT`, `OTHER`, `EXPIRED`, `API`. | `DisconnectReason`                              |
| `contact.durationSec`                    | integer           | yes      | Total Contact duration in seconds.                                                                                                                                                  | derived                                         |
| `contact.scheduledTime`                  | string (ISO 8601) | no       | Scheduled Contact time, for callback Contacts.                                                                                                                                      | `ScheduledTimestamp`                            |
| `contact.lastUpdateTime`                 | string (ISO 8601) | yes      | When AWS last updated the CTR.                                                                                                                                                      | `LastUpdateTimestamp`                           |
| `contact.attributes`                     | object            | no       | Custom contact attributes set in your contact flow. Key-value pairs of strings.                                                                                                     | `Attributes`                                    |
| `serviceAgent.serviceId`                 | string (UUID)     | no       | Amazon Connect agent ID.                                                                                                                                                            | `AgentInfo.Id`                                  |
| `serviceAgent.username`                  | string            | no       | Agent username.                                                                                                                                                                     | `AgentInfo.Username` (from Connect user lookup) |
| `serviceAgent.hierarchyGroups`           | string\[]         | no       | Agent hierarchy-group path.                                                                                                                                                         | `AgentInfo.HierarchyGroups`                     |
| `serviceAgent.afterContactWorkDuration`  | integer           | no       | Agent's after-contact-work time in seconds.                                                                                                                                         | `AgentInfo.AfterContactWorkDuration`            |
| `serviceAgent.agentInteractionDuration`  | integer           | no       | Time in seconds the agent was interacting with the Contact.                                                                                                                         | `AgentInfo.AgentInteractionDuration`            |
| `serviceAgent.customerHoldDuration`      | integer           | no       | Time in seconds the customer was on hold.                                                                                                                                           | `AgentInfo.CustomerHoldDuration`                |
| `serviceAgent.longestHoldDuration`       | integer           | no       | Longest single hold in seconds.                                                                                                                                                     | `AgentInfo.LongestHoldDuration`                 |
| `serviceAgent.numberOfHolds`             | integer           | no       | How many times the agent placed the customer on hold.                                                                                                                               | `AgentInfo.NumberOfHolds`                       |
| `serviceAgent.connectionAttempts`        | integer           | no       | How many times Amazon Connect tried to reach the agent.                                                                                                                             | `AgentInfo.AgentConnectionAttempts`             |
| `queue.arn`                              | string (ARN)      | no       | Amazon Connect queue ARN.                                                                                                                                                           | `Queue.ARN`                                     |
| `queue.name`                             | string            | no       | Queue name.                                                                                                                                                                         | `Queue.Name` (resolved from ARN)                |
| `queue.duration`                         | integer           | no       | Time in seconds the Contact spent in queue.                                                                                                                                         | `Queue.Duration`                                |
| `queue.enqueueTime`                      | string (ISO 8601) | no       | When the Contact entered the queue.                                                                                                                                                 | `Queue.EnqueueTimestamp`                        |
| `queue.disconnectTime`                   | string (ISO 8601) | no       | When the Contact left the queue.                                                                                                                                                    | `Queue.DequeueTimestamp`                        |

For the original CTR field reference (including fields Operata does not surface, like `MediaStreams` or `TransferCompletedTimestamp`), see the [Amazon Connect CTR data model](https://docs.aws.amazon.com/connect/latest/adminguide/ctr-data-model.html).
