Repository navigation
Conversation
Restructures the Lifecycle Object around the operation-scoped deprecation/sunset model from discussion #5's April 2026+ comments (the root-level, document-wide draft from earlier in the thread is superseded) and places it under `features` on the Operation Object, consistent with the Standardized API Feature (SAF) concept being defined in OAI/OpenAPI-Specification#5310 and #5350. Fills in the Introduction, Relationship to the OpenAPI Specification, Definitions (Lifecycle Object, Sunset Object), a new informative Header Mapping section (field -> Deprecation/Sunset/Link header mapping per RFC 9745, RFC 8594, RFC 8288), Appendix A revision history, and a new informative Appendix B on AI agent/MCP tooling usage. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YAmP3nFaRwCARS7JygrV7r
Align lifecycle.md with SAF framing, using discussion #5 example data
minor changes
…ample - Declare the SAF via the root `features` map (OAS PR #5447) and place the Lifecycle Object in a dedicated Operation Object `lifecycle` field - Add a complete OAS 3.3 example using `externalLinks` from the Docs Links proposal alongside the Lifecycle Object - Fix stale listPets_v2 reference in Appendix B Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Align lifecycle SAF with OAS #5447 features and add external links example
Swap `migration`, `replacement`, and `sunset.policy` for a single `lifecycle.externalLinks` array of External Documentation Objects, per the OAS Docs Links proposal. `kind` is required and uses IANA link relation names (`deprecation`, `successor-version`, `sunset`), so each link maps directly to a `Link` header; other kinds are documentation only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Replace named lifecycle link fields with an externalLinks array
The schema was a stub (`properties: {}` with `additionalProperties: false`)
that rejected every non-empty Lifecycle Object. It now validates the
Lifecycle, Sunset, and External Documentation Objects, requiring `kind` on
each `lifecycle.externalLinks` entry and rejecting the removed `migration`,
`replacement`, and `sunset.policy` fields.
Removes the unused Schema Object `$dynamicAnchor` hook and the matching
spec text, since the Lifecycle Object contains no Schema Objects.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Define the Lifecycle Object schema and add pass/fail tests
Define `deprecated` as the authoritative deprecation signal. Operations with `lifecycle` SHOULD set `deprecated: true`; if `deprecated` is absent or false, tools MUST treat the operation as not deprecated and MUST NOT generate headers or present it as deprecated from the Lifecycle Object. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Make deprecated take precedence over the Lifecycle Object
For consistency with the OAS schema, allow URI references, which are resolved against the document's base URI. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
@karenetheridge thanks for the review — I switched |
spec.openapis.org/oas/v3.3.0.html is not published yet, so the link check fails. Link the SAF section to the v3.3-dev source and the Operation and External Documentation Objects to the latest published OAS. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
pinning this here for review: OAI/OpenAPI-Specification#5585 |
|
another thing that came up during the meeting is that we should get generic tooling vendors and get their opinions on the current shape of the spec, especially for scenarios where the lifecycle information and what shows up at runtime disagree. |
…ement Add the Deprecation, Sunset, and Link headers a server would emit for the complete example, with the Lifecycle Object field each comes from. Add an editor's note that the Lifecycle Object will move under the SAF container field once the OAS defines it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks @baywet, agreed: vendor input on the current shape would be valuable before this settles. To make it concrete, here are the disagreement scenarios I'd suggest putting to them:
For context, the spec currently treats the OAD as the design-time source and the headers as an optional runtime byproduct (see Header Mapping and Relationship to Happy to collect the feedback in a discussion on this repo if that's useful. Are there specific vendors you'd suggest reaching out to? |
handrews
left a comment
There was a problem hiding this comment.
I haven't gotten through all of this (and I am wondering if we could perhaps break this up to make it easier to resolve pieces and make progress?) but I wanted to publish this before tomorrow's call. My feedback is on details, the direction is good.
| **Non-goal.** This SAF does not replace `deprecated: true`, which | ||
| remains the coarse signal tooling already recognizes (for example, to gray out | ||
| an operation in Swagger UI). The Lifecycle Object is additional detail used | ||
| alongside it. |
There was a problem hiding this comment.
In my view, framing like "Non-goal" is more of a proposal sort of thing. Since this is addressed in detail where usage is described, I would just leave it there. Mentioning it in the introduction without context or crosslink is a bit confusing.
There was a problem hiding this comment.
Removed in 65659c4; the Relationship to deprecated section covers it.
| meant to complement — not replace — `deprecated: true` on the same Operation | ||
| Object. |
There was a problem hiding this comment.
I find "complement — not replace" to be a bit vague, but fortunately you have the more precise info available. Based on other text, the Lifecycle Object expands on the meaning of deprecated: true since that is required to be set in order for a Lifecycle Object to be usable.
There was a problem hiding this comment.
Reworded in bd72f5c: the Lifecycle Object "expands on the meaning of deprecated: true: it applies only to an Operation Object that sets deprecated: true", with a link to the Relationship to deprecated section. I'll revisit the exact wording there along with your MUST-error suggestion.
…ion note - Replace "complement — not replace" with a precise statement: the Lifecycle Object expands on `deprecated: true` and applies only when it is set. - Remove the sentence saying the spec requires an OAS version with `externalLinks`; SAFs are 3.3+ anyway, and it implied otherwise. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An Operation Object with `lifecycle` MUST set `deprecated: true`; otherwise the OpenAPI Description is invalid and tools MUST report an error instead of silently ignoring the Lifecycle Object. Future deprecations are announced with `deprecated: true` and a future `date`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
When `lifecycle` is declared in `features`, the Lifecycle Object is the only way to describe `Link` headers with the `deprecation`, `successor-version`, or `sunset` relation, on every operation. A `Link` Header Object in a Response Object MUST NOT describe them, and tools MUST report an error if it does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
From the TDC call, we had some comments on the structure of the document. The fields here come from other existing specifications, but they aren't called out early enough in the document and didn't seem to be mentioned alongside the fields that represent them in the SAF. We're suggesting refactoring to put the related concepts closer together and reference the RFCs before showing the implementation. The links for each of the different objects could be nested with the areas they belong to, for example having externalLinks under the sunset section and the deprecated section rather than relying on the |
paths:
'/foo':
get:
deprecated: true
featureFields:
lifecycle:
deprecation:
date: 'some date'
sunset:
date: 'some other date'
successorLink: 'https://example.com' |
SAF objects go under a `featureFields` container rather than directly on core objects; `features` stays the SAF version map. Move `lifecycle` under the Operation Object's `featureFields` in the text and examples, rename "Operation Object Fields" to "Feature Fields", and replace the provisional-placement editor's note with one noting that `featureFields` is still to be defined by the OAS.
The relationship between the Lifecycle Object and `deprecated: true` is covered in the Relationship to `deprecated` section.
Replace the restated rules on the `features` default and multi-document SAF declarations with a link to the OAS section, so they cannot drift.
Per TDC review, replace the kind-keyed lifecycle.externalLinks with Deprecation and Sunset Objects. Links that map to HTTP link relations are named Link Object fields (deprecation.infoLink, deprecation.successorLink, sunset.policyLink); other resources go in documentation-only externalLinks within each section. Add an HTTP Deprecation and Sunset Signals section introducing the RFCs before the objects, and update the header mapping, examples, schema, and tests.
|
@lornajane @baywet thanks for the structure feedback from the TDC call. I've restructured the document in 44d44a7:
featureFields:
lifecycle:
deprecation:
date: "2025-01-15T00:00:00Z" # Deprecation header
reason: "..."
infoLink: # rel="deprecation"
url: https://docs.example.com/migrate
successorLink: # rel="successor-version"
url: https://api.example.com/v2/openapi.yaml
externalLinks: [...] # documentation only
sunset:
date: "2025-07-01T00:00:00Z" # Sunset header
policyLink: # rel="sunset"
url: https://docs.example.com/sunset-policy
externalLinks: [...] # documentation only
Two choices that differ from the sketch:
|
Rewrite the Scope paragraph to state the rule and the Overlays approach without the decision history. A lifecycle key in the featureFields of any object other than an Operation Object is now invalid, and tools MUST report an error.
|
@handrews Thanks a lot for your help and feedback, but I am tired and I don't want to split this PR. I would much rather get this merged and continue with other PRs. AFAIK, I have done all I can for this SAF PR. |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
|
||
| | Field Name | Type | Description | | ||
| | ---- | ---- | ---- | | ||
| | `date` | `string` (date-time) | **REQUIRED.** The date the deprecation takes or took effect. Maps to the `Deprecation` header. | |
There was a problem hiding this comment.
I think we need to formalize what date-time means here, probably RFC3339 or replacement or so.
There was a problem hiding this comment.
the core spec doesn't define/refer to a date-time format because it doesn't have date-time fields as far as I can remember/find with a quick search.
The only place we "define" this is the formats registry https://spec.openapis.org/registry/format/date-time.html, but that's non normative.
So I think this SAF need to refer to that RFC and clarify the "date-time" fields actually mean RFC3339 date-time
|
Update from the TDC call, consensus that we're on good lines here. It needs some copyediting for wording, help very gratefully received on that (and I'll also try to take a look). |
Summary
This PR brings the Lifecycle Specification in line with the SAF mechanism merged in OAI/OpenAPI-Specification#5447. It builds the Lifecycle Object on the Docs Links proposal, and replaces the stub schema with a real one. It supersedes #15.
SAF framing (operation-scoped, per discussion #5)
Deprecation(RFC 9745),Sunset(RFC 8594), andLinkheaders, and an informative appendix on AI agent / MCP use.Alignment with OAS #5447
featuresmap (features: { security: 1.0.0, lifecycle: 1.0.0 }). The spec notes thatsecuritymust be listed explicitly oncefeaturesis set.lifecyclefield, not in an operation-levelfeatures. This avoids reusing the rootfeaturesname with a different type.Adopting
externalLinks(Docs Links proposal)migration,replacement, andsunset.policyare replaced by a singlelifecycle.externalLinksarray of External Documentation Objects.kindis required on each entry.deprecation,successor-version, andsunsetare IANA link relation names, so each link maps directly toLink: <url>; rel="<kind>". Other kinds (for examplechangelog) are documentation only.lifecycle.externalLinks; general docs stay in the operation's ownexternalLinks.deprecatedtakes precedencedeprecatedis the authoritative signal. An operation withlifecycleSHOULD setdeprecated: true. Ifdeprecatedis absent orfalse, tools MUST treat the operation as not deprecated and ignorelifecycle: no headers, no deprecation annotations.deprecated: truewithoutlifecycleworks as before, so APIs can adopt the SAF gradually.Schema
properties: {}+additionalProperties: false) rejected every non-empty Lifecycle Object. The new schema validates the Lifecycle, Sunset, and External Documentation Objects, and requireskindinlifecycle.externalLinks.Open questions for the SIG
lifecyclethe right name for the Operation Object field?lifecycle: 1.1.0.sunset.date>=date; the compatibility[TODO]is unfilled.Test plan
oai-spec-test tests/schema— 24 passed, 100% schema coverageyarn validate-markdown(not run locally)