@synapsor/runner 1.5.3 → 1.6.0

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 (69) hide show
  1. package/CHANGELOG.md +82 -2
  2. package/README.md +131 -130
  3. package/dist/authoring.mjs +405 -9
  4. package/dist/cli.d.ts.map +1 -1
  5. package/dist/local-ui.d.ts +2 -0
  6. package/dist/local-ui.d.ts.map +1 -1
  7. package/dist/runner.mjs +19532 -14246
  8. package/dist/runtime.mjs +10856 -8495
  9. package/dist/shadow.mjs +101 -1
  10. package/docs/README.md +14 -6
  11. package/docs/aggregate-reads.md +22 -0
  12. package/docs/auto-boundary-and-scoped-explore.md +338 -0
  13. package/docs/capability-authoring.md +36 -1
  14. package/docs/cloud-mode.md +18 -0
  15. package/docs/conformance.md +16 -0
  16. package/docs/current-scope.md +55 -28
  17. package/docs/cursor-plugin.md +20 -3
  18. package/docs/database-enforced-scope.md +8 -0
  19. package/docs/dsl-reference.md +123 -4
  20. package/docs/getting-started-own-database.md +42 -35
  21. package/docs/guarded-crud-writeback.md +10 -1
  22. package/docs/http-mcp.md +222 -207
  23. package/docs/limitations.md +33 -9
  24. package/docs/local-mode.md +5 -2
  25. package/docs/mcp-client-setup.md +24 -11
  26. package/docs/mcp-clients.md +10 -4
  27. package/docs/openai-agents-sdk.md +16 -2
  28. package/docs/production.md +72 -7
  29. package/docs/release-notes.md +77 -3
  30. package/docs/runner-bundles.md +7 -2
  31. package/docs/runner-config-reference.md +96 -6
  32. package/docs/running-a-runner-fleet.md +42 -13
  33. package/docs/schema-api-candidates.md +28 -1
  34. package/docs/security-boundary.md +38 -3
  35. package/docs/store-lifecycle.md +93 -5
  36. package/docs/troubleshooting-first-run.md +98 -0
  37. package/examples/auto-boundary-churn/README.md +23 -0
  38. package/examples/auto-boundary-churn/app/page.tsx +8 -0
  39. package/examples/auto-boundary-churn/docker-compose.yml +16 -0
  40. package/examples/auto-boundary-churn/package.json +18 -0
  41. package/examples/auto-boundary-churn/prisma/schema.prisma +36 -0
  42. package/examples/auto-boundary-churn/seed/postgres.sql +126 -0
  43. package/examples/openai-agents-http/README.md +10 -4
  44. package/examples/openai-agents-http/agent.py +2 -2
  45. package/examples/runner-fleet/Dockerfile +7 -2
  46. package/examples/runner-fleet/README.md +11 -7
  47. package/examples/runner-fleet/docker-compose.yml +4 -4
  48. package/examples/runner-fleet/mint-dev-token.mjs +1 -1
  49. package/examples/runner-fleet/start-tls-runner.sh +21 -0
  50. package/examples/runner-fleet/synapsor.runner.json +27 -1
  51. package/examples/support-plan-credit/README.md +6 -1
  52. package/examples/support-plan-credit/mcp-client-examples/generic-streamable-http.json +4 -1
  53. package/examples/support-plan-credit/mcp-client-examples/openai-agents-streamable-http.ts +4 -0
  54. package/examples/support-plan-credit/synapsor.contract.json +0 -3
  55. package/fixtures/compatibility/published-1.5.4/manifest.json +76 -0
  56. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/aggregate-read.synapsor.sql +21 -0
  57. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/billing-late-fee.synapsor.sql +56 -0
  58. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/bounded-set-multi-term.synapsor.sql +30 -0
  59. package/fixtures/compatibility/published-1.5.4/sources/packages/dsl/examples/principal-row-scope.synapsor.sql +23 -0
  60. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/aggregate-read/contract.json +119 -0
  61. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/approval-quorum/contract.json +44 -0
  62. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/bounded-set-threats/contract.json +115 -0
  63. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/principal-row-scope/contract.json +78 -0
  64. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/proposal-capability/contract.json +101 -0
  65. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/conformance/reversible-change-sets/contract.json +98 -0
  66. package/fixtures/compatibility/published-1.5.4/sources/packages/spec/fixtures/valid/basic-read.contract.json +60 -0
  67. package/llms.txt +37 -0
  68. package/package.json +7 -4
  69. package/schemas/synapsor.runner.schema.json +98 -1
@@ -0,0 +1,115 @@
1
+ {
2
+ "spec_version": "0.1",
3
+ "kind": "SynapsorContract",
4
+ "metadata": { "name": "bounded-set-threats", "version": "1.0.0" },
5
+ "contexts": [
6
+ {
7
+ "name": "trusted_operator",
8
+ "bindings": [
9
+ { "name": "tenant_id", "source": "environment", "key": "SYNAPSOR_TENANT_ID", "required": true },
10
+ { "name": "principal", "source": "environment", "key": "SYNAPSOR_PRINCIPAL", "required": true }
11
+ ],
12
+ "tenant_binding": "tenant_id",
13
+ "principal_binding": "principal"
14
+ }
15
+ ],
16
+ "capabilities": [
17
+ {
18
+ "name": "billing.close_overdue_invoices",
19
+ "kind": "proposal",
20
+ "context": "trusted_operator",
21
+ "source": "local_postgres",
22
+ "subject": { "schema": "public", "table": "invoices", "primary_key": "id", "tenant_key": "tenant_id", "conflict_key": "version" },
23
+ "args": { "reason": { "type": "string", "required": true, "max_length": 500 } },
24
+ "visible_fields": ["id", "tenant_id", "status", "balance_cents", "version"],
25
+ "kept_out_fields": ["internal_risk_score"],
26
+ "evidence": { "required": true, "query_audit": true },
27
+ "proposal": {
28
+ "action": "close_overdue",
29
+ "operation": {
30
+ "kind": "update",
31
+ "cardinality": "set",
32
+ "selection": { "all": [{ "column": "status", "operator": "eq", "value": "overdue" }] },
33
+ "max_rows": 10,
34
+ "aggregate_bounds": [{ "column": "balance_cents", "measure": "before", "maximum": 50000 }],
35
+ "version_advance": { "column": "version", "strategy": "integer_increment" }
36
+ },
37
+ "allowed_fields": ["status", "close_reason"],
38
+ "patch": { "status": { "fixed": "closed" }, "close_reason": { "from_arg": "reason" } },
39
+ "conflict_guard": { "column": "version" },
40
+ "approval": { "mode": "human", "required_role": "billing_reviewer" },
41
+ "writeback": { "mode": "direct_sql" }
42
+ }
43
+ },
44
+ {
45
+ "name": "billing.delete_expired_drafts",
46
+ "kind": "proposal",
47
+ "context": "trusted_operator",
48
+ "source": "local_postgres",
49
+ "subject": { "schema": "public", "table": "invoice_drafts", "primary_key": "id", "tenant_key": "tenant_id", "conflict_key": "version" },
50
+ "args": { "reason": { "type": "string", "required": true, "max_length": 500 } },
51
+ "visible_fields": ["id", "tenant_id", "status", "estimated_cents", "version"],
52
+ "evidence": { "required": true, "query_audit": true },
53
+ "proposal": {
54
+ "action": "delete_expired_drafts",
55
+ "operation": {
56
+ "kind": "delete",
57
+ "cardinality": "set",
58
+ "selection": { "all": [{ "column": "status", "operator": "eq", "value": "expired" }] },
59
+ "max_rows": 5,
60
+ "aggregate_bounds": [{ "column": "estimated_cents", "measure": "before", "maximum": 10000 }]
61
+ },
62
+ "allowed_fields": [],
63
+ "patch": {},
64
+ "conflict_guard": { "column": "version" },
65
+ "approval": { "mode": "human", "required_role": "billing_reviewer", "required_approvals": 2 },
66
+ "writeback": { "mode": "direct_sql" }
67
+ }
68
+ },
69
+ {
70
+ "name": "billing.create_credits",
71
+ "kind": "proposal",
72
+ "context": "trusted_operator",
73
+ "source": "local_postgres",
74
+ "subject": { "schema": "public", "table": "account_credits", "primary_key": "id", "tenant_key": "tenant_id" },
75
+ "args": {
76
+ "items": {
77
+ "type": "object_array",
78
+ "required": true,
79
+ "max_items": 10,
80
+ "fields": {
81
+ "id": { "type": "string", "required": true, "max_length": 128 },
82
+ "external_id": { "type": "string", "required": true, "max_length": 128 },
83
+ "amount_cents": { "type": "number", "required": true, "minimum": 1, "maximum": 2500 },
84
+ "reason": { "type": "string", "required": true, "max_length": 500 }
85
+ }
86
+ }
87
+ },
88
+ "visible_fields": ["id", "tenant_id", "external_id", "amount_cents", "reason", "version"],
89
+ "kept_out_fields": ["internal_note"],
90
+ "evidence": { "required": true, "query_audit": true },
91
+ "proposal": {
92
+ "action": "create_credits",
93
+ "operation": {
94
+ "kind": "insert",
95
+ "cardinality": "set",
96
+ "batch": { "items_from_arg": "items" },
97
+ "max_rows": 10,
98
+ "aggregate_bounds": [{ "column": "amount_cents", "measure": "after", "maximum": 25000 }],
99
+ "deduplication": {
100
+ "components": [
101
+ { "column": "tenant_id", "source": "trusted_tenant" },
102
+ { "column": "id", "source": "item_field", "item_field": "id" },
103
+ { "column": "external_id", "source": "item_field", "item_field": "external_id" }
104
+ ]
105
+ }
106
+ },
107
+ "allowed_fields": ["amount_cents", "reason"],
108
+ "patch": { "amount_cents": { "from_item": "amount_cents" }, "reason": { "from_item": "reason" } },
109
+ "numeric_bounds": { "amount_cents": { "minimum": 1, "maximum": 2500 } },
110
+ "approval": { "mode": "human", "required_role": "billing_reviewer" },
111
+ "writeback": { "mode": "direct_sql" }
112
+ }
113
+ }
114
+ ]
115
+ }
@@ -0,0 +1,78 @@
1
+ {
2
+ "spec_version": "0.1",
3
+ "kind": "SynapsorContract",
4
+ "metadata": {
5
+ "name": "trusted principal row scope",
6
+ "description": "Tenant-additive row authority for two case managers in one hospital."
7
+ },
8
+ "contexts": [
9
+ {
10
+ "name": "care_session",
11
+ "bindings": [
12
+ {
13
+ "name": "hospital_id",
14
+ "source": "http_claim",
15
+ "key": "hospital_id",
16
+ "required": true
17
+ },
18
+ {
19
+ "name": "principal",
20
+ "source": "http_claim",
21
+ "key": "sub",
22
+ "required": true
23
+ }
24
+ ],
25
+ "tenant_binding": "hospital_id",
26
+ "principal_binding": "principal"
27
+ }
28
+ ],
29
+ "resources": [],
30
+ "capabilities": [
31
+ {
32
+ "name": "care.inspect_assigned_patient",
33
+ "description": "Inspect one patient assigned to the authenticated case manager within the trusted hospital.",
34
+ "returns_hint": "Returns reviewed patient fields and evidence only when both tenant and assignee locks match.",
35
+ "kind": "read",
36
+ "context": "care_session",
37
+ "source": "local_postgres",
38
+ "subject": {
39
+ "schema": "public",
40
+ "table": "patients",
41
+ "primary_key": "id",
42
+ "tenant_key": "hospital_id",
43
+ "principal_scope_key": "assigned_to",
44
+ "conflict_key": "updated_at"
45
+ },
46
+ "args": {
47
+ "patient_id": {
48
+ "type": "string",
49
+ "required": true,
50
+ "description": "Reviewed patient identifier.",
51
+ "max_length": 128
52
+ }
53
+ },
54
+ "lookup": {
55
+ "id_from_arg": "patient_id"
56
+ },
57
+ "visible_fields": [
58
+ "id",
59
+ "hospital_id",
60
+ "display_name",
61
+ "care_status",
62
+ "updated_at"
63
+ ],
64
+ "kept_out_fields": [
65
+ "assigned_to",
66
+ "diagnosis_notes",
67
+ "insurance_member_id"
68
+ ],
69
+ "evidence": {
70
+ "required": true,
71
+ "query_audit": true
72
+ },
73
+ "max_rows": 1
74
+ }
75
+ ],
76
+ "workflows": [],
77
+ "policies": []
78
+ }
@@ -0,0 +1,101 @@
1
+ {
2
+ "spec_version": "0.1",
3
+ "kind": "SynapsorContract",
4
+ "metadata": {
5
+ "name": "proposal capability conformance"
6
+ },
7
+ "resources": [
8
+ {
9
+ "name": "billing_invoices",
10
+ "engine": "postgres",
11
+ "schema": "public",
12
+ "table": "invoices",
13
+ "primary_key": "id",
14
+ "tenant_key": "tenant_id",
15
+ "conflict_key": "updated_at"
16
+ }
17
+ ],
18
+ "contexts": [
19
+ {
20
+ "name": "local_operator",
21
+ "bindings": [
22
+ {
23
+ "name": "tenant_id",
24
+ "source": "environment",
25
+ "key": "SYNAPSOR_TENANT_ID"
26
+ },
27
+ {
28
+ "name": "principal",
29
+ "source": "environment",
30
+ "key": "SYNAPSOR_PRINCIPAL"
31
+ }
32
+ ],
33
+ "tenant_binding": "tenant_id",
34
+ "principal_binding": "principal"
35
+ }
36
+ ],
37
+ "capabilities": [
38
+ {
39
+ "name": "billing.propose_late_fee_waiver",
40
+ "kind": "proposal",
41
+ "context": "local_operator",
42
+ "source": "local_postgres",
43
+ "subject": {
44
+ "resource": "billing_invoices"
45
+ },
46
+ "args": {
47
+ "invoice_id": {
48
+ "type": "string",
49
+ "required": true
50
+ },
51
+ "waiver_reason": {
52
+ "type": "string",
53
+ "required": true
54
+ }
55
+ },
56
+ "lookup": {
57
+ "id_from_arg": "invoice_id"
58
+ },
59
+ "visible_fields": [
60
+ "id",
61
+ "tenant_id",
62
+ "late_fee_cents",
63
+ "waiver_reason",
64
+ "updated_at"
65
+ ],
66
+ "kept_out_fields": [
67
+ "card_token"
68
+ ],
69
+ "evidence": {
70
+ "required": true,
71
+ "query_audit": true
72
+ },
73
+ "max_rows": 1,
74
+ "proposal": {
75
+ "action": "billing.waive_late_fee",
76
+ "allowed_fields": [
77
+ "late_fee_cents",
78
+ "waiver_reason"
79
+ ],
80
+ "patch": {
81
+ "late_fee_cents": {
82
+ "fixed": 0
83
+ },
84
+ "waiver_reason": {
85
+ "from_arg": "waiver_reason"
86
+ }
87
+ },
88
+ "conflict_guard": {
89
+ "column": "updated_at"
90
+ },
91
+ "approval": {
92
+ "mode": "human",
93
+ "required_role": "billing_lead"
94
+ },
95
+ "writeback": {
96
+ "mode": "direct_sql"
97
+ }
98
+ }
99
+ }
100
+ ]
101
+ }
@@ -0,0 +1,98 @@
1
+ {
2
+ "spec_version": "0.1",
3
+ "kind": "SynapsorContract",
4
+ "metadata": {
5
+ "name": "reviewed-reversible-change-sets",
6
+ "version": "1.4.0"
7
+ },
8
+ "contexts": [
9
+ {
10
+ "name": "trusted_operator",
11
+ "bindings": [
12
+ { "name": "tenant_id", "source": "environment", "key": "SYNAPSOR_TENANT_ID", "required": true },
13
+ { "name": "principal", "source": "environment", "key": "SYNAPSOR_PRINCIPAL", "required": true }
14
+ ],
15
+ "tenant_binding": "tenant_id",
16
+ "principal_binding": "principal"
17
+ }
18
+ ],
19
+ "capabilities": [
20
+ {
21
+ "name": "billing.adjust_credit",
22
+ "kind": "proposal",
23
+ "context": "trusted_operator",
24
+ "source": "local_postgres",
25
+ "subject": {
26
+ "schema": "public",
27
+ "table": "account_credits",
28
+ "primary_key": "id",
29
+ "tenant_key": "tenant_id",
30
+ "conflict_key": "version"
31
+ },
32
+ "args": {
33
+ "credit_id": { "type": "string", "required": true, "max_length": 128 },
34
+ "amount_cents": { "type": "number", "required": true, "minimum": 0, "maximum": 2500 }
35
+ },
36
+ "lookup": { "id_from_arg": "credit_id" },
37
+ "visible_fields": ["id", "tenant_id", "amount_cents", "version"],
38
+ "kept_out_fields": ["internal_note"],
39
+ "evidence": { "required": true, "query_audit": true },
40
+ "proposal": {
41
+ "action": "adjust_credit",
42
+ "operation": {
43
+ "kind": "update",
44
+ "cardinality": "single",
45
+ "version_advance": { "column": "version", "strategy": "integer_increment" }
46
+ },
47
+ "allowed_fields": ["amount_cents"],
48
+ "patch": { "amount_cents": { "from_arg": "amount_cents" } },
49
+ "numeric_bounds": { "amount_cents": { "minimum": 0, "maximum": 2500 } },
50
+ "reversibility": { "mode": "reviewed_inverse" },
51
+ "conflict_guard": { "column": "version" },
52
+ "approval": { "mode": "human", "required_role": "billing_reviewer", "required_approvals": 2 },
53
+ "writeback": { "mode": "direct_sql" }
54
+ }
55
+ },
56
+ {
57
+ "name": "billing.create_credit",
58
+ "kind": "proposal",
59
+ "context": "trusted_operator",
60
+ "source": "local_postgres",
61
+ "subject": {
62
+ "schema": "public",
63
+ "table": "account_credits",
64
+ "primary_key": "id",
65
+ "tenant_key": "tenant_id"
66
+ },
67
+ "args": {
68
+ "amount_cents": { "type": "number", "required": true, "minimum": 1, "maximum": 2500 },
69
+ "reason": { "type": "string", "required": true, "max_length": 500 }
70
+ },
71
+ "visible_fields": ["id", "tenant_id", "amount_cents", "reason"],
72
+ "kept_out_fields": ["internal_note"],
73
+ "evidence": { "required": true, "query_audit": true },
74
+ "proposal": {
75
+ "action": "create_credit",
76
+ "operation": {
77
+ "kind": "insert",
78
+ "cardinality": "single",
79
+ "deduplication": {
80
+ "components": [
81
+ { "column": "tenant_id", "source": "trusted_tenant" },
82
+ { "column": "id", "source": "proposal_id" }
83
+ ]
84
+ }
85
+ },
86
+ "allowed_fields": ["amount_cents", "reason"],
87
+ "patch": {
88
+ "amount_cents": { "from_arg": "amount_cents" },
89
+ "reason": { "from_arg": "reason" }
90
+ },
91
+ "numeric_bounds": { "amount_cents": { "minimum": 1, "maximum": 2500 } },
92
+ "reversibility": { "mode": "reviewed_inverse" },
93
+ "approval": { "mode": "human", "required_role": "billing_reviewer" },
94
+ "writeback": { "mode": "direct_sql" }
95
+ }
96
+ }
97
+ ]
98
+ }
@@ -0,0 +1,60 @@
1
+ {
2
+ "spec_version": "0.1",
3
+ "kind": "SynapsorContract",
4
+ "contexts": [
5
+ {
6
+ "name": "local_operator",
7
+ "bindings": [
8
+ {
9
+ "name": "tenant_id",
10
+ "source": "environment",
11
+ "key": "SYNAPSOR_TENANT_ID"
12
+ },
13
+ {
14
+ "name": "principal",
15
+ "source": "environment",
16
+ "key": "SYNAPSOR_PRINCIPAL"
17
+ }
18
+ ],
19
+ "tenant_binding": "tenant_id",
20
+ "principal_binding": "principal"
21
+ }
22
+ ],
23
+ "capabilities": [
24
+ {
25
+ "name": "billing.inspect_invoice",
26
+ "kind": "read",
27
+ "context": "local_operator",
28
+ "subject": {
29
+ "schema": "public",
30
+ "table": "invoices",
31
+ "primary_key": "id",
32
+ "tenant_key": "tenant_id",
33
+ "conflict_key": "updated_at"
34
+ },
35
+ "args": {
36
+ "invoice_id": {
37
+ "type": "string",
38
+ "required": true
39
+ }
40
+ },
41
+ "lookup": {
42
+ "id_from_arg": "invoice_id"
43
+ },
44
+ "visible_fields": [
45
+ "id",
46
+ "tenant_id",
47
+ "late_fee_cents",
48
+ "updated_at"
49
+ ],
50
+ "kept_out_fields": [
51
+ "card_token"
52
+ ],
53
+ "evidence": {
54
+ "required": true,
55
+ "query_audit": true
56
+ },
57
+ "max_rows": 1
58
+ }
59
+ ]
60
+ }
package/llms.txt ADDED
@@ -0,0 +1,37 @@
1
+ # Synapsor Runner
2
+
3
+ Synapsor Runner is the Apache-2.0 MCP runtime that gives AI agents reviewed
4
+ Postgres/MySQL business capabilities instead of raw SQL. Credentials, trusted
5
+ tenant/principal identity, activation, approval, and commit stay outside the
6
+ model-facing tool surface.
7
+
8
+ Start here:
9
+ - README: https://github.com/Synapsor/Synapsor-Runner
10
+ - Auto Boundary, Scoped Explore, and Protect: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/auto-boundary-and-scoped-explore.md
11
+ - Connect a staging database: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/getting-started-own-database.md
12
+ - Security boundary: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/security-boundary.md
13
+ - Current scope: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/current-scope.md
14
+ - Current limitations: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/limitations.md
15
+ - DSL reference: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/dsl-reference.md
16
+ - MCP audit: https://github.com/Synapsor/Synapsor-Runner/blob/main/docs/mcp-audit.md
17
+
18
+ Current adoption loop:
19
+ Connect staging -> deterministic whole-schema draft -> human boundary review ->
20
+ bounded row or PM-style aggregate Explore in local Cursor -> Protect This Query
21
+ -> digest-bound human activation -> named production capability -> proposal ->
22
+ external approval -> guarded commit -> receipt and replay.
23
+
24
+ Important boundaries:
25
+ - No raw SQL or SQL-string tool argument.
26
+ - Scoped Explore is disabled by default and is local development/staging
27
+ authoring only. Production and shared/remote HTTP never advertise it.
28
+ - Aggregate Explore is a reviewed analytical cube: approved measures,
29
+ dimensions, time buckets, filters, at most one proven many-to-one path,
30
+ suppression, and extraction/differencing budgets.
31
+ - Auto Boundary and Protect are deterministic and use no LLM.
32
+ - Generated authority starts disabled. The model cannot activate, approve,
33
+ apply, commit, or widen it.
34
+ - Existing hand-authored 1.x contracts and established CLI routes do not
35
+ require Auto Boundary, Workbench, rescanning, or generation locks.
36
+ - Rich multi-table transactions and external side effects remain app-owned
37
+ executor work after approval.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synapsor/runner",
3
- "version": "1.5.3",
3
+ "version": "1.6.0",
4
4
  "description": "Stop giving AI agents execute_sql; expose reviewed Postgres/MySQL MCP actions with proposals, approval, writeback, and replay.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -40,6 +40,7 @@
40
40
  "docs/**/*.md",
41
41
  "examples/dangerous-mcp-tools.json",
42
42
  "examples/app-owned-writeback/**",
43
+ "examples/auto-boundary-churn/**",
43
44
  "examples/claude-desktop-postgres/**",
44
45
  "examples/cursor-postgres/**",
45
46
  "examples/mcp-postgres-billing-app-handler/**",
@@ -62,7 +63,8 @@
62
63
  "LICENSE",
63
64
  "NOTICE",
64
65
  "THREAT_MODEL.md",
65
- "TRADEMARKS.md"
66
+ "TRADEMARKS.md",
67
+ "llms.txt"
66
68
  ],
67
69
  "keywords": [
68
70
  "mcp",
@@ -83,7 +85,6 @@
83
85
  },
84
86
  "dependencies": {
85
87
  "@modelcontextprotocol/sdk": "1.29.0",
86
- "@synapsor/spec": "^1.4.2",
87
88
  "jose": "6.2.3",
88
89
  "mysql2": "^3.11.0",
89
90
  "pdf-lib": "1.17.1",
@@ -92,9 +93,11 @@
92
93
  "vscode-languageserver": "9.0.1",
93
94
  "vscode-languageserver-textdocument": "1.0.12",
94
95
  "yaml": "2.8.3",
95
- "zod": "^3.25.0"
96
+ "zod": "^3.25.0",
97
+ "@synapsor/spec": "^1.5.0"
96
98
  },
97
99
  "devDependencies": {
100
+ "@types/pg": "^8.11.0",
98
101
  "ajv": "^8.17.1",
99
102
  "vitest": "^3.2.0"
100
103
  },
@@ -132,6 +132,23 @@
132
132
  "minLength": 1
133
133
  }
134
134
  },
135
+ "generated_authority": {
136
+ "description": "Opt-in fail-closed drift enforcement for Auto Boundary and Protect This Query output. Legacy/manual projects omit this object and are not scanned.",
137
+ "type": "object",
138
+ "additionalProperties": false,
139
+ "required": ["generation_lock_path", "enforcement"],
140
+ "properties": {
141
+ "generation_lock_path": {
142
+ "description": "Local generation-lock file. Relative paths resolve from this config file's directory.",
143
+ "type": "string",
144
+ "minLength": 1,
145
+ "not": { "pattern": "://" }
146
+ },
147
+ "enforcement": {
148
+ "const": "required"
149
+ }
150
+ }
151
+ },
135
152
  "capabilities": {
136
153
  "description": "Embedded compatibility capabilities. May be empty when contracts supplies the capability catalog.",
137
154
  "type": "array",
@@ -293,6 +310,80 @@
293
310
  "max_response_bytes": { "type": "integer", "minimum": 1024, "maximum": 10485760 }
294
311
  }
295
312
  },
313
+ "http_security": {
314
+ "description": "Runner-only deployment security for networked MCP. Credential values remain in environment or secret-manager wiring and never enter portable contracts.",
315
+ "type": "object",
316
+ "additionalProperties": false,
317
+ "properties": {
318
+ "deployment": {
319
+ "description": "Trust topology. shared requires signed per-session http_claims identity; single_tenant may use one opaque service token.",
320
+ "enum": ["loopback", "single_tenant", "shared"]
321
+ },
322
+ "channel": {
323
+ "description": "How a remote listener is protected in transit. insecure_http_break_glass is unsafe and still requires authentication.",
324
+ "enum": ["direct_tls", "trusted_tls_proxy", "insecure_http_break_glass"]
325
+ },
326
+ "static_token": {
327
+ "description": "Environment-variable names for the current opaque endpoint token and at most one previous rotation token.",
328
+ "type": "object",
329
+ "additionalProperties": false,
330
+ "properties": {
331
+ "active_env": { "$ref": "#/$defs/env_name" },
332
+ "previous_env": { "$ref": "#/$defs/env_name" }
333
+ }
334
+ },
335
+ "oauth_resource": {
336
+ "description": "RFC 9728 metadata for Runner as an OAuth protected resource. The external authorization server issues tokens; Runner only verifies them.",
337
+ "type": "object",
338
+ "additionalProperties": false,
339
+ "required": ["resource", "authorization_servers"],
340
+ "properties": {
341
+ "resource": { "type": "string", "pattern": "^https://" },
342
+ "authorization_servers": {
343
+ "type": "array",
344
+ "minItems": 1,
345
+ "maxItems": 8,
346
+ "uniqueItems": true,
347
+ "items": { "type": "string", "pattern": "^https://" }
348
+ },
349
+ "scopes_supported": { "type": "array", "minItems": 1, "maxItems": 64, "uniqueItems": true, "items": { "$ref": "#/$defs/oauth_scope" } },
350
+ "required_scopes": { "type": "array", "minItems": 1, "maxItems": 64, "uniqueItems": true, "items": { "$ref": "#/$defs/oauth_scope" } },
351
+ "resource_name": { "type": "string", "minLength": 1, "maxLength": 128 },
352
+ "resource_documentation": { "type": "string", "pattern": "^https://" }
353
+ }
354
+ },
355
+ "allowed_origins": {
356
+ "description": "Exact browser origins accepted on HTTP MCP requests. Native clients may omit Origin. Wildcards are forbidden.",
357
+ "type": "array",
358
+ "maxItems": 32,
359
+ "uniqueItems": true,
360
+ "items": { "type": "string", "pattern": "^https?://[^/*]+(?::[0-9]+)?$" }
361
+ },
362
+ "allowed_hosts": {
363
+ "description": "Exact HTTP Host authorities accepted by the direct listener or trusted proxy. Forwarded host headers are never authority.",
364
+ "type": "array",
365
+ "minItems": 1,
366
+ "maxItems": 32,
367
+ "uniqueItems": true,
368
+ "items": { "type": "string", "minLength": 1, "maxLength": 255, "pattern": "^(?:\\[[0-9A-Fa-f:.]+\\]|[A-Za-z0-9.-]+)(?::[0-9]{1,5})?$" }
369
+ },
370
+ "limits": {
371
+ "description": "Bounded HTTP request, header, connection, and session resource limits.",
372
+ "type": "object",
373
+ "additionalProperties": false,
374
+ "properties": {
375
+ "max_request_bytes": { "type": "integer", "minimum": 1024, "maximum": 16777216 },
376
+ "max_header_bytes": { "type": "integer", "minimum": 4096, "maximum": 65536 },
377
+ "max_sessions": { "type": "integer", "minimum": 1, "maximum": 100000 },
378
+ "session_idle_timeout_seconds": { "type": "integer", "minimum": 10, "maximum": 86400 },
379
+ "request_timeout_ms": { "type": "integer", "minimum": 1000, "maximum": 300000 },
380
+ "headers_timeout_ms": { "type": "integer", "minimum": 1000, "maximum": 120000 },
381
+ "keep_alive_timeout_ms": { "type": "integer", "minimum": 1000, "maximum": 120000 },
382
+ "max_connections": { "type": "integer", "minimum": 1, "maximum": 100000 }
383
+ }
384
+ }
385
+ }
386
+ },
296
387
  "cloud": {
297
388
  "type": "object",
298
389
  "additionalProperties": false,
@@ -347,6 +438,12 @@
347
438
  "type": "string",
348
439
  "pattern": "^[A-Z_][A-Z0-9_]*$"
349
440
  },
441
+ "oauth_scope": {
442
+ "type": "string",
443
+ "minLength": 1,
444
+ "maxLength": 128,
445
+ "pattern": "^[!#-\\[\\]-~]+$"
446
+ },
350
447
  "identifier": {
351
448
  "type": "string",
352
449
  "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
@@ -408,7 +505,7 @@
408
505
  {
409
506
  "type": "object",
410
507
  "additionalProperties": false,
411
- "required": ["mode", "tenant_setting", "principal_setting"],
508
+ "required": ["mode", "tenant_setting"],
412
509
  "properties": {
413
510
  "mode": { "const": "postgres_rls" },
414
511
  "tenant_setting": {