Repository navigation
Add shared request and response.headers blocks (refs #257) - #301
Merged
Merged
Conversation
Co-Authored-By: Claude Sonnet 5 <[email protected]>
jimhoyd
force-pushed
the
feat/257-shared-blocks
branch
from
September 20, 2026 15:20
b8f7a95 to
06ca1a2
Compare
jimhoyd
enabled auto-merge (squash)
September 20, 2026 15:21
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refs #257 (does not close it).
Implements the maintainer decision on #257: an optional top-level
sharedmap of namedrequestandresponse.headersblocks that a route selects withuse: <name>, modeled onpolicies.profile. Anchors, aliases and merge keys stay rejected.Design points settled (documented in docs/SPECIFICATION.md, Shared blocks):
requestorresponsekey wins as a whole block; no deep merge.useis removed, so the route hash and every downstream consumer see the resolved route. Note:routesinventory output does not print headers or request policy, so the hash and compiled route are where the resolved result shows.response.headersnaming a runtime-owned header fails (the reserved set is now exported from http-policy.ts and reused). Includes mayusebut not declareshared.requestandresponse.headersfor now;sandboxReason,sandbox,policiesand other defaults left out.Also: schema (request/response extracted to shared $defs), YAML reference and llms-full.txt regenerated, new examples/shared-blocks with fixtures, test/shared-blocks.test.ts, #257 row removed from docs/OPEN-DECISIONS.md.
npm run verifyandnpm run check:docspass.Evidence note per the issue: n=1 on one small Todo app; explicit maintainer decision to proceed.
🤖 Generated with Claude Code