Skip to content

Add JSON:API v1.1 support as an additive overlay#79

Draft
arjenblokzijl wants to merge 2 commits into
jmlue42:mainfrom
onlineplasticsgroup:feature/jsonapi-1.1-overlay
Draft

Add JSON:API v1.1 support as an additive overlay#79
arjenblokzijl wants to merge 2 commits into
jmlue42:mainfrom
onlineplasticsgroup:feature/jsonapi-1.1-overlay

Conversation

@arjenblokzijl

@arjenblokzijl arjenblokzijl commented Jun 23, 2026

Copy link
Copy Markdown

Additive v1.1 support via an overlay, the v1.0 ruleset is unchanged, so it's fully backward compatible. Spectral does not inherit aliases through extends, so the alias block is duplicated into the overlay (and rules are not). Flagged this with a comment in the file.

Introduces jsonapi-1.1.yml, which extends the untouched v1.0 ruleset
(.spectral.yml) and only redefines the rules that changed in JSON:API
v1.1: the ext/profile media type parameters, expanded links object
members (rel, describedby, title, type, hreflang), the jsonapi object
ext/profile/meta members, and the lid local identifier on resource
objects and resource identifier objects.

The v1.0 ruleset is unchanged, so existing consumers are unaffected.
Spectral does not inherit aliases through extends, so the alias block
is duplicated into the overlay (rules are not).

Adds an examples/valid-1.1 fixture exercising the new features and a
test:1.1 script; npm test now lints both rulesets. Bumps to 1.1.0.
Note both v1.0 (.spectral.yml) and v1.1 (jsonapi-1.1.yml) rulesets,
how to select one per API version, and that the v1.1 file is an
additive overlay on top of v1.0.
@arjenblokzijl arjenblokzijl changed the title Feature/jsonapi 1.1 overlay Add JSON:API v1.1 support as an additive overlay Jun 23, 2026
@arjenblokzijl arjenblokzijl marked this pull request as draft June 23, 2026 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant