@orygn/opa-mcp 0.1.7 → 0.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (144) hide show
  1. package/CHANGELOG.md +121 -1
  2. package/README.md +31 -27
  3. package/dist/constants.d.ts +1 -1
  4. package/dist/constants.js +1 -1
  5. package/dist/lib/opa-cli.d.ts +68 -15
  6. package/dist/lib/opa-cli.d.ts.map +1 -1
  7. package/dist/lib/opa-cli.js +75 -31
  8. package/dist/lib/opa-cli.js.map +1 -1
  9. package/dist/lib/opa-client.d.ts +5 -0
  10. package/dist/lib/opa-client.d.ts.map +1 -1
  11. package/dist/lib/opa-client.js +12 -1
  12. package/dist/lib/opa-client.js.map +1 -1
  13. package/dist/lib/regal-cli.d.ts +4 -4
  14. package/dist/lib/regal-cli.d.ts.map +1 -1
  15. package/dist/lib/regal-cli.js +10 -8
  16. package/dist/lib/regal-cli.js.map +1 -1
  17. package/dist/lib/subprocess.d.ts +4 -0
  18. package/dist/lib/subprocess.d.ts.map +1 -1
  19. package/dist/lib/subprocess.js +24 -3
  20. package/dist/lib/subprocess.js.map +1 -1
  21. package/dist/lib/tool-helpers.d.ts +13 -0
  22. package/dist/lib/tool-helpers.d.ts.map +1 -1
  23. package/dist/lib/tool-helpers.js +28 -0
  24. package/dist/lib/tool-helpers.js.map +1 -1
  25. package/dist/server.d.ts.map +1 -1
  26. package/dist/server.js +2 -3
  27. package/dist/server.js.map +1 -1
  28. package/dist/tools/authoring/capabilities.d.ts.map +1 -1
  29. package/dist/tools/authoring/capabilities.js +8 -2
  30. package/dist/tools/authoring/capabilities.js.map +1 -1
  31. package/dist/tools/authoring/check.d.ts.map +1 -1
  32. package/dist/tools/authoring/check.js +16 -4
  33. package/dist/tools/authoring/check.js.map +1 -1
  34. package/dist/tools/authoring/deps.d.ts.map +1 -1
  35. package/dist/tools/authoring/deps.js +8 -2
  36. package/dist/tools/authoring/deps.js.map +1 -1
  37. package/dist/tools/authoring/format.d.ts.map +1 -1
  38. package/dist/tools/authoring/format.js +8 -2
  39. package/dist/tools/authoring/format.js.map +1 -1
  40. package/dist/tools/authoring/index.d.ts.map +1 -1
  41. package/dist/tools/authoring/index.js +2 -0
  42. package/dist/tools/authoring/index.js.map +1 -1
  43. package/dist/tools/authoring/inspect.d.ts.map +1 -1
  44. package/dist/tools/authoring/inspect.js +8 -2
  45. package/dist/tools/authoring/inspect.js.map +1 -1
  46. package/dist/tools/authoring/lint.d.ts.map +1 -1
  47. package/dist/tools/authoring/lint.js +11 -12
  48. package/dist/tools/authoring/lint.js.map +1 -1
  49. package/dist/tools/authoring/migrate-v1.d.ts +26 -0
  50. package/dist/tools/authoring/migrate-v1.d.ts.map +1 -0
  51. package/dist/tools/authoring/migrate-v1.js +78 -0
  52. package/dist/tools/authoring/migrate-v1.js.map +1 -0
  53. package/dist/tools/authoring/parse.d.ts.map +1 -1
  54. package/dist/tools/authoring/parse.js +8 -2
  55. package/dist/tools/authoring/parse.js.map +1 -1
  56. package/dist/tools/bundles/build.d.ts.map +1 -1
  57. package/dist/tools/bundles/build.js +8 -2
  58. package/dist/tools/bundles/build.js.map +1 -1
  59. package/dist/tools/bundles/index.d.ts +2 -2
  60. package/dist/tools/bundles/index.d.ts.map +1 -1
  61. package/dist/tools/bundles/index.js +2 -0
  62. package/dist/tools/bundles/index.js.map +1 -1
  63. package/dist/tools/bundles/sign.d.ts.map +1 -1
  64. package/dist/tools/bundles/sign.js +8 -2
  65. package/dist/tools/bundles/sign.js.map +1 -1
  66. package/dist/tools/bundles/verify.d.ts +8 -0
  67. package/dist/tools/bundles/verify.d.ts.map +1 -0
  68. package/dist/tools/bundles/verify.js +73 -0
  69. package/dist/tools/bundles/verify.js.map +1 -0
  70. package/dist/tools/evaluation/_shared.d.ts +1 -1
  71. package/dist/tools/evaluation/_shared.d.ts.map +1 -1
  72. package/dist/tools/evaluation/_shared.js +2 -2
  73. package/dist/tools/evaluation/_shared.js.map +1 -1
  74. package/dist/tools/evaluation/bench.d.ts.map +1 -1
  75. package/dist/tools/evaluation/bench.js +8 -2
  76. package/dist/tools/evaluation/bench.js.map +1 -1
  77. package/dist/tools/evaluation/compile.d.ts.map +1 -1
  78. package/dist/tools/evaluation/compile.js +8 -2
  79. package/dist/tools/evaluation/compile.js.map +1 -1
  80. package/dist/tools/evaluation/eval.d.ts.map +1 -1
  81. package/dist/tools/evaluation/eval.js +32 -8
  82. package/dist/tools/evaluation/eval.js.map +1 -1
  83. package/dist/tools/evaluation/exec.d.ts +23 -0
  84. package/dist/tools/evaluation/exec.d.ts.map +1 -0
  85. package/dist/tools/evaluation/exec.js +105 -0
  86. package/dist/tools/evaluation/exec.js.map +1 -0
  87. package/dist/tools/evaluation/index.d.ts +1 -1
  88. package/dist/tools/evaluation/index.d.ts.map +1 -1
  89. package/dist/tools/evaluation/index.js +2 -0
  90. package/dist/tools/evaluation/index.js.map +1 -1
  91. package/dist/tools/evaluation/test.d.ts.map +1 -1
  92. package/dist/tools/evaluation/test.js +8 -2
  93. package/dist/tools/evaluation/test.js.map +1 -1
  94. package/dist/tools/helpers/coverage-gaps.d.ts.map +1 -1
  95. package/dist/tools/helpers/coverage-gaps.js +8 -2
  96. package/dist/tools/helpers/coverage-gaps.js.map +1 -1
  97. package/dist/tools/helpers/describe-policy.d.ts.map +1 -1
  98. package/dist/tools/helpers/describe-policy.js +8 -2
  99. package/dist/tools/helpers/describe-policy.js.map +1 -1
  100. package/dist/tools/helpers/explain-decision.d.ts.map +1 -1
  101. package/dist/tools/helpers/explain-decision.js +8 -2
  102. package/dist/tools/helpers/explain-decision.js.map +1 -1
  103. package/dist/tools/helpers/fix.d.ts.map +1 -1
  104. package/dist/tools/helpers/fix.js +8 -2
  105. package/dist/tools/helpers/fix.js.map +1 -1
  106. package/dist/tools/helpers/format-write.d.ts.map +1 -1
  107. package/dist/tools/helpers/format-write.js +9 -3
  108. package/dist/tools/helpers/format-write.js.map +1 -1
  109. package/dist/tools/helpers/generate-test-skeleton.d.ts.map +1 -1
  110. package/dist/tools/helpers/generate-test-skeleton.js +8 -2
  111. package/dist/tools/helpers/generate-test-skeleton.js.map +1 -1
  112. package/dist/tools/helpers/infer-input-schema.d.ts.map +1 -1
  113. package/dist/tools/helpers/infer-input-schema.js +9 -3
  114. package/dist/tools/helpers/infer-input-schema.js.map +1 -1
  115. package/dist/tools/helpers/policy-diff.d.ts.map +1 -1
  116. package/dist/tools/helpers/policy-diff.js +11 -2
  117. package/dist/tools/helpers/policy-diff.js.map +1 -1
  118. package/dist/tools/helpers/security-audit.d.ts.map +1 -1
  119. package/dist/tools/helpers/security-audit.js +8 -2
  120. package/dist/tools/helpers/security-audit.js.map +1 -1
  121. package/dist/tools/helpers/suggest-fix.d.ts.map +1 -1
  122. package/dist/tools/helpers/suggest-fix.js +6 -0
  123. package/dist/tools/helpers/suggest-fix.js.map +1 -1
  124. package/dist/tools/meta/server-info.d.ts.map +1 -1
  125. package/dist/tools/meta/server-info.js +9 -3
  126. package/dist/tools/meta/server-info.js.map +1 -1
  127. package/dist/tools/server-management/_shared.d.ts.map +1 -1
  128. package/dist/tools/server-management/_shared.js +4 -1
  129. package/dist/tools/server-management/_shared.js.map +1 -1
  130. package/dist/tools/server-management/data.d.ts.map +1 -1
  131. package/dist/tools/server-management/data.js +57 -3
  132. package/dist/tools/server-management/data.js.map +1 -1
  133. package/dist/tools/server-management/decisions.d.ts.map +1 -1
  134. package/dist/tools/server-management/decisions.js +16 -2
  135. package/dist/tools/server-management/decisions.js.map +1 -1
  136. package/dist/tools/server-management/policies.d.ts.map +1 -1
  137. package/dist/tools/server-management/policies.js +32 -4
  138. package/dist/tools/server-management/policies.js.map +1 -1
  139. package/dist/tools/server-management/status.d.ts.map +1 -1
  140. package/dist/tools/server-management/status.js +24 -4
  141. package/dist/tools/server-management/status.js.map +1 -1
  142. package/dist/types.d.ts +1 -1
  143. package/dist/types.d.ts.map +1 -1
  144. package/package.json +2 -2
package/CHANGELOG.md CHANGED
@@ -17,6 +17,123 @@ not part of the public surface and may change in minor releases.
17
17
 
18
18
  ## [Unreleased]
19
19
 
20
+ ## [0.1.9] - 2026-05-21
21
+
22
+ ### Added
23
+
24
+ - **AbortSignal cancellation** -- all 43 tool handlers now wire the MCP SDK's
25
+ `extra.signal` into every subprocess spawn and OPA HTTP request. When a client
26
+ sends `notifications/cancelled`, in-flight work is actually terminated:
27
+ subprocess receives SIGTERM followed by SIGKILL escalation after 2 seconds;
28
+ HTTP fetches are aborted via `AbortSignal.any()` combining the existing
29
+ per-request timeout with the external client signal.
30
+
31
+ - **`CANCELLED` error code** -- added to `ToolErrorCode`. Returned to the caller
32
+ when a tool is interrupted mid-flight by client cancellation, rather than
33
+ surfacing a misleading `TIMEOUT` or `OPA_BINARY_NOT_FOUND` code.
34
+
35
+ - **`OpaCancelledError`** -- new error class in `OpaClient`. Thrown when a
36
+ fetch aborts because the client signal fired (not a network failure), so
37
+ `mapOpaClientError` can map it precisely to `CANCELLED`.
38
+
39
+ - **Tool annotations, instructions, and path sanitization (MCP spec 2025-11-25)**
40
+ -- all 43 tools now declare `readOnlyHint`, `destructiveHint`, `idempotentHint`,
41
+ and `openWorldHint` in their `annotations` block per the MCP spec. Server
42
+ registers `instructions` at startup describing the tool set. All file path
43
+ arguments validated through a hardened `validatePath` helper that normalises
44
+ Windows drive-letter casing and resolves symlinks before allow-list comparison,
45
+ closing a bypass that existed when a symlink target escaped the allowed root.
46
+
47
+ ### Changed
48
+
49
+ - **`@modelcontextprotocol/sdk` pinned to `^1.29.0`** -- the minimum version that
50
+ exposes `annotations` on `RegisteredTool` and passes `extra.signal` to handlers.
51
+
52
+ ### Internal
53
+
54
+ - `subprocess.ts`: `SpawnResult` gains `aborted: boolean`; `SpawnOptions` gains
55
+ `signal?: AbortSignal`. Early-return path if signal is pre-aborted; abort
56
+ listener shares the SIGTERM->SIGKILL escalation helper with the timeout path.
57
+ - `tool-helpers.ts`: `mapSubprocessFailure` checks `result.aborted` before
58
+ `exitCode === null` so cancellation takes priority over binary-not-found.
59
+ - Tests: all mock `SpawnResult` objects updated to include `aborted: false`;
60
+ `callTool` helper passes `{ signal }` as second argument; two new deterministic
61
+ abort path tests in `subprocess.test.ts`.
62
+
63
+ ## [0.1.8] - 2026-05-21
64
+
65
+ ### Added
66
+
67
+ - **`opa_delete_data`** -- removes a document from OPA's data store at the given
68
+ path (`DELETE /v1/data/{path}`). Accepts the same dotted or slash path forms as
69
+ `opa_get_data`, `opa_put_data`, and `opa_patch_data`. A missing path returns the
70
+ new `DATA_NOT_FOUND` error code; percent-encoded traversal attempts are rejected
71
+ by the shared `parseOpaDataPath` guard with `INVALID_INPUT` before any request is
72
+ issued. Root-path deletion is intentionally excluded -- the path must be at least
73
+ one segment deep.
74
+
75
+ - **`DATA_NOT_FOUND` error code** -- added to `ToolErrorCode`. Returned when a
76
+ `DELETE /v1/data/{path}` (or any future data-path operation) receives a 404 from
77
+ OPA. More specific than `UNKNOWN_ERROR` and symmetrical with the existing
78
+ `POLICY_NOT_FOUND` code.
79
+
80
+ - **`opa_bundle_verify`** -- verifies the signature of a signed OPA bundle using
81
+ `opa eval --bundle --verification-key`. Returns `{ bundle, verified: true }` on
82
+ success. Accepts optional `verificationKeyId`, `signingAlg`, and `scope`. Both
83
+ `bundle` and `verificationKey` paths are validated against the allow-list before
84
+ any subprocess call.
85
+
86
+ - **`rego_migrate_v1`** -- migrates Rego v0 source to v1 syntax using a two-phase
87
+ approach: `opa fmt --rego-v1` rewrites reserved keywords and adds
88
+ `import rego.v1`; `opa check --v1-compatible` then validates the result. Returns
89
+ `{ original, migrated, changed, valid, errors }`. If `fmt` fails the tool returns
90
+ `INVALID_REGO`; if `check` finds remaining semantic issues `valid` is `false` but
91
+ `ok` is still `true` so the caller can inspect both the diff and any remaining
92
+ issues.
93
+
94
+ - **`opa_exec`** -- batch-evaluates a single decision against multiple input files
95
+ using `opa exec --format=json`. Returns `{ results, count, successCount, errorCount }`
96
+ where each result entry carries the input path and either the decision value or an
97
+ error message. Accepts `bundle` or `dataPaths` as the policy source (mutually
98
+ exclusive). All three path types (input, bundle, data) are validated against the
99
+ allow-list.
100
+
101
+ ### Tests
102
+
103
+ - 10 new unit tests for `opa_delete_data` covering: correct URL construction for
104
+ dotted, slash, and `data.`-prefixed paths; `{ path, deleted: true }` response
105
+ shape; bodyless request with no `Content-Type` header; bearer token forwarding;
106
+ 404 mapped to `DATA_NOT_FOUND` with status in details; connection failure mapped to
107
+ `OPA_UNREACHABLE`; 401 mapped to `OPA_AUTH_FAILED`; 5xx mapped to `UNKNOWN_ERROR`;
108
+ and two traversal-rejection cases (`%2e%2e` and double `%2e%2e/%2e%2e`).
109
+
110
+ - 9 new unit tests for `opa_bundle_verify` covering: correct argv construction;
111
+ optional key-id, alg, and scope flags; `verified: true` response; invalid bundle
112
+ mapped to `INVALID_BUNDLE`; binary missing mapped to `OPA_BINARY_NOT_FOUND`;
113
+ timeout mapped to `SUBPROCESS_TIMEOUT`; path-not-found and path-not-allowed.
114
+
115
+ - 10 new unit tests for `rego_migrate_v1` covering: two-phase mock call sequence;
116
+ correct `--rego-v1` and `--v1-compatible` flags; `changed` flag; errors array;
117
+ `ok: true` with `valid: false` when check finds issues; short-circuit to
118
+ `INVALID_REGO` when fmt fails.
119
+
120
+ - 12 new unit tests for `opa_exec` covering: correct argv and flags; mutually
121
+ exclusive `bundle`+`dataPaths` guard; count/successCount/errorCount derivation;
122
+ mixed success/error results; binary missing; timeout; path validation for all
123
+ three path types.
124
+
125
+ - Tool count assertions updated to 43 across `server.test.ts`,
126
+ `tests/integration/protocol.test.ts`, and `tests/integration/distribution.test.ts`.
127
+
128
+ ### CI
129
+
130
+ - Added Smithery publish step to release workflow so the Smithery listing is
131
+ updated automatically on every release.
132
+
133
+ - Updated Node.js Docker base image from `node:20-alpine` to `node:26-alpine`.
134
+
135
+ - Updated `actions/setup-node` from v4 to v6 in CI and release workflows.
136
+
20
137
  ## [0.1.7] - 2026-05-21
21
138
 
22
139
  ### Fixed
@@ -440,7 +557,10 @@ wrappers end-to-end. CI matrix: Ubuntu, macOS, and Windows on Node
440
557
  20 and 22, plus CodeQL security scanning and weekly Dependabot updates
441
558
  for npm, GitHub Actions, and Docker base images.
442
559
 
443
- [Unreleased]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.6...HEAD
560
+ [Unreleased]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.9...HEAD
561
+ [0.1.9]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.8...v0.1.9
562
+ [0.1.8]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.7...v0.1.8
563
+ [0.1.7]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.6...v0.1.7
444
564
  [0.1.6]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.5...v0.1.6
445
565
  [0.1.5]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.4...v0.1.5
446
566
  [0.1.4]: https://github.com/OrygnsCode/opa-mcp-server/compare/v0.1.3...v0.1.4
package/README.md CHANGED
@@ -18,10 +18,10 @@ environment.
18
18
  +--------------------+ MCP / stdio +-----------------+ spawn / HTTP +------------------+
19
19
  | Claude · Cursor · | ------------> | @orygn/opa-mcp | -------------> | opa · regal · |
20
20
  | VS Code · ... | <------------ | | <------------- | OPA REST API |
21
- +--------------------+ 39 tools +-----------------+ +------------------+
21
+ +--------------------+ 43 tools +-----------------+ +------------------+
22
22
  ```
23
23
 
24
- > **Status:** v0.1.5. Tool surface, error codes, and
24
+ > **Status:** v0.1.8. Tool surface, error codes, and
25
25
  > environment variables follow [SemVer](https://semver.org/) from
26
26
  > v0.1.0 forward.
27
27
 
@@ -264,7 +264,7 @@ Every tool returns a JSON envelope:
264
264
  Stable error codes: `INVALID_INPUT`, `INVALID_REGO`, `INVALID_BUNDLE`,
265
265
  `EVAL_ERROR`, `OPA_BINARY_NOT_FOUND`, `REGAL_NOT_FOUND`,
266
266
  `REGAL_VERSION_TOO_OLD`, `OPA_UNREACHABLE`, `OPA_AUTH_FAILED`,
267
- `POLICY_NOT_FOUND`, `PATH_NOT_ALLOWED`, `PATH_NOT_FOUND`,
267
+ `POLICY_NOT_FOUND`, `DATA_NOT_FOUND`, `PATH_NOT_ALLOWED`, `PATH_NOT_FOUND`,
268
268
  `DEPENDENCY_CONFLICT`, `NO_TESTS_FOUND`, `HTTP_SEND_BLOCKED`, `TIMEOUT`,
269
269
  `UNKNOWN_ERROR`.
270
270
 
@@ -274,15 +274,16 @@ Operate on Rego source code without needing a running OPA server. Wrap
274
274
  `opa fmt`, `opa parse`, `opa check`, `opa inspect`, `opa capabilities`,
275
275
  `opa deps`, and `regal`.
276
276
 
277
- | Tool | What it does |
278
- | ------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
279
- | `rego_format` | Format Rego source. Wraps `opa fmt`. Idempotent. |
280
- | `rego_check` | Type-check and validate Rego. Wraps `opa check`. |
281
- | `rego_lint` | Run Regal across a file or directory. Returns findings grouped by category. **Requires `regal` on `PATH` or `REGAL_BINARY` set.** |
282
- | `rego_parse_ast` | Parse Rego to AST JSON. Wraps `opa parse`. |
283
- | `rego_inspect` | Inspect a bundle or directory: packages, rules, annotations. Wraps `opa inspect`. |
284
- | `rego_capabilities` | Return the capabilities (built-ins, future keywords) understood by the bundled OPA. |
285
- | `rego_deps` | Static dependency analysis: rule-level data references and cross-package calls. |
277
+ | Tool | What it does |
278
+ | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
279
+ | `rego_format` | Format Rego source. Wraps `opa fmt`. Idempotent. |
280
+ | `rego_check` | Type-check and validate Rego. Wraps `opa check`. |
281
+ | `rego_lint` | Run Regal across a file or directory. Returns findings grouped by category. **Requires `regal` on `PATH` or `REGAL_BINARY` set.** |
282
+ | `rego_parse_ast` | Parse Rego to AST JSON. Wraps `opa parse`. |
283
+ | `rego_inspect` | Inspect a bundle or directory: packages, rules, annotations. Wraps `opa inspect`. |
284
+ | `rego_capabilities` | Return the capabilities (built-ins, future keywords) understood by the bundled OPA. |
285
+ | `rego_deps` | Static dependency analysis: rule-level data references and cross-package calls. |
286
+ | `rego_migrate_v1` | Migrate Rego v0 source to v1 syntax. Runs `opa fmt --rego-v1` then validates with `opa check --v1-compatible`. Returns `{ original, migrated, changed, valid, errors }`. |
286
287
 
287
288
  #### Featured: `rego_format`
288
289
 
@@ -332,15 +333,16 @@ Operate on Rego source code without needing a running OPA server. Wrap
332
333
  Run a query against a policy and input. Wrap `opa eval`, `opa test`, and
333
334
  `opa bench`.
334
335
 
335
- | Tool | What it does |
336
- | ------------------------- | ------------------------------------------------------------------------------------ |
337
- | `rego_eval` | Evaluate a query against a policy and input. The bread-and-butter tool. |
338
- | `rego_eval_with_explain` | Evaluate with `--explain=full` and return a structured trace. |
339
- | `rego_eval_with_profile` | Evaluate with `--profile` and return per-rule timing and evaluation counts. |
340
- | `rego_eval_with_coverage` | Evaluate with `--coverage` and return per-line coverage. |
341
- | `rego_test` | Run `opa test` over a directory. Returns pass/fail per test, with optional coverage. |
342
- | `rego_bench` | Run `opa bench` and return statistical timing data. |
343
- | `rego_compile_query` | Partially evaluate a query against a policy. |
336
+ | Tool | What it does |
337
+ | ------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
338
+ | `rego_eval` | Evaluate a query against a policy and input. The bread-and-butter tool. |
339
+ | `rego_eval_with_explain` | Evaluate with `--explain=full` and return a structured trace. |
340
+ | `rego_eval_with_profile` | Evaluate with `--profile` and return per-rule timing and evaluation counts. |
341
+ | `rego_eval_with_coverage` | Evaluate with `--coverage` and return per-line coverage. |
342
+ | `rego_test` | Run `opa test` over a directory. Returns pass/fail per test, with optional coverage. |
343
+ | `rego_bench` | Run `opa bench` and return statistical timing data. |
344
+ | `rego_compile_query` | Partially evaluate a query against a policy. |
345
+ | `opa_exec` | Batch-evaluate a decision against multiple input files. Returns per-file results with `successCount` and `errorCount`. |
344
346
 
345
347
  #### Featured: `rego_eval`
346
348
 
@@ -365,10 +367,11 @@ Run a query against a policy and input. Wrap `opa eval`, `opa test`, and
365
367
 
366
368
  Package and sign deployable bundles. Wrap `opa build` and `opa sign`.
367
369
 
368
- | Tool | What it does |
369
- | ------------------ | ------------------------------------------------------------------------------------- |
370
- | `opa_bundle_build` | Build a `.tar.gz` bundle from a policy directory. Supports `optimize` and `revision`. |
371
- | `opa_bundle_sign` | Sign a bundle with a private key. Returns `.signatures.json` content. |
370
+ | Tool | What it does |
371
+ | ------------------- | ------------------------------------------------------------------------------------------------- |
372
+ | `opa_bundle_build` | Build a `.tar.gz` bundle from a policy directory. Supports `optimize` and `revision`. |
373
+ | `opa_bundle_sign` | Sign a bundle with a private key. Returns `.signatures.json` content. |
374
+ | `opa_bundle_verify` | Verify the signature of a signed bundle using a public key. Returns `{ bundle, verified: true }`. |
372
375
 
373
376
  ### Category D: OPA server management
374
377
 
@@ -384,6 +387,7 @@ point at a reachable server.
384
387
  | `opa_get_data` | Read a path from the data hierarchy. |
385
388
  | `opa_put_data` | Write to a path in the data hierarchy. |
386
389
  | `opa_patch_data` | Apply a JSON Patch to the data hierarchy. |
390
+ | `opa_delete_data` | Delete a document from the data hierarchy. |
387
391
  | `opa_query_decision` | POST to a `/v1/data/...` decision endpoint with input. |
388
392
  | `opa_compile_query` | Partially evaluate a query against the running server. |
389
393
  | `opa_health` | Liveness / readiness check. |
@@ -416,7 +420,7 @@ the tasks agents are actually asked to do.
416
420
 
417
421
  ## Prompts
418
422
 
419
- Three [MCP prompts](https://modelcontextprotocol.io/specification/server/prompts)
423
+ Three [MCP prompts](https://modelcontextprotocol.io/specification/2025-11-25/server/prompts)
420
424
  ship with the server. Clients surface them as slash commands or workflow
421
425
  templates.
422
426
 
@@ -428,7 +432,7 @@ templates.
428
432
 
429
433
  ## Resources
430
434
 
431
- Three [MCP resources](https://modelcontextprotocol.io/specification/server/resources)
435
+ Three [MCP resources](https://modelcontextprotocol.io/specification/2025-11-25/server/resources)
432
436
  expose curated reference data the agent can read at any time.
433
437
 
434
438
  | Resource URI | What's there |
@@ -4,5 +4,5 @@
4
4
  * (server.ts -> tools -> meta -> server.ts).
5
5
  */
6
6
  export declare const SERVER_NAME = "orygn-opa-mcp";
7
- export declare const SERVER_VERSION = "0.1.7";
7
+ export declare const SERVER_VERSION = "0.1.9";
8
8
  //# sourceMappingURL=constants.d.ts.map
package/dist/constants.js CHANGED
@@ -4,5 +4,5 @@
4
4
  * (server.ts -> tools -> meta -> server.ts).
5
5
  */
6
6
  export const SERVER_NAME = 'orygn-opa-mcp';
7
- export const SERVER_VERSION = '0.1.7';
7
+ export const SERVER_VERSION = '0.1.9';
8
8
  //# sourceMappingURL=constants.js.map
@@ -4,6 +4,8 @@ import { type SpawnResult } from './subprocess.js';
4
4
  export interface FmtInput {
5
5
  /** Rego source code to format. */
6
6
  source: string;
7
+ /** Format for compatibility with both Rego v1 and the current OPA version (`opa fmt --rego-v1`). */
8
+ regoV1?: boolean;
7
9
  }
8
10
  /** Input for `opa fmt --list` / `opa fmt --write` (file-based formatting). */
9
11
  export interface FmtWriteInput {
@@ -28,6 +30,10 @@ export interface CheckInput {
28
30
  strict?: boolean;
29
31
  /** Schema directory for input/data validation. */
30
32
  schemaDir?: string;
33
+ /** Opt-in to OPA v1.0-compatible behaviors (`opa check --v1-compatible`). */
34
+ v1Compatible?: boolean;
35
+ /** Opt-in to OPA behaviors prior to the v1.0 release (`opa check --v0-compatible`). */
36
+ v0Compatible?: boolean;
31
37
  }
32
38
  /** Input for `opa parse`. */
33
39
  export interface ParseInput {
@@ -146,6 +152,39 @@ export interface SignInput {
146
152
  /** Path to a claims file (extra signed claims). */
147
153
  claimsFile?: string;
148
154
  }
155
+ /** Input for `opa exec` -- batch evaluation against multiple input files. */
156
+ export interface ExecInput {
157
+ /** One or more input file paths (JSON/YAML) or directories to evaluate. */
158
+ inputPaths: string[];
159
+ /** The policy decision (entrypoint) to evaluate for each input, e.g. `data.authz.allow`. */
160
+ decision: string;
161
+ /** Load path as a bundle file or root directory. Mutually exclusive with `dataPaths`. */
162
+ bundle?: string;
163
+ /** Policy/data file or directory paths to load. Mutually exclusive with `bundle`. */
164
+ dataPaths?: string[];
165
+ }
166
+ /** Input for bundle signature verification via `opa eval --bundle`. */
167
+ export interface BundleVerifyInput {
168
+ /** Path to the signed bundle directory or `.tar.gz` archive. */
169
+ bundle: string;
170
+ /**
171
+ * Path to the PEM file containing the public key (RSA/ECDSA) or the
172
+ * HMAC secret file used to verify the bundle signature.
173
+ */
174
+ verificationKey: string;
175
+ /**
176
+ * Key ID that must match the `keyid` claim in the bundle signature.
177
+ * Required when the bundle was signed with `--public-key-id`.
178
+ */
179
+ verificationKeyId?: string;
180
+ /** Signing algorithm used when the bundle was signed (e.g. `RS256`, `HS256`). */
181
+ signingAlg?: string;
182
+ /**
183
+ * Expected `scope` value in the bundle signature. Required when the
184
+ * bundle was signed with `--scope`.
185
+ */
186
+ scope?: string;
187
+ }
149
188
  /**
150
189
  * Wrapper around the local `opa` binary.
151
190
  *
@@ -162,13 +201,13 @@ export declare class OpaCli {
162
201
  * Verify the binary is present and report its version.
163
202
  * Returns null if the binary is unreachable or output is malformed.
164
203
  */
165
- version(): Promise<string | null>;
204
+ version(signal?: AbortSignal): Promise<string | null>;
166
205
  /**
167
206
  * Format Rego source. Stdout contains the formatted output. Reports
168
207
  * `exitCode: 0` even when no changes are needed -- callers compare
169
208
  * input vs output to detect a no-op.
170
209
  */
171
- fmt(input: FmtInput): Promise<SpawnResult>;
210
+ fmt(input: FmtInput, signal?: AbortSignal): Promise<SpawnResult>;
172
211
  /**
173
212
  * List files that would be reformatted. Stdout is one absolute path per
174
213
  * line for each file that is not already canonical. Exit 0 on success,
@@ -177,12 +216,12 @@ export declare class OpaCli {
177
216
  * NOTE: --list and --write are mutually exclusive in OPA: passing both
178
217
  * suppresses the write. Always use separate fmtList + fmtWrite calls.
179
218
  */
180
- fmtList(input: FmtWriteInput): Promise<SpawnResult>;
219
+ fmtList(input: FmtWriteInput, signal?: AbortSignal): Promise<SpawnResult>;
181
220
  /**
182
221
  * Overwrite each file with its canonically formatted version. Exit 0 on
183
222
  * success, non-zero (exit 2) if any file cannot be parsed.
184
223
  */
185
- fmtWrite(input: FmtWriteInput): Promise<SpawnResult>;
224
+ fmtWrite(input: FmtWriteInput, signal?: AbortSignal): Promise<SpawnResult>;
186
225
  /**
187
226
  * Type-check Rego. Returns `exitCode: 0` and empty `stdout` when the
188
227
  * policy is valid. On failure, `exitCode` is non-zero and the JSON
@@ -191,55 +230,69 @@ export declare class OpaCli {
191
230
  * diagnostics). Either inline `source` or one or more `paths` must be
192
231
  * provided.
193
232
  */
194
- check(input: CheckInput): Promise<SpawnResult>;
233
+ check(input: CheckInput, signal?: AbortSignal): Promise<SpawnResult>;
195
234
  /**
196
235
  * Parse Rego source to a JSON AST. Stdout is the AST as JSON.
197
236
  */
198
- parse(input: ParseInput): Promise<SpawnResult>;
237
+ parse(input: ParseInput, signal?: AbortSignal): Promise<SpawnResult>;
199
238
  /**
200
239
  * Inspect a bundle, directory, or single Rego file. Returns its
201
240
  * packages, namespaces, manifest, and annotations as JSON on stdout.
202
241
  */
203
- inspect(input: InspectInput): Promise<SpawnResult>;
242
+ inspect(input: InspectInput, signal?: AbortSignal): Promise<SpawnResult>;
204
243
  /**
205
244
  * Print available capabilities. With `current=true`, prints the
206
245
  * capabilities of the running OPA. With a `version`, prints those of
207
246
  * a specific named version. Without either, lists available named
208
247
  * versions.
209
248
  */
210
- capabilities(input?: CapabilitiesInput): Promise<SpawnResult>;
249
+ capabilities(input?: CapabilitiesInput, signal?: AbortSignal): Promise<SpawnResult>;
211
250
  /**
212
251
  * Static dependency analysis for a Rego ref. Stdout is JSON with the
213
252
  * `base` and `virtual` document references the ref depends on.
214
253
  */
215
- deps(input: DepsInput): Promise<SpawnResult>;
254
+ deps(input: DepsInput, signal?: AbortSignal): Promise<SpawnResult>;
216
255
  /**
217
256
  * Evaluate a query against a policy + input. Stdout is JSON with the
218
257
  * standard `{result: [...]}` shape (plus optional explain, profile,
219
258
  * coverage, and metrics sections).
220
259
  */
221
- eval(input: EvalInput): Promise<SpawnResult>;
260
+ eval(input: EvalInput, signal?: AbortSignal): Promise<SpawnResult>;
222
261
  /**
223
262
  * Run Rego unit tests. Stdout is JSON with per-test pass/fail.
224
263
  */
225
- test(input: TestInput): Promise<SpawnResult>;
264
+ test(input: TestInput, signal?: AbortSignal): Promise<SpawnResult>;
226
265
  /**
227
266
  * Benchmark a query. Stdout is JSON with iteration timing statistics.
228
267
  */
229
- bench(input: BenchInput): Promise<SpawnResult>;
268
+ bench(input: BenchInput, signal?: AbortSignal): Promise<SpawnResult>;
230
269
  /** Build a deployable bundle from policy + data paths. */
231
- build(input: BuildInput): Promise<SpawnResult>;
270
+ build(input: BuildInput, signal?: AbortSignal): Promise<SpawnResult>;
232
271
  /**
233
272
  * Sign a bundle. Writes a `.signatures.json` next to the bundle
234
273
  * directory.
235
274
  */
236
- sign(input: SignInput): Promise<SpawnResult>;
275
+ sign(input: SignInput, signal?: AbortSignal): Promise<SpawnResult>;
276
+ /**
277
+ * Verify a signed bundle using `opa eval --bundle --verification-key`.
278
+ * OPA verifies the bundle signature before loading any policies; a
279
+ * failed signature produces a non-zero exit and the error message on
280
+ * stderr. The trivial query `true` is used so the process exits
281
+ * immediately after verification without entering a REPL.
282
+ */
283
+ bundleVerify(input: BundleVerifyInput, signal?: AbortSignal): Promise<SpawnResult>;
284
+ /**
285
+ * Batch-evaluate a policy decision against one or more input files using
286
+ * `opa exec`. Each input file is evaluated independently; results are
287
+ * returned as a JSON array with one entry per file.
288
+ */
289
+ exec(input: ExecInput, signal?: AbortSignal): Promise<SpawnResult>;
237
290
  /**
238
291
  * Run `opa` with the given argv and optional stdin. Tools should
239
292
  * prefer the typed methods above, but this exists for the rare cases
240
293
  * the typed surface does not yet cover.
241
294
  */
242
- run(args: string[], stdin?: string): Promise<SpawnResult>;
295
+ run(args: string[], stdin?: string, signal?: AbortSignal): Promise<SpawnResult>;
243
296
  /**
244
297
  * Write `source` to a uniquely named `.rego` file in the OS tmp dir,
245
298
  * pass its path to `fn`, and remove it on completion (success or
@@ -1 +1 @@
1
- {"version":3,"file":"opa-cli.d.ts","sourceRoot":"","sources":["../../src/lib/opa-cli.ts"],"names":[],"mappings":"AAsBA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAC3C,OAAO,EAAa,KAAK,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAE9D,+BAA+B;AAC/B,MAAM,WAAW,QAAQ;IACvB,kCAAkC;IAClC,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,8EAA8E;AAC9E,MAAM,WAAW,aAAa;IAC5B,6CAA6C;IAC7C,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,uFAAuF;IACvF,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,yDAAyD;IACzD,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,+CAA+C;IAC/C,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAED,6BAA6B;AAC7B,MAAM,WAAW,UAAU;IACzB,2DAA2D;IAC3D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,oEAAoE;IACpE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,2EAA2E;IAC3E,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,kDAAkD;IAClD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,6BAA6B;AAC7B,MAAM,WAAW,UAAU;IACzB,4BAA4B;IAC5B,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,+BAA+B;AAC/B,MAAM,WAAW,YAAY;IAC3B,gEAAgE;IAChE,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,oCAAoC;AACpC,MAAM,WAAW,iBAAiB;IAChC,4EAA4E;IAC5E,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,wDAAwD;IACxD,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,4BAA4B;AAC5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