MCP: connect Claude (web, Cowork) to a cluster as a custom connector, without the CLI
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- typescript
调研方向
Start by reading the Studio flows that configure clusters and providers; the issue does not name their files or entry points, so locate them in the repository. Verify whether Claude completes OAuth against Harper’s /mcp without a challenge, and decide whether connectors may access the operations part. Done means Studio gives eligible clusters a no-CLI setup path for Claude’s application tools, explains the public-address requirement where relevant, and retains the CLI route for other cases.
由索引模型根据 Issue 内容生成。
描述
Why
#2011 (PR #2096) connects an AI tool through the harper CLI: harper login on the user's machine, then a local bridge in the client's config. That works for engineers. A reviewer who isn't one asked whether they could instead paste the cluster's MCP address into Claude (web or Cowork) as a custom connector. For non-engineers that is the lowest-friction way in, and today it isn't possible. This was left out of #2096 on purpose.
What a connector needs
A Claude custom connector signs in with OAuth against the MCP server itself. Harper's built-in MCP server has no OAuth of its own, but the @harperfast/oauth plugin can act as the authorization server for it:
- With
mcp.enabled: true, on a Harper that hasserver.registerBearerValidator(first tagged in v5.4.0-alpha.1), the plugin registers its token check with Harper, so Harper's own/mcpaccepts the plugin's tokens with no custom route (oauthdocs/mcp-oauth.md"Option A"). - No per-cluster registration with Anthropic. claude.ai identifies itself with a Client ID Metadata Document (
client_id=https://claude.ai/oauth/mcp-oauth-client-metadata, per HarperFast/oauth#199), and the plugin accepts those by default (docs/mcp-oauth.md#L33). - Per-cluster sign-in provider setup is needed. The plugin sends people to a configured provider (GitHub, Google, Okta, …) to log in, and
redirectUrimust be the cluster's public origin plus/oauth/callback(docs/getting-started.md#L27). So each cluster needs a provider app (or a shared one listing each cluster's callback) and its client id and secret. - Each login has to become a Harper user. The token's subject must resolve to an active Harper user with a role, either by provisioning matching users or by mapping identities in an
onLoginhook (docs/mcp-oauth.md#L69-L72).
Gaps found in Harper
- Only the application part can be reached this way. Harper skips the plugin's token check on the operations server (
security/auth.ts#L350:hasActiveValidators = !request.isOperationsServer && …). A connector could use the application part (mcp.application: tables and resources), not the operations part (admin commands). That may be the right limit; it should be a stated decision. - Harper's
/mcpdoesn't challenge. It answers a request with no token as an anonymous session, and its 401 carries noWWW-Authenticate: Bearer resource_metadata=…header (docs/mcp-oauth.md#L73-L79). A client that waits for that challenge before starting OAuth never signs in. Unverified: whether Claude's connector looks up/.well-known/oauth-protected-resourceon its own.
Open questions
- Does Claude's connector complete sign-in against Harper's
/mcptoday (gap 2), or does Harper need to send the challenge? - Should a connector ever reach the operations part (gap 1)?
- Who sets this up on Fabric: a Studio page that configures the plugin and provider per cluster, Fabric provisioning it, or docs only?
- Self-managed clusters: the connector reaches the server from Anthropic's side, not the user's machine, so the address must be public. Verify, and say so where Studio shows it.
Done when
A non-engineer can follow steps in Studio to add a cluster to Claude as a custom connector, sign in through a browser, and use the application part's tools, with no CLI. Studio shows that path only where the cluster can serve it, and keeps the harper login route for everything else.
🤖 Generated by Claude Code (Claude Opus 5.5); posted via @dawsontoth.
Epic: HarperFast/harper#2102 (MCP server & OpenAPI schema generation).
- 主要语言
- TypeScript
- 星标
- 5
- 派生
- 4
- 平均合并
- 2 天 13 小时
- 30 天内合并 PR
- 60
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
HarperFast/studio 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 70/100
HarperFast/studio#2111 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
HarperFast/studio#2109 ·
维护者通常 1 天内回复
-
rum
难度 2/5 1-3 小时 新手友好度 72/100
HarperFast/studio#2085 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
HarperFast/studio#2070 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 74/100
HarperFast/studio#2067 ·
维护者通常 1 天内回复
查看 HarperFast/studio 的全部 Issue
相似的 Issue
-
bot:ai-assisted component:platform-js status:untriaged
难度 1/5 1 小时以内 新手友好度 74/100
midnightntwrk/platform-js#38 ·
-
难度 2/5 1-3 小时 新手友好度 68/100
ranxianglei/billion-context#7068 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
mybigday/whisper.rn#348 ·
-
enhancement severity:low
难度 2/5 1-3 小时 新手友好度 82/100
Battle-Cattle/BCUK-Bot-4#1075 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 67/100
ilan-pinto/roaring-lions#1552 ·
维护者通常 1 天内回复