feat(plugins): (P1-B) versioned insomnia.permissions JSON schema - #10352
Draft
jackkav wants to merge 1 commit into
Draft
feat(plugins): (P1-B) versioned insomnia.permissions JSON schema#10352jackkav wants to merge 1 commit into
jackkav wants to merge 1 commit into
Conversation
…+ parser lockstep test
✅ Circular References ReportGenerated at: 2026-08-07T16:45:28.004Z Summary
Click to view all circular references in PR (9)Click to view all circular references in base branch (9)Analysis✅ No Change: This PR does not introduce or remove any circular references. This report was generated automatically by comparing against the |
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.
P1-B (start): versioned JSON schema for
insomnia.permissionsFirst increment of the P1-B "sandboxing refinements" tier — formalizing the manifest contract. Draft to iterate on.
Adds a checked-in, version-stamped JSON Schema (
permissions-schema.ts) as the canonical, exportable contract for theinsomnia.permissionsblock — something plugin authors, editor tooling, and docs can point at as one source of truth.Deliberately additive, zero behavior change: the runtime validator (
parsePluginPermissions) stays the lenient "never throw, degrade-to-baseline-with-a-warning" parser it is today. A lockstep test (permissions-schema.test.ts) asserts the invariant that a presentpermissionsblock is schema-valid iff the parser accepts it with zero warnings, across a case table (valid, empty, dups, unknown names, unknown keys, non-array axis, non-string/empty entries, non-object permissions). So the formal schema and the runtime parser can't drift apart.The schema matches the parser's intentional leniencies (documented inline): unknown module/capability names allowed, duplicates allowed, unknown keys inside
permissionsignored.Validated:
tscclean, eslint clean, 22 tests green (new cross-check + existing parser suite, no regression).Remaining P1-B items (not in this PR)
elevatedgrants — record when a plugin is elevated/de-elevated (needs a persistence decision for the audit trail).🤖 Authored by Claude Code