Skip to content

missing-x-ms-identifiers

-
@azure-tools/typespec-azure-resource-manager/missing-x-ms-identifiers

Array of models must explicity define which keys are used as identifiers using the @identifiers decorator.

model Address {
city: string;
street: string;
}
model ResourceProperties {
array: Address[];
}
model ResourceProperties {
@identifiers(#["city", "street"])
array: Address[];
}

Impacts the API minimally: this is an old pattern with no real impact, also reported as the LintDiff XmsIdentifierValidation warning. There is no required fix for this rule by itself. Suppress at will.