Skip to content

πŸ™Œ OpenHands: AI-Driven Development

Update Slack MCP catalog entry (#641)

Engel Nyst7b9c2fec33fc
diff --git a/AGENTS.md b/AGENTS.md
index c65c422736..9ad77f611e 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -157,6 +157,7 @@ you are running inside of β€” NOT the automation backend.
- `@openhands/typescript-client` is currently pinned to commit `ef62e82fc3dfb03991a1c8025429caf354427263` because the package metadata needed by this PR has not been published as a consistent npm/tagged release yet. That commit ships the needed typed clients plus subpath exports for `client/http-client`, `events/remote-events-list`, and `workspace/remote-workspace`. `RemoteWorkspace.gitChanges`/`gitDiff` accept an optional `{ ref }` option; agent-canvas passes `'HEAD'` so the changes panel reflects working-tree + index versus the latest commit (i.e. staged + unstaged) instead of a diff against the upstream/default branch.
- The `@openhands/typescript-client` git dep must be expressed as a `git+https://github.com/...` URL in both `package.json` and the top-level dep entry of `package-lock.json`; the `github:OpenHands/...` shorthand normalizes to `git+ssh://` inside the lockfile, and Vercel's build environment has no GitHub SSH key, so an ssh-pinned lockfile makes Vercel fall back to a stale cached tarball and the bundler then fails with `[MISSING_EXPORT] ConversationClient/FileClient/SharedClient is not exported by .../dist/clients.js`. `scripts/vercel-install.sh` (wired up via `vercel.json`'s `installCommand`) defensively rewrites any leftover `git+ssh://[email protected]/` resolved URLs to `git+https://github.com/` and adds matching `git config --global url..insteadOf` aliases before invoking `npm ci`, so a future regression that re-introduces an ssh-pinned lockfile entry still builds on Vercel. See GitHub issue #384 for the original failure and PR #382 for the prior single-shot lockfile fix that this generalizes.
+
## API Access Rules
Two strict conventions govern every REST call in the frontend. Violations break CI
@@ -169,6 +170,7 @@ All calls that target the local agent-server (`/api/*`, `/server_info`, `/socket
raw `axios`, `fetch`, or the legacy shared `openHands` axios instance.
Available clients and their subpath imports:
+
- `ConversationClient` -- `@openhands/typescript-client/clients`
- `FileClient` -- `@openhands/typescript-client/clients`
- `VSCodeClient` -- `@openhands/typescript-client/clients`
@@ -178,6 +180,7 @@ Available clients and their subpath imports:
- `RemoteEventsList` -- `@openhands/typescript-client/events/remote-events-list`
Client options are always assembled via helpers in `src/api/agent-server-client-options.ts`:
+
- `getAgentServerClientOptions(overrides?)` -- for SDK client constructors
- `getAgentServerHttpClientOptions(overrides?)` -- for `HttpClient`-based callers
@@ -186,8 +189,12 @@ registry and env config, so callers never hardcode URLs or auth tokens.
```ts
// CORRECT
-const data = await new ConversationClient(getAgentServerClientOptions()).getConversation(id);
-const file = await new FileClient(getAgentServerClientOptions()).downloadTextFile(path);
+const data = await new ConversationClient(
+ getAgentServerClientOptions(),
+).getConversation(id);
+const file = await new FileClient(
+ getAgentServerClientOptions(),
+).downloadTextFile(path);
// WRONG -- raw axios/fetch calls fail the no-direct-agent-server-calls.test.ts guard
const data = await axios.get(`${host}/api/conversations/${id}`);
@@ -195,6 +202,7 @@ const data = await fetch(`/api/conversations/${id}`);
```
**Allowed exceptions** (files that may use axios directly for infrastructure reasons):
+
- `src/api/automation-service/automation-service.api.ts`
- `src/api/cloud/proxy.ts` -- the proxy envelope POST itself
@@ -231,6 +239,7 @@ const result = await axios.get(`${backend.host}/api/v1/app-conversations`);
```
`callCloudProxy` key options:
+
- `backend` -- the cloud `Backend` object (provides host and bearer token)
- `hostOverride` -- override for runtime-sandbox calls; replaces `backend.host`
- `authMode` -- `"bearer"` (default, cloud) | `"session-api-key"` (runtime sandbox) | `"none"`
@@ -391,7 +400,7 @@ return new ConversationClient(getAgentServerClientOptions()).someMethod(...);
- Custom secrets are NOT auto-attached by the agent-server. `POST /api/conversations` only persists what the client sends in `request.secrets`; the persisted secrets store (`/api/settings/secrets`) is never read at conversation-start. `buildStartConversationRequestWithEncryptedSettings` enumerates `SecretsService.getSecrets()` and turns each entry into a `LookupSecret` whose `url` points back at `/api/settings/secrets/{name}` and whose `headers` carry `X-Session-API-Key` for auth. Pre-1.21.x agent-server SDKs would silently drop that header during validation when `secrets_encrypted=true` (the cipher in the validation context tried to `cipher.decrypt(plaintext_session_key)`, failed, and the validator removed the header β€” the conversation runtime then got 401s for every saved secret). The SDK fix preserves plaintext header values when decryption fails; if you still see saved secrets unavailable inside a conversation, verify the running agent-server bundles a `LookupSecret._validate_secrets` that falls back to plaintext on decrypt failure.
-- MCP page layout: MCP is a **top-level** nav entry at `/mcp` (rendered by `src/routes/mcp.tsx`), shown right below "Skills" in `src/components/features/sidebar/sidebar.tsx`. The legacy `/settings/mcp` route still works as a redirect via `src/routes/mcp-settings-redirect.tsx`, and `src/routes/mcp-settings.tsx` re-exports the new page so the published `MCPSettings` library symbol (in `src/components/settings/index.ts`) keeps the same shape. Marketplace catalog data and MCP logo mappings live in `@openhands/extensions/mcps` (Slack and Tavily must stay first in that package) β€” `src/utils/mcp-marketplace-utils.ts` matches installed servers back to catalog entries (Tavily uses the `"tavily-builtin"` sentinel because it is gated by `search_api_key_set` rather than `mcp_config`). Components are colocated under `src/components/features/mcp-page/` and reuse the existing `MCPServerForm` for the "Add custom server" / edit flow.
+- MCP page layout: MCP is a **top-level** nav entry at `/mcp` (rendered by `src/routes/mcp.tsx`), shown right below "Skills" in `src/components/features/sidebar/sidebar.tsx`. The legacy `/settings/mcp` route still works as a redirect via `src/routes/mcp-settings-redirect.tsx`, and `src/routes/mcp-settings.tsx` re-exports the new page so the published `MCPSettings` library symbol (in `src/components/settings/index.ts`) keeps the same shape. Marketplace catalog data and MCP logo mappings live in `@openhands/extensions/mcps`; the Slack catalog entry there should point at `https://github.com/zencoderai/slack-mcp-server` and use `@zencoderai/slack-mcp-server`. `src/utils/mcp-marketplace-utils.ts` matches installed servers back to catalog entries. Tavily is a regular stdio MCP entry (`tavily-mcp` + `TAVILY_API_KEY`), not a special built-in sentinel anymore. Components are colocated under `src/components/features/mcp-page/` and reuse the existing `MCPServerForm` for the "Add custom server" / edit flow.
- Library packaging notes:
- Public npm entrypoints now come from `src/index.ts` β†’ `src/lib/index.ts`, with domain barrels under `src/components/{conversation,terminal,browser,files,settings,sidebar}/index.ts`.
diff --git a/__tests__/components/features/mcp-page/install-server-modal.test.tsx b/__tests__/components/features/mcp-page/install-server-modal.test.tsx
index dda3ce905f..968512384a 100644
--- a/__tests__/components/features/mcp-page/install-server-modal.test.tsx
+++ b/__tests__/components/features/mcp-page/install-server-modal.test.tsx
@@ -66,6 +66,7 @@ describe("InstallServerModal", () => {
expect(sentMcpConfig.mcp_config.mcpServers).toMatchObject({
slack: {
command: "npx",
+ args: ["-y", "@zencoderai/slack-mcp-server"],
env: { SLACK_BOT_TOKEN: "xoxb-abc", SLACK_TEAM_ID: "T01" },
},
});
@@ -194,8 +195,7 @@ describe("InstallServerModal", () => {
// Assert: Cancel precedes the dominant Install action in DOM order.
// eslint-disable-next-line no-bitwise
expect(
- cancel.compareDocumentPosition(submit) &
- Node.DOCUMENT_POSITION_FOLLOWING,
+ cancel.compareDocumentPosition(submit) & Node.DOCUMENT_POSITION_FOLLOWING,
).toBeTruthy();
});
});
diff --git a/__tests__/constants/extensions-catalogs.test.ts b/__tests__/constants/extensions-catalogs.test.ts
index 27b50a7388..51ae5a6b64 100644
--- a/__tests__/constants/extensions-catalogs.test.ts
+++ b/__tests__/constants/extensions-catalogs.test.ts
@@ -1,7 +1,7 @@
import { describe, expect, it } from "vitest";
import { AUTOMATION_CATALOG } from "@openhands/extensions/automations";
-import { MCP_CATALOG } from "@openhands/extensions/mcps";
import { MCP_LOGO_IDS, MCP_LOGOS } from "@openhands/extensions/mcps/logos";
+import { MCP_CATALOG } from "@openhands/extensions/mcps";
describe("OpenHands extensions catalogs", () => {
it("hydrates the MCP marketplace from @openhands/extensions", () => {
@@ -16,6 +16,21 @@ describe("OpenHands extensions catalogs", () => {
}
});
+ it("patches Slack to the maintained docs and npm package", () => {
+ const slack = MCP_CATALOG.find((entry) => entry.id === "slack");
+ expect(slack?.docsUrl).toBe(
+ "https://github.com/zencoderai/slack-mcp-server",
+ );
+ expect(slack?.template.kind).toBe("stdio");
+ if (slack?.template.kind !== "stdio") {
+ throw new Error("Slack template should be stdio");
+ }
+ expect(slack.template.args).toContain("@zencoderai/slack-mcp-server");
+ expect(slack.template.args).not.toContain(
+ "@modelcontextprotocol/server-slack",
+ );
+ });
+
it("loads recommended automations from @openhands/extensions", () => {
expect(AUTOMATION_CATALOG.length).toBeGreaterThan(0);
diff --git a/__tests__/routes/mcp-page.test.tsx b/__tests__/routes/mcp-page.test.tsx
index df4085e0e3..0c0a8ad0e6 100644
--- a/__tests__/routes/mcp-page.test.tsx
+++ b/__tests__/routes/mcp-page.test.tsx
@@ -136,7 +136,7 @@ describe("MCPPage", () => {
mcpServers: {
slack: {
command: "npx",
- args: ["-y", "@modelcontextprotocol/server-slack"],
+ args: ["-y", "@zencoderai/slack-mcp-server"],
env: { SLACK_BOT_TOKEN: "xoxb-abc", SLACK_TEAM_ID: "T01" },
},
},
@@ -212,7 +212,7 @@ describe("MCPPage", () => {
mcpServers: {
slack: {
command: "npx",
- args: ["-y", "@modelcontextprotocol/server-slack"],
+ args: ["-y", "@zencoderai/slack-mcp-server"],
env: { SLACK_BOT_TOKEN: "xoxb-old", SLACK_TEAM_ID: "T01" },
},
},
diff --git a/__tests__/utils/mcp-marketplace-utils.test.ts b/__tests__/utils/mcp-marketplace-utils.test.ts
index 7a12f46c65..71a4762b1b 100644
--- a/__tests__/utils/mcp-marketplace-utils.test.ts
+++ b/__tests__/utils/mcp-marketplace-utils.test.ts
@@ -21,7 +21,7 @@ describe("findInstalledMatch", () => {
type: "stdio",
name: "slack",
command: "npx",
- args: ["-y", "@modelcontextprotocol/server-slack"],
+ args: ["-y", "@zencoderai/slack-mcp-server"],
},
]);
expect(result).toEqual(expect.objectContaining({ id: "stdio-0" }));
@@ -122,7 +122,7 @@ describe("installedServerMatchesQuery", () => {
type: "stdio" as const,
name: "slack",
command: "npx",
- args: ["-y", "@modelcontextprotocol/server-slack"],
+ args: ["-y", "@zencoderai/slack-mcp-server"],
};
it("matches by stdio server name", () => {
diff --git a/package-lock.json b/package-lock.json
index 6ac159ef68..1945bdd5ad 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -12,7 +12,7 @@
"@heroui/react": "2.8.10",
"@microlink/react-json-view": "1.31.20",
"@monaco-editor/react": "4.7.0",
- "@openhands/extensions": "git+https://github.com/OpenHands/extensions.git#3bba8e3bd8a134ad190347549d9aead98b081980",
+ "@openhands/extensions": "git+https://github.com/OpenHands/extensions.git#c3f896acc55d8ee8717ab40f236960e71c2d477d",
"@openhands/typescript-client": "git+https://github.com/OpenHands/typescript-client.git#v0.6.0",
"@react-router/node": "7.14.2",
"@react-router/serve": "7.14.2",
@@ -3441,7 +3441,8 @@
},
"node_modules/@openhands/extensions": {
"version": "0.0.0",
- "resolved": "git+https://github.com/OpenHands/extensions.git#3bba8e3bd8a134ad190347549d9aead98b081980",
+ "resolved": "git+https://github.com/OpenHands/extensions.git#c3f896acc55d8ee8717ab40f236960e71c2d477d",
+ "integrity": "sha512-PzLYaZA9ys8is9dNqNDDAExkz40DJ7t1sXUUrUUdha6vrO1/J4xqspK4YLOp0V5i4DewP3U9Rzqi2nFC/bVIMQ==",
"license": "MIT",
"engines": {
"node": ">=18.20.0"
diff --git a/package.json b/package.json
index 58dacf5b88..862cafdd9d 100644
--- a/package.json
+++ b/package.json
@@ -23,7 +23,7 @@
"@heroui/react": "2.8.10",
"@microlink/react-json-view": "1.31.20",
"@monaco-editor/react": "4.7.0",
- "@openhands/extensions": "git+https://github.com/OpenHands/extensions.git#3bba8e3bd8a134ad190347549d9aead98b081980",
+ "@openhands/extensions": "git+https://github.com/OpenHands/extensions.git#c3f896acc55d8ee8717ab40f236960e71c2d477d",
"@openhands/typescript-client": "git+https://github.com/OpenHands/typescript-client.git#v0.6.0",
"@react-router/node": "7.14.2",
"@react-router/serve": "7.14.2",