Skip to content

Mask PII

A Mask PII step hides personal data in the run, such as a PAN, an Aadhaar number or a phone number. You choose how the value is masked and how far the masking reaches: for the rest of the run, for the next step only, or only in the run views.

  • Mask a PAN after KYC so later agents and systems never see it.
  • Show only the last four digits of an account number to a task agent.
  • Keep full card details out of the run timeline while steps still use them.
  • You need to check content against a policy. Use Policy check, which can also mask on failure.
  • The data should not be collected at all. Remove it from the trigger’s input fields or the agent’s details to collect.
Setting What it does
Fields to mask Required. One or more paths such as input.pan, data.customer.phone or steps.kyc.aadhaar. A bare name, such as pan, is looked up in input and data.
Mask as full (default) replaces the value with ***. last4 keeps the last four characters. hash gives a one-way hash. token gives a stable stand-in such as tok_3f9a…, so records can still be matched; it cannot be reversed.
For rest_of_run (default) changes the value in the run for all later steps and views. next_step: only the following step sees the masked value. logs_only: the timeline and run views are masked; steps keep the real value.
  • A single Next.
  • The listed values masked as you chose. Hashes and tokens are the same for the same value within your organisation, so you can still compare them.

A lender masks the PAN once KYC is done, then asks a task agent for a summary.

Sub-workflow (KYC) → Mask PII (input.pan, data.kyc.pan; last4; rest of run) → Task agent (case summary) → End

Before and after:

{ "before": { "pan": "ABCDE1234F" }, "after": { "pan": "******234F" } }