Skip to main content
The Contact Trace Record (CTR) redaction Lambda enforces this schema. The Lambda runs inside your AWS account. It applies your connect/ctr redaction policy to every Amazon Connect CTR read from Kinesis and ships only the surviving record to Operata. For the policy rules and endpoints, see Redaction policy. For the model behind redaction, see Privacy and redaction.
This schema applies to the CTR collector in Cloud Collector v1.2.3 and later. Earlier releases read the legacy redaction config. See Configure CTR redaction (legacy) and the legacy config endpoints. Contact flow logs and Amazon Lex have their own schemas.

Field tiers

Every field in a CTR falls into one of four tiers. With no ALLOW or DENY rules, a CTR reaches Operata with every key present but only the mandatory values filled in.

Processing order

The Lambda checks each field against the tiers in order and applies the first one that matches.
  1. Mandatory. Keep the field. If a mandatory field sits under a denied parent, keep the parent and remove its other children.
  2. Deny. Remove the field and everything under it.
  3. Allow. Keep the field and everything under it.
  4. Default. Set the value to null.
Deny comes before allow, so a DENY on a parent removes it even when an ALLOW names one of its children. An ALLOW on a parent with a DENY on a child keeps every child except the denied one.

Path notation

Rules use dot notation against the CTR JSON. For the full syntax, including wildcards and filters, see Field paths.
  • Attributes matches the whole Attributes object.
  • CustomerEndpoint.Address matches only that subfield.
  • Attributes.* matches every direct child of Attributes.
  • [Channel == 'CHAT'].Agent.ARN matches Agent.ARN only on chat CTRs.

Chat CTRs

The Lambda always collects voice CTRs. It collects chat and other non-voice CTRs only when chat collection is on for your Operata Group. Operata manages this setting. If the Lambda can’t read it, it treats chat collection as off and drops non-voice CTRs. Chat CTRs carry extra mandatory fields, such as ChatMetrics. They appear in the keep-list with a [Channel == 'CHAT'] prefix. On voice CTRs, those fields follow your ALLOW and DENY rules like any other field.

Data flow

The Lambda refreshes the policy from Operata at most every five minutes and caches it in AWS Secrets Manager in your account. If Operata is unreachable, it applies the cached policy. If it has no policy at all, it fails the batch rather than ship an unredacted CTR.

Mandatory keep-list

The Lambda always preserves these fields. To see the current list for your Operata Group, read your policy with Get redaction policy.

All CTRs

Chat CTRs only