@zackbart/connecta 0.34.1 → 0.36.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.
- package/CHANGELOG.md +418 -0
- package/README.md +65 -105
- package/SECURITY.md +3 -2
- package/bin/connecta.mjs +41 -16
- package/bin/version.mjs +1 -1
- package/dist/access-tokens.d.ts +2 -1
- package/dist/access-tokens.js +66 -30
- package/dist/activity.d.ts +1 -1
- package/dist/activity.js +2 -0
- package/dist/agent-config.d.ts +23 -0
- package/dist/agent-config.js +59 -0
- package/dist/agent-description.js +16 -0
- package/dist/agent-identity.js +4 -4
- package/dist/agent-observation.js +39 -0
- package/dist/auth/clerk-sdk/client.d.ts +2 -0
- package/dist/auth/clerk-sdk/generated.js +554 -563
- package/dist/auth/clerk-transport.js +70 -3
- package/dist/auth/clerk.d.ts +13 -0
- package/dist/auth/clerk.js +653 -246
- package/dist/auth/cloudflare-access.js +46 -42
- package/dist/auth/downstream-client-metadata.js +2 -2
- package/dist/auth/downstream-oauth.js +2044 -1161
- package/dist/auth/downstream-revocation.js +88 -88
- package/dist/auth/native-call.js +20 -0
- package/dist/auth/native.js +184 -0
- package/dist/auth/oauth-start-reset.js +11 -5
- package/dist/auth/oauth-token-response.js +121 -102
- package/dist/auth/oauth-v2-migration.js +97 -78
- package/dist/auth/renewable-grant.js +10 -0
- package/dist/auth/static-oauth.js +751 -281
- package/dist/auth/vercel-agent.js +266 -0
- package/dist/auth-admission.js +204 -0
- package/dist/auth-elicitation.js +350 -241
- package/dist/authorization-handoff.js +164 -90
- package/dist/call-admission-context.js +3 -10
- package/dist/call-admission.js +2 -0
- package/dist/call-classification.js +9 -0
- package/dist/call-recovery.js +32 -13
- package/dist/canonical-json.js +8 -0
- package/dist/catalog-cache.js +369 -213
- package/dist/catalog-service.js +659 -530
- package/dist/catalog.js +5 -1
- package/dist/concurrency.js +0 -25
- package/dist/config-defaults.d.ts +1 -0
- package/dist/config-defaults.js +1 -0
- package/dist/config-schema.d.ts +3 -1
- package/dist/config-schema.js +13 -3
- package/dist/config.d.ts +40 -6
- package/dist/config.js +40 -26
- package/dist/connector-caller.d.ts +4 -0
- package/dist/connector-caller.js +17 -4
- package/dist/connectors/api-connector.d.ts +29 -7
- package/dist/connectors/api-connector.js +145 -57
- package/dist/connectors/guarded-fetch.d.ts +51 -17
- package/dist/connectors/guarded-fetch.js +215 -121
- package/dist/connectors/negotiation-cache.js +20 -10
- package/dist/connectors/remote-mcp.d.ts +10 -30
- package/dist/connectors/remote-mcp.js +955 -563
- package/dist/d1.js +10 -243
- package/dist/derived-context.js +5 -0
- package/dist/describe-config.d.ts +3 -1
- package/dist/describe-config.js +2 -0
- package/dist/downstream-input.js +347 -260
- package/dist/errors.d.ts +87 -6
- package/dist/errors.js +114 -4
- package/dist/execute.js +87 -50
- package/dist/executor-admission.js +3 -0
- package/dist/executors/quickjs.js +163 -112
- package/dist/guarded-transport.js +50 -0
- package/dist/guest-runtime.js +1 -1
- package/dist/http/client.js +439 -0
- package/dist/http/errors.js +558 -0
- package/dist/http/fields.js +49 -0
- package/dist/http/hatch-paging.js +318 -0
- package/dist/http/hatch.js +1279 -0
- package/dist/http/json-schema.js +267 -0
- package/dist/http/node-transport.js +241 -0
- package/dist/http/oauth.js +162 -0
- package/dist/http/paging.js +227 -0
- package/dist/http/provider.js +221 -0
- package/dist/http/safety.js +82 -0
- package/dist/http/services.js +79 -0
- package/dist/http/tools.js +379 -0
- package/dist/http/vendor-index.js +138 -0
- package/dist/http/vendor.js +448 -0
- package/dist/http/write-request.js +66 -0
- package/dist/http-policy.d.ts +11 -0
- package/dist/http-policy.js +45 -0
- package/dist/inbound-credential.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -0
- package/dist/invocation-auth.js +30 -19
- package/dist/invocation.js +218 -85
- package/dist/mcp-result.js +0 -4
- package/dist/membership.d.ts +4 -0
- package/dist/meta-output.js +1 -1
- package/dist/meta-tools.js +531 -406
- package/dist/native-recovery.js +52 -0
- package/dist/native-tools.js +382 -0
- package/dist/node.d.ts +4 -3
- package/dist/node.js +45 -8
- package/dist/oauth-handoff.js +177 -104
- package/dist/oauth-partition.js +6 -20
- package/dist/oauth-sealing.js +6 -7
- package/dist/operation-vocabulary.js +101 -0
- package/dist/operator-record.d.ts +2 -2
- package/dist/operator-record.js +17 -4
- package/dist/operator-ui/contract.d.ts +8 -3
- package/dist/operator-ui/generated.js +4 -4
- package/dist/operator-ui/model.d.ts +2 -3
- package/dist/program-writes.js +47 -26
- package/dist/provider-call-facts.d.ts +115 -0
- package/dist/provider-call-facts.js +182 -0
- package/dist/provider-call.d.ts +112 -0
- package/dist/provider-call.js +271 -0
- package/dist/provider.d.ts +65 -31
- package/dist/provider.js +116 -39
- package/dist/providers/_shared/google/hatch.js +91 -0
- package/dist/providers/_shared/google/kit.js +427 -0
- package/dist/providers/_shared/google/result-size.js +15 -2
- package/dist/providers/_shared/google/service-account.d.ts +2 -1
- package/dist/providers/_shared/google/service-account.js +8 -4
- package/dist/providers/_shared/google/workspace.d.ts +6 -210
- package/dist/providers/_shared/google/workspace.js +6 -425
- package/dist/providers/_shared/rest/compact-index.js +86 -0
- package/dist/providers/_shared/rest/kit.js +146 -0
- package/dist/providers/_shared/rest/operation-index.js +230 -14
- package/dist/providers/_shared/rest/response-media.js +11 -0
- package/dist/providers/_shared/rest/value-safety.js +353 -195
- package/dist/providers/_shared/sensitive-fields.js +27 -0
- package/dist/providers/breeze/api.js +584 -0
- package/dist/providers/breeze/index.d.ts +1 -3
- package/dist/providers/breeze/index.js +67 -1420
- package/dist/providers/breeze/openapi.generated.js +60 -0
- package/dist/providers/breeze/skill.generated.js +2 -6
- package/dist/providers/breeze/tools.js +696 -0
- package/dist/providers/ccb/api.js +496 -0
- package/dist/providers/ccb/index.d.ts +15 -37
- package/dist/providers/ccb/index.js +77 -1702
- package/dist/providers/ccb/lib/constants.d.ts +34 -0
- package/dist/providers/ccb/lib/constants.js +74 -0
- package/dist/providers/ccb/lib/guide.js +9 -0
- package/dist/providers/ccb/lib/verdicts.js +387 -0
- package/dist/providers/ccb/openapi.generated.js +397 -0
- package/dist/providers/ccb/safety.js +295 -0
- package/dist/providers/ccb/skill.generated.js +2 -6
- package/dist/providers/ccb/tools.js +853 -0
- package/dist/providers/cloudflare/api.js +1066 -0
- package/dist/providers/cloudflare/index.d.ts +5 -22
- package/dist/providers/cloudflare/index.js +79 -197
- package/dist/providers/cloudflare/lib/config.d.ts +16 -0
- package/dist/providers/cloudflare/lib/config.js +2 -0
- package/dist/providers/cloudflare/lib/discovery.js +29 -0
- package/dist/providers/cloudflare/{graphql.js → lib/graphql.js} +1 -1
- package/dist/providers/cloudflare/lib/hatch.js +103 -0
- package/dist/providers/cloudflare/lib/path-bounds.js +28 -0
- package/dist/providers/cloudflare/lib/response-media.js +75 -0
- package/dist/providers/cloudflare/openapi.generated.js +4 -3
- package/dist/providers/cloudflare/{value-safety.js → safety.js} +487 -0
- package/dist/providers/cloudflare/skill.generated.js +2 -10
- package/dist/providers/cloudflare/tools.js +360 -0
- package/dist/providers/docs/api.js +51 -0
- package/dist/providers/docs/index.d.ts +1 -12
- package/dist/providers/docs/index.js +53 -1165
- package/dist/providers/docs/lib/constants.d.ts +18 -0
- package/dist/providers/docs/lib/constants.js +18 -0
- package/dist/providers/docs/lib/discovery.js +26 -0
- package/dist/providers/docs/lib/requests.js +48 -0
- package/dist/providers/docs/lib/schemas.js +168 -0
- package/dist/providers/docs/openapi.generated.js +16 -0
- package/dist/providers/docs/safety.js +54 -0
- package/dist/providers/docs/skill.generated.js +2 -6
- package/dist/providers/docs/tools.js +801 -0
- package/dist/providers/drive/api.js +177 -0
- package/dist/providers/drive/index.d.ts +1 -12
- package/dist/providers/drive/index.js +38 -1448
- package/dist/providers/drive/lib/constants.d.ts +6 -0
- package/dist/providers/drive/lib/constants.js +6 -0
- package/dist/providers/drive/lib/contracts.js +532 -0
- package/dist/providers/drive/lib/hatch.js +197 -0
- package/dist/providers/drive/openapi.generated.js +77 -0
- package/dist/providers/drive/safety.js +90 -0
- package/dist/providers/drive/skill.generated.js +2 -6
- package/dist/providers/drive/tools.js +1290 -0
- package/dist/providers/forms/api.js +71 -0
- package/dist/providers/forms/index.d.ts +1 -12
- package/dist/providers/forms/index.js +49 -1145
- package/dist/providers/forms/lib/constants.d.ts +14 -0
- package/dist/providers/forms/lib/constants.js +19 -0
- package/dist/providers/forms/lib/hatch.js +72 -0
- package/dist/providers/forms/openapi.generated.js +23 -0
- package/dist/providers/forms/safety.js +34 -0
- package/dist/providers/forms/skill.generated.js +2 -8
- package/dist/providers/forms/tools.js +1023 -0
- package/dist/providers/github/api.js +150 -0
- package/dist/providers/github/index.d.ts +4 -5
- package/dist/providers/github/index.js +30 -87
- package/dist/providers/github/{auth.d.ts → lib/auth.d.ts} +5 -3
- package/dist/providers/github/{auth.js → lib/auth.js} +40 -43
- package/dist/providers/github/lib/discovery.js +132 -0
- package/dist/providers/github/lib/operations.js +58 -0
- package/dist/providers/github/{scope.d.ts → lib/scope.d.ts} +2 -0
- package/dist/providers/github/{scope.js → lib/scope.js} +25 -1
- package/dist/providers/github/openapi.generated.js +1216 -0
- package/dist/providers/github/safety.js +216 -0
- package/dist/providers/github/skill.generated.js +2 -5
- package/dist/providers/github/tools.js +506 -0
- package/dist/providers/gmail/api.js +114 -0
- package/dist/providers/gmail/index.d.ts +1 -12
- package/dist/providers/gmail/index.js +73 -1621
- package/dist/providers/gmail/lib/constants.d.ts +13 -0
- package/dist/providers/gmail/lib/constants.js +16 -0
- package/dist/providers/gmail/lib/index.js +173 -0
- package/dist/providers/gmail/lib/schemas.js +176 -0
- package/dist/providers/gmail/lib/threading.js +120 -0
- package/dist/providers/gmail/openapi.generated.js +92 -0
- package/dist/providers/gmail/safety.js +21 -0
- package/dist/providers/gmail/skill.generated.js +2 -6
- package/dist/providers/gmail/tools.js +1435 -0
- package/dist/providers/overflow/api.js +1008 -0
- package/dist/providers/overflow/index.d.ts +1 -17
- package/dist/providers/overflow/index.js +60 -1488
- package/dist/providers/overflow/skill.generated.js +2 -5
- package/dist/providers/overflow/tools.js +873 -0
- package/dist/providers/planning-center/api.js +467 -0
- package/dist/providers/planning-center/index.d.ts +4 -35
- package/dist/providers/planning-center/index.js +69 -2445
- package/dist/providers/planning-center/lib/constants.d.ts +58 -0
- package/dist/providers/planning-center/lib/constants.js +83 -0
- package/dist/providers/planning-center/lib/discovery.js +40 -0
- package/dist/providers/planning-center/lib/guide.js +39 -0
- package/dist/providers/planning-center/lib/json-api.js +83 -0
- package/dist/providers/planning-center/lib/verdicts.js +1758 -0
- package/dist/providers/planning-center/openapi.generated.js +1764 -0
- package/dist/providers/planning-center/safety.js +188 -0
- package/dist/providers/planning-center/skill.generated.js +2 -27
- package/dist/providers/planning-center/tools.js +1010 -0
- package/dist/providers/quickbooks/api.js +299 -0
- package/dist/providers/quickbooks/index.d.ts +13 -0
- package/dist/providers/quickbooks/index.js +93 -0
- package/dist/providers/quickbooks/lib/query.js +118 -0
- package/dist/providers/quickbooks/lib/writes.js +168 -0
- package/dist/providers/quickbooks/safety.js +222 -0
- package/dist/providers/quickbooks/skill.generated.js +5 -0
- package/dist/providers/quickbooks/tools.js +117 -0
- package/dist/providers/sheets/api.js +133 -0
- package/dist/providers/sheets/index.d.ts +4 -16
- package/dist/providers/sheets/index.js +61 -1172
- package/dist/providers/sheets/lib/constants.d.ts +14 -0
- package/dist/providers/sheets/lib/constants.js +14 -0
- package/dist/providers/sheets/lib/hatch.js +163 -0
- package/dist/providers/sheets/lib/requests.js +105 -0
- package/dist/providers/sheets/lib/schemas.js +138 -0
- package/dist/providers/sheets/openapi.generated.js +30 -0
- package/dist/providers/sheets/safety.js +27 -0
- package/dist/providers/sheets/skill.generated.js +2 -7
- package/dist/providers/sheets/tools.js +733 -0
- package/dist/providers/slides/api.js +147 -0
- package/dist/providers/slides/index.d.ts +2 -10
- package/dist/providers/slides/index.js +48 -2555
- package/dist/providers/slides/lib/constants.d.ts +11 -0
- package/dist/providers/slides/lib/constants.js +11 -0
- package/dist/providers/slides/lib/requests.js +60 -0
- package/dist/providers/slides/lib/schemas.js +565 -0
- package/dist/providers/slides/openapi.generated.js +18 -0
- package/dist/providers/slides/skill.generated.js +2 -6
- package/dist/providers/slides/tools.js +1968 -0
- package/dist/providers/stripe/api.js +401 -0
- package/dist/providers/stripe/index.d.ts +5 -27
- package/dist/providers/stripe/index.js +74 -210
- package/dist/providers/stripe/lib/config.d.ts +4 -0
- package/dist/providers/stripe/lib/config.js +2 -0
- package/dist/providers/stripe/openapi.generated.js +4 -3
- package/dist/providers/stripe/{value-safety.js → safety.js} +5 -5
- package/dist/providers/stripe/skill.generated.js +2 -11
- package/dist/providers/stripe/tools.js +77 -0
- package/dist/providers/tithely/api.js +531 -0
- package/dist/providers/tithely/index.d.ts +17 -0
- package/dist/providers/tithely/index.js +86 -965
- package/dist/providers/tithely/skill.generated.js +2 -5
- package/dist/providers/tithely/tools.js +426 -0
- package/dist/providers/vercel/api.js +551 -0
- package/dist/providers/vercel/index.d.ts +9 -25
- package/dist/providers/vercel/index.js +65 -260
- package/dist/providers/vercel/lib/config.d.ts +2 -0
- package/dist/providers/vercel/lib/config.js +2 -0
- package/dist/providers/vercel/lib/index.js +117 -0
- package/dist/providers/vercel/lib/logs.js +100 -0
- package/dist/providers/vercel/lib/pin.js +270 -0
- package/dist/providers/vercel/openapi.generated.js +10 -5
- package/dist/providers/vercel/{value-safety.js → safety.js} +247 -38
- package/dist/providers/vercel/skill.generated.js +2 -7
- package/dist/providers/vercel/tools.js +642 -0
- package/dist/redaction-identity.js +47 -0
- package/dist/redaction-marker.js +125 -0
- package/dist/registry.d.ts +21 -15
- package/dist/registry.js +409 -376
- package/dist/routes/access-tokens.js +1 -1
- package/dist/routes/actor-labels.js +1 -1
- package/dist/routes/connect.js +1 -1
- package/dist/routes/dispatch.js +103 -0
- package/dist/routes/mcp.js +170 -79
- package/dist/routes/oauth.js +6 -1
- package/dist/routes/operator.js +2 -2
- package/dist/routes/shared.d.ts +5 -4
- package/dist/routes/shared.js +244 -177
- package/dist/routes/skills.js +10 -8
- package/dist/routes/ui-config.js +27 -3
- package/dist/routes/ui-data.js +21 -20
- package/dist/routes/ui.js +1 -1
- package/dist/runtime/call-admission.js +0 -26
- package/dist/runtime/call-entry.js +30 -0
- package/dist/runtime/call.js +552 -0
- package/dist/runtime/connector-scope.js +7 -0
- package/dist/runtime/credential-probe.js +34 -0
- package/dist/runtime/executor.js +40 -0
- package/dist/runtime/native-storage.js +63 -0
- package/dist/runtime/registry.js +27 -0
- package/dist/runtime/request-scope.js +72 -0
- package/dist/runtime/run.js +15 -7
- package/dist/runtime/shared-read.js +34 -5
- package/dist/runtime/storage.js +34 -21
- package/dist/sent-secrets.d.ts +194 -37
- package/dist/sent-secrets.js +1743 -340
- package/dist/server.js +5 -56
- package/dist/skills.js +322 -223
- package/dist/sqlite.js +15 -14
- package/dist/storage/d1-copy.js +255 -0
- package/dist/storage/d1-driver.js +15 -0
- package/dist/storage/keys.js +28 -0
- package/dist/storage/sql-driver.js +88 -0
- package/dist/storage/sql-native.js +544 -0
- package/dist/storage/sql-schema.d.ts +6 -0
- package/dist/storage/sql-schema.js +15 -0
- package/dist/storage/sql.d.ts +14 -20
- package/dist/storage/sql.js +29 -535
- package/dist/timeout.js +0 -26
- package/dist/tool-safety.js +20 -10
- package/dist/types.d.ts +9 -109
- package/dist/ui.d.ts +1 -1
- package/dist/ui.js +0 -1
- package/dist/upward.js +3 -0
- package/dist/usage-guide.js +3 -1
- package/dist/validate.d.ts +4 -2
- package/dist/validate.js +86 -9
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/worker.js +312 -292
- package/dist/workspace-subject.js +5 -1
- package/dist/write-outcome.js +454 -34
- package/documentation/README.md +28 -7
- package/documentation/architecture.md +2409 -255
- package/documentation/auth.md +867 -114
- package/documentation/code-mode.md +49 -16
- package/documentation/deploying.md +164 -20
- package/documentation/hosted-mcp-migration.md +460 -0
- package/documentation/integrating.md +129 -144
- package/documentation/meta-tools.md +409 -32
- package/documentation/operating.md +27 -3
- package/documentation/operator-tests.md +3 -0
- package/documentation/operator-ui.md +84 -48
- package/documentation/provider-auth-migration.md +16 -63
- package/documentation/provider-migration-0.29.md +10 -5
- package/documentation/provider-migration-0.35.md +975 -0
- package/documentation/providers.md +1347 -0
- package/examples/worker/AGENTS.md +23 -9
- package/examples/worker/README.md +254 -135
- package/examples/worker/alchemy.run.ts +116 -0
- package/examples/worker/gitignore +10 -0
- package/examples/worker/src/connecta.config.ts +23 -21
- package/examples/worker/wrangler.jsonc +14 -5
- package/guides/connecting-agents.md +157 -0
- package/guides/how-it-works.md +156 -0
- package/guides/safety-and-trust.md +153 -0
- package/package.json +30 -50
- package/templates/node/.env.example +3 -0
- package/templates/node/README.md +22 -2
- package/templates/node/docker-compose.yml +1 -0
- package/templates/node/package.json +3 -2
- package/templates/node/src/connecta.config.ts +8 -0
- package/dist/catalog-drift.d.ts +0 -138
- package/dist/catalog-drift.js +0 -578
- package/dist/operator-ui/agents.d.ts +0 -74
- package/dist/operator-ui/agents.js +0 -104
- package/dist/operator-ui/config-summary.js +0 -565
- package/dist/operator-ui/connection-map.js +0 -376
- package/dist/operator-ui/endpoints.js +0 -221
- package/dist/operator-ui/fix-prompts.d.ts +0 -18
- package/dist/operator-ui/fix-prompts.js +0 -87
- package/dist/operator-ui/health.js +0 -52
- package/dist/operator-ui/member-page.js +0 -97
- package/dist/operator-ui/overview.js +0 -123
- package/dist/operator-ui/setup-commands.js +0 -51
- package/dist/operator-ui/view.d.ts +0 -401
- package/dist/operator-ui/view.js +0 -705
- package/dist/providers/_shared/request-token.js +0 -83
- package/dist/providers/_shared/rest/dispatch.js +0 -41
- package/dist/providers/_shared/rest/operation-index.d.ts +0 -133
- package/dist/providers/_shared/rest/tools.d.ts +0 -141
- package/dist/providers/_shared/rest/tools.js +0 -569
- package/dist/providers/_shared/rest/value-safety.d.ts +0 -201
- package/dist/providers/basecamp/index.d.ts +0 -45
- package/dist/providers/basecamp/index.js +0 -997
- package/dist/providers/basecamp/skill.generated.js +0 -9
- package/dist/providers/cloudflare/rest.d.ts +0 -37
- package/dist/providers/cloudflare/rest.js +0 -1097
- package/dist/providers/github/hosted.js +0 -218
- package/dist/providers/github/rest.js +0 -321
- package/dist/providers/infisical/index.d.ts +0 -7
- package/dist/providers/infisical/index.js +0 -713
- package/dist/providers/infisical/skill.generated.js +0 -8
- package/dist/providers/intercom/index.d.ts +0 -24
- package/dist/providers/intercom/index.js +0 -121
- package/dist/providers/intercom/skill.generated.js +0 -8
- package/dist/providers/linear/index.d.ts +0 -55
- package/dist/providers/linear/index.js +0 -537
- package/dist/providers/linear/skill.generated.js +0 -8
- package/dist/providers/mixpanel/index.d.ts +0 -59
- package/dist/providers/mixpanel/index.js +0 -472
- package/dist/providers/mixpanel/operations.js +0 -20
- package/dist/providers/mixpanel/rest.js +0 -603
- package/dist/providers/mixpanel/skill.generated.js +0 -10
- package/dist/providers/mixpanel/value-safety.js +0 -16
- package/dist/providers/notion/index.d.ts +0 -67
- package/dist/providers/notion/index.js +0 -368
- package/dist/providers/notion/openapi.generated.js +0 -75
- package/dist/providers/notion/rest.d.ts +0 -24
- package/dist/providers/notion/rest.js +0 -1226
- package/dist/providers/notion/skill.generated.js +0 -11
- package/dist/providers/notion/value-safety.js +0 -56
- package/dist/providers/revenuecat/index.d.ts +0 -51
- package/dist/providers/revenuecat/index.js +0 -697
- package/dist/providers/revenuecat/skill.generated.js +0 -11
- package/dist/providers/stripe/rest.d.ts +0 -14
- package/dist/providers/stripe/rest.js +0 -402
- package/dist/providers/vercel/rest.d.ts +0 -20
- package/dist/providers/vercel/rest.js +0 -1020
- package/dist/providers/wispr-flow/index.d.ts +0 -14
- package/dist/providers/wispr-flow/index.js +0 -117
- package/dist/providers/wispr-flow/skill.generated.js +0 -8
- /package/dist/providers/github/{key.js → lib/key.js} +0 -0
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
# Safety and trust
|
|
2
|
+
|
|
3
|
+
Connecta helps limit tool access. It does not approve every action or
|
|
4
|
+
guarantee that returned business data is safe to share. Your operator—the
|
|
5
|
+
person or team running the server—chooses accounts, access, and approval rules.
|
|
6
|
+
|
|
7
|
+
With authentication configured, Connecta checks who is calling and which
|
|
8
|
+
tools they can use. Without configured authentication, the main `/mcp`
|
|
9
|
+
endpoint serves its whole tool list to anyone who can reach it.
|
|
10
|
+
|
|
11
|
+
The [operator documentation](../documentation/README.md) owns exact setup
|
|
12
|
+
and behavior. This guide explains the boundaries and their limits.
|
|
13
|
+
|
|
14
|
+
## A timeout can leave a change's status unknown
|
|
15
|
+
|
|
16
|
+
A **write** changes something: a record, payment, permission, or other service
|
|
17
|
+
state. The service might apply it even when no answer comes back. Check the
|
|
18
|
+
current record or service history before trying again.
|
|
19
|
+
|
|
20
|
+
For tools classified as writes, once Connecta sends a change, it never
|
|
21
|
+
automatically sends it again. This includes a timeout or a lost response.
|
|
22
|
+
That does not promise the service completed it exactly once. A new request
|
|
23
|
+
or a rerun of a program can repeat the action.
|
|
24
|
+
|
|
25
|
+
```mermaid
|
|
26
|
+
sequenceDiagram
|
|
27
|
+
participant A as Agent
|
|
28
|
+
participant C as Connecta
|
|
29
|
+
participant S as Service
|
|
30
|
+
A->>C: Request a write
|
|
31
|
+
C->>S: Send once
|
|
32
|
+
S->>S: The write may have applied
|
|
33
|
+
S--xC: Response lost or deadline reached
|
|
34
|
+
C-->>A: Outcome unknown, do not blindly repeat
|
|
35
|
+
A->>C: Check current state or history
|
|
36
|
+
C->>S: Read available evidence
|
|
37
|
+
S-->>C: Current state or history
|
|
38
|
+
C-->>A: Investigate further if still uncertain
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
An **unknown outcome** means Connecta cannot prove whether the change
|
|
42
|
+
happened. A read may help, but may not settle it. If the answer is still
|
|
43
|
+
unclear, stop and investigate.
|
|
44
|
+
|
|
45
|
+
Do not repeat a successful change just to recover its output either.
|
|
46
|
+
The [write contract](../documentation/code-mode.md#writes) and
|
|
47
|
+
[result recovery guide](../documentation/meta-tools.md#paging-with-connectaresult)
|
|
48
|
+
explain how to check the service or retrieve retained output.
|
|
49
|
+
|
|
50
|
+
## Read-only blocks actions that change data
|
|
51
|
+
|
|
52
|
+
A read-only pool hides tools marked as writes and refuses attempts to call
|
|
53
|
+
them before sending anything. Guessing a tool name or asking from a program
|
|
54
|
+
does not bypass it. A whole service connection can also be read-only; a
|
|
55
|
+
writable pool cannot reopen that connection for writes.
|
|
56
|
+
|
|
57
|
+
```mermaid
|
|
58
|
+
flowchart LR
|
|
59
|
+
Call["Requested action"] --> Allowed{"Pool allows this tool?"}
|
|
60
|
+
Allowed -->|No| Refuse["Refuse"]
|
|
61
|
+
Allowed -->|Yes| Write{"Marked as a write?"}
|
|
62
|
+
Write -->|No| Run["Check inputs and send"]
|
|
63
|
+
Write -->|Yes| ReadOnly{"Pool or connection read-only?"}
|
|
64
|
+
ReadOnly -->|Yes| Refuse
|
|
65
|
+
ReadOnly -->|No| Run
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
Read-only protection and the single-attempt rule depend on truthful
|
|
69
|
+
classification: the labels identifying actions that change data. Missing
|
|
70
|
+
or contradictory read hints count as writes, but a service can mislabel an
|
|
71
|
+
action and an operator can override its label. Use restricted service
|
|
72
|
+
credentials as another boundary where possible.
|
|
73
|
+
|
|
74
|
+
The AI app owns approvals. It may ask based on an earlier tool label. If a
|
|
75
|
+
read becomes a write, a writable pool can execute it without a fresh
|
|
76
|
+
approval; a read-only pool refuses it. Connecta does not pause a program to
|
|
77
|
+
ask a person partway through.
|
|
78
|
+
|
|
79
|
+
See [read-only setup](../documentation/integrating.md#make-one-connection-read-only)
|
|
80
|
+
and the [write policy](../documentation/code-mode.md#writes) for exact rules.
|
|
81
|
+
|
|
82
|
+
## Keep credentials private and enable the vault
|
|
83
|
+
|
|
84
|
+
The agent receives tool results without needing the service credential used
|
|
85
|
+
to make the call. Redaction removes known secrets from output, but is not a
|
|
86
|
+
general detector for every secret or piece of personal data in a record.
|
|
87
|
+
|
|
88
|
+
With the encrypted credential vault configured, Connecta seals stored
|
|
89
|
+
downstream credentials and OAuth tokens and binds each to its connector and
|
|
90
|
+
owner. Without a vault, stored OAuth tokens are kept in plaintext, so enable
|
|
91
|
+
the vault **before connecting accounts**. Follow
|
|
92
|
+
[shared credential setup](../documentation/auth.md#connect-a-shared-credential)
|
|
93
|
+
and [OAuth storage rules](../documentation/auth.md#downstream-oauth-state-at-rest).
|
|
94
|
+
|
|
95
|
+
Maintained integrations also withhold reviewed sensitive values. A value
|
|
96
|
+
shown as `[redacted]` is unavailable, not a usable credential. Redaction
|
|
97
|
+
covers known values and supported forms; a malicious service can transform
|
|
98
|
+
data into forms outside that coverage.
|
|
99
|
+
|
|
100
|
+
Connecta's activity, status, and logs omit arguments, results, program source,
|
|
101
|
+
and raw downstream error text. Your AI app, proxies, and other logging systems
|
|
102
|
+
need their own data-handling policies. Keep agent tokens in the app's secret
|
|
103
|
+
store, outside prompts, source files, and logs.
|
|
104
|
+
|
|
105
|
+
The [operator data contract](../documentation/operator-ui.md#operator-data-contract)
|
|
106
|
+
explains activity disclosure.
|
|
107
|
+
|
|
108
|
+
## A credential proves an agent, not a person
|
|
109
|
+
|
|
110
|
+
Anyone holding an agent's `cta_` token can act as that agent. Vercel workload
|
|
111
|
+
identity uses a signed project token instead. It removes the separately
|
|
112
|
+
provisioned Connecta secret, while still trusting whoever can obtain the
|
|
113
|
+
project token.
|
|
114
|
+
|
|
115
|
+
```mermaid
|
|
116
|
+
flowchart TB
|
|
117
|
+
Saved["Agent-token holder"] --> Agent["Declared agent"]
|
|
118
|
+
Project["Trusted Vercel project-token holder"] --> Agent
|
|
119
|
+
Agent --> Pools["Configured pools"]
|
|
120
|
+
Pools --> Accounts["Assigned service accounts"]
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
Trust project code, build steps, and services receiving a Vercel token with
|
|
124
|
+
the same agent access. Preview or development environments should be enabled
|
|
125
|
+
only if they deserve that access too. A token holder may obtain fresh tokens,
|
|
126
|
+
so access can outlast the original token's expiry.
|
|
127
|
+
|
|
128
|
+
When both methods are enabled, stopping one leaves the other active.
|
|
129
|
+
Removing the declared agent stops both. Revocation does not recall requests
|
|
130
|
+
already admitted. Neither method identifies the human chatting with the agent.
|
|
131
|
+
|
|
132
|
+
The [token guide](../documentation/auth.md#issue-rotate-or-revoke-an-agent-token)
|
|
133
|
+
and [Vercel trust guide](../documentation/auth.md#vercel-workload-credentials)
|
|
134
|
+
own availability, project/environment choices, and revocation details.
|
|
135
|
+
|
|
136
|
+
## What the operator remains responsible for
|
|
137
|
+
|
|
138
|
+
| Decision | Why it matters |
|
|
139
|
+
| ------------------------------ | ---------------------------------------------------------------------------------------------------- |
|
|
140
|
+
| Inbound authentication | Without configured `auth`, plain `/mcp` serves the whole catalog to anyone who can reach it. |
|
|
141
|
+
| Enable the credential vault | Encrypt stored credentials and OAuth tokens before connecting accounts. |
|
|
142
|
+
| Pool membership and tools | Each member can use every action that pool grants. |
|
|
143
|
+
| Service permissions | A shared credential uses the same account for every member. |
|
|
144
|
+
| Approval policy | A writable pool can run unattended; the Eve helper defaults to that behavior. |
|
|
145
|
+
| Tool classification | Labels must match the service's actual behavior. |
|
|
146
|
+
| Deployment and secret handling | Enable the credential vault; protect storage, encryption keys, backups, ingress, and the agent host. |
|
|
147
|
+
| Conversation routing | Keep private results out of broader chats. |
|
|
148
|
+
| Uncertain changes | Check the service before requesting another change. |
|
|
149
|
+
|
|
150
|
+
For concrete steps, use [deployment operations](../documentation/deploying.md),
|
|
151
|
+
[agent pool layout](../documentation/auth.md#organizing-an-agents-pools), and
|
|
152
|
+
[Connecting agents](./connecting-agents.md). The [security policy](../SECURITY.md)
|
|
153
|
+
explains how to report a problem.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zackbart/connecta",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.36.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"description": "One MCP to rule them all — a single MCP endpoint aggregating many downstream connectors behind a code-first surface of six meta-tools.",
|
|
@@ -33,6 +33,7 @@
|
|
|
33
33
|
"bin",
|
|
34
34
|
"dist",
|
|
35
35
|
"documentation",
|
|
36
|
+
"guides",
|
|
36
37
|
"examples/worker",
|
|
37
38
|
"templates",
|
|
38
39
|
"README.md",
|
|
@@ -74,10 +75,6 @@
|
|
|
74
75
|
"types": "./dist/auth/cloudflare-access.d.ts",
|
|
75
76
|
"import": "./dist/auth/cloudflare-access.js"
|
|
76
77
|
},
|
|
77
|
-
"./providers/basecamp": {
|
|
78
|
-
"types": "./dist/providers/basecamp/index.d.ts",
|
|
79
|
-
"import": "./dist/providers/basecamp/index.js"
|
|
80
|
-
},
|
|
81
78
|
"./providers/breeze": {
|
|
82
79
|
"types": "./dist/providers/breeze/index.d.ts",
|
|
83
80
|
"import": "./dist/providers/breeze/index.js"
|
|
@@ -110,26 +107,6 @@
|
|
|
110
107
|
"types": "./dist/providers/gmail/index.d.ts",
|
|
111
108
|
"import": "./dist/providers/gmail/index.js"
|
|
112
109
|
},
|
|
113
|
-
"./providers/infisical": {
|
|
114
|
-
"types": "./dist/providers/infisical/index.d.ts",
|
|
115
|
-
"import": "./dist/providers/infisical/index.js"
|
|
116
|
-
},
|
|
117
|
-
"./providers/intercom": {
|
|
118
|
-
"types": "./dist/providers/intercom/index.d.ts",
|
|
119
|
-
"import": "./dist/providers/intercom/index.js"
|
|
120
|
-
},
|
|
121
|
-
"./providers/linear": {
|
|
122
|
-
"types": "./dist/providers/linear/index.d.ts",
|
|
123
|
-
"import": "./dist/providers/linear/index.js"
|
|
124
|
-
},
|
|
125
|
-
"./providers/mixpanel": {
|
|
126
|
-
"types": "./dist/providers/mixpanel/index.d.ts",
|
|
127
|
-
"import": "./dist/providers/mixpanel/index.js"
|
|
128
|
-
},
|
|
129
|
-
"./providers/notion": {
|
|
130
|
-
"types": "./dist/providers/notion/index.d.ts",
|
|
131
|
-
"import": "./dist/providers/notion/index.js"
|
|
132
|
-
},
|
|
133
110
|
"./providers/overflow": {
|
|
134
111
|
"types": "./dist/providers/overflow/index.d.ts",
|
|
135
112
|
"import": "./dist/providers/overflow/index.js"
|
|
@@ -138,9 +115,9 @@
|
|
|
138
115
|
"types": "./dist/providers/planning-center/index.d.ts",
|
|
139
116
|
"import": "./dist/providers/planning-center/index.js"
|
|
140
117
|
},
|
|
141
|
-
"./providers/
|
|
142
|
-
"types": "./dist/providers/
|
|
143
|
-
"import": "./dist/providers/
|
|
118
|
+
"./providers/quickbooks": {
|
|
119
|
+
"types": "./dist/providers/quickbooks/index.d.ts",
|
|
120
|
+
"import": "./dist/providers/quickbooks/index.js"
|
|
144
121
|
},
|
|
145
122
|
"./providers/sheets": {
|
|
146
123
|
"types": "./dist/providers/sheets/index.d.ts",
|
|
@@ -162,10 +139,6 @@
|
|
|
162
139
|
"types": "./dist/providers/vercel/index.d.ts",
|
|
163
140
|
"import": "./dist/providers/vercel/index.js"
|
|
164
141
|
},
|
|
165
|
-
"./providers/wispr-flow": {
|
|
166
|
-
"types": "./dist/providers/wispr-flow/index.d.ts",
|
|
167
|
-
"import": "./dist/providers/wispr-flow/index.js"
|
|
168
|
-
},
|
|
169
142
|
"./ui": {
|
|
170
143
|
"types": "./dist/ui.d.ts",
|
|
171
144
|
"import": "./dist/ui.js"
|
|
@@ -199,7 +172,7 @@
|
|
|
199
172
|
"test:browser": "playwright test",
|
|
200
173
|
"test:browser:snapshots": "node scripts/update-operator-snapshots.mjs",
|
|
201
174
|
"pretest:browser:snapshots": "pnpm run build:operator-ui",
|
|
202
|
-
"test:node": "vitest run --
|
|
175
|
+
"test:node": "vitest run --config vitest.config.node.ts",
|
|
203
176
|
"test:workers": "vitest run --project workers",
|
|
204
177
|
"check:docs": "node scripts/check-doc-links.mjs",
|
|
205
178
|
"check:lint": "oxlint -D correctness --report-unused-disable-directives .",
|
|
@@ -209,19 +182,22 @@
|
|
|
209
182
|
"check:package": "node scripts/check-package.mjs",
|
|
210
183
|
"check:declarations": "node scripts/check-declarations.mjs --dist .",
|
|
211
184
|
"check:bundle": "node scripts/bundle-size.mjs",
|
|
212
|
-
"providers:check": "tsx scripts/drift-check.mjs --specs --
|
|
185
|
+
"providers:check": "tsx scripts/drift-check.mjs --specs --manual",
|
|
213
186
|
"drift:check": "tsx scripts/drift-check.mjs",
|
|
214
187
|
"eval:selftest": "tsx eval/selftest.ts",
|
|
215
188
|
"eval:agent": "tsx eval/run-agent.ts",
|
|
216
189
|
"eval:smoke": "tsx eval/run-smoke.ts",
|
|
190
|
+
"eval:outcomes": "tsx eval/run-outcomes.ts",
|
|
191
|
+
"preeval:outcomes": "node scripts/generate-version.mjs && pnpm run build:operator-ui",
|
|
217
192
|
"eval:perf": "tsx eval/run-perf.ts",
|
|
218
193
|
"eval:report": "tsx eval/report.ts",
|
|
219
|
-
"check:
|
|
220
|
-
"check:
|
|
221
|
-
"check": "pnpm run check:
|
|
222
|
-
"
|
|
194
|
+
"check:static": "node --test scripts/check-provider-exemptions.test.mjs && pnpm run format:check && pnpm run check:providers-generated && pnpm run check:docs && pnpm run check:changes && pnpm run check:operator-ui && pnpm run check:clerk-sdk && pnpm run check:lint && pnpm run check:unused && pnpm run typecheck",
|
|
195
|
+
"check:build": "pnpm run build && pnpm run check:declarations && pnpm run check:bundle",
|
|
196
|
+
"check:fast": "pnpm run check:static && vitest run --config vitest.config.node.ts --changed origin/main --passWithNoTests",
|
|
197
|
+
"check": "pnpm run check:static && pnpm run test && pnpm run check:build",
|
|
198
|
+
"release:check": "pnpm run release:check:core && pnpm run release:check:eve",
|
|
223
199
|
"prepack": "pnpm run check",
|
|
224
|
-
"check:changes": "node scripts/changelog.mjs --check && node
|
|
200
|
+
"check:changes": "node scripts/changelog.mjs --check && node --test scripts/changelog.test.mjs",
|
|
225
201
|
"changelog:assemble": "node scripts/changelog.mjs",
|
|
226
202
|
"providers:generate": "tsx scripts/generate-providers.mjs",
|
|
227
203
|
"check:providers-generated": "tsx scripts/generate-providers.mjs --check",
|
|
@@ -232,25 +208,29 @@
|
|
|
232
208
|
"pretest:browser": "pnpm run build:operator-ui",
|
|
233
209
|
"pretypecheck": "node scripts/generate-version.mjs && pnpm run build:operator-ui",
|
|
234
210
|
"precheck:bundle": "pnpm run build:operator-ui",
|
|
235
|
-
"precheck:fast": "pnpm run check:operator-ui",
|
|
236
211
|
"eval:regrade": "tsx eval/regrade.ts",
|
|
237
212
|
"eval:compare": "tsx eval/compare.ts",
|
|
238
213
|
"format": "oxfmt --write .",
|
|
239
214
|
"format:check": "oxfmt --check .",
|
|
240
|
-
"providers:spec": "tsx scripts/generate-openapi.mjs"
|
|
215
|
+
"providers:spec": "tsx scripts/generate-openapi.mjs",
|
|
216
|
+
"check:eve-package": "node scripts/check-eve-package.mjs",
|
|
217
|
+
"release:check:core": "pnpm run check && pnpm run test:browser && pnpm run check:examples && pnpm run check:security && pnpm run check:package",
|
|
218
|
+
"release:check:eve": "pnpm --filter @zackbart/connecta-eve run check && pnpm run check:eve-package && pnpm run check:security:eve",
|
|
219
|
+
"check:security:eve": "pnpm --dir packages/connecta-eve audit --audit-level moderate"
|
|
241
220
|
},
|
|
242
221
|
"dependencies": {
|
|
243
222
|
"@cfworker/json-schema": "^4.1.1",
|
|
244
223
|
"@modelcontextprotocol/client": "2.3.1",
|
|
245
224
|
"@modelcontextprotocol/server": "2.3.1",
|
|
246
225
|
"acorn": "^8.19.0",
|
|
247
|
-
"effect": "
|
|
248
|
-
"zod": "^4.
|
|
226
|
+
"effect": "4.0.5",
|
|
227
|
+
"zod": "^4.6.6"
|
|
249
228
|
},
|
|
250
229
|
"peerDependencies": {
|
|
251
230
|
"@clerk/backend": "^3.12.0",
|
|
252
231
|
"@cloudflare/codemode": "^0.4.4 || ^0.5.0",
|
|
253
|
-
"quickjs-emscripten": "^0.32.0"
|
|
232
|
+
"quickjs-emscripten": "^0.32.0",
|
|
233
|
+
"undici": "6.29.1"
|
|
254
234
|
},
|
|
255
235
|
"peerDependenciesMeta": {
|
|
256
236
|
"@clerk/backend": {
|
|
@@ -261,6 +241,9 @@
|
|
|
261
241
|
},
|
|
262
242
|
"quickjs-emscripten": {
|
|
263
243
|
"optional": true
|
|
244
|
+
},
|
|
245
|
+
"undici": {
|
|
246
|
+
"optional": true
|
|
264
247
|
}
|
|
265
248
|
},
|
|
266
249
|
"devDependencies": {
|
|
@@ -268,21 +251,18 @@
|
|
|
268
251
|
"@cloudflare/codemode": "^0.5.0",
|
|
269
252
|
"@cloudflare/vitest-pool-workers": "^0.18.8",
|
|
270
253
|
"@cloudflare/workers-types": "^4.20250101.0 || ^5.0.0",
|
|
254
|
+
"@effect/platform-node": "4.0.5",
|
|
271
255
|
"@fontsource-variable/hanken-grotesk": "^5.3.0",
|
|
272
256
|
"@fontsource-variable/jetbrains-mono": "^5.3.0",
|
|
273
257
|
"@playwright/test": "^1.62.0",
|
|
274
258
|
"@radix-ui/react-dialog": "^1.2.0",
|
|
275
|
-
"@radix-ui/react-slot": "^1.4.0",
|
|
276
259
|
"@radix-ui/react-tabs": "^1.1.22",
|
|
277
|
-
"@tailwindcss/node": "^4.3.3",
|
|
278
|
-
"@tailwindcss/oxide": "^4.3.3",
|
|
279
|
-
"@tanstack/react-query": "^5.104.1",
|
|
280
260
|
"@tanstack/react-router": "^1.170.41",
|
|
281
261
|
"@types/node": "^22.0.0",
|
|
282
262
|
"@types/react": "^19.3.0",
|
|
283
263
|
"@types/react-dom": "^19.3.0",
|
|
264
|
+
"alchemy": "2.0.0-beta.83",
|
|
284
265
|
"cmdk": "^1.1.1",
|
|
285
|
-
"commonmark": "^0.31.2",
|
|
286
266
|
"esbuild": "^0.28.0",
|
|
287
267
|
"knip": "^6.29.0",
|
|
288
268
|
"oxfmt": "0.72.0",
|
|
@@ -290,9 +270,9 @@
|
|
|
290
270
|
"quickjs-emscripten": "^0.32.0",
|
|
291
271
|
"react": "^19.3.0",
|
|
292
272
|
"react-dom": "^19.3.0",
|
|
293
|
-
"tailwindcss": "^4.3.3",
|
|
294
273
|
"tsx": "^4.23.1",
|
|
295
274
|
"typescript": "^5.9.3",
|
|
275
|
+
"undici": "6.29.1",
|
|
296
276
|
"vitest": "^4.1.6",
|
|
297
277
|
"wrangler": "^4.114.0"
|
|
298
278
|
}
|
|
@@ -26,6 +26,9 @@ CONNECTA_DATABASE=
|
|
|
26
26
|
# may write a credential; machine access tokens grant no interactive authority.
|
|
27
27
|
CLERK_PUBLISHABLE_KEY=
|
|
28
28
|
CLERK_SECRET_KEY=
|
|
29
|
+
# Optional with Clerk: the one Clerk Organization (org_...) whose members this
|
|
30
|
+
# deployment admits, when one Clerk instance serves several deployments.
|
|
31
|
+
CLERK_ORGANIZATION_ID=
|
|
29
32
|
# Required with Clerk: comma-separated Clerk user ids of the maintainers, who
|
|
30
33
|
# alone use plain /mcp and the operator UI.
|
|
31
34
|
CONNECTA_MAINTAINERS=
|
package/templates/node/README.md
CHANGED
|
@@ -18,6 +18,21 @@ npm run --silent rotate-token -- local-machine
|
|
|
18
18
|
npm start
|
|
19
19
|
```
|
|
20
20
|
|
|
21
|
+
Keep the template's pinned `undici` dependency and its `listen` import from
|
|
22
|
+
`@zackbart/connecta/node`. `listen` installs the owned HTTP transport used by
|
|
23
|
+
every maintained-provider request, reads included, remote MCP writes, and
|
|
24
|
+
downstream OAuth token, registration and revocation POSTs.
|
|
25
|
+
Without `listen()`, maintained-provider writes, reviewed POST reads and remote
|
|
26
|
+
MCP writes are refused before sending; downstream OAuth credential POSTs also
|
|
27
|
+
require the owned sender. It connects directly by default. For an HTTP(S) CONNECT
|
|
28
|
+
proxy, configure `listen(connecta, { port, proxy: "http://proxy.example.com:8080" })`
|
|
29
|
+
in `src/index.ts`. Ambient proxy variables and host dispatchers do not configure
|
|
30
|
+
the owned sender. Remote MCP reads and OAuth discovery GETs retain native fetch
|
|
31
|
+
and need their own host proxy policy. An uncertain refresh requires fresh
|
|
32
|
+
authorization rather than replaying the spent token. See
|
|
33
|
+
[Node transport requirements](https://github.com/zackbart/connecta/blob/main/documentation/deploying.md#start-on-node)
|
|
34
|
+
for proxy credentials and TLS trust.
|
|
35
|
+
|
|
21
36
|
The manifest approves only `esbuild@0.28.2` to run its install script. `tsx`
|
|
22
37
|
uses esbuild to run this TypeScript source, so that script is part of the
|
|
23
38
|
prescribed runtime path. npm 11 therefore installs without an unreviewed-script
|
|
@@ -173,6 +188,11 @@ Enable `aud_claim_enabled: true` in Clerk's instance OAuth application settings
|
|
|
173
188
|
(`PATCH /v1/instance/oauth_application_settings` in Clerk's Backend API), then
|
|
174
189
|
read the setting back. Both JWT and opaque OAuth tokens are supported.
|
|
175
190
|
Leave `allowedOAuthClientIds` omitted or `[]` to require bound tokens.
|
|
191
|
+
To share one Clerk instance across deployments, give each deployment its own
|
|
192
|
+
Clerk Organization and set `CLERK_ORGANIZATION_ID` to its `org_` id: only that
|
|
193
|
+
Organization's members sign in, and maintainers and pool members still come
|
|
194
|
+
from `src/connecta.config.ts`. [Clerk Organizations](https://github.com/zackbart/connecta/blob/main/documentation/auth.md#one-clerk-instance-one-organization-per-deployment)
|
|
195
|
+
lists the Clerk setup and the isolation tradeoff.
|
|
176
196
|
|
|
177
197
|
Connecta's protected-resource metadata advertises the exact public `/mcp` or
|
|
178
198
|
`/mcp/<pool>` URL as `resource` and Clerk as the authorization server. MCP
|
|
@@ -216,8 +236,8 @@ node -e "console.log(crypto.randomBytes(32).toString('base64'))"
|
|
|
216
236
|
Keep this key outside the database. Losing it makes saved values unreadable;
|
|
217
237
|
upgrades must reuse it. The shipped `time` connector declares no credential
|
|
218
238
|
slot. Add `credential: { label: "API token" }` to an `api()` connector and read
|
|
219
|
-
it through `await ctx.credential?.get()`, or use a
|
|
220
|
-
connector with `auth: { type: "
|
|
239
|
+
it through `await ctx.credential?.get()`, or use a Stripe
|
|
240
|
+
connector with `auth: { type: "apiKey" }`, which declares its own slot. Maintainers manage the slot on that
|
|
221
241
|
connector's Connection tab (`/connectors/<id>`); there is no separate Credentials tab.
|
|
222
242
|
|
|
223
243
|
In 0.25.0, this vault also seals downstream OAuth tokens on their first read.
|
|
@@ -28,6 +28,7 @@ services:
|
|
|
28
28
|
# on when set and off when empty.
|
|
29
29
|
CLERK_PUBLISHABLE_KEY: ${CLERK_PUBLISHABLE_KEY:-}
|
|
30
30
|
CLERK_SECRET_KEY: ${CLERK_SECRET_KEY:-}
|
|
31
|
+
CLERK_ORGANIZATION_ID: ${CLERK_ORGANIZATION_ID:-}
|
|
31
32
|
CONNECTA_MAINTAINERS: ${CONNECTA_MAINTAINERS:-}
|
|
32
33
|
CONNECTA_CREDENTIAL_KEY: ${CONNECTA_CREDENTIAL_KEY:-}
|
|
33
34
|
CONNECTA_ACTIVITY: ${CONNECTA_ACTIVITY:-}
|
|
@@ -18,8 +18,9 @@
|
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"@clerk/backend": "^3.12.0",
|
|
21
|
-
"@zackbart/connecta": "0.
|
|
22
|
-
"quickjs-emscripten": "0.32.0"
|
|
21
|
+
"@zackbart/connecta": "0.36.0",
|
|
22
|
+
"quickjs-emscripten": "0.32.0",
|
|
23
|
+
"undici": "6.29.1"
|
|
23
24
|
},
|
|
24
25
|
"devDependencies": {
|
|
25
26
|
"@types/node": "^22.0.0",
|
|
@@ -25,6 +25,7 @@ export interface Env {
|
|
|
25
25
|
CONNECTA_DATABASE?: string;
|
|
26
26
|
CLERK_PUBLISHABLE_KEY?: string;
|
|
27
27
|
CLERK_SECRET_KEY?: string;
|
|
28
|
+
CLERK_ORGANIZATION_ID?: string;
|
|
28
29
|
CONNECTA_MAINTAINERS?: string;
|
|
29
30
|
CONNECTA_CREDENTIAL_KEY?: string;
|
|
30
31
|
CONNECTA_ACTIVITY?: string;
|
|
@@ -43,6 +44,10 @@ export default defineConfig((env: Env) => {
|
|
|
43
44
|
if (Boolean(clerkPublishableKey) !== Boolean(clerkSecretKey)) {
|
|
44
45
|
throw new Error("Operator sign-in needs both CLERK_PUBLISHABLE_KEY and CLERK_SECRET_KEY.");
|
|
45
46
|
}
|
|
47
|
+
const clerkOrganizationId = set("CLERK_ORGANIZATION_ID");
|
|
48
|
+
if (clerkOrganizationId && !clerkSecretKey) {
|
|
49
|
+
throw new Error("CLERK_ORGANIZATION_ID needs CLERK_PUBLISHABLE_KEY and CLERK_SECRET_KEY.");
|
|
50
|
+
}
|
|
46
51
|
const clerk =
|
|
47
52
|
clerkPublishableKey && clerkSecretKey
|
|
48
53
|
? clerkAuth({
|
|
@@ -51,6 +56,9 @@ export default defineConfig((env: Env) => {
|
|
|
51
56
|
// Enable Clerk aud_claim_enabled; hosts request the MCP URL as
|
|
52
57
|
// resource. Bound JWT and opaque tokens are the default.
|
|
53
58
|
publicUrl,
|
|
59
|
+
// One Clerk instance can serve many deployments, one Organization
|
|
60
|
+
// each: with CLERK_ORGANIZATION_ID set, only its members sign in.
|
|
61
|
+
...(clerkOrganizationId ? { organizationId: clerkOrganizationId } : {}),
|
|
54
62
|
// Restrict who may sign in with `allowedDomains: ["acme.com"]`, or
|
|
55
63
|
// `gate` for anything a domain cannot express. Absent, every
|
|
56
64
|
// authenticated Clerk user is admitted.
|
package/dist/catalog-drift.d.ts
DELETED
|
@@ -1,138 +0,0 @@
|
|
|
1
|
-
import type { CatalogDriftCounts, CatalogDriftReport, Connector, Logger, ToolClassification, ToolDef } from "./types.js";
|
|
2
|
-
/**
|
|
3
|
-
* Rebuild a drift report as bounded counts, closed verification facts, and a timestamp.
|
|
4
|
-
*
|
|
5
|
-
* `Connector.catalogDrift()` sits on the open plugin seam, and what it returns
|
|
6
|
-
* lands on authenticated connector status and the operator page. TypeScript
|
|
7
|
-
* constrains neither extra enumerable properties nor `observedAt` at runtime.
|
|
8
|
-
* Counts, closed verification facts, and a time are rebuilt at the boundary where
|
|
9
|
-
* third-party output becomes a response — rather than trusted. A report whose
|
|
10
|
-
* `observedAt` names no instant is no observation connecta can date, and is
|
|
11
|
-
* dropped whole (INV-6): a plugin forwarding a downstream's report could
|
|
12
|
-
* otherwise put any text there. The activity path reconstructs its five
|
|
13
|
-
* fields for the same reason.
|
|
14
|
-
*/
|
|
15
|
-
export declare function boundedCatalogDrift(report: CatalogDriftReport | undefined): CatalogDriftReport | undefined;
|
|
16
|
-
/**
|
|
17
|
-
* What a release decided a tool does. `"read-only"` is observational;
|
|
18
|
-
* `"destructive"` modifies or removes state that already exists; `"additive"`
|
|
19
|
-
* only brings something new into being. Both writes leave the read-only path
|
|
20
|
-
* — the distinction decides whether the connection asserts `destructiveHint`,
|
|
21
|
-
* which shapes the approval copy a human reads.
|
|
22
|
-
*/
|
|
23
|
-
type VettedVerdict = "read-only" | "additive" | "destructive";
|
|
24
|
-
/** One tool as a release reviewed it. */
|
|
25
|
-
interface VettedToolRecord {
|
|
26
|
-
verdict: VettedVerdict;
|
|
27
|
-
/**
|
|
28
|
-
* Digest of the input and output schemas that release read, or undefined
|
|
29
|
-
* when no release has recorded them. Undefined is not "unchanged": a
|
|
30
|
-
* manifest with no digest cannot report a schema change, and says so by
|
|
31
|
-
* counting none and reporting the unpinned coverage. The provider check never
|
|
32
|
-
* creates or updates schema digests; live `tools/list` remains the schema
|
|
33
|
-
* agents receive ([#351](https://github.com/zackbart/connecta/issues/351)).
|
|
34
|
-
*/
|
|
35
|
-
schemaDigest?: string;
|
|
36
|
-
optional?: boolean;
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* The vetted manifest one hosted-MCP proxy ships: every tool name a release
|
|
40
|
-
* reviewed, what it reviewed it as, and — where a release recorded them — the
|
|
41
|
-
* schemas it read. This is the single per-provider source P13 asks for, so the
|
|
42
|
-
* classification the connector applies and the classification a drift check
|
|
43
|
-
* compares against cannot disagree.
|
|
44
|
-
*/
|
|
45
|
-
export interface VettedCatalog {
|
|
46
|
-
unlisted?: "hide";
|
|
47
|
-
/** Manifest format. Bumped when the comparison itself changes shape. */
|
|
48
|
-
version: 1;
|
|
49
|
-
tools: ReadonlyMap<string, VettedToolRecord>;
|
|
50
|
-
}
|
|
51
|
-
export interface VettedCatalogInput {
|
|
52
|
-
/** Names whose contract is observational rather than mutating. */
|
|
53
|
-
reads: ReadonlySet<string>;
|
|
54
|
-
/** Names that write, with the verdict that shapes the approval copy. */
|
|
55
|
-
writes: ReadonlyMap<string, "additive" | "destructive">;
|
|
56
|
-
/**
|
|
57
|
-
* Schemas this release reviewed, as `name` → digest from
|
|
58
|
-
* {@link vettedSchemaDigest}. Omit entirely until a release has actually
|
|
59
|
-
* read them; an invented digest reports drift that never happened.
|
|
60
|
-
*/
|
|
61
|
-
schemaDigests?: Readonly<Record<string, string>>;
|
|
62
|
-
/** Reviewed names that may be absent under plan/permission gating. */
|
|
63
|
-
optionalTools?: ReadonlySet<string>;
|
|
64
|
-
}
|
|
65
|
-
/**
|
|
66
|
-
* Digest the schemas of one downstream tool.
|
|
67
|
-
*
|
|
68
|
-
* Canonical rather than literal, unlike the catalog fingerprint in
|
|
69
|
-
* `src/catalog-fingerprint.ts`: that one is deliberately conservative because a
|
|
70
|
-
* spurious cache write is cheap, while a spurious drift finding spends a
|
|
71
|
-
* maintainer's attention on a downstream that reordered its JSON keys.
|
|
72
|
-
* New pins use `sha256-sets-v1:` and sort required, enum, and type arrays only
|
|
73
|
-
* at schema keyword locations. Tuple arrays and JSON data keep their order.
|
|
74
|
-
* Legacy `sha256:` pins use the original literal-array form, so an upgrade
|
|
75
|
-
* cannot silently invalidate a reviewed provider manifest.
|
|
76
|
-
* Description and annotations are excluded — a reworded description is P1's
|
|
77
|
-
* business, and an annotation change is already its own drift category.
|
|
78
|
-
*
|
|
79
|
-
* Rejects rather than digesting part of a schema: a digest that ignored some
|
|
80
|
-
* leaf would let a reviewed read keep its verdict after that leaf changed.
|
|
81
|
-
*/
|
|
82
|
-
export declare function vettedSchemaDigest(tool: ToolDef, format?: "sets-v1" | "legacy"): Promise<string>;
|
|
83
|
-
/**
|
|
84
|
-
* Build a provider's manifest from the lists it already maintains.
|
|
85
|
-
*
|
|
86
|
-
* Throws when a name is classified twice, because a tool that is both a read
|
|
87
|
-
* and a write is a review mistake that must not boot: the annotation the
|
|
88
|
-
* connector would apply depends on which branch runs first, and "safe by
|
|
89
|
-
* default" cannot be decided by ordering.
|
|
90
|
-
*/
|
|
91
|
-
export declare function vettedCatalog(input: VettedCatalogInput): VettedCatalog;
|
|
92
|
-
/** Validate a {@link ToolClassification} and build the manifest it describes. */
|
|
93
|
-
export declare function reviewedCatalog(classification: ToolClassification, owner: string): VettedCatalog;
|
|
94
|
-
/**
|
|
95
|
-
* Validate a {@link ToolClassification} and return a deep-frozen copy of it:
|
|
96
|
-
* what a connector carries as `classification`, so neither the caller's
|
|
97
|
-
* original object nor a write through the connector can change a verdict
|
|
98
|
-
* after review.
|
|
99
|
-
*/
|
|
100
|
-
export declare function reviewedClassification(classification: ToolClassification, owner: string): ToolClassification;
|
|
101
|
-
/** One whole-schema verification shared by reporting and serving this listing. */
|
|
102
|
-
export interface CatalogSchemaVerification {
|
|
103
|
-
changed: ReadonlySet<string>;
|
|
104
|
-
available: boolean;
|
|
105
|
-
}
|
|
106
|
-
/**
|
|
107
|
-
* Compare a live catalog with the manifest and count what moved.
|
|
108
|
-
*
|
|
109
|
-
* Counts only, and by construction: there is nowhere here to put a tool name,
|
|
110
|
-
* a schema, or a downstream string, so no later surface has to remember to
|
|
111
|
-
* strip one. Reads nothing but the tools it was handed — the caller already
|
|
112
|
-
* fetched them to serve a request, and this function never fetches anything.
|
|
113
|
-
*/
|
|
114
|
-
export declare function detectCatalogDrift(catalog: VettedCatalog, tools: readonly ToolDef[]): Promise<CatalogDriftCounts>;
|
|
115
|
-
/**
|
|
116
|
-
* The review `connector.classification` declares, or undefined when it
|
|
117
|
-
* declares none. Throws on a malformed one (INV-11).
|
|
118
|
-
*/
|
|
119
|
-
export declare function catalogReviewOf(connector: Connector): VettedCatalog | undefined;
|
|
120
|
-
/**
|
|
121
|
-
* Classify downstream facts with a review: what the registry serves on every
|
|
122
|
-
* read, from whichever cache layer the facts came from.
|
|
123
|
-
*
|
|
124
|
-
* Every tool returned is fresh. The registry supplies the same whole-schema
|
|
125
|
-
* verification it observed for this listing, including failures. Standalone
|
|
126
|
-
* callers verify here. No failed verification survives onto a later listing,
|
|
127
|
-
* and meanwhile no digested review vouches for a read (INV-1).
|
|
128
|
-
*/
|
|
129
|
-
export declare function classifyCatalog(catalog: VettedCatalog, connectorId: string, facts: readonly ToolDef[], logger: Logger, overrides?: Readonly<Record<string, "read" | "write">>, verification?: CatalogSchemaVerification): Promise<ToolDef[]>;
|
|
130
|
-
/**
|
|
131
|
-
* Observe tools already fetched by a listing. No probe, persistence, or catalog
|
|
132
|
-
* payload: registry-owned partition tokens isolate deployment and subject.
|
|
133
|
-
* A digest failure replaces old success, while classification fails closed.
|
|
134
|
-
*/
|
|
135
|
-
export declare function observeReviewedDrift(connector: Connector, catalog: VettedCatalog | undefined, listed: readonly ToolDef[], logger: Logger, partition?: object, droppedTools?: number): Promise<CatalogSchemaVerification | undefined>;
|
|
136
|
-
/** Look up only this runtime/catalog partition; never start a listing. */
|
|
137
|
-
export declare function observedCatalogDrift(connector: Connector, partition?: object): CatalogDriftReport | undefined;
|
|
138
|
-
export {};
|