arm-resource-invalid-version-format
@azure-tools/typespec-azure-resource-manager/arm-resource-invalid-version-formatCheck for valid versions.
ARM resource versions must follow the YYYY-MM-DD format, with an optional suffix such as -preview or a versioned suffix like -alpha.1.
Impact
Section titled “Impact”- Area: API
The api-version does not follow the required format, violating the RPC contract.
LintDiff Equivalent
Section titled “LintDiff Equivalent”This rule corresponds to the LintDiff rule ApiVersionPattern.
❌ Incorrect
Section titled “❌ Incorrect”@versioned(Versions)@armProviderNamespacenamespace Microsoft.Contoso;
enum Versions { v1: "1.2.3",}✅ Correct
Section titled “✅ Correct”@versioned(Versions)@armProviderNamespacenamespace Microsoft.Contoso;
enum Versions { v2024_01_01: "2024-01-01", v2024_06_01_preview: "2024-06-01-preview",}Suppression
Section titled “Suppression”Suppress only when required to match an existing API; otherwise use the YYYY-MM-DD[-preview] format.