Skip to content

feat(integrations): multi-account grants, custom API-key integrations, MCP servers - #736

Open
ja-818 wants to merge 5 commits into
mainfrom
agent/task-20260706-175822-6w1nb/houston
Open

feat(integrations): multi-account grants, custom API-key integrations, MCP servers#736
ja-818 wants to merge 5 commits into
mainfrom
agent/task-20260706-175822-6w1nb/houston

Conversation

@ja-818

@ja-818 ja-818 commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

Integrations overhaul — Elements A+B+C (client/host side)

Sibling gateway PR: gethouston/cloud#54. Four reviewable commits:

A — multiple accounts per app, per-account agent grants. Grant unit moves from toolkit slug to connected account. Labeled accounts, per-account disconnect/rename, execute account pinning (single auto-pin; several require explicit account), grants wire {accounts}, legacy records materialize fail-closed. Per-account UI toggles (en/es/pt).

B — custom API-key integrations. Services outside the Composio catalog; the key lives only in the gateway and never reaches the agent/pod/model/transcript. Provider custom, sandbox multi-provider fan-out, CUSTOM_<SLUG>_REQUEST routing, propose_custom_integration runtime tool + in-chat secure-key setup card, "Can't find your app?" form.

C — remote MCP servers. Provider mcp (Streamable HTTP), MCP_<SLUG>_<TOOL> actions with longest-owner fail-closed grant matching, visible unreachable-server warnings, propose_mcp_server tool + chat card, "Add an MCP server" dialog (en/es/pt).

Verification

Every element: biome, host/runtime/domain vitest (final: 698/474/domain green), full typecheck, app tsgo + check-locales + 926 app tests, houston-web typecheck, boundaries, parity, cargo check. Three adversarial multi-agent review waves; every confirmed finding fixed with a reproduce-first failing test — including a real per-agent grant-bypass via overlapping MCP slugs, caught and closed on both sides.

🤖 Generated with Claude Code

ja-818 and others added 3 commits July 7, 2026 02:36
…grants

Grant unit moves from toolkit slug to connected account (connectionId):

- Connection carries accountLabel (alias > state.val identifier > word_id);
  connect links with allow_multiple so users can add a second account
- Per-account disconnect (ownership-guarded) and new rename (alias) route
- IntegrationProvider port: search returns SearchResult {items, accounts?},
  execute takes opts {acting?, account?} and pins connected_account_id
- Local grants v2: records store {connectionId, toolkit} pairs; legacy
  {toolkits} files materialize to connected accounts on read (fail-closed);
  grants wire is {accounts: string[]}; disconnect prunes stale grant ids
- Sandbox enforcement resolves the account per execute: single granted
  account auto-pins, several require an explicit account, unknown ones 403
- Runtime tools: integration_execute gains account param and returns an
  actionable account_required message; search lists granted accounts
- UI: one card per app with labeled account rows, per-agent toggles,
  rename and disconnect per account, "Add another account" flow (en/es/pt)

Gateway-side enforcement ships in the sibling cloud PR.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…sisted setup

Users can add services outside the Composio catalog by storing an API key;
the key lives only in the gateway and is injected server-side, never
reaching the agent, the pod, the model, or the chat transcript.

- New provider id "custom" registered as a second remote provider against
  the gateway; sandbox search fans out across all providers and execute
  routes by action prefix (CUSTOM_<SLUG>_REQUEST -> custom)
- IntegrationProvider gains an optional CustomIntegrationHost extension
  (create/update) forwarded by RemoteIntegrationProvider; host routes
  expose create/update passthroughs when the provider supports them
- Protocol: PendingInteraction kind "custom_integration" (proposal only,
  never a secret); runtime tool propose_custom_integration guides agents
  to never ask for keys in chat
- engine-client: createCustomIntegration/updateCustomIntegration; hooks
  and query keys for the custom provider
- UI: "Can't find your app?" form dialog (name, base URL, header/query
  auth, key, agent-facing description), custom app cards with Edit/Delete
  and grant toggles, and an in-chat setup card where the key is pasted
  into a secure field and cleared after create (en/es/pt)

Gateway-side provider, sealed storage, and SSRF-guarded execution ship in
the sibling cloud PR.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@ja-818 ja-818 changed the title feat(integrations): multiple accounts per app with per-account agent grants feat(integrations): multi-account grants + custom API-key integrations Jul 7, 2026
Users connect remote MCP servers (Streamable HTTP) as integrations; their
tools surface through integration_search/integration_execute like any app.

- New provider id "mcp" registered as a third remote provider; actions
  named MCP_<SLUG>_<TOOL> and routed by prefix; grant matching resolves
  the LONGEST owning server slug against the full server universe and
  fails closed, so an overlapping shorter slug can never bypass grants
- SearchResult.warnings: unreachable MCP servers surface as visible
  warnings in search output, never silently dropped
- Protocol: PendingInteraction kind "mcp_server"; runtime tool
  propose_mcp_server (secrets never requested in chat)
- engine-client: createMcpServer/updateMcpServer; McpServerAuth types
- UI: "Add an MCP server" dialog (URL, none/bearer/header auth, secret
  kept on blank edit), MCP badges, per-agent grant toggles, in-chat setup
  card with capability gating; shared ProposalLogo extracted (en/es/pt)

Gateway-side MCP client, sealed auth storage, SSRF-pinned transport, and
enforcement ship in the sibling cloud PR.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@ja-818 ja-818 changed the title feat(integrations): multi-account grants + custom API-key integrations feat(integrations): multi-account grants, custom API-key integrations, MCP servers Jul 7, 2026
…on rework + UI updates)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant