@integrity-labs/agt-cli 0.28.1054 → 0.28.1056

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 (24) hide show
  1. package/dist/bin/agt.js +5 -5
  2. package/dist/{chunk-AT7E625H.js → chunk-A7HDJW23.js} +2 -2
  3. package/dist/{chunk-M4ADTK6F.js → chunk-M5P24M2Z.js} +11 -5
  4. package/dist/{chunk-M4ADTK6F.js.map → chunk-M5P24M2Z.js.map} +1 -1
  5. package/dist/{chunk-2SGXGNDW.js → chunk-P544KDE3.js} +129 -36
  6. package/dist/chunk-P544KDE3.js.map +1 -0
  7. package/dist/{claude-pair-runtime-GO3C7KT6.js → claude-pair-runtime-TSRRFBNJ.js} +2 -2
  8. package/dist/lib/manager-worker.js +17 -14
  9. package/dist/lib/manager-worker.js.map +1 -1
  10. package/dist/mcp/direct-chat-channel.js +31 -33
  11. package/dist/mcp/index.js +31 -33
  12. package/dist/mcp/origami.js +31 -33
  13. package/dist/mcp/slack-channel.js +31 -33
  14. package/dist/mcp/telegram-channel.js +31 -33
  15. package/dist/{persistent-session-3WRSJIDM.js → persistent-session-WSJVCGEO.js} +3 -3
  16. package/dist/{responsiveness-probe-2DF6VH7Q.js → responsiveness-probe-7MQI6SUF.js} +3 -3
  17. package/dist/{session-auth-dead-GRTHA2Z5.js → session-auth-dead-NFVTUFPI.js} +2 -2
  18. package/package.json +1 -1
  19. package/dist/chunk-2SGXGNDW.js.map +0 -1
  20. /package/dist/{chunk-AT7E625H.js.map → chunk-A7HDJW23.js.map} +0 -0
  21. /package/dist/{claude-pair-runtime-GO3C7KT6.js.map → claude-pair-runtime-TSRRFBNJ.js.map} +0 -0
  22. /package/dist/{persistent-session-3WRSJIDM.js.map → persistent-session-WSJVCGEO.js.map} +0 -0
  23. /package/dist/{responsiveness-probe-2DF6VH7Q.js.map → responsiveness-probe-7MQI6SUF.js.map} +0 -0
  24. /package/dist/{session-auth-dead-GRTHA2Z5.js.map → session-auth-dead-NFVTUFPI.js.map} +0 -0
@@ -30595,7 +30595,7 @@ var integration_metadata_v1_default = {
30595
30595
  type: "string",
30596
30596
  format: "uri",
30597
30597
  pattern: "^https://",
30598
- description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty)."
30598
+ description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty), unless the definition declares a per-install `base_url_template` instead (CS-1863)."
30599
30599
  },
30600
30600
  auth_scheme: {
30601
30601
  type: "string",
@@ -30629,6 +30629,22 @@ var integration_metadata_v1_default = {
30629
30629
  }
30630
30630
  }
30631
30631
  },
30632
+ base_url_template: {
30633
+ type: "object",
30634
+ description: "A PER-INSTALL API host (CS-1863), for vendors with one host per customer (Storrito: https://<ORG_UUID>.storrito.com/api/v1). Used when base_url is absent. `template` holds exactly one `{value}` placeholder in its host; the value is read from the install's config[config_key], must match value_pattern in full, and the built host must be exactly <value>.<host_suffix> over https. Resolved and re-validated at call time by resolveIntegrationBaseUrl.",
30635
+ additionalProperties: false,
30636
+ required: ["template", "config_key", "value_pattern", "host_suffix"],
30637
+ properties: {
30638
+ template: { type: "string", pattern: "^https://\\{value\\}\\.[^{}]+$" },
30639
+ config_key: { type: "string", pattern: "^[a-z][a-z0-9_]*$" },
30640
+ value_pattern: { type: "string", minLength: 1 },
30641
+ host_suffix: { type: "string", pattern: "^[a-z0-9.-]+\\.[a-z]{2,}$" }
30642
+ }
30643
+ },
30644
+ redirect_means_auth_failure: {
30645
+ type: "boolean",
30646
+ description: "The vendor answers a rejected credential with a REDIRECT (Storrito: a 302 to its login page) rather than a 401. A redirected non-GET call is never followed (vendor-fetch.ts) and always fails; with this set, it is also treated like a 401 and the install is flagged for re-auth."
30647
+ },
30632
30648
  tools: {
30633
30649
  type: "array",
30634
30650
  description: "Auto-loaded MCP tool descriptors. Each entry produces one MCP tool entry per supported runtime scope.",
@@ -30640,7 +30656,10 @@ var integration_metadata_v1_default = {
30640
30656
  properties: { tools: { type: "array", minItems: 1 } },
30641
30657
  required: ["tools"]
30642
30658
  },
30643
- then: { required: ["base_url"] },
30659
+ then: {
30660
+ description: "A tool needs an API root: a fixed base_url, or a per-install base_url_template (CS-1863).",
30661
+ anyOf: [{ required: ["base_url"] }, { required: ["base_url_template"] }]
30662
+ },
30644
30663
  not: {
30645
30664
  description: "auth_scheme and auth_encoding are mutually exclusive (ENG-10524). The templater refuses the combination on every call, so catalog validation refuses it first.",
30646
30665
  required: ["auth_scheme", "auth_encoding"]
@@ -37838,7 +37857,7 @@ var FLAG_REGISTRY = [
37838
37857
  },
37839
37858
  {
37840
37859
  key: "email-require-approval-enforcement",
37841
- description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are armed by an org-scoped override written at org creation; existing orgs stay off until an operator flips them. Evaluated per-org. Ships dark.',
37860
+ description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are no longer armed (ENG-11234). Orgs created while the ENG-9629/9675 new-org arm was live keep their org-scoped ON override until an operator flips them per org. Evaluated per-org. Ships dark.',
37842
37861
  flagType: "boolean",
37843
37862
  // Declared safe value is `false` (no hold). A flag-DB read error degrades here, so a flags
37844
37863
  // outage can never silently start holding real customer email — the same fail-OPEN posture
@@ -37848,36 +37867,15 @@ var FLAG_REGISTRY = [
37848
37867
  defaultValue: false,
37849
37868
  // Turning it on holds real customer email pending a human tap, so it is a deliberate,
37850
37869
  // audited per-org flip (ADR-0022 §4).
37851
- sensitive: true,
37852
- // ENG-9629: NEW orgs are armed on. Declared here rather than hardcoded in the
37853
- // seeding code, so `listNewOrgFlagOverrides()` is the one answer to "which flags
37854
- // does a new org get". `defaultValue` stays false so the ~4 months of orgs already
37855
- // carrying an inert enforce-level email.require_approval row are NOT armed on deploy.
37856
- // ENG-9675: EVERY creation path, self-serve included.
37857
- //
37858
- // ENG-9630 had restricted this to API-created orgs on the grounds that a
37859
- // self-serve org has no way of being TOLD about a held send — no Slack
37860
- // alert channel is wired at signup. That reasoning was wrong, and the check
37861
- // behind it was incomplete: it confirmed an in-console page exists at
37862
- // /organization/approvals and stopped, without looking at the dispatch path.
37863
- //
37864
- // `routeBlockedCallToApproval` has three dispatchers, and the Direct Chat
37865
- // one (lib/integration-broker-approval-direct-chat.ts, ENG-7680) is the
37866
- // universal fallback — "every managed agent always has a Direct Chat session
37867
- // its operator/manager watches in the Console ... usable out of the box with
37868
- // no per-org approval-route setup and no Slack dependency". It posts into a
37869
- // thread keyed on the approval_requests.id and correlates the manager's
37870
- // reply back through tryCaptureDirectChatApproval, so a self-serve org has
37871
- // both a zero-config delivery channel AND a reply path.
37872
- //
37873
- // With the stated blocker gone, the guardrail's own promise — "before
37874
- // sending any email" — applies to the organizations with the LEAST operator
37875
- // oversight exactly as it does to the rest.
37876
- //
37877
- // Existing self-serve orgs are deliberately NOT armed by this: newOrgOverride
37878
- // is applied at creation, and nothing backfills. Extending it to them is a
37879
- // separate decision with a comms obligation.
37880
- newOrgOverride: true
37870
+ sensitive: true
37871
+ // No newOrgOverride (ENG-11234). ENG-9629/ENG-9675 armed this on EVERY new org at
37872
+ // creation, so every org created since then held each dispatching send, internal
37873
+ // recipients included, behind a human tap. In practice that stalled real work: Pedders
37874
+ // (CS-1904/1908/1910) had an agent's emails to its own principal expire unapproved,
37875
+ // because "any email" includes the person the agent works for. New orgs now start at
37876
+ // `defaultValue` (off) like every other org; turning it on is the deliberate, audited
37877
+ // per-org flip `sensitive: true` already describes. Orgs armed by the old override keep
37878
+ // their override row; nothing here disarms them (that is an operator decision per org).
37881
37879
  },
37882
37880
  {
37883
37881
  key: "mail-rule-control-enforcement",
package/dist/mcp/index.js CHANGED
@@ -23199,7 +23199,7 @@ var integration_metadata_v1_default = {
23199
23199
  type: "string",
23200
23200
  format: "uri",
23201
23201
  pattern: "^https://",
23202
- description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty)."
23202
+ description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty), unless the definition declares a per-install `base_url_template` instead (CS-1863)."
23203
23203
  },
23204
23204
  auth_scheme: {
23205
23205
  type: "string",
@@ -23233,6 +23233,22 @@ var integration_metadata_v1_default = {
23233
23233
  }
23234
23234
  }
23235
23235
  },
23236
+ base_url_template: {
23237
+ type: "object",
23238
+ description: "A PER-INSTALL API host (CS-1863), for vendors with one host per customer (Storrito: https://<ORG_UUID>.storrito.com/api/v1). Used when base_url is absent. `template` holds exactly one `{value}` placeholder in its host; the value is read from the install's config[config_key], must match value_pattern in full, and the built host must be exactly <value>.<host_suffix> over https. Resolved and re-validated at call time by resolveIntegrationBaseUrl.",
23239
+ additionalProperties: false,
23240
+ required: ["template", "config_key", "value_pattern", "host_suffix"],
23241
+ properties: {
23242
+ template: { type: "string", pattern: "^https://\\{value\\}\\.[^{}]+$" },
23243
+ config_key: { type: "string", pattern: "^[a-z][a-z0-9_]*$" },
23244
+ value_pattern: { type: "string", minLength: 1 },
23245
+ host_suffix: { type: "string", pattern: "^[a-z0-9.-]+\\.[a-z]{2,}$" }
23246
+ }
23247
+ },
23248
+ redirect_means_auth_failure: {
23249
+ type: "boolean",
23250
+ description: "The vendor answers a rejected credential with a REDIRECT (Storrito: a 302 to its login page) rather than a 401. A redirected non-GET call is never followed (vendor-fetch.ts) and always fails; with this set, it is also treated like a 401 and the install is flagged for re-auth."
23251
+ },
23236
23252
  tools: {
23237
23253
  type: "array",
23238
23254
  description: "Auto-loaded MCP tool descriptors. Each entry produces one MCP tool entry per supported runtime scope.",
@@ -23244,7 +23260,10 @@ var integration_metadata_v1_default = {
23244
23260
  properties: { tools: { type: "array", minItems: 1 } },
23245
23261
  required: ["tools"]
23246
23262
  },
23247
- then: { required: ["base_url"] },
23263
+ then: {
23264
+ description: "A tool needs an API root: a fixed base_url, or a per-install base_url_template (CS-1863).",
23265
+ anyOf: [{ required: ["base_url"] }, { required: ["base_url_template"] }]
23266
+ },
23248
23267
  not: {
23249
23268
  description: "auth_scheme and auth_encoding are mutually exclusive (ENG-10524). The templater refuses the combination on every call, so catalog validation refuses it first.",
23250
23269
  required: ["auth_scheme", "auth_encoding"]
@@ -30169,7 +30188,7 @@ var FLAG_REGISTRY = [
30169
30188
  },
30170
30189
  {
30171
30190
  key: "email-require-approval-enforcement",
30172
- description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are armed by an org-scoped override written at org creation; existing orgs stay off until an operator flips them. Evaluated per-org. Ships dark.',
30191
+ description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are no longer armed (ENG-11234). Orgs created while the ENG-9629/9675 new-org arm was live keep their org-scoped ON override until an operator flips them per org. Evaluated per-org. Ships dark.',
30173
30192
  flagType: "boolean",
30174
30193
  // Declared safe value is `false` (no hold). A flag-DB read error degrades here, so a flags
30175
30194
  // outage can never silently start holding real customer email — the same fail-OPEN posture
@@ -30179,36 +30198,15 @@ var FLAG_REGISTRY = [
30179
30198
  defaultValue: false,
30180
30199
  // Turning it on holds real customer email pending a human tap, so it is a deliberate,
30181
30200
  // audited per-org flip (ADR-0022 §4).
30182
- sensitive: true,
30183
- // ENG-9629: NEW orgs are armed on. Declared here rather than hardcoded in the
30184
- // seeding code, so `listNewOrgFlagOverrides()` is the one answer to "which flags
30185
- // does a new org get". `defaultValue` stays false so the ~4 months of orgs already
30186
- // carrying an inert enforce-level email.require_approval row are NOT armed on deploy.
30187
- // ENG-9675: EVERY creation path, self-serve included.
30188
- //
30189
- // ENG-9630 had restricted this to API-created orgs on the grounds that a
30190
- // self-serve org has no way of being TOLD about a held send — no Slack
30191
- // alert channel is wired at signup. That reasoning was wrong, and the check
30192
- // behind it was incomplete: it confirmed an in-console page exists at
30193
- // /organization/approvals and stopped, without looking at the dispatch path.
30194
- //
30195
- // `routeBlockedCallToApproval` has three dispatchers, and the Direct Chat
30196
- // one (lib/integration-broker-approval-direct-chat.ts, ENG-7680) is the
30197
- // universal fallback — "every managed agent always has a Direct Chat session
30198
- // its operator/manager watches in the Console ... usable out of the box with
30199
- // no per-org approval-route setup and no Slack dependency". It posts into a
30200
- // thread keyed on the approval_requests.id and correlates the manager's
30201
- // reply back through tryCaptureDirectChatApproval, so a self-serve org has
30202
- // both a zero-config delivery channel AND a reply path.
30203
- //
30204
- // With the stated blocker gone, the guardrail's own promise — "before
30205
- // sending any email" — applies to the organizations with the LEAST operator
30206
- // oversight exactly as it does to the rest.
30207
- //
30208
- // Existing self-serve orgs are deliberately NOT armed by this: newOrgOverride
30209
- // is applied at creation, and nothing backfills. Extending it to them is a
30210
- // separate decision with a comms obligation.
30211
- newOrgOverride: true
30201
+ sensitive: true
30202
+ // No newOrgOverride (ENG-11234). ENG-9629/ENG-9675 armed this on EVERY new org at
30203
+ // creation, so every org created since then held each dispatching send, internal
30204
+ // recipients included, behind a human tap. In practice that stalled real work: Pedders
30205
+ // (CS-1904/1908/1910) had an agent's emails to its own principal expire unapproved,
30206
+ // because "any email" includes the person the agent works for. New orgs now start at
30207
+ // `defaultValue` (off) like every other org; turning it on is the deliberate, audited
30208
+ // per-org flip `sensitive: true` already describes. Orgs armed by the old override keep
30209
+ // their override row; nothing here disarms them (that is an operator decision per org).
30212
30210
  },
30213
30211
  {
30214
30212
  key: "mail-rule-control-enforcement",
@@ -37111,7 +37111,7 @@ var integration_metadata_v1_default = {
37111
37111
  type: "string",
37112
37112
  format: "uri",
37113
37113
  pattern: "^https://",
37114
- description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty)."
37114
+ description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty), unless the definition declares a per-install `base_url_template` instead (CS-1863)."
37115
37115
  },
37116
37116
  auth_scheme: {
37117
37117
  type: "string",
@@ -37145,6 +37145,22 @@ var integration_metadata_v1_default = {
37145
37145
  }
37146
37146
  }
37147
37147
  },
37148
+ base_url_template: {
37149
+ type: "object",
37150
+ description: "A PER-INSTALL API host (CS-1863), for vendors with one host per customer (Storrito: https://<ORG_UUID>.storrito.com/api/v1). Used when base_url is absent. `template` holds exactly one `{value}` placeholder in its host; the value is read from the install's config[config_key], must match value_pattern in full, and the built host must be exactly <value>.<host_suffix> over https. Resolved and re-validated at call time by resolveIntegrationBaseUrl.",
37151
+ additionalProperties: false,
37152
+ required: ["template", "config_key", "value_pattern", "host_suffix"],
37153
+ properties: {
37154
+ template: { type: "string", pattern: "^https://\\{value\\}\\.[^{}]+$" },
37155
+ config_key: { type: "string", pattern: "^[a-z][a-z0-9_]*$" },
37156
+ value_pattern: { type: "string", minLength: 1 },
37157
+ host_suffix: { type: "string", pattern: "^[a-z0-9.-]+\\.[a-z]{2,}$" }
37158
+ }
37159
+ },
37160
+ redirect_means_auth_failure: {
37161
+ type: "boolean",
37162
+ description: "The vendor answers a rejected credential with a REDIRECT (Storrito: a 302 to its login page) rather than a 401. A redirected non-GET call is never followed (vendor-fetch.ts) and always fails; with this set, it is also treated like a 401 and the install is flagged for re-auth."
37163
+ },
37148
37164
  tools: {
37149
37165
  type: "array",
37150
37166
  description: "Auto-loaded MCP tool descriptors. Each entry produces one MCP tool entry per supported runtime scope.",
@@ -37156,7 +37172,10 @@ var integration_metadata_v1_default = {
37156
37172
  properties: { tools: { type: "array", minItems: 1 } },
37157
37173
  required: ["tools"]
37158
37174
  },
37159
- then: { required: ["base_url"] },
37175
+ then: {
37176
+ description: "A tool needs an API root: a fixed base_url, or a per-install base_url_template (CS-1863).",
37177
+ anyOf: [{ required: ["base_url"] }, { required: ["base_url_template"] }]
37178
+ },
37160
37179
  not: {
37161
37180
  description: "auth_scheme and auth_encoding are mutually exclusive (ENG-10524). The templater refuses the combination on every call, so catalog validation refuses it first.",
37162
37181
  required: ["auth_scheme", "auth_encoding"]
@@ -44083,7 +44102,7 @@ var FLAG_REGISTRY = [
44083
44102
  },
44084
44103
  {
44085
44104
  key: "email-require-approval-enforcement",
44086
- description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are armed by an org-scoped override written at org creation; existing orgs stay off until an operator flips them. Evaluated per-org. Ships dark.',
44105
+ description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are no longer armed (ENG-11234). Orgs created while the ENG-9629/9675 new-org arm was live keep their org-scoped ON override until an operator flips them per org. Evaluated per-org. Ships dark.',
44087
44106
  flagType: "boolean",
44088
44107
  // Declared safe value is `false` (no hold). A flag-DB read error degrades here, so a flags
44089
44108
  // outage can never silently start holding real customer email — the same fail-OPEN posture
@@ -44093,36 +44112,15 @@ var FLAG_REGISTRY = [
44093
44112
  defaultValue: false,
44094
44113
  // Turning it on holds real customer email pending a human tap, so it is a deliberate,
44095
44114
  // audited per-org flip (ADR-0022 §4).
44096
- sensitive: true,
44097
- // ENG-9629: NEW orgs are armed on. Declared here rather than hardcoded in the
44098
- // seeding code, so `listNewOrgFlagOverrides()` is the one answer to "which flags
44099
- // does a new org get". `defaultValue` stays false so the ~4 months of orgs already
44100
- // carrying an inert enforce-level email.require_approval row are NOT armed on deploy.
44101
- // ENG-9675: EVERY creation path, self-serve included.
44102
- //
44103
- // ENG-9630 had restricted this to API-created orgs on the grounds that a
44104
- // self-serve org has no way of being TOLD about a held send — no Slack
44105
- // alert channel is wired at signup. That reasoning was wrong, and the check
44106
- // behind it was incomplete: it confirmed an in-console page exists at
44107
- // /organization/approvals and stopped, without looking at the dispatch path.
44108
- //
44109
- // `routeBlockedCallToApproval` has three dispatchers, and the Direct Chat
44110
- // one (lib/integration-broker-approval-direct-chat.ts, ENG-7680) is the
44111
- // universal fallback — "every managed agent always has a Direct Chat session
44112
- // its operator/manager watches in the Console ... usable out of the box with
44113
- // no per-org approval-route setup and no Slack dependency". It posts into a
44114
- // thread keyed on the approval_requests.id and correlates the manager's
44115
- // reply back through tryCaptureDirectChatApproval, so a self-serve org has
44116
- // both a zero-config delivery channel AND a reply path.
44117
- //
44118
- // With the stated blocker gone, the guardrail's own promise — "before
44119
- // sending any email" — applies to the organizations with the LEAST operator
44120
- // oversight exactly as it does to the rest.
44121
- //
44122
- // Existing self-serve orgs are deliberately NOT armed by this: newOrgOverride
44123
- // is applied at creation, and nothing backfills. Extending it to them is a
44124
- // separate decision with a comms obligation.
44125
- newOrgOverride: true
44115
+ sensitive: true
44116
+ // No newOrgOverride (ENG-11234). ENG-9629/ENG-9675 armed this on EVERY new org at
44117
+ // creation, so every org created since then held each dispatching send, internal
44118
+ // recipients included, behind a human tap. In practice that stalled real work: Pedders
44119
+ // (CS-1904/1908/1910) had an agent's emails to its own principal expire unapproved,
44120
+ // because "any email" includes the person the agent works for. New orgs now start at
44121
+ // `defaultValue` (off) like every other org; turning it on is the deliberate, audited
44122
+ // per-org flip `sensitive: true` already describes. Orgs armed by the old override keep
44123
+ // their override row; nothing here disarms them (that is an operator decision per org).
44126
44124
  },
44127
44125
  {
44128
44126
  key: "mail-rule-control-enforcement",
@@ -31559,7 +31559,7 @@ var integration_metadata_v1_default = {
31559
31559
  type: "string",
31560
31560
  format: "uri",
31561
31561
  pattern: "^https://",
31562
- description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty)."
31562
+ description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty), unless the definition declares a per-install `base_url_template` instead (CS-1863)."
31563
31563
  },
31564
31564
  auth_scheme: {
31565
31565
  type: "string",
@@ -31593,6 +31593,22 @@ var integration_metadata_v1_default = {
31593
31593
  }
31594
31594
  }
31595
31595
  },
31596
+ base_url_template: {
31597
+ type: "object",
31598
+ description: "A PER-INSTALL API host (CS-1863), for vendors with one host per customer (Storrito: https://<ORG_UUID>.storrito.com/api/v1). Used when base_url is absent. `template` holds exactly one `{value}` placeholder in its host; the value is read from the install's config[config_key], must match value_pattern in full, and the built host must be exactly <value>.<host_suffix> over https. Resolved and re-validated at call time by resolveIntegrationBaseUrl.",
31599
+ additionalProperties: false,
31600
+ required: ["template", "config_key", "value_pattern", "host_suffix"],
31601
+ properties: {
31602
+ template: { type: "string", pattern: "^https://\\{value\\}\\.[^{}]+$" },
31603
+ config_key: { type: "string", pattern: "^[a-z][a-z0-9_]*$" },
31604
+ value_pattern: { type: "string", minLength: 1 },
31605
+ host_suffix: { type: "string", pattern: "^[a-z0-9.-]+\\.[a-z]{2,}$" }
31606
+ }
31607
+ },
31608
+ redirect_means_auth_failure: {
31609
+ type: "boolean",
31610
+ description: "The vendor answers a rejected credential with a REDIRECT (Storrito: a 302 to its login page) rather than a 401. A redirected non-GET call is never followed (vendor-fetch.ts) and always fails; with this set, it is also treated like a 401 and the install is flagged for re-auth."
31611
+ },
31596
31612
  tools: {
31597
31613
  type: "array",
31598
31614
  description: "Auto-loaded MCP tool descriptors. Each entry produces one MCP tool entry per supported runtime scope.",
@@ -31604,7 +31620,10 @@ var integration_metadata_v1_default = {
31604
31620
  properties: { tools: { type: "array", minItems: 1 } },
31605
31621
  required: ["tools"]
31606
31622
  },
31607
- then: { required: ["base_url"] },
31623
+ then: {
31624
+ description: "A tool needs an API root: a fixed base_url, or a per-install base_url_template (CS-1863).",
31625
+ anyOf: [{ required: ["base_url"] }, { required: ["base_url_template"] }]
31626
+ },
31608
31627
  not: {
31609
31628
  description: "auth_scheme and auth_encoding are mutually exclusive (ENG-10524). The templater refuses the combination on every call, so catalog validation refuses it first.",
31610
31629
  required: ["auth_scheme", "auth_encoding"]
@@ -38722,7 +38741,7 @@ var FLAG_REGISTRY = [
38722
38741
  },
38723
38742
  {
38724
38743
  key: "email-require-approval-enforcement",
38725
- description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are armed by an org-scoped override written at org creation; existing orgs stay off until an operator flips them. Evaluated per-org. Ships dark.',
38744
+ description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are no longer armed (ENG-11234). Orgs created while the ENG-9629/9675 new-org arm was live keep their org-scoped ON override until an operator flips them per org. Evaluated per-org. Ships dark.',
38726
38745
  flagType: "boolean",
38727
38746
  // Declared safe value is `false` (no hold). A flag-DB read error degrades here, so a flags
38728
38747
  // outage can never silently start holding real customer email — the same fail-OPEN posture
@@ -38732,36 +38751,15 @@ var FLAG_REGISTRY = [
38732
38751
  defaultValue: false,
38733
38752
  // Turning it on holds real customer email pending a human tap, so it is a deliberate,
38734
38753
  // audited per-org flip (ADR-0022 §4).
38735
- sensitive: true,
38736
- // ENG-9629: NEW orgs are armed on. Declared here rather than hardcoded in the
38737
- // seeding code, so `listNewOrgFlagOverrides()` is the one answer to "which flags
38738
- // does a new org get". `defaultValue` stays false so the ~4 months of orgs already
38739
- // carrying an inert enforce-level email.require_approval row are NOT armed on deploy.
38740
- // ENG-9675: EVERY creation path, self-serve included.
38741
- //
38742
- // ENG-9630 had restricted this to API-created orgs on the grounds that a
38743
- // self-serve org has no way of being TOLD about a held send — no Slack
38744
- // alert channel is wired at signup. That reasoning was wrong, and the check
38745
- // behind it was incomplete: it confirmed an in-console page exists at
38746
- // /organization/approvals and stopped, without looking at the dispatch path.
38747
- //
38748
- // `routeBlockedCallToApproval` has three dispatchers, and the Direct Chat
38749
- // one (lib/integration-broker-approval-direct-chat.ts, ENG-7680) is the
38750
- // universal fallback — "every managed agent always has a Direct Chat session
38751
- // its operator/manager watches in the Console ... usable out of the box with
38752
- // no per-org approval-route setup and no Slack dependency". It posts into a
38753
- // thread keyed on the approval_requests.id and correlates the manager's
38754
- // reply back through tryCaptureDirectChatApproval, so a self-serve org has
38755
- // both a zero-config delivery channel AND a reply path.
38756
- //
38757
- // With the stated blocker gone, the guardrail's own promise — "before
38758
- // sending any email" — applies to the organizations with the LEAST operator
38759
- // oversight exactly as it does to the rest.
38760
- //
38761
- // Existing self-serve orgs are deliberately NOT armed by this: newOrgOverride
38762
- // is applied at creation, and nothing backfills. Extending it to them is a
38763
- // separate decision with a comms obligation.
38764
- newOrgOverride: true
38754
+ sensitive: true
38755
+ // No newOrgOverride (ENG-11234). ENG-9629/ENG-9675 armed this on EVERY new org at
38756
+ // creation, so every org created since then held each dispatching send, internal
38757
+ // recipients included, behind a human tap. In practice that stalled real work: Pedders
38758
+ // (CS-1904/1908/1910) had an agent's emails to its own principal expire unapproved,
38759
+ // because "any email" includes the person the agent works for. New orgs now start at
38760
+ // `defaultValue` (off) like every other org; turning it on is the deliberate, audited
38761
+ // per-org flip `sensitive: true` already describes. Orgs armed by the old override keep
38762
+ // their override row; nothing here disarms them (that is an operator decision per org).
38765
38763
  },
38766
38764
  {
38767
38765
  key: "mail-rule-control-enforcement",
@@ -31671,7 +31671,7 @@ var integration_metadata_v1_default = {
31671
31671
  type: "string",
31672
31672
  format: "uri",
31673
31673
  pattern: "^https://",
31674
- description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty)."
31674
+ description: "Absolute HTTPS URL the broker uses as the vendor API root. Required when any tool descriptor relies on http_templater (i.e. whenever `tools[]` is non-empty), unless the definition declares a per-install `base_url_template` instead (CS-1863)."
31675
31675
  },
31676
31676
  auth_scheme: {
31677
31677
  type: "string",
@@ -31705,6 +31705,22 @@ var integration_metadata_v1_default = {
31705
31705
  }
31706
31706
  }
31707
31707
  },
31708
+ base_url_template: {
31709
+ type: "object",
31710
+ description: "A PER-INSTALL API host (CS-1863), for vendors with one host per customer (Storrito: https://<ORG_UUID>.storrito.com/api/v1). Used when base_url is absent. `template` holds exactly one `{value}` placeholder in its host; the value is read from the install's config[config_key], must match value_pattern in full, and the built host must be exactly <value>.<host_suffix> over https. Resolved and re-validated at call time by resolveIntegrationBaseUrl.",
31711
+ additionalProperties: false,
31712
+ required: ["template", "config_key", "value_pattern", "host_suffix"],
31713
+ properties: {
31714
+ template: { type: "string", pattern: "^https://\\{value\\}\\.[^{}]+$" },
31715
+ config_key: { type: "string", pattern: "^[a-z][a-z0-9_]*$" },
31716
+ value_pattern: { type: "string", minLength: 1 },
31717
+ host_suffix: { type: "string", pattern: "^[a-z0-9.-]+\\.[a-z]{2,}$" }
31718
+ }
31719
+ },
31720
+ redirect_means_auth_failure: {
31721
+ type: "boolean",
31722
+ description: "The vendor answers a rejected credential with a REDIRECT (Storrito: a 302 to its login page) rather than a 401. A redirected non-GET call is never followed (vendor-fetch.ts) and always fails; with this set, it is also treated like a 401 and the install is flagged for re-auth."
31723
+ },
31708
31724
  tools: {
31709
31725
  type: "array",
31710
31726
  description: "Auto-loaded MCP tool descriptors. Each entry produces one MCP tool entry per supported runtime scope.",
@@ -31716,7 +31732,10 @@ var integration_metadata_v1_default = {
31716
31732
  properties: { tools: { type: "array", minItems: 1 } },
31717
31733
  required: ["tools"]
31718
31734
  },
31719
- then: { required: ["base_url"] },
31735
+ then: {
31736
+ description: "A tool needs an API root: a fixed base_url, or a per-install base_url_template (CS-1863).",
31737
+ anyOf: [{ required: ["base_url"] }, { required: ["base_url_template"] }]
31738
+ },
31720
31739
  not: {
31721
31740
  description: "auth_scheme and auth_encoding are mutually exclusive (ENG-10524). The templater refuses the combination on every call, so catalog validation refuses it first.",
31722
31741
  required: ["auth_scheme", "auth_encoding"]
@@ -38828,7 +38847,7 @@ var FLAG_REGISTRY = [
38828
38847
  },
38829
38848
  {
38830
38849
  key: "email-require-approval-enforcement",
38831
- description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are armed by an org-scoped override written at org creation; existing orgs stay off until an operator flips them. Evaluated per-org. Ships dark.',
38850
+ description: 'Enforcement gate for the `email.require_approval` guardrail (ENG-9611). That guardrail has been `default_for_new_orgs` since ~2026-05-03 and its display text promises "Require human approval before sending any email", but nothing ever read it: its only runtime path was toGuardrailForPrompt, i.e. a line in the agent CLAUDE.md. When ON for an org, a DISPATCHING email send (never a draft-create, ENG-7980) is held and routed to Human Approval regardless of recipient domain \u2014 which is what "any email" means, and is what distinguishes it from email-guard-require-approval-enabled, whose require_approval stage only intercepts a would-be DOMAIN block. Deliberately separate from the guardrail row: roughly four months of orgs already carry an inert `enforce`-level row, so reading the row alone would arm a blocking control across all of them on deploy. New orgs are no longer armed (ENG-11234). Orgs created while the ENG-9629/9675 new-org arm was live keep their org-scoped ON override until an operator flips them per org. Evaluated per-org. Ships dark.',
38832
38851
  flagType: "boolean",
38833
38852
  // Declared safe value is `false` (no hold). A flag-DB read error degrades here, so a flags
38834
38853
  // outage can never silently start holding real customer email — the same fail-OPEN posture
@@ -38838,36 +38857,15 @@ var FLAG_REGISTRY = [
38838
38857
  defaultValue: false,
38839
38858
  // Turning it on holds real customer email pending a human tap, so it is a deliberate,
38840
38859
  // audited per-org flip (ADR-0022 §4).
38841
- sensitive: true,
38842
- // ENG-9629: NEW orgs are armed on. Declared here rather than hardcoded in the
38843
- // seeding code, so `listNewOrgFlagOverrides()` is the one answer to "which flags
38844
- // does a new org get". `defaultValue` stays false so the ~4 months of orgs already
38845
- // carrying an inert enforce-level email.require_approval row are NOT armed on deploy.
38846
- // ENG-9675: EVERY creation path, self-serve included.
38847
- //
38848
- // ENG-9630 had restricted this to API-created orgs on the grounds that a
38849
- // self-serve org has no way of being TOLD about a held send — no Slack
38850
- // alert channel is wired at signup. That reasoning was wrong, and the check
38851
- // behind it was incomplete: it confirmed an in-console page exists at
38852
- // /organization/approvals and stopped, without looking at the dispatch path.
38853
- //
38854
- // `routeBlockedCallToApproval` has three dispatchers, and the Direct Chat
38855
- // one (lib/integration-broker-approval-direct-chat.ts, ENG-7680) is the
38856
- // universal fallback — "every managed agent always has a Direct Chat session
38857
- // its operator/manager watches in the Console ... usable out of the box with
38858
- // no per-org approval-route setup and no Slack dependency". It posts into a
38859
- // thread keyed on the approval_requests.id and correlates the manager's
38860
- // reply back through tryCaptureDirectChatApproval, so a self-serve org has
38861
- // both a zero-config delivery channel AND a reply path.
38862
- //
38863
- // With the stated blocker gone, the guardrail's own promise — "before
38864
- // sending any email" — applies to the organizations with the LEAST operator
38865
- // oversight exactly as it does to the rest.
38866
- //
38867
- // Existing self-serve orgs are deliberately NOT armed by this: newOrgOverride
38868
- // is applied at creation, and nothing backfills. Extending it to them is a
38869
- // separate decision with a comms obligation.
38870
- newOrgOverride: true
38860
+ sensitive: true
38861
+ // No newOrgOverride (ENG-11234). ENG-9629/ENG-9675 armed this on EVERY new org at
38862
+ // creation, so every org created since then held each dispatching send, internal
38863
+ // recipients included, behind a human tap. In practice that stalled real work: Pedders
38864
+ // (CS-1904/1908/1910) had an agent's emails to its own principal expire unapproved,
38865
+ // because "any email" includes the person the agent works for. New orgs now start at
38866
+ // `defaultValue` (off) like every other org; turning it on is the deliberate, audited
38867
+ // per-org flip `sensitive: true` already describes. Orgs armed by the old override keep
38868
+ // their override row; nothing here disarms them (that is an operator decision per org).
38871
38869
  },
38872
38870
  {
38873
38871
  key: "mail-rule-control-enforcement",
@@ -65,8 +65,8 @@ import {
65
65
  writeDirectChatSessionState,
66
66
  writeEgressAllowlist,
67
67
  writePersistentClaudeWrapper
68
- } from "./chunk-AT7E625H.js";
69
- import "./chunk-2SGXGNDW.js";
68
+ } from "./chunk-A7HDJW23.js";
69
+ import "./chunk-P544KDE3.js";
70
70
  import "./chunk-OCMJ5E6J.js";
71
71
  import "./chunk-XWVM4KPK.js";
72
72
  import "./chunk-EL5MWGGH.js";
@@ -139,4 +139,4 @@ export {
139
139
  writeEgressAllowlist,
140
140
  writePersistentClaudeWrapper
141
141
  };
142
- //# sourceMappingURL=persistent-session-3WRSJIDM.js.map
142
+ //# sourceMappingURL=persistent-session-WSJVCGEO.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  paneLogPath
3
- } from "./chunk-AT7E625H.js";
4
- import "./chunk-2SGXGNDW.js";
3
+ } from "./chunk-A7HDJW23.js";
4
+ import "./chunk-P544KDE3.js";
5
5
  import "./chunk-OCMJ5E6J.js";
6
6
  import "./chunk-XWVM4KPK.js";
7
7
  import "./chunk-EL5MWGGH.js";
@@ -802,4 +802,4 @@ export {
802
802
  readAndResetSlackReplyBindingClassifications,
803
803
  readAndResetSlackReplyTargetClassifications
804
804
  };
805
- //# sourceMappingURL=responsiveness-probe-2DF6VH7Q.js.map
805
+ //# sourceMappingURL=responsiveness-probe-7MQI6SUF.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  sessionTranscriptDir
3
- } from "./chunk-2SGXGNDW.js";
3
+ } from "./chunk-P544KDE3.js";
4
4
  import "./chunk-DGUM43GV.js";
5
5
 
6
6
  // src/lib/session-auth-dead.ts
@@ -204,4 +204,4 @@ export {
204
204
  decideSessionAuthState,
205
205
  probeSessionAuth
206
206
  };
207
- //# sourceMappingURL=session-auth-dead-GRTHA2Z5.js.map
207
+ //# sourceMappingURL=session-auth-dead-NFVTUFPI.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integrity-labs/agt-cli",
3
- "version": "0.28.1054",
3
+ "version": "0.28.1056",
4
4
  "description": "Augmented Team CLI — agent provisioning and management",
5
5
  "type": "module",
6
6
  "engines": {