Skip to main content
Version: v0.0.4

Interface: DeidentifiedAttribute

One audited attribute outcome. Carries only structural facts - tag, keyword, the resolved Annex E action code, and the SQ context path - never a decoded value, so a report is always safe to log.

Example

import { deidentify, parseDicom, type DeidentifiedAttribute } from "@cosyte/dicom";
const { report } = deidentify(parseDicom(buf));
report.attributes.forEach((a: DeidentifiedAttribute) => {
console.log(a.keyword, a.action, a.applied); // structural facts only - safe to log
});

Properties

action

readonly action: "D" | "Z" | "X" | "K" | "C" | "U"

The resolved single action after collapsing any conditional code.


applied

readonly applied: AppliedAction


contextPath?

readonly optional contextPath?: readonly string[]

Tag/index chain for an attribute inside a sequence; omitted at the root.


keyword

readonly keyword: string


repeatingGroup?

readonly optional repeatingGroup?: string

Present when the action came from a Table E.1-1 row that names a repeating-group family rather than this single tag: the mask that matched, e.g. "60xx4000" for Overlay Comments in any overlay plane. tag is always the concrete tag that was in the file. Absent for every exact-tag row.


tag

readonly tag: string