The registry accepts specs that mark operations, parameters, or schema properties as deprecated: true without an x-sunset date. This creates a dead-end lifecycle: the item can never be removed later without --force, because the grace-period engine blocks removal of deprecated items without sunset.
Deprecation and sunset should be declared together. docs/registry/compat-classification.md already treats *-removed-missing-sunset as a blocked state, but the check only runs at removal time, not when the item is first marked deprecated.
Goal: reject specs where deprecated: true appears without a valid x-sunset date at push and validate time.
Expected behavior: POST /v1/specs and POST /v1/specs/:name/validate return 422 with error code missing_sunset_date when any operation, parameter, request body property, or response property is deprecated without x-sunset.
Suggested location: src/registry/parser/openapi/validate.ts, since both push and validate already call it.
The registry accepts specs that mark operations, parameters, or schema properties as
deprecated: truewithout anx-sunsetdate. This creates a dead-end lifecycle: the item can never be removed later without--force, because the grace-period engine blocks removal of deprecated items without sunset.Deprecation and sunset should be declared together.
docs/registry/compat-classification.mdalready treats*-removed-missing-sunsetas a blocked state, but the check only runs at removal time, not when the item is first marked deprecated.Goal: reject specs where
deprecated: trueappears without a validx-sunsetdate at push and validate time.Expected behavior:
POST /v1/specsandPOST /v1/specs/:name/validatereturn422with error codemissing_sunset_datewhen any operation, parameter, request body property, or response property is deprecated withoutx-sunset.Suggested location:
src/registry/parser/openapi/validate.ts, since both push and validate already call it.