🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
✨ feat(marketplace): organize app capabilities and separate the MCP catalog (#23579)
AmAzing-42f94517560b
diff --git a/.agents/ux/components.md b/.agents/ux/components.mdindex 35b264d8aab..723676711e8 100644--- a/.agents/ux/components.md+++ b/.agents/ux/components.md@@ -53,6 +53,8 @@| `components/Skeleton`、`ListSkeleton` | 路由级骨架和列表占位 | 骨架形状要贴近真实布局;路由骨架登记方式见 `spa-routes` skill || `features/CommandMenu` | 全局命令面板 | 新的全局动作登记进来,不另做搜索弹窗 |+市场中的应用和 MCP 共用 `SkillListRow` 目录行。用户已安装的 MCP 和技能分别在各自目录顶部展示,复用 `CatalogSection` 的预览和「查看全部」。未连接项的行尾用 `RowAddAction` 显示加号,已连接项用 `RowMoreMenu` 打开管理菜单。+#### mobile 外壳(桌面页面在 mobile 全屏打开)mobile 与 web 是同一套 DOM 组件;分类同 web(薄包装 / 重复 / 业务组件),没有单独的 RN 原子层。diff --git a/apps/cli/src/commands/botMessengers.test.ts b/apps/cli/src/commands/botMessengers.test.tsindex 1d329a420ab..c0018fd4482 100644--- a/apps/cli/src/commands/botMessengers.test.ts+++ b/apps/cli/src/commands/botMessengers.test.ts@@ -99,7 +99,7 @@ describe('bot messengers', () => {await createProgram().parseAsync(['node', 'test', 'bot', 'messengers', 'list']);const out = renderedOutput();expect(out).toContain('No System Bot installations connected.');- expect(out).toContain('Settings → Messenger');+ expect(out).toContain('Marketplace → Apps');});it('--json passes through the payload', async () => {diff --git a/apps/cli/src/commands/botMessengers.ts b/apps/cli/src/commands/botMessengers.tsindex 44b846bb616..574dc1de0c9 100644--- a/apps/cli/src/commands/botMessengers.ts+++ b/apps/cli/src/commands/botMessengers.ts@@ -57,7 +57,7 @@ export function registerBotMessengersCommands(bot: Command) {console.log('No System Bot installations connected.');console.log(`\nRun ${pc.dim('lh bot messengers platforms')} to see what's available, then install via ` +- `${pc.dim('Settings → Messenger')} (OAuth requires a browser).`,+ `${pc.dim('Marketplace → Apps')} (OAuth requires a browser).`,);return;}@@ -178,7 +178,7 @@ export function registerBotMessengersCommands(bot: Command) {]);printTable(rows, ['ID', 'NAME', 'APP ID', 'BOT USERNAME']);console.log(- `\nInstalls are initiated via ${pc.dim('Settings → Messenger')} in the web UI ` ++ `\nInstalls are initiated via ${pc.dim('Marketplace → Apps')} in the web UI ` +'(OAuth needs a browser).',);});diff --git a/apps/server/src/router-hono/agent/handlers/__tests__/messengerOAuthCallback.test.ts b/apps/server/src/router-hono/agent/handlers/__tests__/messengerOAuthCallback.test.tsindex 7ff055a34ac..a13ecff9d11 100644--- a/apps/server/src/router-hono/agent/handlers/__tests__/messengerOAuthCallback.test.ts+++ b/apps/server/src/router-hono/agent/handlers/__tests__/messengerOAuthCallback.test.ts@@ -113,7 +113,7 @@ describe('GET /api/agent/messenger/:platform/oauth/callback', () => {const res = await messengerOAuthCallback(buildContext('slack', 'error=access_denied'));expect(res.status).toBe(302);const loc = new URL(res.headers.get('location')!);- expect(loc.pathname).toBe('/settings/messenger/slack');+ expect(loc.pathname).toBe('/marketplace/app/slack');expect(loc.searchParams.get('error')).toBe('access_denied');});@@ -121,7 +121,7 @@ describe('GET /api/agent/messenger/:platform/oauth/callback', () => {const res = await messengerOAuthCallback(buildContext('slack', ''));expect(res.status).toBe(302);const loc = new URL(res.headers.get('location')!);- expect(loc.pathname).toBe('/settings/messenger/slack');+ expect(loc.pathname).toBe('/marketplace/app/slack');expect(loc.searchParams.get('error')).toBe('missing_code_or_state');});@@ -257,7 +257,7 @@ describe('GET /api/agent/messenger/:platform/oauth/callback', () => {expect(res.status).toBe(302);const loc = new URL(res.headers.get('location')!);- expect(loc.pathname).toBe('/settings/messenger/slack');+ expect(loc.pathname).toBe('/marketplace/app/slack');expect(loc.searchParams.get('error')).toBe('already_installed');expect(loc.searchParams.get('workspace')).toBe('Acme Inc');});@@ -326,7 +326,7 @@ describe('GET /api/agent/messenger/:platform/oauth/callback', () => {expect(res.status).toBe(302);const loc = new URL(res.headers.get('location')!);- expect(loc.pathname).toBe('/settings/messenger/slack');+ expect(loc.pathname).toBe('/marketplace/app/slack');expect(loc.searchParams.get('installed')).toBe('ok');});});@@ -382,7 +382,7 @@ describe('GET /api/agent/messenger/:platform/oauth/callback', () => {expect(res.status).toBe(302);const loc = new URL(res.headers.get('location')!);- expect(loc.pathname).toBe('/settings/messenger/discord');+ expect(loc.pathname).toBe('/marketplace/app/discord');expect(loc.searchParams.get('installed')).toBe('ok');});});diff --git a/apps/server/src/router-hono/agent/handlers/messengerOAuthCallback.ts b/apps/server/src/router-hono/agent/handlers/messengerOAuthCallback.tsindex 1aeb694eb40..fa781c813f6 100644--- a/apps/server/src/router-hono/agent/handlers/messengerOAuthCallback.ts+++ b/apps/server/src/router-hono/agent/handlers/messengerOAuthCallback.ts@@ -11,13 +11,14 @@ import { messengerPlatformRegistry } from '@/server/services/messenger/platformsconst log = debug('lobe-server:messenger:oauth-callback');-const SETTINGS_PATH = '/settings/messenger';+const MARKETPLACE_APPS_PATH = '/marketplace/app';// All OAuth callbacks land on the per-platform detail page so the user sees the// freshly-installed workspace/server without an extra click. The detail page// reads `installed=ok` / `error=...` / `workspace=...` from the URL.-const redirectToPlatform = (origin: string, platform: string, query?: string): Response => {- const target = new URL(`${SETTINGS_PATH}/${platform}${query ? `?${query}` : ''}`, origin);+const redirectToPlatform = (origin: string, platform: string, query: string): Response => {+ const target = new URL(`${MARKETPLACE_APPS_PATH}/${platform}`, origin);+ target.search = query;return Response.redirect(target, 302);};@@ -41,7 +42,7 @@ const errorRedirect = (origin: string, platform: string, code: string, extra?: U* 3. Detect tenant takeover (another LobeHub user already owns this row)* 4. Encrypt + upsert into `messenger_installations`* 5. Hand off to the platform's deep-link redirect (Slack- * `slack.com/app/open`) or fall back to the settings page.+ * `slack.com/app/open`) or fall back to the Marketplace app.*/export async function messengerOAuthCallback(c: Context): Promise<Response> {const platform = c.req.param('platform');@@ -174,7 +175,7 @@ export async function messengerOAuthCallback(c: Context): Promise<Response> {return errorRedirect(url.origin, platform, 'persist_failed');}- // 5. Branch on outcome. Takeover attempts get bounced to settings with a+ // 5. Branch on outcome. Takeover attempts get sent to the Marketplace app with a// dedicated error so the page can render a Modal explaining the situation// (tenant name lets the UI name the workspace/guild).if (isTakeoverAttempt) {@@ -191,7 +192,7 @@ export async function messengerOAuthCallback(c: Context): Promise<Response> {}// 6. Hand off to the platform's deep-link if it provides one, otherwise- // fall back to the settings page with a `<platform>_installed=ok` flag.+ // fall back to the Marketplace app with a `installed=ok` flag.const deepLink = definition.oauth.buildPostInstallRedirect?.(install, url.origin);if (deepLink) {log(diff --git a/apps/server/src/services/messenger/platforms/linq/binder.test.ts b/apps/server/src/services/messenger/platforms/linq/binder.test.tsindex e667613e2e9..85dc3528979 100644--- a/apps/server/src/services/messenger/platforms/linq/binder.test.ts+++ b/apps/server/src/services/messenger/platforms/linq/binder.test.ts@@ -113,7 +113,7 @@ describe('MessengerLinqBinder.handleUnlinkedMessage', () => {expect(mocks.upsertForPlatform).not.toHaveBeenCalled();expect(mocks.sendText).toHaveBeenCalledWith('chat_1',- expect.stringContaining('https://app.test/settings/messenger/linq'),+ expect.stringContaining('https://app.test/marketplace/app/linq'),);});diff --git a/apps/server/src/services/messenger/platforms/linq/binder.ts b/apps/server/src/services/messenger/platforms/linq/binder.tsindex d164be8cfec..5a48512aea3 100644--- a/apps/server/src/services/messenger/platforms/linq/binder.ts+++ b/apps/server/src/services/messenger/platforms/linq/binder.ts@@ -24,7 +24,7 @@ const log = debug('lobe-server:messenger:linq:binder');const settingsUrl = (): string | undefined => {if (!appEnv.APP_URL) return undefined;- return new URL('/settings/messenger/linq', appEnv.APP_URL).toString();+ return new URL('/marketplace/app/linq', appEnv.APP_URL).toString();};/** Replies are deliberately short: they arrive as iMessage / SMS bubbles. */@@ -32,7 +32,7 @@ export const LINQ_REPLY = {alreadyLinkedToOther:'This number is already connected to a different LobeHub account. Disconnect it there first, then send your code again.',codeInvalid:- 'That link code has expired or was already used. Open LobeHub → Settings → Messenger → iMessage to get a fresh one.',+ 'That link code has expired or was already used. Open LobeHub → Marketplace → Apps → iMessage to get a fresh one.',linked: (agentName?: string) =>agentName? `You're connected to LobeHub. Messages you send here go to ${agentName}.`@@ -40,9 +40,9 @@ export const LINQ_REPLY = {needLink: (url?: string) =>url? `Hi! This number isn't connected to LobeHub yet. Open ${url} and tap Connect — it will text us a one-time code from your phone.`- : "Hi! This number isn't connected to LobeHub yet. Open LobeHub → Settings → Messenger → iMessage and tap Connect.",+ : "Hi! This number isn't connected to LobeHub yet. Open LobeHub → Marketplace → Apps → iMessage and tap Connect.",unlinkBeforeRelink:- 'Your LobeHub account is already connected to another number. Disconnect it in Settings → Messenger first, then send your code again.',+ 'Your LobeHub account is already connected to another number. Disconnect it in Marketplace → Apps first, then send your code again.',} as const;type LinkOutcome =diff --git a/apps/server/src/services/messenger/platforms/types.ts b/apps/server/src/services/messenger/platforms/types.tsindex 5d13d57e55b..0dacbc98fb7 100644--- a/apps/server/src/services/messenger/platforms/types.ts+++ b/apps/server/src/services/messenger/platforms/types.ts@@ -103,7 +103,7 @@ export interface MessengerPlatformOAuthAdapter {buildAuthorizeUrl: (params: OAuthBuildAuthorizeUrlParams) => string;/*** Final redirect after a successful install. Returning `null` falls back to- * the route's default `/settings/messenger?<platform>_installed=ok`.+ * the route's default `/marketplace/app/<platform>?installed=ok`.* Slack uses this to deep-link `slack.com/app/open?team=...&id=...`.*/buildPostInstallRedirect?: (install: NormalizedInstallation, origin: string) => URL | null;diff --git a/apps/server/src/services/toolExecution/serverRuntimes/__tests__/message.test.ts b/apps/server/src/services/toolExecution/serverRuntimes/__tests__/message.test.tsindex a7711e9b133..000aeab6aa1 100644--- a/apps/server/src/services/toolExecution/serverRuntimes/__tests__/message.test.ts+++ b/apps/server/src/services/toolExecution/serverRuntimes/__tests__/message.test.ts@@ -955,7 +955,7 @@ describe('messageRuntime', () => {expect(result.success).toBe(true);expect(result.content).toContain('No System Bot connections found');- expect(result.content).toContain('Settings → Messenger');+ expect(result.content).toContain('Marketplace → Apps');});// Telegram is env-backed (no installation row); the runtime synthesizes a@@ -1491,7 +1491,7 @@ describe('messageRuntime', () => {expect(result.content).toContain('send any message to the LobeHub WeChat bot');});- it('directs the user to Settings → Messenger when the platform is unlinked', async () => {+ it('directs the user to Marketplace → Apps when the platform is unlinked', async () => {mockSendMessengerPush.mockResolvedValueOnce({ status: 'unlinked' });const runtime = await messageRuntime.factory(validContext);@@ -1499,7 +1499,7 @@ describe('messageRuntime', () => {expect(result.success).toBe(false);expect(result.state.status).toBe('unlinked');- expect(result.content).toContain('Settings → Messenger');+ expect(result.content).toContain('Marketplace → Apps');});it('reports unavailable without retrying', async () => {diff --git a/apps/server/src/services/toolExecution/serverRuntimes/message/index.ts b/apps/server/src/services/toolExecution/serverRuntimes/message/index.tsindex 1b8bb5eeaed..bdbba3e7921 100644--- a/apps/server/src/services/toolExecution/serverRuntimes/message/index.ts+++ b/apps/server/src/services/toolExecution/serverRuntimes/message/index.ts@@ -626,7 +626,7 @@ export const messageRuntime: ServerRuntimeRegistration = {// ─── System Bot messenger management ─────────────────────────────────// Mirrors `messenger.*` TRPC procedures but exposed via the tool runtime// so LLM-driven flows can manage installs + links the same way the- // Settings → Messenger UI does. Each handler enforces user ownership;+ // Marketplace → Apps UI does. Each handler enforces user ownership;// the underlying models are already user-scoped where applicable.listMessengers: async () => {if (!context.userId || !context.serverDB) {diff --git a/docs/usage/channels/overview.mdx b/docs/usage/channels/overview.mdxindex 65c74096980..c24bb4ba749 100644--- a/docs/usage/channels/overview.mdx+++ b/docs/usage/channels/overview.mdx@@ -40,7 +40,7 @@ Users or group members → Your bot → One bound Agent| Chat entry | A bot you create or connect | A LobeHub-managed bot or service || Agent relationship | Each channel is bound to one Agent | Each linked account selects an active Agent and can switch it || Who uses it | You, approved users, a team, or a community | The user whose platform account is linked to LobeHub |-| Configured at | **Agent → Channels** | **Settings → Messenger** |+| Configured at | **Agent → Channels** | **Marketplace → Apps** || What you set up | Platform bot or app credentials and access rules | Account link and active Agent |Access policies decide whether a Channel is private or shared. You can restrict your bot to yourself or selected users.@@ -53,18 +53,18 @@ Access policies decide whether a Channel is private or shared. You can restrict### Available Now-| Platform | Description |-| ------------------------------------------ | --------------------------------------------------------------------------------------------------- |-| [Discord](/docs/usage/channels/discord) | Connect to Discord servers for channel chat and direct messages |-| [Slack](/docs/usage/channels/slack) | Connect to Slack for channel and direct message conversations |-| [Telegram](/docs/usage/channels/telegram) | Connect to Telegram for private and group conversations |-| [LINE](/docs/usage/channels/line) | Connect to LINE Messaging API for direct and group chats |-| [QQ](/docs/usage/channels/qq) | Connect to QQ for group chats and direct messages |-| [WeChat (微信)](/docs/usage/channels/wechat) | Connect to WeChat via iLink Bot for direct messages (Pro; group support unconfirmed) |-| [WeCom](/docs/usage/channels/wecom) | Connect a WeCom AI bot for direct chats and group @-mentions (Cloud, or single-instance self-hosts) |-| [Feishu (飞书)](/docs/usage/channels/feishu) | Connect to Feishu for team collaboration (Chinese version) |-| [Lark](/docs/usage/channels/lark) | Connect to Lark for team collaboration (international version) |-| [DingTalk (钉钉)](/docs/usage/channels/dingtalk) | Connect a DingTalk internal app robot for single chats and group @-mentions |+| Platform | Description |+| ---------------------------------------------- | --------------------------------------------------------------------------------------------------- |+| [Discord](/docs/usage/channels/discord) | Connect to Discord servers for channel chat and direct messages |+| [Slack](/docs/usage/channels/slack) | Connect to Slack for channel and direct message conversations |+| [Telegram](/docs/usage/channels/telegram) | Connect to Telegram for private and group conversations |+| [LINE](/docs/usage/channels/line) | Connect to LINE Messaging API for direct and group chats |+| [QQ](/docs/usage/channels/qq) | Connect to QQ for group chats and direct messages |+| [WeChat (微信)](/docs/usage/channels/wechat) | Connect to WeChat via iLink Bot for direct messages (Pro; group support unconfirmed) |+| [WeCom](/docs/usage/channels/wecom) | Connect a WeCom AI bot for direct chats and group @-mentions (Cloud, or single-instance self-hosts) |+| [Feishu (飞书)](/docs/usage/channels/feishu) | Connect to Feishu for team collaboration (Chinese version) |+| [Lark](/docs/usage/channels/lark) | Connect to Lark for team collaboration (international version) |+| [DingTalk (钉钉)](/docs/usage/channels/dingtalk) | Connect a DingTalk internal app robot for single chats and group @-mentions |### Coming Soondiff --git a/docs/usage/channels/overview.zh-CN.mdx b/docs/usage/channels/overview.zh-CN.mdxindex ad3dbfabd6c..14715889191 100644--- a/docs/usage/channels/overview.zh-CN.mdx+++ b/docs/usage/channels/overview.zh-CN.mdx@@ -38,7 +38,7 @@ tags:| 聊天入口 | 你创建或连接的机器人 | LobeHub 官方机器人或托管服务 || Agent 关系 | 每个渠道固定绑定一个 Agent | 每个账号选择一个当前 Agent,可随时切换 || 谁来使用 | 你、获准用户、团队或社区成员 | 已关联 LobeHub 账号的用户本人 |-| 配置位置 | **Agent → 渠道** | **设置 → Messenger** |+| 配置位置 | **Agent → 渠道** | **市场 → 应用** || 你需要做什么 | 准备平台机器人或应用凭据,并设置访问范围 | 关联平台账号并选择 Agent |渠道是否对外开放由访问策略决定。你也可以把自己的机器人限制为仅自己或指定用户使用。diff --git a/docs/usage/messenger/discord.mdx b/docs/usage/messenger/discord.mdxindex 602054d4345..345a8353160 100644--- a/docs/usage/messenger/discord.mdx+++ b/docs/usage/messenger/discord.mdx@@ -14,7 +14,7 @@ tags:# Use LobeHub on Discord-Discord works in two phases: a **server admin adds** the official LobeHub bot to a Discord server once, and then **each member links** their personal Discord account to LobeHub. Both phases happen from **Settings → Messenger → Discord**.+Discord works in two phases: a **server admin adds** the official LobeHub bot to a Discord server once, and then **each member links** their personal Discord account to LobeHub. Both phases happen from **Marketplace → Apps → Discord**.> The Discord install audit is per-server, but your **personal link is global** to your Discord account — you only link once, and the same link works in every server that has the bot.@@ -27,9 +27,9 @@ Discord works in two phases: a **server admin adds** the official LobeHub bot to## Phase A — Add the LobeHub bot to a server (server admin)<Steps>- ### Open Settings → Messenger → Discord+ ### Open Marketplace → Apps → Discord- In LobeHub, open **Settings → Messenger** and click the **Discord** card. Click **Connect** in the top-right.+ In LobeHub, open **Marketplace → Apps** and click the **Discord** card. Click **Connect** in the top-right.{/* TODO: screenshot — Discord detail page with empty Connections list and the Connect button */}@@ -79,7 +79,7 @@ Discord works in two phases: a **server admin adds** the official LobeHub bot toTwo equivalent ways:- **On Discord** — DM the bot `/agents` and pick a different agent.-- **In LobeHub** — open **Settings → Messenger → Discord** and use the agent picker on your link row.+- **In LobeHub** — open **Marketplace → Apps → Discord** and use the agent picker on your link row.The change takes effect on the next message you send.@@ -98,9 +98,9 @@ You can re-add the bot to a server (or re-link personally) at any time by repeat- **"Server already connected"** — Another LobeHub user already added the bot to this server. DM the LobeHub bot on Discord to link your personal account; you do not need to add the bot again.- **Discord install failed (`<reason>`)** — Common reasons: authorisation cancelled, install session expired (re-open the modal and try again), Discord returned incomplete data (retry; if persistent, contact support).-- **Bot is in the server but doesn't reply** — Check that you have a personal link under **Settings → Messenger → Discord**. The bot only answers users with a confirmed personal link.+- **Bot is in the server but doesn't reply** — Check that you have a personal link under **Marketplace → Apps → Discord**. The bot only answers users with a confirmed personal link.- **Bot replies in some channels but not in a private one** — Discord only delivers a private channel's messages to members listed in its permissions. Open the channel's **Settings → Permissions**, click **Add members or roles**, and add the LobeHub bot with **View Channel**, **Send Messages**, **Read Message History** and **Send Messages in Threads** allowed.- **Removed the audit row but the bot is still in my server** — That's expected. Disconnecting in LobeHub only removes the audit entry; a Discord server admin must kick the bot from Discord itself.- **"This link is already used"** — One-time confirmation links expire after one use. DM the bot again to get a new link.- **"This account is already linked"** — Your Discord account is bound to a different LobeHub account. Sign in to that LobeHub account to manage the link, or unlink there before retrying.-- **"Another Discord account is already linked"** — Your LobeHub account already has a Discord link. Disconnect it in **Settings → Messenger → Discord** before linking a new Discord account.+- **"Another Discord account is already linked"** — Your LobeHub account already has a Discord link. Disconnect it in **Marketplace → Apps → Discord** before linking a new Discord account.diff --git a/docs/usage/messenger/discord.zh-CN.mdx b/docs/usage/messenger/discord.zh-CN.mdxindex db77387c00d..9748201d473 100644--- a/docs/usage/messenger/discord.zh-CN.mdx+++ b/docs/usage/messenger/discord.zh-CN.mdx@@ -13,7 +13,7 @@ tags:# 在 Discord 使用 LobeHub-Discord 接入分两步:**服务器管理员把 LobeHub 机器人加入 Discord 服务器**(每个服务器一次),然后 **每位成员把自己的 Discord 账号关联到 LobeHub**。两步都在 **设置 → Messenger → Discord** 里完成。+Discord 接入分两步:**服务器管理员把 LobeHub 机器人加入 Discord 服务器**(每个服务器一次),然后 **每位成员把自己的 Discord 账号关联到 LobeHub**。两步都在 **市场 → 应用 → Discord** 里完成。> Discord 安装审计是按服务器记录的,但你的 **个人关联是全局的**,挂在你的 Discord 账号下 —— 只需关联一次,所有装了机器人的服务器里它都生效。@@ -26,9 +26,9 @@ Discord 接入分两步:**服务器管理员把 LobeHub 机器人加入 Discor## 阶段 A —— 把 LobeHub 机器人加入服务器(服务器管理员)<Steps>- ### 打开「设置 → Messenger → Discord」+ ### 打开「市场 → 应用 → Discord」- 在 LobeHub 中打开 **设置 → Messenger**,点击 **Discord** 卡片,再点右上角的 **连接**。+ 在 LobeHub 中打开 **市场 → 应用**,点击 **Discord** 卡片,再点右上角的 **连接**。{/* TODO: 截图 —— Discord 详情页(Connections 列表为空 + Connect 按钮) */}@@ -78,7 +78,7 @@ Discord 接入分两步:**服务器管理员把 LobeHub 机器人加入 Discor两种等价方式:- **在 Discord 里** —— 私聊机器人发送 `/agents`,挑一个新的 Agent。-- **在 LobeHub 里** —— 打开 **设置 → Messenger → Discord**,在你的关联行里使用 Agent 选择器。+- **在 LobeHub 里** —— 打开 **市场 → 应用 → Discord**,在你的关联行里使用 Agent 选择器。切换会对你发送的下一条消息立即生效。@@ -97,9 +97,9 @@ Discord 也有两种含义不同的断开操作,有一处和 Slack 不同需- **"Server already connected"(服务器已连接)** —— 服务器已被另一位 LobeHub 用户加过机器人。直接在 Discord 私聊 LobeHub 机器人完成个人关联即可,无需重新添加。- **Discord 安装失败(`<原因>`)** —— 常见原因:用户取消授权、安装会话过期(重新打开弹窗再试)、Discord 返回的数据不完整(重试;持续失败请联系支持)。-- **机器人在服务器但不回我消息** —— 检查 **设置 → Messenger → Discord** 下你是否有个人关联。机器人只回复完成了个人关联的用户。+- **机器人在服务器但不回我消息** —— 检查 **市场 → 应用 → Discord** 下你是否有个人关联。机器人只回复完成了个人关联的用户。- **机器人在其他频道能回复,在某个私有频道不回复** —— Discord 只会把私有频道的消息发给其权限列表里的成员。打开该频道的 **设置 → Permissions(权限)**,点击 **Add members or roles**,把 LobeHub 机器人加进来,并允许 **查看频道**、**发送消息**、**阅读消息历史记录** 和 **在子区内发送消息**。- **断开了审计行,但机器人还在服务器里** —— 这是预期行为。在 LobeHub 里断开只移除审计记录,需要 Discord 服务器管理员手动从 Discord 那边把机器人踢出。- **"This link is already used"** —— 一次性确认链接只能用一次,给机器人再发一条消息获取新链接。- **"This account is already linked"** —— 这个 Discord 账号已绑定到另一个 LobeHub 账号。请用那个 LobeHub 账号登录管理,或先在那边解绑。-- **"Another Discord account is already linked"** —— 你的 LobeHub 账号在 Discord 上已有关联。先在 **设置 → Messenger → Discord** 断开旧关联,再绑定新的 Discord 账号。+- **"Another Discord account is already linked"** —— 你的 LobeHub 账号在 Discord 上已有关联。先在 **市场 → 应用 → Discord** 断开旧关联,再绑定新的 Discord 账号。diff --git a/docs/usage/messenger/overview.mdx b/docs/usage/messenger/overview.mdxindex c4dd3dcb60d..3995c54dd8f 100644--- a/docs/usage/messenger/overview.mdx+++ b/docs/usage/messenger/overview.mdx@@ -23,20 +23,20 @@ You → LobeHub-managed bot or service → Your active AgentYou can switch Agents inside the same official bot. Switching changes the Agent behind the conversation; it does not open another bot or chat.-Manage Messenger from **Settings → Messenger** in LobeHub.+Manage Messenger from **Marketplace → Apps** in LobeHub.## Should I use Messenger or Channels?- **Choose Messenger** when you want to use your Agents from a familiar chat app and want LobeHub to manage the bot.- **Choose [Channels](/docs/usage/channels/overview)** when you want your own bot identity for teammates, customers, or community members to use with a specific Agent.-| | **Messenger** | **Channels** |-| --- | --- | --- |-| Chat entry | A LobeHub-managed bot or service | A bot you create or connect |-| Agent relationship | Each linked account selects an active Agent and can switch it | Each channel is bound to one Agent |-| Who uses it | The user whose platform account is linked to LobeHub | You, approved users, a team, or a community |-| Configured at | **Settings → Messenger** | **Agent → Channels** |-| What you set up | Account link and active Agent | Platform bot or app credentials and access rules |+| | **Messenger** | **Channels** |+| ------------------ | ------------------------------------------------------------- | ------------------------------------------------ |+| Chat entry | A LobeHub-managed bot or service | A bot you create or connect |+| Agent relationship | Each linked account selects an active Agent and can switch it | Each channel is bound to one Agent |+| Who uses it | The user whose platform account is linked to LobeHub | You, approved users, a team, or a community |+| Configured at | **Marketplace → Apps** | **Agent → Channels** |+| What you set up | Account link and active Agent | Platform bot or app credentials and access rules |Public versus private access is not the distinction. A Channel can also be restricted to you or selected users.@@ -49,15 +49,15 @@ Public versus private access is not the distinction. A Channel can also be restr| **Discord** | Per-server install + per-member link | [Use LobeHub on Discord](/docs/usage/messenger/discord) || **WeChat** | QR-code account link (Pro) | [Use LobeHub on WeChat](/docs/usage/messenger/wechat) |-If a platform card does not appear at **Settings → Messenger**, it has not been enabled on your deployment yet — check back later or ask your administrator.+If a platform card does not appear at **Marketplace → Apps**, it has not been enabled on your deployment yet — check back later or ask your administrator.-{/* TODO: screenshot — Settings → Messenger landing screen showing the four platform cards */}+{/* TODO: screenshot — Marketplace → Apps landing screen showing the four platform cards */}## How It Works1. Link your platform account to your LobeHub account. Depending on the platform, this uses a confirmation link, OAuth, or a QR code.2. Select the active Agent. Messages you send to the LobeHub-managed bot are routed to it. In a Slack workspace or Discord server where the official bot is installed, channel `@mentions` can also use your active Agent.-3. Send `/agents`, or use **Settings → Messenger**, to select another Agent. The next message uses the new selection.+3. Send `/agents`, or use **Marketplace → Apps**, to select another Agent. The next message uses the new selection.4. If workspaces are enabled, `/switch` changes between your personal scope and a team workspace.5. Disconnecting your personal link leaves the official bot on the platform, but your messages are no longer routed to LobeHub until you link again.@@ -80,7 +80,7 @@ On platforms other than WeChat, an unlinked user can send `/start` to begin linkYou can switch the agent that answers your messages at any time:- **From the bot** — send `/agents` and pick a different agent.-- **From LobeHub** — open **Settings → Messenger**, select the platform, and use the agent picker on your link row.+- **From LobeHub** — open **Marketplace → Apps**, select the platform, and use the agent picker on your link row.Changes take effect immediately for the next message you send.@@ -88,9 +88,9 @@ Changes take effect immediately for the next message you send.Telegram and WeChat only have a personal account link. Slack and Discord also show workspace or server installations, so they have two different disconnect actions:-| Action | Effect |-| -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |-| **Disconnect** on a *user* row | Unlinks **your** LobeHub account from the platform account. Inbound messages stop until you repeat that platform's linking flow. |+| Action | Effect |+| -------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |+| **Disconnect** on a *user* row | Unlinks **your** LobeHub account from the platform account. Inbound messages stop until you repeat that platform's linking flow. || **Disconnect** on a *workspace / server* row | Applies only to platforms with workspace or server installs. It removes the install audit entry. On Slack, this also freezes the workspace bot for everyone. On Discord, the bot stays in the server until a server admin kicks it. |You can re-link at any time by repeating that platform's linking flow.@@ -101,6 +101,6 @@ These messages can appear on platforms that use one-time confirmation links:- **"This link is already used"** — The one-time confirm link can only be used once. Return to the bot and send `/start` again to issue a new link.- **"This account is already linked"** — The platform account is bound to a different LobeHub account. Sign in to that account to manage it, or unlink it there before retrying.-- **"Another \<platform> account is already linked"** — Your LobeHub account already has a link on this platform. Disconnect the existing link in **Settings → Messenger** before linking a new one.+- **"Another \<platform> account is already linked"** — Your LobeHub account already has a link on this platform. Disconnect the existing link in **Marketplace → Apps** before linking a new one.For platform-specific issues, see the troubleshooting section on each platform's guide.diff --git a/docs/usage/messenger/overview.zh-CN.mdx b/docs/usage/messenger/overview.zh-CN.mdxindex 696d660f68b..e2ec40186e0 100644--- a/docs/usage/messenger/overview.zh-CN.mdx+++ b/docs/usage/messenger/overview.zh-CN.mdx@@ -22,41 +22,41 @@ tags:你可以在同一个官方机器人里切换 Agent。切换的是后台接收消息的 Agent,不会出现另一个机器人或新的聊天窗口。-所有配置都在 LobeHub 的 **设置 → Messenger** 页面完成。+所有配置都在 LobeHub 的 **市场 → 应用** 页面完成。## 我该使用 Messenger 还是渠道?- **选择 Messenger**:你想在常用聊天应用里使用自己的 Agent,并希望由 LobeHub 管理机器人。- **选择 [渠道(Channels)](/zh/docs/usage/channels/overview)**:你想创建自己的机器人,让同事、客户或群成员与一个指定 Agent 对话。-| | **Messenger** | **渠道(Channels)** |-| --- | --- | --- |-| 聊天入口 | LobeHub 官方机器人或托管服务 | 你创建或连接的机器人 |-| Agent 关系 | 每个账号选择一个当前 Agent,可随时切换 | 每个渠道固定绑定一个 Agent |-| 谁来使用 | 已关联 LobeHub 账号的用户本人 | 你、获准用户、团队或社区成员 |-| 配置位置 | **设置 → Messenger** | **Agent → 渠道** |-| 你需要做什么 | 关联平台账号并选择 Agent | 准备平台机器人或应用凭据,并设置访问范围 |+| | **Messenger** | **渠道(Channels)** |+| -------- | ---------------------- | -------------------- |+| 聊天入口 | LobeHub 官方机器人或托管服务 | 你创建或连接的机器人 |+| Agent 关系 | 每个账号选择一个当前 Agent,可随时切换 | 每个渠道固定绑定一个 Agent |+| 谁来使用 | 已关联 LobeHub 账号的用户本人 | 你、获准用户、团队或社区成员 |+| 配置位置 | **市场 → 应用** | **Agent → 渠道** |+| 你需要做什么 | 关联平台账号并选择 Agent | 准备平台机器人或应用凭据,并设置访问范围 |是否公开不是两者的区别。渠道也可以限制为仅自己或指定用户使用。## 支持的平台-| 平台 | 接入模式 | 文档 |-| ------------ | ------------------- | ------------------------------------------------------- |+| 平台 | 接入模式 | 文档 |+| ------------ | ------------------- | ---------------------------------------------------------- || **Telegram** | 全局机器人 —— 任意账号都可直接私聊 | [在 Telegram 使用 LobeHub](/zh/docs/usage/messenger/telegram) || **Slack** | 按工作区安装 + 成员各自关联 | [在 Slack 使用 LobeHub](/zh/docs/usage/messenger/slack) || **Discord** | 按服务器安装 + 成员各自关联 | [在 Discord 使用 LobeHub](/zh/docs/usage/messenger/discord) |-| **微信** | 扫码关联账号(Pro) | [在微信使用 LobeHub](/zh/docs/usage/messenger/wechat) |+| **微信** | 扫码关联账号(Pro) | [在微信使用 LobeHub](/zh/docs/usage/messenger/wechat) |-如果 **设置 → Messenger** 页面没有出现某个平台的卡片,说明当前部署尚未启用该平台 —— 请稍后再来,或联系管理员开启。+如果 **市场 → 应用** 页面没有出现某个平台的卡片,说明当前部署尚未启用该平台 —— 请稍后再来,或联系管理员开启。-{/* TODO: 截图 —— 设置 → Messenger 入口页,四个平台卡片 */}+{/* TODO: 截图 —— 市场 → 应用 入口页,四个平台卡片 */}## 工作原理1. 将你的平台账号与 LobeHub 账号关联。不同平台会使用确认链接、OAuth 授权或二维码。2. 选择一个当前 Agent。你发给 LobeHub 官方机器人的消息会路由到它。在已安装官方机器人的 Slack 工作区或 Discord 服务器中,也可以通过频道 `@提及` 使用当前 Agent。-3. 发送 `/agents`,或在 **设置 → Messenger** 中选择其他 Agent。下一条消息会立即使用新的 Agent。+3. 发送 `/agents`,或在 **市场 → 应用** 中选择其他 Agent。下一条消息会立即使用新的 Agent。4. 如果启用了工作区,还可以发送 `/switch` 在个人空间和团队工作区之间切换。5. 断开个人关联后,官方机器人会保留在平台中,但不再把你的消息路由到 LobeHub,直到你重新关联。@@ -79,7 +79,7 @@ tags:你可以随时切换接收你消息的 Agent:- **在机器人里** —— 发送 `/agents`,挑一个新的 Agent。-- **在 LobeHub 里** —— 打开 **设置 → Messenger**,选择平台,在你的关联行里使用 Agent 选择器。+- **在 LobeHub 里** —— 打开 **市场 → 应用**,选择平台,在你的关联行里使用 Agent 选择器。切换会立即对你发送的下一条消息生效。@@ -87,9 +87,9 @@ tags:Telegram 和微信只有个人关联。Slack 和 Discord 还会显示工作区或服务器安装,因此有两种含义不同的断开操作:-| 操作 | 效果 |-| -------------------------------- | ------------------------------------------------------------------------ |-| 在 *user* 行点 **断开** | 解除 **你自己** 的 LobeHub 账号与该平台账号的关联。机器人不再接收你的消息,直到你重新完成该平台的关联流程。 |+| 操作 | 效果 |+| -------------------------------- | ----------------------------------------------------------------------------------------------- |+| 在 *user* 行点 **断开** | 解除 **你自己** 的 LobeHub 账号与该平台账号的关联。机器人不再接收你的消息,直到你重新完成该平台的关联流程。 || 在 *workspace / server* 行点 **断开** | 仅适用于存在工作区或服务器安装的平台。该操作会移除安装审计记录;Slack 会因此让该工作区的整个机器人失效,Discord 上机器人会继续留在服务器,直到 Discord 管理员把它踢出。 |任何时候都可以重新完成对应平台的关联流程。@@ -100,6 +100,6 @@ Telegram 和微信只有个人关联。Slack 和 Discord 还会显示工作区- **"This link is already used"(链接已被使用)** —— 一次性确认链接只能使用一次。请回到机器人重新发送 `/start` 获取新链接。- **"This account is already linked"(该账号已被关联)** —— 该平台账号已绑定到另一个 LobeHub 账号。请用那个 LobeHub 账号登录管理;或先在那边解绑后再尝试。-- **"Another \<platform> account is already linked"(另一个平台账号已关联)** —— 你的 LobeHub 账号在该平台上已有关联。先在 **设置 → Messenger** 里断开旧关联,再绑定新账号。+- **"Another \<platform> account is already linked"(另一个平台账号已关联)** —— 你的 LobeHub 账号在该平台上已有关联。先在 **市场 → 应用** 里断开旧关联,再绑定新账号。平台特有的报错和细节请见各平台文档的「故障排查」一节。diff --git a/docs/usage/messenger/slack.mdx b/docs/usage/messenger/slack.mdxindex a6f43375306..bbcb3cd7274 100644--- a/docs/usage/messenger/slack.mdx+++ b/docs/usage/messenger/slack.mdx@@ -14,7 +14,7 @@ tags:# Use LobeHub on Slack-Slack works in two phases: a **workspace admin installs** the official LobeHub Slack app once, and then **each member links** their personal LobeHub account. Both phases happen from **Settings → Messenger → Slack**.+Slack works in two phases: a **workspace admin installs** the official LobeHub Slack app once, and then **each member links** their personal LobeHub account. Both phases happen from **Marketplace → Apps → Slack**.## Prerequisites@@ -25,9 +25,9 @@ Slack works in two phases: a **workspace admin installs** the official LobeHub S## Phase A — Install the LobeHub Slack app (admin, once per workspace)<Steps>- ### Open Settings → Messenger → Slack+ ### Open Marketplace → Apps → Slack- In LobeHub, open **Settings → Messenger** and click the **Slack** card. Click **Connect** in the top-right.+ In LobeHub, open **Marketplace → Apps** and click the **Slack** card. Click **Connect** in the top-right.{/* TODO: screenshot — Slack detail page with empty Connections list and the Connect button */}@@ -77,7 +77,7 @@ Slack works in two phases: a **workspace admin installs** the official LobeHub STwo equivalent ways:- **On Slack** — DM the bot `/agents` and pick a different agent.-- **In LobeHub** — open **Settings → Messenger → Slack** and use the agent picker on your link row.+- **In LobeHub** — open **Marketplace → Apps → Slack** and use the agent picker on your link row.The change takes effect on the next message you send.@@ -96,7 +96,7 @@ You can re-install (workspace) or re-link (personal) at any time by repeating th- **"Workspace already connected"** — Another LobeHub user already installed the app to this workspace. DM **@LobeHub** to link your personal account; you do not need to install again. To take over ownership, ask the original installer to disconnect first.- **Slack install failed (`<reason>`)** — Common reasons: authorisation cancelled, install session expired (re-open the modal and try again), Slack returned incomplete data (retry; if persistent, contact support).-- **Bot does not reply to your DM** — The workspace install may have been disconnected. Check **Settings → Messenger → Slack** for a workspace row; if missing, ask an admin to re-install.+- **Bot does not reply to your DM** — The workspace install may have been disconnected. Check **Marketplace → Apps → Slack** for a workspace row; if missing, ask an admin to re-install.- **"This link is already used"** — One-time confirmation links expire after one use. DM the bot again to get a new link.- **"This account is already linked"** — Your Slack account is bound to a different LobeHub account. Sign in to that LobeHub account to manage the link, or unlink there before retrying.-- **"Another Slack account is already linked"** — Your LobeHub account already has a Slack link in this workspace. Disconnect it in **Settings → Messenger → Slack** before linking a new Slack account.+- **"Another Slack account is already linked"** — Your LobeHub account already has a Slack link in this workspace. Disconnect it in **Marketplace → Apps → Slack** before linking a new Slack account.diff --git a/docs/usage/messenger/slack.zh-CN.mdx b/docs/usage/messenger/slack.zh-CN.mdxindex 3a5fd4caceb..6da37d63f40 100644--- a/docs/usage/messenger/slack.zh-CN.mdx+++ b/docs/usage/messenger/slack.zh-CN.mdx@@ -13,7 +13,7 @@ tags:# 在 Slack 使用 LobeHub-Slack 接入分两步:**工作区管理员安装一次** 官方 LobeHub Slack 应用,然后 **每位成员各自关联** 自己的 LobeHub 账号。两步都在 **设置 → Messenger → Slack** 里完成。+Slack 接入分两步:**工作区管理员安装一次** 官方 LobeHub Slack 应用,然后 **每位成员各自关联** 自己的 LobeHub 账号。两步都在 **市场 → 应用 → Slack** 里完成。## 前置条件@@ -24,9 +24,9 @@ Slack 接入分两步:**工作区管理员安装一次** 官方 LobeHub Slack## 阶段 A —— 安装 LobeHub Slack 应用(管理员,每个工作区一次)<Steps>- ### 打开「设置 → Messenger → Slack」+ ### 打开「市场 → 应用 → Slack」- 在 LobeHub 中打开 **设置 → Messenger**,点击 **Slack** 卡片,再点右上角的 **连接**。+ 在 LobeHub 中打开 **市场 → 应用**,点击 **Slack** 卡片,再点右上角的 **连接**。{/* TODO: 截图 —— Slack 详情页(Connections 列表为空 + Connect 按钮) */}@@ -76,7 +76,7 @@ Slack 接入分两步:**工作区管理员安装一次** 官方 LobeHub Slack两种等价方式:- **在 Slack 里** —— 私聊机器人发送 `/agents`,挑一个新的 Agent。-- **在 LobeHub 里** —— 打开 **设置 → Messenger → Slack**,在你的关联行里使用 Agent 选择器。+- **在 LobeHub 里** —— 打开 **市场 → 应用 → Slack**,在你的关联行里使用 Agent 选择器。切换会对你发送的下一条消息立即生效。@@ -95,7 +95,7 @@ Slack 有两种含义不同的断开操作:- **"Workspace already connected"(工作区已连接)** —— 工作区已被另一位 LobeHub 用户安装过。私聊 **@LobeHub** 完成个人关联即可,无需重装。如需接管,请请求最初的安装者先断开。- **Slack 安装失败(`<原因>`)** —— 常见原因:用户取消授权、安装会话过期(重新打开弹窗再试)、Slack 返回的数据不完整(重试;持续失败请联系支持)。-- **机器人不回 DM** —— 工作区安装可能已被断开。检查 **设置 → Messenger → Slack** 是否还有 workspace 行;没有就请管理员重新安装。+- **机器人不回 DM** —— 工作区安装可能已被断开。检查 **市场 → 应用 → Slack** 是否还有 workspace 行;没有就请管理员重新安装。- **"This link is already used"** —— 一次性确认链接只能用一次,给机器人再发一条消息获取新链接。- **"This account is already linked"** —— 这个 Slack 账号已绑定到另一个 LobeHub 账号。请用那个 LobeHub 账号登录管理,或先在那边解绑。-- **"Another Slack account is already linked"** —— 你的 LobeHub 账号在该工作区里已有 Slack 关联。先在 **设置 → Messenger → Slack** 断开旧关联,再绑定新的 Slack 账号。+- **"Another Slack account is already linked"** —— 你的 LobeHub 账号在该工作区里已有 Slack 关联。先在 **市场 → 应用 → Slack** 断开旧关联,再绑定新的 Slack 账号。diff --git a/docs/usage/messenger/telegram.mdx b/docs/usage/messenger/telegram.mdxindex 1eb42ee768a..eac5113ccdb 100644--- a/docs/usage/messenger/telegram.mdx+++ b/docs/usage/messenger/telegram.mdx@@ -20,11 +20,11 @@ Telegram is the simplest Messenger platform: there is one global LobeHub bot, an- A LobeHub account- A Telegram account on any device-## Step 1: Open Settings → Messenger+## Step 1: Open Marketplace → Apps-In LobeHub, open **Settings → Messenger** and click the **Telegram** card.+In LobeHub, open **Marketplace → Apps** and click the **Telegram** card.-{/* TODO: screenshot — Settings → Messenger with Telegram card highlighted */}+{/* TODO: screenshot — Marketplace → Apps with Telegram card highlighted */}## Step 2: Click Connect@@ -59,19 +59,19 @@ After confirming, the Telegram detail page shows your link as a "user" row withTwo equivalent ways:- **On Telegram** — send `/agents` to the bot and pick a different agent.-- **In LobeHub** — open **Settings → Messenger → Telegram** and use the agent picker on your link row.+- **In LobeHub** — open **Marketplace → Apps → Telegram** and use the agent picker on your link row.The change takes effect on the next message you send.## Disconnecting-In **Settings → Messenger → Telegram**, click **Disconnect** on the link row. The bot will stop accepting your messages until you re-link by sending `/start` again.+In **Marketplace → Apps → Telegram**, click **Disconnect** on the link row. The bot will stop accepting your messages until you re-link by sending `/start` again.> Disconnecting from LobeHub does not remove the bot from your Telegram chat list — you can manually delete the chat on Telegram if you no longer want to see it.## Troubleshooting-- **The bot does not reply to `/start`** — Check that the platform card actually exists in **Settings → Messenger**. If your deployment hasn't enabled Telegram yet, the bot won't respond.+- **The bot does not reply to `/start`** — Check that the platform card actually exists in **Marketplace → Apps**. If your deployment hasn't enabled Telegram yet, the bot won't respond.- **"This link is already used"** — One-time links can only be used once. Send `/start` again to get a new link.- **"This account is already linked"** — Your Telegram account is bound to a different LobeHub account. Sign in to that LobeHub account to manage the link, or unlink there first.-- **"Another Telegram account is already linked"** — Your LobeHub account already has a Telegram link. Disconnect it in **Settings → Messenger → Telegram** before linking a new Telegram account.+- **"Another Telegram account is already linked"** — Your LobeHub account already has a Telegram link. Disconnect it in **Marketplace → Apps → Telegram** before linking a new Telegram account.diff --git a/docs/usage/messenger/telegram.zh-CN.mdx b/docs/usage/messenger/telegram.zh-CN.mdxindex 33a8686a941..5d376ebbdf1 100644--- a/docs/usage/messenger/telegram.zh-CN.mdx+++ b/docs/usage/messenger/telegram.zh-CN.mdx@@ -19,11 +19,11 @@ Telegram 是 Messenger 里最简单的平台:只有一个全局 LobeHub 机器- 一个 LobeHub 账号- 任意设备上的 Telegram 账号-## 第 1 步:打开「设置 → Messenger」+## 第 1 步:打开「市场 → 应用」-在 LobeHub 中打开 **设置 → Messenger**,点击 **Telegram** 卡片。+在 LobeHub 中打开 **市场 → 应用**,点击 **Telegram** 卡片。-{/* TODO: 截图 —— 设置 → Messenger 入口页,高亮 Telegram 卡片 */}+{/* TODO: 截图 —— 市场 → 应用 入口页,高亮 Telegram 卡片 */}## 第 2 步:点击「连接」@@ -58,19 +58,19 @@ Telegram 是 Messenger 里最简单的平台:只有一个全局 LobeHub 机器两种等价方式:- **在 Telegram 里** —— 给机器人发送 `/agents`,挑一个新的 Agent。-- **在 LobeHub 里** —— 打开 **设置 → Messenger → Telegram**,在你的关联行里使用 Agent 选择器。+- **在 LobeHub 里** —— 打开 **市场 → 应用 → Telegram**,在你的关联行里使用 Agent 选择器。切换会对你发送的下一条消息立即生效。## 断开连接-在 **设置 → Messenger → Telegram** 里点关联行上的 **断开**。断开后机器人不再接收你的消息,直到你重新发送 `/start` 关联。+在 **市场 → 应用 → Telegram** 里点关联行上的 **断开**。断开后机器人不再接收你的消息,直到你重新发送 `/start` 关联。> 在 LobeHub 里断开不会从 Telegram 聊天列表里删掉机器人 —— 如果不想再看到它,可以在 Telegram 里手动删除该会话。## 故障排查-- **机器人不回复 `/start`** —— 先确认 **设置 → Messenger** 里有 Telegram 卡片。如果当前部署没启用 Telegram,机器人不会响应。+- **机器人不回复 `/start`** —— 先确认 **市场 → 应用** 里有 Telegram 卡片。如果当前部署没启用 Telegram,机器人不会响应。- **"This link is already used"** —— 一次性链接只能用一次,重新发送 `/start` 获取新链接。- **"This account is already linked"** —— 这个 Telegram 账号已绑定到另一个 LobeHub 账号。请用那个 LobeHub 账号登录管理,或先在那边解绑。-- **"Another Telegram account is already linked"** —— 你的 LobeHub 账号在 Telegram 上已有关联。先在 **设置 → Messenger → Telegram** 断开旧关联,再绑定新的 Telegram 账号。+- **"Another Telegram account is already linked"** —— 你的 LobeHub 账号在 Telegram 上已有关联。先在 **市场 → 应用 → Telegram** 断开旧关联,再绑定新的 Telegram 账号。diff --git a/docs/usage/messenger/wechat.mdx b/docs/usage/messenger/wechat.mdxindex 6bc4b57244b..09ab964a480 100644--- a/docs/usage/messenger/wechat.mdx+++ b/docs/usage/messenger/wechat.mdx@@ -25,11 +25,11 @@ WeChat Messenger lets you chat privately with your LobeHub agents from your WeCh- A LobeHub account with a **Pro** plan- A WeChat account on a mobile device-## Step 1: Open Settings → Messenger → WeChat+## Step 1: Open Marketplace → Apps → WeChat-In LobeHub, open **Settings → Messenger**, then click the **WeChat** card.+In LobeHub, open **Marketplace → Apps**, then click the **WeChat** card.-{/* TODO: screenshot — Settings → Messenger landing page with the WeChat card and Pro badge */}+{/* TODO: screenshot — Marketplace → Apps landing page with the WeChat card and Pro badge */}## Step 2: Scan the QR code@@ -57,21 +57,21 @@ Open the LobeHub conversation in WeChat and send a message. The message is routeYou can change the current routing in either place:- **In WeChat** — send `/agents` to list your agents and switch the active agent. Send `/switch` to switch between your personal workspace and team workspaces.-- **In LobeHub** — open **Settings → Messenger → WeChat**, then use the workspace and active-agent selectors.+- **In LobeHub** — open **Marketplace → Apps → WeChat**, then use the workspace and active-agent selectors.## CommandsSend these commands in the private chat with the LobeHub contact:-| Command | Action |-| ----------- | ------------------------------------------------------------------------- |-| `/agents` | List your agents and switch the active agent |-| `/switch` | Switch between your personal workspace and team workspaces |-| `/new` | Start a new conversation |-| `/mode` | Show or switch Agent / Chat mode |-| `/stop` | Stop the current run |+| Command | Action |+| --------------------- | ---------------------------------------------------------------- |+| `/agents` | List your agents and switch the active agent |+| `/switch` | Switch between your personal workspace and team workspaces |+| `/new` | Start a new conversation |+| `/mode` | Show or switch Agent / Chat mode |+| `/stop` | Stop the current run || `/feedback <message>` | Send feedback to the LobeHub team without triggering an AI reply |-| `/help` | Show all available commands |+| `/help` | Show all available commands |## Proactive Messages@@ -81,7 +81,7 @@ Each reply from you resets the allowance to **10 proactive messages within 24 ho## Disconnecting-In **Settings → Messenger → WeChat**, click **Disconnect** on the connected user row. This unlinks your WeChat account and stops message routing.+In **Marketplace → Apps → WeChat**, click **Disconnect** on the connected user row. This unlinks your WeChat account and stops message routing.To reconnect later, return to the same page and scan a new QR code.diff --git a/docs/usage/messenger/wechat.zh-CN.mdx b/docs/usage/messenger/wechat.zh-CN.mdxindex 345b6ed5db3..0736ce36448 100644--- a/docs/usage/messenger/wechat.zh-CN.mdx+++ b/docs/usage/messenger/wechat.zh-CN.mdx@@ -24,11 +24,11 @@ tags:- 一个开通 **Pro** 方案的 LobeHub 账号- 手机端微信账号-## 第 1 步:打开「设置 → Messenger → 微信」+## 第 1 步:打开「市场 → 应用 → 微信」-在 LobeHub 中打开 **设置 → Messenger**,然后点击 **微信** 卡片。+在 LobeHub 中打开 **市场 → 应用**,然后点击 **微信** 卡片。-{/* TODO: 截图 —— 设置 → Messenger 入口页,显示微信卡片与 Pro 标识 */}+{/* TODO: 截图 —— 市场 → 应用 入口页,显示微信卡片与 Pro 标识 */}## 第 2 步:使用微信扫码@@ -56,21 +56,21 @@ tags:你可以通过两种方式修改当前消息路由:- **在微信中** —— 发送 `/agents` 查看 Agent 列表并切换当前 Agent;发送 `/switch` 在个人工作区与团队工作区之间切换。-- **在 LobeHub 中** —— 打开 **设置 → Messenger → 微信**,使用工作区和当前 Agent 选择器。+- **在 LobeHub 中** —— 打开 **市场 → 应用 → 微信**,使用工作区和当前 Agent 选择器。## 指令在微信的 LobeHub 私聊中发送以下指令:-| 指令 | 作用 |-| ----------- | --------------------------------------------- |-| `/agents` | 列出你的 Agent,并切换当前激活 Agent |-| `/switch` | 在个人工作区与团队工作区之间切换 |-| `/new` | 开启新对话 |-| `/mode` | 查看或切换 Agent / Chat 模式 |-| `/stop` | 停止当前执行 |-| `/feedback <内容>` | 向 LobeHub 团队发送反馈,不会触发 AI 回复 |-| `/help` | 查看全部可用指令 |+| 指令 | 作用 |+| ---------------- | --------------------------- |+| `/agents` | 列出你的 Agent,并切换当前激活 Agent |+| `/switch` | 在个人工作区与团队工作区之间切换 |+| `/new` | 开启新对话 |+| `/mode` | 查看或切换 Agent / Chat 模式 |+| `/stop` | 停止当前执行 |+| `/feedback <内容>` | 向 LobeHub 团队发送反馈,不会触发 AI 回复 |+| `/help` | 查看全部可用指令 |## 主动消息推送@@ -80,7 +80,7 @@ tags:## 断开连接-在 **设置 → Messenger → 微信** 中,点击已连接用户行上的 **断开**。断开后,微信账号与 LobeHub 的关联会被解除,消息也不再路由。+在 **市场 → 应用 → 微信** 中,点击已连接用户行上的 **断开**。断开后,微信账号与 LobeHub 的关联会被解除,消息也不再路由。需要恢复时,返回同一页面并重新扫码即可。diff --git a/e2e/src/features/community/detail-pages.feature b/e2e/src/features/community/detail-pages.featureindex 1ef1899f7a4..7d1c01d4468 100644--- a/e2e/src/features/community/detail-pages.feature+++ b/e2e/src/features/community/detail-pages.feature@@ -78,7 +78,7 @@ Feature: Discover Detail Pages@COMMUNITY-DETAIL-007 @P1Scenario: Load MCP detail page and verify content- Given I navigate to "/marketplace/connector?source=public"+ Given I navigate to "/marketplace/mcp"And I wait for the page to fully loadWhen I click on the first MCP cardThen I should be on an MCP detail page@@ -88,8 +88,9 @@ Feature: Discover Detail Pages@COMMUNITY-DETAIL-008 @P1Scenario: Navigate back from MCP detail page- Given I navigate to "/marketplace/connector?source=public"+ Given I navigate to "/marketplace/mcp?category=developer"And I wait for the page to fully loadAnd I click on the first MCP cardWhen I click the back button- Then I should be navigated to "/marketplace/connector?source=public"+ Then I should be navigated to "/marketplace/mcp?category=developer"+ And I should see MCP cardsdiff --git a/e2e/src/features/community/interactions.feature b/e2e/src/features/community/interactions.featureindex 4f2d0c67a8e..9ea4d86f61d 100644--- a/e2e/src/features/community/interactions.feature+++ b/e2e/src/features/community/interactions.feature@@ -74,11 +74,10 @@ Feature: Discover Interactions# ============================================@COMMUNITY-INTERACT-008 @P1- Scenario: Browse a category in Connectors Discover- Given I navigate to "/marketplace/connector"- When I select the "Public" connector filter- And I open the MCP category "developer"- Then I should be navigated to "/marketplace/connector?category=developer&source=public"+ Scenario: Browse an MCP category+ Given I navigate to "/marketplace/mcp"+ When I open the MCP category "developer"+ Then I should be navigated to "/marketplace/mcp?category=developer"And I should see only these MCP cards| File Manager || Build Runner |@@ -90,7 +89,7 @@ Feature: Discover Interactions@COMMUNITY-INTERACT-009 @P1Scenario: Navigate to MCP detail page- Given I navigate to "/marketplace/connector?source=public"+ Given I navigate to "/marketplace/mcp"When I click on the first MCP cardThen I should be navigated to the MCP detail pageAnd I should see the MCP detail content@@ -98,8 +97,6 @@ Feature: Discover Interactions@COMMUNITY-INTERACT-010 @P1Scenario: Open an old marketplace bookmark with a searchGiven I navigate to "/community?q=developer"- Then I should be navigated to "/marketplace/connector?q=developer"- And the "Verified" connector filter should be selected- When I select the "Public" connector filter- Then I should see only these MCP cards- | File Manager |+ Then I should be navigated to "/marketplace/app?q=developer"+ And I should see the catalog titled "Apps"+ And the catalog search bar should contain "developer"diff --git a/e2e/src/features/community/smoke.feature b/e2e/src/features/community/smoke.featureindex 4520aa9bd6f..f1c9ca643b6 100644--- a/e2e/src/features/community/smoke.feature+++ b/e2e/src/features/community/smoke.feature@@ -3,12 +3,13 @@ Feature: Community Smoke TestsCritical path tests to ensure the community/discover module is functional@COMMUNITY-SMOKE-001 @P0- Scenario: Open the marketplace at the verified connector list+ Scenario: Open the marketplace at the Apps catalogGiven I navigate to "/marketplace"Then the page should load without errorsAnd I should see the page body- And I should be navigated to "/marketplace/connector"- And the "Verified" connector filter should be selected+ And I should be navigated to "/marketplace/app"+ And I should see the catalog titled "Apps"+ And I should see the search bar@COMMUNITY-SMOKE-002 @P0Scenario: Load Assistant List Page@@ -35,18 +36,20 @@ Feature: Community Smoke TestsAnd I should see provider cards@COMMUNITY-SMOKE-005 @P0- Scenario: Load Connectors Discover- Given I navigate to "/marketplace/connector"- Then the page should load without errors- And I should see the page body- When I select the "Public" connector filter- Then the "Public" connector filter should be selected+ Scenario: Open MCP discovery from the separate Marketplace entry+ Given I navigate to "/marketplace/app"+ When I open the MCP catalog from the Marketplace sidebar+ Then I should be navigated to "/marketplace/mcp"+ And the page should load without errors+ And I should see the catalog titled "MCP"+ And I should see the search barAnd I should see MCP cardsAnd I should see the MCP category "developer"@COMMUNITY-SMOKE-006 @P0Scenario: Open a legacy MCP catalog link- Given I navigate to "/community/mcp?category=productivity"- Then I should be navigated to "/marketplace/connector?category=productivity"+ Given I navigate to "/community/mcp?category=productivity&q=search"+ Then I should be navigated to "/marketplace/mcp?category=productivity&q=search"+ And the catalog search bar should contain "search"And I should see only these MCP cards| Web Search |diff --git a/e2e/src/steps/community/interactions.steps.ts b/e2e/src/steps/community/interactions.steps.tsindex 158996e63ae..7ce1364a9f0 100644--- a/e2e/src/steps/community/interactions.steps.ts+++ b/e2e/src/steps/community/interactions.steps.ts@@ -38,21 +38,17 @@ When('I open the recommended assistants', async function (this: CustomWorld) {await this.page.locator('section a[href="/marketplace/agent?sort=recommended"]').click();});-When('I select the {string} connector filter', async function (this: CustomWorld, name: string) {- await this.page.getByRole('button', { exact: true, name }).click();+When('I open the MCP catalog from the Marketplace sidebar', async function (this: CustomWorld) {+ await expect(this.page.getByRole('heading', { exact: true, level: 1, name: 'Apps' })).toBeVisible(+ {+ timeout: WAIT_TIMEOUT,+ },+ );+ await this.page.getByRole('link', { exact: true, name: 'MCP' }).click();});-Then(- 'the {string} connector filter should be selected',- async function (this: CustomWorld, name: string) {- await expect(this.page.getByRole('button', { exact: true, name, pressed: true })).toBeVisible();- },-);-When('I open the MCP category {string}', async function (this: CustomWorld, category: string) {- await this.page- .locator(`section a[href="/marketplace/connector?category=${category}&source=public"]`)- .click();+ await this.page.locator(`section a[href="/marketplace/mcp?category=${category}"]`).click();});When('I wait for the filtered results to load', async function (this: CustomWorld) {diff --git a/e2e/src/steps/community/smoke.steps.ts b/e2e/src/steps/community/smoke.steps.tsindex 2db11baf8a9..58be2ede3d6 100644--- a/e2e/src/steps/community/smoke.steps.ts+++ b/e2e/src/steps/community/smoke.steps.ts@@ -1,12 +1,27 @@import { Then } from '@cucumber/cucumber';import { expect } from '@playwright/test';-import type { CustomWorld } from '../../support/world';+import { type CustomWorld, WAIT_TIMEOUT } from '../../support/world';// ============================================// Then Steps (Assertions)// ============================================+Then('I should see the catalog titled {string}', async function (this: CustomWorld, name: string) {+ await expect(this.page.getByRole('heading', { exact: true, level: 1, name })).toBeVisible({+ timeout: WAIT_TIMEOUT,+ });+});++Then(+ 'the catalog search bar should contain {string}',+ async function (this: CustomWorld, search: string) {+ await expect(this.page.getByTestId('search-bar')).toHaveValue(search, {+ timeout: WAIT_TIMEOUT,+ });+ },+);+// Assistant List Page StepsThen('I should see the search bar', async function (this: CustomWorld) {// SearchBar component has data-testid="search-bar"@@ -85,9 +100,7 @@ Then('I should see the MCP category {string}',async function (this: CustomWorld, category: string) {await expect(- this.page.locator(- `section a[href="/marketplace/connector?category=${category}&source=public"]`,- ),+ this.page.locator(`section a[href="/marketplace/mcp?category=${category}"]`),).toBeVisible();},);diff --git a/locales/ar/messenger.json b/locales/ar/messenger.jsonindex 52c2e0084cf..0af56493821 100644--- a/locales/ar/messenger.json+++ b/locales/ar/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "حدث خطأ ما. يرجى المحاولة مرة أخرى.","verify.error.missingToken": "رابط غير صالح. افتح هذه الصفحة من البوت.","verify.error.title": "تعذر تأكيد الرابط",- "verify.error.unlinkBeforeRelink": "تم ربط حساب LobeHub هذا بالفعل بحساب Telegram آخر. قم بفصله في الإعدادات → المراسلة قبل ربط حساب جديد.","verify.signInCta": "تسجيل الدخول للمتابعة","verify.signInRequired": "يرجى تسجيل الدخول إلى LobeHub لتأكيد الرابط.","verify.success.backToLobeHub": "العودة إلى LobeHub",diff --git a/locales/bg-BG/messenger.json b/locales/bg-BG/messenger.jsonindex a93d32839dc..76a70ec0928 100644--- a/locales/bg-BG/messenger.json+++ b/locales/bg-BG/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Нещо се обърка. Моля, опитайте отново.","verify.error.missingToken": "Невалидна връзка. Отворете тази страница от бота.","verify.error.title": "Неуспешно потвърждаване на връзката",- "verify.error.unlinkBeforeRelink": "Този LobeHub акаунт вече е свързан с друг Telegram акаунт. Прекъснете връзката в Настройки → Messenger, преди да свържете нов.","verify.signInCta": "Влезте, за да продължите","verify.signInRequired": "Моля, влезте в LobeHub, за да потвърдите връзката.","verify.success.backToLobeHub": "Обратно към LobeHub",diff --git a/locales/de-DE/messenger.json b/locales/de-DE/messenger.jsonindex f966b2c3f0c..8a654131a2c 100644--- a/locales/de-DE/messenger.json+++ b/locales/de-DE/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Etwas ist schiefgelaufen. Bitte versuchen Sie es erneut.","verify.error.missingToken": "Ungültiger Link. Öffnen Sie diese Seite über den Bot.","verify.error.title": "Verknüpfung konnte nicht bestätigt werden",- "verify.error.unlinkBeforeRelink": "Dieses LobeHub-Konto ist bereits mit einem anderen Telegram-Konto verknüpft. Trennen Sie es in Einstellungen → Messenger, bevor Sie ein neues verknüpfen.","verify.signInCta": "Anmelden, um fortzufahren","verify.signInRequired": "Bitte melden Sie sich bei LobeHub an, um die Verknüpfung zu bestätigen.","verify.success.backToLobeHub": "Zurück zu LobeHub",diff --git a/locales/en-US/components.json b/locales/en-US/components.jsonindex 96126c06322..3f6d5f0a473 100644--- a/locales/en-US/components.json+++ b/locales/en-US/components.json@@ -48,6 +48,7 @@"FileManager.actions.goBack": "Go to previous page","FileManager.actions.goForward": "Go to next page","FileManager.actions.goToParent": "Go to parent folder",+ "FileManager.actions.manageChatApps": "Manage chat apps","FileManager.actions.moveError": "Failed to move file","FileManager.actions.moveHere": "Move here","FileManager.actions.moveSuccess": "File moved successfully",@@ -62,7 +63,6 @@"FileManager.actions.renameSuccess": "Rename successful","FileManager.actions.reorderError": "Failed to update order, please try again","FileManager.actions.sendToMessenger": "Send to Messenger",- "FileManager.actions.sendToMessengerSettings": "Messenger Settings","FileManager.actions.sendToMessengerSetup": "Set Up Channels","FileManager.actions.sendToMessengerSetupAction": "Set Up","FileManager.bottom": "You've reached the end.",diff --git a/locales/en-US/discover.json b/locales/en-US/discover.jsonindex bc5ba149707..7aae61266ec 100644--- a/locales/en-US/discover.json+++ b/locales/en-US/discover.json@@ -1,4 +1,23 @@{+ "apps.addMcp": "Add custom MCP server",+ "apps.category.chat": "Chat platforms",+ "apps.category.developer": "Developer tools",+ "apps.category.documents": "Documents & storage",+ "apps.category.productivity": "Productivity",+ "apps.category.projects": "Project management",+ "apps.chatCapability": "Chat with your Agent",+ "apps.connect": "Connect",+ "apps.connected": "Connected apps",+ "apps.continue": "Continue setup",+ "apps.description": "Connect the apps you use to chat with your Agent or give it tools.",+ "apps.empty": "No apps available",+ "apps.manage": "Manage",+ "apps.mcpDescription": "Find MCP servers and connect custom servers to your Agents.",+ "apps.noInstalledMcp": "No installed MCP servers yet",+ "apps.noMatches": "No matching apps",+ "apps.noneConnected": "No connected apps yet",+ "apps.toolCapability": "Agent tools",+ "apps.unavailable": "This app is unavailable.","assistant.favorite": "Save","assistant.favoriteFailed": "Failed to save","assistant.favoriteSuccess": "Saved",@@ -103,6 +122,7 @@"catalog.verified": "Verified","catalog.viewAll": "View all","catalog.viewAllIn": "View all in {{name}}",+ "catalog.yourMcpServers": "Your MCP servers","catalog.yourSkills": "Your skills","category.assistant.academic": "Academic","category.assistant.all": "All",@@ -638,9 +658,11 @@"skills.sorts.name": "Name","skills.sorts.stars": "GitHub Stars","skills.sorts.updatedAt": "Recently Updated",+ "tab.apps": "Apps","tab.assistant": "Agent","tab.connector": "Connectors","tab.home": "Home",+ "tab.mcp": "MCP","tab.model": "Model","tab.plugin": "Skill","tab.provider": "Provider",diff --git a/locales/en-US/electron.json b/locales/en-US/electron.jsonindex 9092ec8c9fd..b2b52675349 100644--- a/locales/en-US/electron.json+++ b/locales/en-US/electron.json@@ -41,6 +41,7 @@"navigation.mail": "Mail","navigation.marketplace": "Marketplace","navigation.marketplaceAgents": "Marketplace · Agents",+ "navigation.marketplaceApps": "Apps","navigation.marketplaceConnectors": "Connectors","navigation.marketplaceInstalledSkills": "Installed Skills","navigation.marketplaceMcp": "Marketplace · MCP",diff --git a/locales/en-US/messenger.json b/locales/en-US/messenger.jsonindex 9da4566c00e..3ee854bf782 100644--- a/locales/en-US/messenger.json+++ b/locales/en-US/messenger.json@@ -30,7 +30,7 @@"messenger.discord.connections.disconnectSuccess": "Server removed.","messenger.discord.connections.disconnectTitle": "Remove server","messenger.discord.installBlocked.dismiss": "Got it",- "messenger.discord.installBlocked.suggestion": "DM the LobeHub bot on Discord to link your personal account — you don't need to add the bot again. Or ask the original installer to remove this server in LobeHub Settings → Messenger before re-adding it.",+ "messenger.discord.installBlocked.nextSteps": "DM the LobeHub bot on Discord to link your personal account — you don't need to add the bot again. Or ask the original installer to remove this server in LobeHub Marketplace → Apps before re-adding it.","messenger.discord.installBlocked.title": "Server already connected","messenger.discord.installBlocked.withName": "\"{{workspace}}\" is already connected to LobeHub by another user.","messenger.discord.installBlocked.withoutName": "This Discord server is already connected to LobeHub by another user.",@@ -131,7 +131,7 @@"messenger.slack.connections.disconnectSuccess": "Workspace disconnected.","messenger.slack.connections.disconnectTitle": "Disconnect workspace","messenger.slack.installBlocked.dismiss": "Got it",- "messenger.slack.installBlocked.suggestion": "DM @LobeHub on Slack to link your personal account — you don't need to install again. Or ask the original installer to disconnect this workspace first if you want to take over ownership.",+ "messenger.slack.installBlocked.nextSteps": "DM @LobeHub on Slack to link your personal account — you don't need to install again. Or ask the original installer to disconnect this workspace first if you want to take over ownership.","messenger.slack.installBlocked.title": "Workspace already connected","messenger.slack.installBlocked.withName": "\"{{workspace}}\" is already connected to LobeHub by another user.","messenger.slack.installBlocked.withoutName": "This Slack workspace is already connected to LobeHub by another user.",@@ -202,14 +202,14 @@"verify.confirm.conflict.title": "This account is already linked","verify.confirm.cta": "Confirm linking","verify.confirm.defaultAgent": "Default agent",- "verify.confirm.defaultAgentHint": "Your messages will be routed here first. You can switch any time via /agents in the bot or from Settings → Messenger.",+ "verify.confirm.defaultAgentMarketplaceHint": "Your messages will be routed here first. You can switch any time via /agents in the bot or from Marketplace → Apps.","verify.confirm.defaultAgentPlaceholder": "Select an agent","verify.confirm.fields.lobeHubAccount": "LobeHub account","verify.confirm.fields.platformAccount": "{{platform}} account","verify.confirm.fields.workspace": "Workspace","verify.confirm.noAgents": "You don't have any agents yet. Create one in LobeHub, then come back to finish linking.",- "verify.confirm.relink.description": "This LobeHub account is already linked to {{platform}} account {{account}}. To link a different {{platform}} account, disconnect the current one first in Settings → Messenger.",- "verify.confirm.relink.manage": "Open Messenger settings",+ "verify.confirm.relink.disconnectInMarketplace": "This LobeHub account is already linked to {{platform}} account {{account}}. To link a different {{platform}} account, disconnect the current one first in Marketplace → Apps.",+ "verify.confirm.relink.openApp": "Open app","verify.confirm.relink.title": "Another {{platform}} account is already linked","verify.confirm.title": "Confirm linking","verify.confirm.workspace": "Workspace: {{workspace}}",@@ -220,7 +220,7 @@"verify.error.generic": "Something went wrong. Please try again.","verify.error.missingToken": "Invalid link. Open this page from the bot.","verify.error.title": "Unable to confirm link",- "verify.error.unlinkBeforeRelink": "This LobeHub account is already linked to another account on this platform. Disconnect it in Settings → Messenger before linking a new one.",+ "verify.error.unlinkBeforeRelink": "This LobeHub account is already linked to another account on this platform. Disconnect it in Marketplace → Apps before linking a new one.","verify.signInCta": "Sign in to continue","verify.signInRequired": "Please sign in to LobeHub to confirm the link.","verify.success.backToLobeHub": "Back to LobeHub",diff --git a/locales/en-US/setting.json b/locales/en-US/setting.jsonindex 7d81b7d49c3..fe9336d0bb2 100644--- a/locales/en-US/setting.json+++ b/locales/en-US/setting.json@@ -320,7 +320,7 @@"apps.desktop.inUseDesc": "You're already in the desktop app.","apps.desktop.title": "Desktop","apps.messenger.desc": "Talk to your agents where your team already is — replies land back in LobeHub.",- "apps.messenger.setup": "Set up",+ "apps.messenger.openApp": "Open app","apps.messenger.title": "Messenger","apps.mobile.cta": "Get mobile app","apps.mobile.desc": "Pick up where you left off — your chats, agents, and files travel with you.",diff --git a/locales/es-ES/messenger.json b/locales/es-ES/messenger.jsonindex 57331490f7c..887e24ac23d 100644--- a/locales/es-ES/messenger.json+++ b/locales/es-ES/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Algo salió mal. Por favor, inténtalo de nuevo.","verify.error.missingToken": "Enlace no válido. Abre esta página desde el bot.","verify.error.title": "No se pudo confirmar la vinculación",- "verify.error.unlinkBeforeRelink": "Esta cuenta de LobeHub ya está vinculada a otra cuenta de Telegram. Desconéctala en Configuración → Messenger antes de vincular una nueva.","verify.signInCta": "Inicia sesión para continuar","verify.signInRequired": "Por favor, inicia sesión en LobeHub para confirmar la vinculación.","verify.success.backToLobeHub": "Volver a LobeHub",diff --git a/locales/fa-IR/messenger.json b/locales/fa-IR/messenger.jsonindex 01fb6f1f78a..c4dbc92b1e4 100644--- a/locales/fa-IR/messenger.json+++ b/locales/fa-IR/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "مشکلی پیش آمد. لطفاً دوباره امتحان کنید.","verify.error.missingToken": "لینک نامعتبر. این صفحه را از ربات باز کنید.","verify.error.title": "تأیید لینک امکانپذیر نیست",- "verify.error.unlinkBeforeRelink": "این حساب LobeHub قبلاً به یک حساب تلگرام دیگر متصل شده است. ابتدا آن را در تنظیمات → پیامرسان قطع کنید تا بتوانید حساب جدیدی را متصل کنید.","verify.signInCta": "برای ادامه وارد شوید","verify.signInRequired": "لطفاً وارد LobeHub شوید تا لینک را تأیید کنید.","verify.success.backToLobeHub": "بازگشت به LobeHub",diff --git a/locales/fr-FR/messenger.json b/locales/fr-FR/messenger.jsonindex 18a42b05535..67386972497 100644--- a/locales/fr-FR/messenger.json+++ b/locales/fr-FR/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Une erreur s'est produite. Veuillez réessayer.","verify.error.missingToken": "Lien invalide. Ouvrez cette page depuis le bot.","verify.error.title": "Impossible de confirmer la liaison",- "verify.error.unlinkBeforeRelink": "Ce compte LobeHub est déjà lié à un autre compte Telegram. Déconnectez-le dans Paramètres → Messagerie avant d'en lier un nouveau.","verify.signInCta": "Connectez-vous pour continuer","verify.signInRequired": "Veuillez vous connecter à LobeHub pour confirmer la liaison.","verify.success.backToLobeHub": "Retour à LobeHub",diff --git a/locales/it-IT/messenger.json b/locales/it-IT/messenger.jsonindex b689b853022..2f5233d89d8 100644--- a/locales/it-IT/messenger.json+++ b/locales/it-IT/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Qualcosa è andato storto. Riprova.","verify.error.missingToken": "Collegamento non valido. Apri questa pagina dal bot.","verify.error.title": "Impossibile confermare il collegamento",- "verify.error.unlinkBeforeRelink": "Questo account LobeHub è già collegato a un altro account Telegram. Scollegalo in Impostazioni → Messenger prima di collegarne uno nuovo.","verify.signInCta": "Accedi per continuare","verify.signInRequired": "Accedi a LobeHub per confermare il collegamento.","verify.success.backToLobeHub": "Torna a LobeHub",diff --git a/locales/ja-JP/messenger.json b/locales/ja-JP/messenger.jsonindex a4eae071bbc..f96007dc71f 100644--- a/locales/ja-JP/messenger.json+++ b/locales/ja-JP/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "問題が発生しました。もう一度お試しください。","verify.error.missingToken": "無効なリンクです。このページをボットから開いてください。","verify.error.title": "リンクを確認できません",- "verify.error.unlinkBeforeRelink": "このLobeHubアカウントはすでに別のTelegramアカウントにリンクされています。新しいアカウントをリンクする前に、設定 → メッセンジャーでリンクを解除してください。","verify.signInCta": "サインインして続行","verify.signInRequired": "リンクを確認するには LobeHub にサインインしてください。","verify.success.backToLobeHub": "LobeHubに戻る",diff --git a/locales/ko-KR/messenger.json b/locales/ko-KR/messenger.jsonindex cbd7cfdf6b7..6047f5ae756 100644--- a/locales/ko-KR/messenger.json+++ b/locales/ko-KR/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "문제가 발생했습니다. 다시 시도하세요.","verify.error.missingToken": "잘못된 링크입니다. 봇에서 이 페이지를 여세요.","verify.error.title": "링크를 확인할 수 없음",- "verify.error.unlinkBeforeRelink": "이 LobeHub 계정은 이미 다른 Telegram 계정에 연결되어 있습니다. 새 계정을 연결하기 전에 설정 → 메신저에서 연결을 해제하세요.","verify.signInCta": "계속하려면 로그인","verify.signInRequired": "LobeHub에 로그인하여 링크를 확인하세요.","verify.success.backToLobeHub": "LobeHub으로 돌아가기",diff --git a/locales/nl-NL/messenger.json b/locales/nl-NL/messenger.jsonindex 7c43dd3351f..a73473ecc89 100644--- a/locales/nl-NL/messenger.json+++ b/locales/nl-NL/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Er is iets misgegaan. Probeer het opnieuw.","verify.error.missingToken": "Ongeldige koppeling. Open deze pagina vanuit de bot.","verify.error.title": "Koppeling kan niet worden bevestigd",- "verify.error.unlinkBeforeRelink": "Dit LobeHub-account is al gekoppeld aan een ander Telegram-account. Ontkoppel het in Instellingen → Messenger voordat je een nieuw account koppelt.","verify.signInCta": "Log in om door te gaan","verify.signInRequired": "Log in bij LobeHub om de koppeling te bevestigen.","verify.success.backToLobeHub": "Terug naar LobeHub",diff --git a/locales/pl-PL/messenger.json b/locales/pl-PL/messenger.jsonindex aa07846c20f..bedcae70b2c 100644--- a/locales/pl-PL/messenger.json+++ b/locales/pl-PL/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Coś poszło nie tak. Spróbuj ponownie.","verify.error.missingToken": "Nieprawidłowe połączenie. Otwórz tę stronę z poziomu bota.","verify.error.title": "Nie można potwierdzić połączenia",- "verify.error.unlinkBeforeRelink": "To konto LobeHub jest już powiązane z innym kontem Telegram. Odłącz je w Ustawieniach → Messenger przed powiązaniem nowego.","verify.signInCta": "Zaloguj się, aby kontynuować","verify.signInRequired": "Zaloguj się do LobeHub, aby potwierdzić połączenie.","verify.success.backToLobeHub": "Powrót do LobeHub",diff --git a/locales/pt-BR/messenger.json b/locales/pt-BR/messenger.jsonindex 29b82143b2a..301c1c10b2b 100644--- a/locales/pt-BR/messenger.json+++ b/locales/pt-BR/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Algo deu errado. Por favor, tente novamente.","verify.error.missingToken": "Vínculo inválido. Abra esta página a partir do bot.","verify.error.title": "Não foi possível confirmar o vínculo",- "verify.error.unlinkBeforeRelink": "Esta conta do LobeHub já está vinculada a outra conta do Telegram. Desconecte-a em Configurações → Messenger antes de vincular uma nova.","verify.signInCta": "Faça login para continuar","verify.signInRequired": "Por favor, faça login no LobeHub para confirmar o vínculo.","verify.success.backToLobeHub": "Voltar para o LobeHub",diff --git a/locales/ru-RU/messenger.json b/locales/ru-RU/messenger.jsonindex 56fcd62f404..992abc1030f 100644--- a/locales/ru-RU/messenger.json+++ b/locales/ru-RU/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Что-то пошло не так. Пожалуйста, попробуйте снова.","verify.error.missingToken": "Недействительная привязка. Откройте эту страницу через бота.","verify.error.title": "Не удалось подтвердить привязку",- "verify.error.unlinkBeforeRelink": "Этот аккаунт LobeHub уже связан с другим аккаунтом Telegram. Отключите его в Настройки → Мессенджер перед привязкой нового.","verify.signInCta": "Войдите, чтобы продолжить","verify.signInRequired": "Пожалуйста, войдите в LobeHub, чтобы подтвердить привязку.","verify.success.backToLobeHub": "Вернуться в LobeHub",diff --git a/locales/tr-TR/messenger.json b/locales/tr-TR/messenger.jsonindex 4f0514588ba..a8dbb762ba2 100644--- a/locales/tr-TR/messenger.json+++ b/locales/tr-TR/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Bir şeyler ters gitti. Lütfen tekrar deneyin.","verify.error.missingToken": "Geçersiz bağlantı. Bu sayfayı bottan açın.","verify.error.title": "Bağlantı onaylanamıyor",- "verify.error.unlinkBeforeRelink": "Bu LobeHub hesabı zaten başka bir Telegram hesabıyla bağlantılı. Yeni bir hesap bağlamadan önce Ayarlar → Messenger bölümünden bağlantıyı kesin.","verify.signInCta": "Devam etmek için giriş yapın","verify.signInRequired": "Bağlantıyı onaylamak için LobeHub'a giriş yapın.","verify.success.backToLobeHub": "LobeHub'a Dön",diff --git a/locales/vi-VN/messenger.json b/locales/vi-VN/messenger.jsonindex 86865697e59..7bfcf64fb39 100644--- a/locales/vi-VN/messenger.json+++ b/locales/vi-VN/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "Đã xảy ra lỗi. Vui lòng thử lại.","verify.error.missingToken": "Liên kết không hợp lệ. Mở trang này từ bot.","verify.error.title": "Không thể xác nhận liên kết",- "verify.error.unlinkBeforeRelink": "Tài khoản LobeHub này đã được liên kết với một tài khoản Telegram khác. Ngắt kết nối trong Cài đặt → Messenger trước khi liên kết tài khoản mới.","verify.signInCta": "Đăng nhập để tiếp tục","verify.signInRequired": "Vui lòng đăng nhập vào LobeHub để xác nhận liên kết.","verify.success.backToLobeHub": "Quay lại LobeHub",diff --git a/locales/zh-CN/components.json b/locales/zh-CN/components.jsonindex 00d6974ea84..a4f0cca37f5 100644--- a/locales/zh-CN/components.json+++ b/locales/zh-CN/components.json@@ -48,6 +48,7 @@"FileManager.actions.goBack": "返回上一页","FileManager.actions.goForward": "前往下一页","FileManager.actions.goToParent": "返回上级文件夹",+ "FileManager.actions.manageChatApps": "管理聊天应用","FileManager.actions.moveError": "移动遇到了问题,请重试","FileManager.actions.moveHere": "移动到此处","FileManager.actions.moveSuccess": "文件移动成功",@@ -62,7 +63,6 @@"FileManager.actions.renameSuccess": "重命名成功","FileManager.actions.reorderError": "调整排序失败,请重试","FileManager.actions.sendToMessenger": "发送到聊天平台",- "FileManager.actions.sendToMessengerSettings": "聊天平台设置","FileManager.actions.sendToMessengerSetup": "去绑定渠道","FileManager.actions.sendToMessengerSetupAction": "去绑定","FileManager.bottom": "已到达页面底部。",diff --git a/locales/zh-CN/discover.json b/locales/zh-CN/discover.jsonindex 5154f7acef2..79e2e42568f 100644--- a/locales/zh-CN/discover.json+++ b/locales/zh-CN/discover.json@@ -1,4 +1,23 @@{+ "apps.addMcp": "添加自定义 MCP 服务器",+ "apps.category.chat": "聊天平台",+ "apps.category.developer": "开发工具",+ "apps.category.documents": "文档与存储",+ "apps.category.productivity": "效率工具",+ "apps.category.projects": "项目管理",+ "apps.chatCapability": "与 Agent 对话",+ "apps.connect": "连接",+ "apps.connected": "已连接的应用",+ "apps.continue": "继续绑定",+ "apps.description": "连接常用应用,与 Agent 对话或为它添加工具。",+ "apps.empty": "暂无可用应用",+ "apps.manage": "管理",+ "apps.mcpDescription": "发现 MCP 服务器,或为 Agent 添加自定义服务器。",+ "apps.noInstalledMcp": "还没有已安装的 MCP 服务器",+ "apps.noMatches": "没有找到匹配的应用",+ "apps.noneConnected": "还没有已连接的应用",+ "apps.toolCapability": "Agent 工具",+ "apps.unavailable": "此应用暂不可用。","assistant.favorite": "收藏","assistant.favoriteFailed": "收藏失败","assistant.favoriteSuccess": "已收藏",@@ -103,6 +122,7 @@"catalog.verified": "已验证","catalog.viewAll": "查看全部","catalog.viewAllIn": "查看 {{name}} 的全部条目",+ "catalog.yourMcpServers": "你的 MCP","catalog.yourSkills": "你的技能","category.assistant.academic": "学术","category.assistant.all": "全部",@@ -638,9 +658,11 @@"skills.sorts.name": "名称","skills.sorts.stars": "GitHub 星标","skills.sorts.updatedAt": "最近更新",+ "tab.apps": "应用","tab.assistant": "助理","tab.connector": "连接器","tab.home": "首页",+ "tab.mcp": "MCP","tab.model": "模型","tab.plugin": "技能","tab.provider": "模型服务商",diff --git a/locales/zh-CN/electron.json b/locales/zh-CN/electron.jsonindex b4e95b0bc0a..ad8201360c0 100644--- a/locales/zh-CN/electron.json+++ b/locales/zh-CN/electron.json@@ -41,6 +41,7 @@"navigation.mail": "邮箱","navigation.marketplace": "市场","navigation.marketplaceAgents": "市场 · 助理",+ "navigation.marketplaceApps": "应用","navigation.marketplaceConnectors": "连接器","navigation.marketplaceInstalledSkills": "已安装技能","navigation.marketplaceMcp": "市场 · MCP",diff --git a/locales/zh-CN/messenger.json b/locales/zh-CN/messenger.jsonindex e5957cf5e3c..baf9130ee35 100644--- a/locales/zh-CN/messenger.json+++ b/locales/zh-CN/messenger.json@@ -30,7 +30,7 @@"messenger.discord.connections.disconnectSuccess": "服务器已移除。","messenger.discord.connections.disconnectTitle": "移除服务器","messenger.discord.installBlocked.dismiss": "我知道了",- "messenger.discord.installBlocked.suggestion": "在 Discord 中私信 LobeHub 机器人即可绑定个人账号——不需要再次添加机器人。如需重新接管该服务器,请让原安装人先在「设置 → Messenger」中移除该服务器后再重新邀请。",+ "messenger.discord.installBlocked.nextSteps": "在 Discord 中私信 LobeHub 机器人即可绑定个人账号——不需要再次添加机器人。如需重新接管该服务器,请让原安装人先在「市场 → 应用」中移除该服务器后再重新邀请。","messenger.discord.installBlocked.title": "服务器已被连接","messenger.discord.installBlocked.withName": "「{{workspace}}」已被另一位 LobeHub 用户连接到 LobeHub。","messenger.discord.installBlocked.withoutName": "该 Discord 服务器已被另一位 LobeHub 用户连接到 LobeHub。",@@ -131,7 +131,7 @@"messenger.slack.connections.disconnectSuccess": "工作区已断开。","messenger.slack.connections.disconnectTitle": "断开工作区","messenger.slack.installBlocked.dismiss": "我知道了",- "messenger.slack.installBlocked.suggestion": "在 Slack 中私信 @LobeHub 即可绑定个人账号——不需要再次安装。如果想接管该工作区,请让原安装人先断开连接。",+ "messenger.slack.installBlocked.nextSteps": "在 Slack 中私信 @LobeHub 即可绑定个人账号——不需要再次安装。如果想接管该工作区,请让原安装人先断开连接。","messenger.slack.installBlocked.title": "工作区已被连接","messenger.slack.installBlocked.withName": "「{{workspace}}」已被另一位 LobeHub 用户连接到 LobeHub。","messenger.slack.installBlocked.withoutName": "该 Slack 工作区已被另一位 LobeHub 用户连接到 LobeHub。",@@ -202,14 +202,14 @@"verify.confirm.conflict.title": "该账号已被绑定","verify.confirm.cta": "确认绑定","verify.confirm.defaultAgent": "默认 Agent",- "verify.confirm.defaultAgentHint": "你的消息将首先路由到这里。你可以随时在机器人中通过 /agents 或在「设置 → Messenger」中切换。",+ "verify.confirm.defaultAgentMarketplaceHint": "你的消息将首先路由到这里。你可以随时在机器人中通过 /agents 或在「市场 → 应用」中切换。","verify.confirm.defaultAgentPlaceholder": "请选择 Agent","verify.confirm.fields.lobeHubAccount": "LobeHub 账号","verify.confirm.fields.platformAccount": "{{platform}} 账号","verify.confirm.fields.workspace": "工作区","verify.confirm.noAgents": "你还没有 Agent。请先在 LobeHub 中创建一个,再回来完成绑定。",- "verify.confirm.relink.description": "此 LobeHub 账户已链接到 {{platform}} 账户 {{account}}。若要链接其他 {{platform}} 账户,请先在 设置 → Messenger 中断开当前账户。",- "verify.confirm.relink.manage": "打开 Messenger 设置",+ "verify.confirm.relink.disconnectInMarketplace": "此 LobeHub 账户已链接到 {{platform}} 账户 {{account}}。若要链接其他 {{platform}} 账户,请先在「市场 → 应用」中断开当前账户。",+ "verify.confirm.relink.openApp": "打开应用","verify.confirm.relink.title": "已链接到其他 {{platform}} 账户","verify.confirm.title": "确认绑定","verify.confirm.workspace": "工作区:{{workspace}}",@@ -220,7 +220,7 @@"verify.error.generic": "出错了。请重试。","verify.error.missingToken": "无效链接。请从机器人中打开此页面。","verify.error.title": "无法确认绑定",- "verify.error.unlinkBeforeRelink": "此 LobeHub 账户已链接到当前平台上的另一个账户。请先在 设置 → Messenger 中断开后再链接新账户。",+ "verify.error.unlinkBeforeRelink": "此 LobeHub 账户已链接到当前平台上的另一个账户。请先在「市场 → 应用」中断开后再链接新账户。","verify.signInCta": "登录以继续","verify.signInRequired": "请登录 LobeHub 以确认绑定。","verify.success.backToLobeHub": "回到 LobeHub",diff --git a/locales/zh-CN/setting.json b/locales/zh-CN/setting.jsonindex ef59521c5ab..8d62481642c 100644--- a/locales/zh-CN/setting.json+++ b/locales/zh-CN/setting.json@@ -320,7 +320,7 @@"apps.desktop.inUseDesc": "你已经在桌面应用里。","apps.desktop.title": "桌面","apps.messenger.desc": "在团队已经在用的聊天软件里和你的智能体对话——回复会同步回 LobeHub。",- "apps.messenger.setup": "去设置",+ "apps.messenger.openApp": "打开应用","apps.messenger.title": "Messenger","apps.mobile.cta": "获取移动应用","apps.mobile.desc": "从上次停下的地方继续——你的会话、智能体和文件都随身携带。",diff --git a/locales/zh-TW/messenger.json b/locales/zh-TW/messenger.jsonindex d3521560a56..94c473aa9c2 100644--- a/locales/zh-TW/messenger.json+++ b/locales/zh-TW/messenger.json@@ -220,7 +220,6 @@"verify.error.generic": "發生錯誤。請重試。","verify.error.missingToken": "無效的連結。請從機器人打開此頁面。","verify.error.title": "無法確認連結",- "verify.error.unlinkBeforeRelink": "此 LobeHub 帳戶已連結至其他 Telegram 帳戶。請在 設定 → Messenger 中解除連結後再連結新的帳戶。","verify.signInCta": "登入以繼續","verify.signInRequired": "請登入 LobeHub 以確認連結。","verify.success.backToLobeHub": "返回 LobeHub",diff --git a/packages/builtin-tool-message/src/ExecutionRuntime/botManagement.ts b/packages/builtin-tool-message/src/ExecutionRuntime/botManagement.tsindex 9c1468fdd14..2ccf6525aa8 100644--- a/packages/builtin-tool-message/src/ExecutionRuntime/botManagement.ts+++ b/packages/builtin-tool-message/src/ExecutionRuntime/botManagement.ts@@ -239,7 +239,7 @@ export class MessageExecutionRuntime extends ChannelMessageRuntime {if (installations.length === 0) {return {content:- 'No System Bot connections found. Tell the user to connect one via Settings → Messenger; `listMessengerPlatforms` shows what platforms are available.',+ 'No System Bot connections found. Tell the user to connect one via Marketplace → Apps; `listMessengerPlatforms` shows what platforms are available.',state: { installations } satisfies ListMessengersState,success: true,};@@ -342,7 +342,7 @@ export class MessageExecutionRuntime extends ChannelMessageRuntime {return `- ${parts.join(' ')}`;});return {- content: `${platforms.length} platform(s) available for System Bot install:\n${lines.join('\n')}\n\nInstalls are initiated via Settings → Messenger (OAuth requires a browser).`,+ content: `${platforms.length} platform(s) available for System Bot install:\n${lines.join('\n')}\n\nInstalls are initiated via Marketplace → Apps (OAuth requires a browser).`,state: { platforms } satisfies ListMessengerPlatformsState,success: true,};@@ -524,7 +524,7 @@ export class MessageExecutionRuntime extends ChannelMessageRuntime {}case 'unlinked': {return {- content: `The user has no linked ${platform} account for the LobeHub System Bot. Ask them to open Settings → Messenger and connect ${platform} first.`,+ content: `The user has no linked ${platform} account for the LobeHub System Bot. Ask them to open Marketplace → Apps and connect ${platform} first.`,state,success: false,};diff --git a/packages/builtin-tool-message/src/manifest.ts b/packages/builtin-tool-message/src/manifest.tsindex ee523e0d329..596c9b48657 100644--- a/packages/builtin-tool-message/src/manifest.ts+++ b/packages/builtin-tool-message/src/manifest.ts@@ -1069,7 +1069,7 @@ export const MessageManifest: BuiltinToolManifest = {},},{- description: `List the platforms where the user can connect the ${BRANDING_NAME} System Bot. Returns \`appId\` / \`botUsername\` when relevant. Use when guiding the user through \`Settings → Messenger\`; browser OAuth and QR setup flows cannot be initiated from this tool.`,+ description: `List the platforms where the user can connect the ${BRANDING_NAME} System Bot. Returns \`appId\` / \`botUsername\` when relevant. Use when guiding the user through \`Marketplace → Apps\`; browser OAuth and QR setup flows cannot be initiated from this tool.`,name: MessageApiName.listMessengerPlatforms,parameters: {additionalProperties: false,diff --git a/packages/builtin-tool-message/src/systemRole.ts b/packages/builtin-tool-message/src/systemRole.tsindex 5540c5f5e20..a39ba210454 100644--- a/packages/builtin-tool-message/src/systemRole.ts+++ b/packages/builtin-tool-message/src/systemRole.ts@@ -32,24 +32,24 @@ The rest of this section is for sending to **someone else**, to a channel, or inThe send APIs (\`sendMessage\`, \`sendDirectMessage\`, \`replyToThread\`) can deliver through **two sources** — both use the same underlying platform clients (so attachments / formatting / rate behavior are identical), but they come from different lists:- **Per-agent bot** (pass \`botId\`) — the agent's own credentials, configured via \`createBot\`. Listed by \`listBots\`. Messages appear with the per-agent bot's identity.-- **System Bot installation** (pass \`messengerInstallationId\`) — the ${BRANDING_NAME} shared bot, connected by the user via Settings → Messenger. Listed by \`listMessengers\`. Messages appear with the ${BRANDING_NAME} System Bot identity.+- **System Bot installation** (pass \`messengerInstallationId\`) — the ${BRANDING_NAME} shared bot, connected by the user via Marketplace → Apps. Listed by \`listMessengers\`. Messages appear with the ${BRANDING_NAME} System Bot identity.**Routing rule — apply in order:**0. **The target is the conversation you are in right now** (you're running inside an IM conversation — there is a \`<current_conversation>\` block — and you're sending into it, e.g. delivering a generated file): pass **neither** \`botId\` nor \`messengerInstallationId\`. The runtime sends through the exact connection this conversation arrived on. Skip discovery entirely — another bot on the same platform is a different identity and may have a dead session.1. **Call \`listBots\`.** If an entry has \`platform: "<target>"\` and its \`status\` is NOT \`failed\` → use its \`botId\` on the send API. Done. A \`failed\` bot's credentials are broken (e.g. an expired WeChat login accepts text but rejects every file); never auto-pick it — continue to step 2, and mention to the user that the bot needs reconnecting.2. **Otherwise call \`listMessengers\`.** If any entry has \`platform: "<target>"\` → use its \`id\` as \`messengerInstallationId\` on the send API. Done.-3. **Neither has a usable connection for the platform → do NOT pick a different platform.** Tell the user: "I can't reach <platform> for you yet. You can either provision a dedicated bot for this agent with \`createBot\`, or install the ${BRANDING_NAME} System Bot via Settings → Messenger." Stop. (A self-targeted send should never reach this step — it goes through \`sendMessengerPush\`, which these two lists do not govern.)+3. **Neither has a usable connection for the platform → do NOT pick a different platform.** Tell the user: "I can't reach <platform> for you yet. You can either provision a dedicated bot for this agent with \`createBot\`, or install the ${BRANDING_NAME} System Bot via Marketplace → Apps." Stop. (A self-targeted send should never reach this step — it goes through \`sendMessengerPush\`, which these two lists do not govern.)For sends elsewhere, healthy per-agent bots come first because they're purpose-built for the current agent and use identity the user explicitly configured. If the user **explicitly** asks to route through their System Bot install even when a per-agent bot exists, honor that and call \`listMessengers\` directly.Pass **at most one** of \`botId\` / \`messengerInstallationId\` — never both. Omitting both is only for step 0.-When a send reports a WeChat \`errcode -14\` (session expired), the error names the bot's App ID — tell the user to rescan the QR code of **that** bot (per-agent bot settings for a \`listBots\` App ID, Settings → Messenger for a System Bot connection), not whichever WeChat connection comes to mind.+When a send reports a WeChat \`errcode -14\` (session expired), the error names the bot's App ID — tell the user to rescan the QR code of **that** bot (per-agent bot settings for a \`listBots\` App ID, Marketplace → Apps for a System Bot connection), not whichever WeChat connection comes to mind.</outbound_routing><system_bot_management>-The **System Bot** is the ${BRANDING_NAME}-owned shared bot the user connects via \`Settings → Messenger\`. It's separate from per-agent bots (\`createBot\` / \`listBots\`). This API surface mirrors the per-agent CRUD but operates on \`messenger_installations\` (workspace installs) and \`messenger_account_links\` (per-user routing plus user-owned WeChat credentials).+The **System Bot** is the ${BRANDING_NAME}-owned shared bot the user connects via \`Marketplace → Apps\`. It's separate from per-agent bots (\`createBot\` / \`listBots\`). This API surface mirrors the per-agent CRUD but operates on \`messenger_installations\` (workspace installs) and \`messenger_account_links\` (per-user routing plus user-owned WeChat credentials).**Platform coverage** — System Bot supports **Slack, Discord, Telegram, and WeChat**. Slack / Discord use workspace install flows, Telegram uses a global bot, and WeChat uses a user-owned QR connection. For Feishu / Lark / QQ the user must use a per-agent bot via \`createBot\`. \`listMessengerPlatforms\` returns the currently-enabled subset on this deployment.@@ -70,7 +70,7 @@ The **System Bot** is the ${BRANDING_NAME}-owned shared bot the user connects viWhen in doubt, ask. Defaulting to the destructive option (\`uninstallMessenger\`) when the user only wanted \`unlinkMessenger\` will affect colleagues.-**Why there's no \`createMessenger\`**: Setup requires a browser OAuth redirect or QR scan — the tool cannot start either flow. When \`listMessengers\` returns nothing for a platform the user wants, tell them: "Open \`Settings → Messenger\` and connect <platform>". Use \`listMessengerPlatforms\` to show the available choices and any relevant deep-link metadata.+**Why there's no \`createMessenger\`**: Setup requires a browser OAuth redirect or QR scan — the tool cannot start either flow. When \`listMessengers\` returns nothing for a platform the user wants, tell them: "Open \`Marketplace → Apps\` and connect <platform>". Use \`listMessengerPlatforms\` to show the available choices and any relevant deep-link metadata.</system_bot_management><proactive_push>@@ -90,7 +90,7 @@ Platform semantics:Status handling:- \`sent\` — done; for WeChat mention the remaining window quota only if the user asks.- \`queued\` — WeChat only; instruct the user to message the bot first (see above).-- \`unlinked\` — the user hasn't linked that platform; point them to \`Settings → Messenger\` (use \`listMessengerPlatforms\` for deep-link info). Do not fall back to another platform silently.+- \`unlinked\` — the user hasn't linked that platform; point them to \`Marketplace → Apps\` (use \`listMessengerPlatforms\` for deep-link info). Do not fall back to another platform silently.- \`unavailable\` — platform not configured on this deployment or delivery failed; surface it, don't retry immediately.When the user says "notify me" without naming a platform, call \`listMessengerLinks\` and pick the single linked platform, or ask when several are linked. When they DO name one, push straight to it.diff --git a/packages/locales/src/default/components.ts b/packages/locales/src/default/components.tsindex 6786199b4b7..9ae2a926fb9 100644--- a/packages/locales/src/default/components.ts+++ b/packages/locales/src/default/components.ts@@ -73,7 +73,7 @@ export default {'FileManager.actions.renameSuccess': 'Rename successful','FileManager.actions.reorderError': 'Failed to update order, please try again','FileManager.actions.sendToMessenger': 'Send to Messenger',- 'FileManager.actions.sendToMessengerSettings': 'Messenger Settings',+ 'FileManager.actions.manageChatApps': 'Manage chat apps','FileManager.actions.sendToMessengerSetup': 'Set Up Channels','FileManager.actions.sendToMessengerSetupAction': 'Set Up','FileManager.bottom': "You've reached the end.",diff --git a/packages/locales/src/default/discover.ts b/packages/locales/src/default/discover.tsindex cee16afdde4..6ed268f13d3 100644--- a/packages/locales/src/default/discover.ts+++ b/packages/locales/src/default/discover.ts@@ -88,6 +88,27 @@ export default {'assistants.withKnowledge': 'This Agent includes Libraries','assistants.withPlugin': 'This Agent includes Skills','back': 'Back to Discovery',+ 'apps.addMcp': 'Add custom MCP server',+ 'apps.category.chat': 'Chat platforms',+ 'apps.category.developer': 'Developer tools',+ 'apps.category.documents': 'Documents & storage',+ 'apps.category.productivity': 'Productivity',+ 'apps.category.projects': 'Project management',+ 'apps.chatCapability': 'Chat with your Agent',+ 'apps.connect': 'Connect',+ 'apps.connected': 'Connected apps',+ 'apps.continue': 'Continue setup',+ 'apps.description': 'Connect the apps you use to chat with your Agent or give it tools.',+ 'apps.empty': 'No apps available',+ 'apps.manage': 'Manage',+ 'apps.mcpDescription': 'Find MCP servers and connect custom servers to your Agents.',+ 'apps.noInstalledMcp': 'No installed MCP servers yet',+ 'apps.noMatches': 'No matching apps',+ 'apps.noneConnected': 'No connected apps yet',+ 'apps.toolCapability': 'Agent tools',+ 'apps.unavailable': 'This app is unavailable.',+ 'tab.apps': 'Apps',+ 'tab.mcp': 'MCP','catalog.add': 'Add','catalog.agentDescription':'Find Agents and groups for tasks like writing, coding, and research.',@@ -112,6 +133,7 @@ export default {'catalog.verified': 'Verified','catalog.viewAll': 'View all','catalog.viewAllIn': 'View all in {{name}}',+ 'catalog.yourMcpServers': 'Your MCP servers','catalog.yourSkills': 'Your skills','category.assistant.academic': 'Academic','category.assistant.all': 'All',diff --git a/packages/locales/src/default/electron.ts b/packages/locales/src/default/electron.tsindex 4cfc3d5a40f..1f3ed438afe 100644--- a/packages/locales/src/default/electron.ts+++ b/packages/locales/src/default/electron.ts@@ -21,6 +21,7 @@ export default {'navigation.marketplaceModels': 'Marketplace · Models','navigation.marketplaceProviders': 'Marketplace · Providers','navigation.marketplaceSkills': 'Marketplace · Skills',+ 'navigation.marketplaceApps': 'Apps','navigation.marketplaceConnectors': 'Connectors','navigation.marketplaceInstalledSkills': 'Installed Skills','navigation.appMenu': 'App menu',diff --git a/packages/locales/src/default/messenger.ts b/packages/locales/src/default/messenger.tsindex 254720f326e..79b8142ec25 100644--- a/packages/locales/src/default/messenger.ts+++ b/packages/locales/src/default/messenger.ts@@ -54,7 +54,7 @@ export default {'messenger.slack.connections.disconnectSuccess': 'Workspace disconnected.','messenger.slack.connections.disconnectTitle': 'Disconnect workspace','messenger.slack.installBlocked.dismiss': 'Got it',- 'messenger.slack.installBlocked.suggestion':+ 'messenger.slack.installBlocked.nextSteps':"DM @LobeHub on Slack to link your personal account — you don't need to install again. Or ask the original installer to disconnect this workspace first if you want to take over ownership.",'messenger.slack.installBlocked.title': 'Workspace already connected','messenger.slack.installBlocked.withName':@@ -88,8 +88,8 @@ export default {'messenger.discord.connections.disconnectSuccess': 'Server removed.','messenger.discord.connections.disconnectTitle': 'Remove server','messenger.discord.installBlocked.dismiss': 'Got it',- 'messenger.discord.installBlocked.suggestion':- "DM the LobeHub bot on Discord to link your personal account — you don't need to add the bot again. Or ask the original installer to remove this server in LobeHub Settings → Messenger before re-adding it.",+ 'messenger.discord.installBlocked.nextSteps':+ "DM the LobeHub bot on Discord to link your personal account — you don't need to add the bot again. Or ask the original installer to remove this server in LobeHub Marketplace → Apps before re-adding it.",'messenger.discord.installBlocked.title': 'Server already connected','messenger.discord.installBlocked.withName':'"{{workspace}}" is already connected to LobeHub by another user.',@@ -246,17 +246,17 @@ export default {'verify.confirm.conflict.title': 'This account is already linked','verify.confirm.cta': 'Confirm linking','verify.confirm.defaultAgent': 'Default agent',- 'verify.confirm.defaultAgentHint':- 'Your messages will be routed here first. You can switch any time via /agents in the bot or from Settings → Messenger.',+ 'verify.confirm.defaultAgentMarketplaceHint':+ 'Your messages will be routed here first. You can switch any time via /agents in the bot or from Marketplace → Apps.','verify.confirm.defaultAgentPlaceholder': 'Select an agent','verify.confirm.fields.lobeHubAccount': 'LobeHub account','verify.confirm.fields.platformAccount': '{{platform}} account','verify.confirm.fields.workspace': 'Workspace','verify.confirm.noAgents':"You don't have any agents yet. Create one in LobeHub, then come back to finish linking.",- 'verify.confirm.relink.description':- 'This LobeHub account is already linked to {{platform}} account {{account}}. To link a different {{platform}} account, disconnect the current one first in Settings → Messenger.',- 'verify.confirm.relink.manage': 'Open Messenger settings',+ 'verify.confirm.relink.disconnectInMarketplace':+ 'This LobeHub account is already linked to {{platform}} account {{account}}. To link a different {{platform}} account, disconnect the current one first in Marketplace → Apps.',+ 'verify.confirm.relink.openApp': 'Open app','verify.confirm.relink.title': 'Another {{platform}} account is already linked','verify.confirm.title': 'Confirm linking','verify.confirm.workspace': 'Workspace: {{workspace}}',@@ -270,7 +270,7 @@ export default {'verify.error.missingToken': 'Invalid link. Open this page from the bot.','verify.error.title': 'Unable to confirm link','verify.error.unlinkBeforeRelink':- 'This LobeHub account is already linked to another account on this platform. Disconnect it in Settings → Messenger before linking a new one.',+ 'This LobeHub account is already linked to another account on this platform. Disconnect it in Marketplace → Apps before linking a new one.','verify.signInCta': 'Sign in to continue','verify.signInRequired': 'Please sign in to LobeHub to confirm the link.','verify.success.backToLobeHub': 'Back to LobeHub',diff --git a/packages/locales/src/default/setting.ts b/packages/locales/src/default/setting.tsindex 6201a53cd88..47adfb345c5 100644--- a/packages/locales/src/default/setting.ts+++ b/packages/locales/src/default/setting.ts@@ -1096,7 +1096,7 @@ export default {'apps.desktop.title': 'Desktop','apps.messenger.desc':'Talk to your agents where your team already is — replies land back in LobeHub.',- 'apps.messenger.setup': 'Set up',+ 'apps.messenger.openApp': 'Open app','apps.messenger.title': 'Messenger','apps.mobile.cta': 'Get mobile app','apps.mobile.desc': 'Pick up where you left off — your chats, agents, and files travel with you.',diff --git a/scripts/stylexMigration/legacyFiles.json b/scripts/stylexMigration/legacyFiles.jsonindex b8a0233f5b4..21f78a367f3 100644--- a/scripts/stylexMigration/legacyFiles.json+++ b/scripts/stylexMigration/legacyFiles.json@@ -402,10 +402,8 @@"src/features/Messenger/IntegrationDetail/MessengerPushWindowState.tsx","src/features/Messenger/IntegrationDetail/Wechat.tsx","src/features/Messenger/IntegrationDetail/shared.tsx",- "src/features/Messenger/IntegrationList.tsx","src/features/Messenger/LinkModal/Telegram.tsx","src/features/Messenger/Verify/Body/shared.tsx",- "src/features/Messenger/index.tsx","src/features/Messenger/scopeOptions.tsx","src/features/MobileHome/Layout/MobileLayout/style.ts","src/features/MobileHome/Layout/SessionHeader/style.ts",diff --git a/src/components/Skeleton/Settings/MessengerDetail.tsx b/src/components/Skeleton/Settings/MessengerDetail.tsxindex 295856df4f0..1a499ec2b5c 100644--- a/src/components/Skeleton/Settings/MessengerDetail.tsx+++ b/src/components/Skeleton/Settings/MessengerDetail.tsx@@ -24,21 +24,6 @@ const styles = stylex.create({borderColor: cssVar.colorBorder,borderRadius: cssVar.borderRadius,},- grid: {- display: 'grid',- gridTemplateColumns: {- '@media (width <= 720px)': '1fr',- 'default': 'repeat(2, 1fr)',- },- gap: '12px',- },- listCard: {- padding: '16px',- borderWidth: '1px',- borderStyle: 'solid',- borderColor: cssVar.colorBorderSecondary,- borderRadius: cssVar.borderRadiusLG,- },});const isPlatform = (value: string | undefined): value is MessengerPlatform =>@@ -51,44 +36,6 @@ const Line = ({ bar, height, width }: { bar: number; height: number; width: numb</Flexbox>);-/**- * The platform cards of `IntegrationList`: a two-column grid (one column under- * 720px) of outlined cards with a 48px avatar, a name + description stack and a- * chevron. Which platforms the server offers is data, so the cards are bars.- */-export const MessengerListGridSkeleton = ({ cards = 4 }: { cards?: number }) => (- <div aria-busy data-testid={'messenger-list-skeleton'} {...stylex.props(styles.grid)}>- {Array.from({ length: cards }, (_, index) => (- <div key={index} {...stylex.props(styles.listCard)}>- <Flexbox horizontal align={'center'} gap={16}>- <SkeletonBar height={48} radius={'50%'} width={48} />- <Flexbox flex={1} gap={2} style={{ minWidth: 0 }}>- <Line bar={15} height={24} width={88 + (index % 2) * 24} />- <Line bar={12} height={22} width={'80%'} />- </Flexbox>- <SkeletonBar height={16} width={16} />- </Flexbox>- </div>- ))}- </div>-);--/** `/settings/messenger`: the subtitle (static copy) above the platform grid. */-export const MessengerListSkeleton = () => {- const { t, ready } = useTranslation('messenger');-- return (- <Flexbox gap={20}>- {ready ? (- <Text type={'secondary'}>{t('messenger.subtitle')}</Text>- ) : (- <Line bar={14} height={22} width={360} />- )}- <MessengerListGridSkeleton />- </Flexbox>- );-};-const ConnectionSkeleton = memo<{ withNestedContent?: boolean }>(({ withNestedContent }) => (<Block className={stylex.props(styles.card).className}><Flexbox gap={12}>@@ -187,7 +134,3 @@ export const IntegrationDetailSkeleton = memo<IntegrationDetailSkeletonProps>(},);IntegrationDetailSkeleton.displayName = 'MessengerIntegrationDetailSkeleton';--export const MessengerPlatformDetailSkeleton = ({ platform }: { platform: string }) => (- <IntegrationDetailSkeleton platform={platform} withNestedContent={platform !== 'slack'} />-);diff --git a/src/components/Skeleton/Settings/Page.test.ts b/src/components/Skeleton/Settings/Page.test.tsindex 3eb9c92a741..dee88797489 100644--- a/src/components/Skeleton/Settings/Page.test.ts+++ b/src/components/Skeleton/Settings/Page.test.ts@@ -8,9 +8,9 @@ import { getSettingsTabSkeleton, SETTINGS_TAB_SKELETONS } from './tabs';describe('resolveSettingsSkeletonTab', () => {it('reads the tab and its sub-segment', () => {- expect(resolveSettingsSkeletonTab('/settings/messenger/discord')).toEqual({- sub: 'discord',- tab: 'messenger',+ expect(resolveSettingsSkeletonTab('/settings/provider/all')).toEqual({+ sub: 'all',+ tab: 'provider',});expect(resolveSettingsSkeletonTab('/settings/billing')).toEqual({ tab: 'billing' });});diff --git a/src/components/Skeleton/Settings/tabs/Messenger.tsx b/src/components/Skeleton/Settings/tabs/Messenger.tsxdeleted file mode 100644index 31031021de7..00000000000--- a/src/components/Skeleton/Settings/tabs/Messenger.tsx+++ /dev/null@@ -1,12 +0,0 @@-'use client';--import { MessengerListSkeleton, MessengerPlatformDetailSkeleton } from '../MessengerDetail';-import type { SettingsTabSkeleton, SettingsTabSkeletonProps } from './types';--/** `/settings/messenger` lists the platforms; `/settings/messenger/:platform` is one platform. */-const Body = ({ sub }: SettingsTabSkeletonProps) =>- sub ? <MessengerPlatformDetailSkeleton platform={sub} /> : <MessengerListSkeleton />;--const MessengerSkeleton: SettingsTabSkeleton = { Body };--export default MessengerSkeleton;diff --git a/src/components/Skeleton/Settings/tabs/index.ts b/src/components/Skeleton/Settings/tabs/index.tsindex 2ab4e66712c..d2f0bef0f7f 100644--- a/src/components/Skeleton/Settings/tabs/index.ts+++ b/src/components/Skeleton/Settings/tabs/index.ts@@ -14,7 +14,6 @@ import HotkeySkeleton from './Hotkey';import LabelsSkeleton from './Labels';import LabsSkeleton from './Labs';import MemorySkeleton from './Memory';-import MessengerSkeleton from './Messenger';import NotificationSkeleton from './Notification';import OAuthAppsSkeleton from './OAuthApps';import PlansSkeleton from './Plans';@@ -52,7 +51,6 @@ export const SETTINGS_TAB_SKELETONS: Partial<Record<SettingsTabs, SettingsTabSke[SettingsTabs.Labels]: LabelsSkeleton,[SettingsTabs.Labs]: LabsSkeleton,[SettingsTabs.Memory]: MemorySkeleton,- [SettingsTabs.Messenger]: MessengerSkeleton,[SettingsTabs.Notification]: NotificationSkeleton,[SettingsTabs.OAuthApps]: OAuthAppsSkeleton,[SettingsTabs.Plans]: PlansSkeleton,diff --git a/src/features/Apps/index.tsx b/src/features/Apps/index.tsxindex 41868791503..d8df6f97e94 100644--- a/src/features/Apps/index.tsx+++ b/src/features/Apps/index.tsx@@ -5,9 +5,10 @@ import { Button, Tag, Text } from '@lobehub/ui';import { ArrowUpRight, Check, Copy } from 'lucide-react';import { useState } from 'react';import { useTranslation } from 'react-i18next';-import { useNavigate } from 'react-router';+import { marketplaceAppPath } from '@/features/Marketplace/paths';import { PlatformAvatar, SUPPORTED_MESSENGER_PLATFORMS } from '@/features/Messenger/constants';+import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import { CLI_INSTALL_COMMAND } from './const';import { CliScene, DesktopScene, MobileScene } from './scenes';@@ -21,7 +22,7 @@ const DESKTOP_FEATURES = ['files', 'tools', 'focus'] as const;const AppsPage = () => {const { t } = useTranslation('setting');- const navigate = useNavigate();+ const navigate = useWorkspaceAwareNavigate();const [copied, setCopied] = useState(false);const copyInstallCommand = async () => {@@ -108,9 +109,9 @@ const AppsPage = () => {icon={ArrowUpRight}iconPosition="end"size="small"- onClick={() => navigate('/settings/messenger')}+ onClick={() => navigate(marketplaceAppPath(platform.id))}>- {t('apps.messenger.setup')}+ {t('apps.messenger.openApp')}</Button></div>))}diff --git a/src/features/Home/InputArea/MessengerBanner.tsx b/src/features/Home/InputArea/MessengerBanner.tsxindex 9a9ad944041..cdbe32b2c71 100644--- a/src/features/Home/InputArea/MessengerBanner.tsx+++ b/src/features/Home/InputArea/MessengerBanner.tsx@@ -7,6 +7,7 @@ import { memo, useCallback, useMemo } from 'react';import { useTranslation } from 'react-i18next';import { getPlatformIcon } from '@/features/AgentChannel/const';+import { MARKETPLACE_APPS_PATH } from '@/features/Marketplace/paths';import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import { InputBanner } from './InputBanner';@@ -34,7 +35,7 @@ const styles = createStaticStyles(({ css, cssVar }) => ({background: ${cssVar.colorBgContainer};box-shadow:- 0 0 8px -2px rgb(0 0 0 / 5%),+ ${cssVar.boxShadowTertiary},0 0 0 1px ${cssVar.colorFillTertiary};`,icon: css`@@ -71,7 +72,7 @@ const MessengerBanner = memo(() => {}, []);const handleNavigateToMessenger = useCallback(() => {- navigate('/settings/messenger');+ navigate(MARKETPLACE_APPS_PATH);}, [navigate]);return (diff --git a/src/features/Integrations/ConnectorGate.tsx b/src/features/Integrations/ConnectorGate.tsxindex f98bc68eba7..0a916bc6040 100644--- a/src/features/Integrations/ConnectorGate.tsx+++ b/src/features/Integrations/ConnectorGate.tsx@@ -40,7 +40,7 @@ interface ConnectorGateProps {* separate authorization, so it stays here under the connect row.*/const ConnectorGate = memo<ConnectorGateProps>(({ children, identifier }) => {- const { t } = useTranslation('integration');+ const { t, ready } = useTranslation('integration');const { available, connected, error, isInitialLoading, provider, retry, server } =useConnectorConnection(identifier);const view = resolveConnectorPageView({@@ -51,6 +51,7 @@ const ConnectorGate = memo<ConnectorGateProps>(({ children, identifier }) => {isInitialLoading,});+ if (!ready) return <IntegrationConnectionsSkeleton />;if (view === 'ready' && connected) return children;return (diff --git a/src/features/Integrations/connectorPage.test.ts b/src/features/Integrations/connectorPage.test.tsindex 6be550e8093..1476d38f9f6 100644--- a/src/features/Integrations/connectorPage.test.ts+++ b/src/features/Integrations/connectorPage.test.ts@@ -1,7 +1,5 @@import { describe, expect, it } from 'vitest';-import { parseMobileSelection } from '@/features/Settings/skill/mobileSelection';-import {buildConnectorPagePath,buildLegacyIntegrationPath,@@ -14,11 +12,7 @@ describe('buildConnectorPagePath', () => {it.each(['github', 'linear'] as const)('opens the %s connector in the Marketplace', (id) => {const path = buildConnectorPagePath(id);- expect(path.startsWith('/marketplace/connector/installed?')).toBe(true);- expect(parseMobileSelection(query(path).get('open'))).toEqual({- identifier: id,- type: 'lobehub-connector',- });+ expect(path).toBe(`/marketplace/app/${id}`);});it('carries the install result over', () => {@@ -35,7 +29,7 @@ describe('buildConnectorPagePath', () => {const params = query(buildConnectorPagePath('linear', '?open=plugin:other&foo=1'));expect(params.get('foo')).toBeNull();- expect(params.get('open')).toBe('lobehub-connector:linear');+ expect(params.get('open')).toBeNull();});});@@ -43,15 +37,13 @@ describe('buildLegacyIntegrationPath', () => {it('sends an integration page to its connector with the callback result', () => {const params = query(buildLegacyIntegrationPath('linear', '?error=access_denied'));- expect(params.get('open')).toBe('lobehub-connector:linear');+ expect(params.get('open')).toBeNull();expect(params.get('error')).toBe('access_denied');});- it('sends the directory and unknown pages to the installed connectors', () => {- expect(buildLegacyIntegrationPath(undefined)).toBe('/marketplace/connector/installed');- expect(buildLegacyIntegrationPath('vercel', '?installed=ok')).toBe(- '/marketplace/connector/installed',- );+ it('sends the directory and unknown pages to Apps', () => {+ expect(buildLegacyIntegrationPath(undefined)).toBe('/marketplace/app');+ expect(buildLegacyIntegrationPath('vercel', '?installed=ok')).toBe('/marketplace/app');});});diff --git a/src/features/Integrations/connectorPage.ts b/src/features/Integrations/connectorPage.tsindex 5f5ea8b3c99..9887d281d1a 100644--- a/src/features/Integrations/connectorPage.ts+++ b/src/features/Integrations/connectorPage.ts@@ -1,8 +1,4 @@-import { MARKETPLACE_INSTALLED_CONNECTORS_PATH } from '@/features/Marketplace/paths';-import {- encodeMobileSelection,- MOBILE_SELECTION_PARAM,-} from '@/features/Settings/skill/mobileSelection';+import { MARKETPLACE_APPS_PATH, marketplaceAppPath } from '@/features/Marketplace/paths';/*** Connectors whose Marketplace page also manages a LobeHub-owned integration@@ -22,14 +18,13 @@ export const hasConnectorPage = (identifier: string): identifier is ConnectorPag/** The connector's Marketplace page, carrying an install result over from `search`. */export const buildConnectorPagePath = (identifier: ConnectorPageId, search = ''): string => {const source = new URLSearchParams(search);- const params = new URLSearchParams({- [MOBILE_SELECTION_PARAM]: encodeMobileSelection({ identifier, type: 'lobehub-connector' }),- });+ const params = new URLSearchParams();for (const key of INSTALL_RESULT_PARAMS) {const value = source.get(key);if (value) params.set(key, value);}- return `${MARKETPLACE_INSTALLED_CONNECTORS_PATH}?${params}`;+ const path = marketplaceAppPath(identifier);+ return params.size ? `${path}?${params}` : path;};/**@@ -37,6 +32,4 @@ export const buildConnectorPagePath = (identifier: ConnectorPageId, search = '')* callbacks still return to those paths, so their result must survive this.*/export const buildLegacyIntegrationPath = (sub: string | undefined, search = ''): string =>- sub && hasConnectorPage(sub)- ? buildConnectorPagePath(sub, search)- : MARKETPLACE_INSTALLED_CONNECTORS_PATH;+ sub && hasConnectorPage(sub) ? buildConnectorPagePath(sub, search) : MARKETPLACE_APPS_PATH;diff --git a/src/features/Integrations/useLinearIntegration.ts b/src/features/Integrations/useLinearIntegration.tsindex bddaf50a515..c825c62b7c9 100644--- a/src/features/Integrations/useLinearIntegration.ts+++ b/src/features/Integrations/useLinearIntegration.ts@@ -5,16 +5,18 @@ import { linearService } from '@/services/linear';import { linearKeys } from './Linear/swrKeys';+export const useLinearConnections = () => {+ const workspaceId = useActiveWorkspaceId();+ return useSWR(linearKeys.connections(workspaceId), () => linearService.listConnections());+};+/*** Everything the Linear integration surfaces need, shared by the overview* card and the detail page. `enabled` is "at least one active connection".*/export const useLinearIntegration = () => {- const workspaceId = useActiveWorkspaceId();const config = useSWR(linearKeys.config(), () => linearService.getConfig());- const connections = useSWR(linearKeys.connections(workspaceId), () =>- linearService.listConnections(),- );+ const connections = useLinearConnections();const isInitialLoading = config.data === undefined || connections.data === undefined;const error = config.error ?? connections.error;diff --git a/src/features/MCPPluginDetail/Header.tsx b/src/features/MCPPluginDetail/Header.tsxindex b251496b6e3..9e73c6b4c39 100644--- a/src/features/MCPPluginDetail/Header.tsx+++ b/src/features/MCPPluginDetail/Header.tsx@@ -33,7 +33,7 @@ import { useTranslation } from 'react-i18next';import { Link } from 'react-router';import OfficialIcon from '@/components/OfficialIcon';-import { MARKETPLACE_CONNECTOR_PATH } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import Scores from '@/features/MCP/Scores';import { getLanguageColor, getRecommendedDeployment } from '@/features/MCP/utils';import { useCategory } from '@/hooks/useMCPCategory';@@ -143,7 +143,7 @@ const Header = memo<{ inModal?: boolean; mobile?: boolean }>(({ mobile: isMobile<Linkto={qs.stringifyUrl({query: { category: cate?.key },- url: MARKETPLACE_CONNECTOR_PATH,+ url: MARKETPLACE_MCP_PATH,})}><Button icon={cate?.icon} size={'middle'}>diff --git a/src/features/MCPPluginDetail/Overview/TagList.tsx b/src/features/MCPPluginDetail/Overview/TagList.tsxindex dc86bd1e8e8..b3b8969d4a7 100644--- a/src/features/MCPPluginDetail/Overview/TagList.tsx+++ b/src/features/MCPPluginDetail/Overview/TagList.tsx@@ -4,7 +4,7 @@ import { createStaticStyles, Flexbox, Tag } from '@lobehub/ui';import qs from 'query-string';import { memo } from 'react';-import { MARKETPLACE_CONNECTOR_PATH } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import { Link } from '@/libs/router';import { densityVars } from '@/styles/densityVars';@@ -33,7 +33,7 @@ const TagList = memo<{ tags: string[] }>(({ tags }) => {query: {q: tag,},- url: MARKETPLACE_CONNECTOR_PATH,+ url: MARKETPLACE_MCP_PATH,})}><Tag className={styles.tag}>{tag}</Tag>diff --git a/src/features/MCPPluginDetail/Overview/index.tsx b/src/features/MCPPluginDetail/Overview/index.tsxindex 3567372b540..bc54ba217d8 100644--- a/src/features/MCPPluginDetail/Overview/index.tsx+++ b/src/features/MCPPluginDetail/Overview/index.tsx@@ -3,7 +3,7 @@ import qs from 'query-string';import { memo } from 'react';import { useTranslation } from 'react-i18next';-import { MARKETPLACE_CONNECTOR_PATH } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import MarkdownRender from '@/routes/(main)/community/(detail)/features/MakedownRender';import McpList from '@/routes/(main)/community/(list)/mcp/features/List';import Title from '@/routes/(main)/community/features/Title';@@ -44,7 +44,7 @@ const Overview = memo<{ inModal?: boolean }>(({ inModal }) => {query: {category,},- url: MARKETPLACE_CONNECTOR_PATH,+ url: MARKETPLACE_MCP_PATH,})}>{t('mcp.details.related.listTitle')}diff --git a/src/features/Marketplace/Apps/AppCatalog.tsx b/src/features/Marketplace/Apps/AppCatalog.tsxnew file mode 100644index 00000000000..12983d62985--- /dev/null+++ b/src/features/Marketplace/Apps/AppCatalog.tsx@@ -0,0 +1,143 @@+'use client';++import { Button, Tag, Text } from '@lobehub/ui';+import * as stylex from '@stylexjs/stylex';+import { useTranslation } from 'react-i18next';+import { useSearchParams } from 'react-router';++import AsyncBoundary from '@/components/AsyncBoundary';+import AsyncError from '@/components/AsyncError';+import { CatalogRowsSkeleton } from '@/components/Skeleton/MarketplaceCatalog';+import {+ matchesConnectorKeyword,+ matchesIntegrationKeyword,+} from '@/features/Settings/skill/features/connectorSections';+import { RowAddAction, RowMoreMenu } from '@/features/Settings/skill/features/RowActions';+import SkillListRow from '@/features/Settings/skill/features/SkillListRow';+import { isMobileSurface } from '@/utils/mobileSurface';++import CatalogSection from '../Catalog/CatalogSection';+import DiscoverCatalogHeader from '../Catalog/DiscoverCatalogHeader';+import { catalogStyles } from '../Catalog/styles';+import { useCatalogDetailNavigate } from '../Catalog/useCatalogDetailNavigate';+import { AppIcon } from './AppIcon';+import { appCategories, getAppHome, hasAppConnection } from './catalog';+import { useMarketplaceApps } from './useMarketplaceApps';++export default function AppCatalog() {+ const { t } = useTranslation('discover');+ const { t: ts } = useTranslation('setting');+ const { t: tm } = useTranslation('messenger');+ const [params, setParams] = useSearchParams();+ const connected = params.get('view') === 'connected';+ const keyword = params.get('q') ?? '';+ const navigate = useCatalogDetailNavigate();+ const { apps, loading, refreshing, error, retry } = useMarketplaceApps();+ const rows = apps.filter((app) => {+ if (connected && !hasAppConnection(app)) return false;+ return (+ matchesConnectorKeyword(keyword, [+ app.name,+ app.id,+ t(`apps.category.${app.category}`),+ app.channel && tm(`messenger.list.${app.channel.id}.description`),+ ]) ||+ (app.tool && matchesIntegrationKeyword(app.tool, keyword, ts))+ );+ });++ return (+ <div {...stylex.props(catalogStyles.frame)}>+ <DiscoverCatalogHeader+ kind={'app'}+ titleExtra={+ isMobileSurface() && (+ <Button+ aria-pressed={connected}+ size={'small'}+ type={connected ? 'primary' : 'default'}+ onClick={() => {+ const next = new URLSearchParams(params);+ if (connected) next.delete('view');+ else next.set('view', 'connected');+ setParams(next);+ }}+ >+ {t('apps.connected')}+ </Button>+ )+ }+ />+ {Boolean(error) && <AsyncError error={error} variant={'block'} onRetry={retry} />}+ <AsyncBoundary+ data={rows.length || undefined}+ isEmpty={!error && rows.length === 0}+ isLoading={loading || (connected && refreshing)}+ loading={<CatalogRowsSkeleton />}+ empty={+ <Text align={'center'} type={'secondary'}>+ {keyword ? t('apps.noMatches') : connected ? t('apps.noneConnected') : t('apps.empty')}+ </Text>+ }+ >+ {appCategories.map((category) => {+ const group = rows.filter((app) => app.category === category);+ if (!group.length) return null;+ return (+ <CatalogSection+ count={group.length}+ key={category}+ label={t(`apps.category.${category}`)}+ loading={false}+ >+ {group.map((app) => {+ const tool = app.tool;+ const summary = app.channel+ ? tm(`messenger.list.${app.channel.id}.description`)+ : tool?.type === 'lobehub'+ ? ts(`tools.lobehubSkill.providers.${tool.provider.id}.description`, {+ defaultValue: tool.provider.description,+ })+ : tool &&+ ts(`tools.composio.servers.${tool.serverType.identifier}.description`, {+ defaultValue: tool.serverType.description,+ });+ const isConnected = hasAppConnection(app);+ const label = t('catalog.rowAction', {+ action: isConnected+ ? t('apps.manage')+ : app.channelPending+ ? t('apps.continue')+ : t('apps.connect'),+ name: app.name,+ });+ const open = () => navigate(getAppHome(app));+ return (+ <SkillListRow+ icon={() => <AppIcon app={app} size={20} />}+ key={app.id}+ summary={summary}+ title={app.name}+ extra={+ <>+ {app.channel?.access?.requiredPlan === 'paid' && (+ <Tag size={'small'}>{tm('messenger.paidBadge')}</Tag>+ )}+ {isConnected ? (+ <RowMoreMenu label={label} onOpenDetail={open} />+ ) : (+ <RowAddAction label={label} onClick={open} />+ )}+ </>+ }+ onClick={open}+ />+ );+ })}+ </CatalogSection>+ );+ })}+ </AsyncBoundary>+ </div>+ );+}diff --git a/src/features/Marketplace/Apps/AppDetail.tsx b/src/features/Marketplace/Apps/AppDetail.tsxnew file mode 100644index 00000000000..c696d5b358a--- /dev/null+++ b/src/features/Marketplace/Apps/AppDetail.tsx@@ -0,0 +1,167 @@+'use client';++import { Button, Flexbox, Segmented, Text } from '@lobehub/ui';+import * as stylex from '@stylexjs/stylex';+import isEqual from 'fast-deep-equal';+import { ChevronLeft } from 'lucide-react';+import { useTranslation } from 'react-i18next';+import { useLocation, useParams, useSearchParams } from 'react-router';++import { useActiveWorkspaceId } from '@/business/client/hooks/useActiveWorkspaceId';+import AsyncBoundary from '@/components/AsyncBoundary';+import { CatalogRowsSkeleton } from '@/components/Skeleton/MarketplaceCatalog';+import { hasConnectorPage } from '@/features/Integrations/connectorPage';+import InstallResult from '@/features/Messenger/InstallResult';+import IntegrationDetail from '@/features/Messenger/IntegrationDetail';+import ComposioSkillItem from '@/features/Settings/skill/features/ComposioSkillItem';+import LobehubSkillItem from '@/features/Settings/skill/features/LobehubSkillItem';+import SkillDetail from '@/features/Settings/skill/features/SkillDetail';+import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';+import { useToolStore } from '@/store/tool';+import { connectorSelectors, isIntegrationInConnectorTab } from '@/store/tool/slices/connector';++import { catalogStyles } from '../Catalog/styles';+import { MARKETPLACE_APPS_PATH } from '../paths';+import { AppIcon } from './AppIcon';+import { useMarketplaceApps } from './useMarketplaceApps';++export default function AppDetail() {+ const { appId } = useParams();+ const [params, setParams] = useSearchParams();+ const location = useLocation();+ const navigate = useWorkspaceAwareNavigate();+ const { t } = useTranslation(['discover', 'setting']);+ const { apps, composioServers, lobehubServers, toolSync, loading, error, retry } =+ useMarketplaceApps();+ const app = apps.find((entry) => entry.id === appId);+ const tool = app?.tool;+ const channel = app?.channel;+ const workspace = useActiveWorkspaceId();+ const useConnectors = useToolStore((s) => s.useFetchConnectors);+ const connectorsSync = useConnectors(!!tool);+ const connectors = useToolStore(connectorSelectors.connectorList, isEqual);+ const initialized = useToolStore((s) => s.isConnectorsInit);+ const toolInitialized = useToolStore((s) =>+ tool?.type === 'composio' ? s.isComposioServersInit : s.lobehubSkillServers !== undefined,+ );+ const composioServer = composioServers.find((s) => s.identifier === appId);+ const account = tool?.type === 'composio' ? composioServer?.connectedAccountId : undefined;+ const inPublic = app && isIntegrationInConnectorTab(app.id, connectors, 'public', account);+ const inPrivate = app && isIntegrationInConnectorTab(app.id, connectors, 'private', account);+ const privateTab = inPrivate && (!inPublic || params.get('visibility') === 'private');+ const visibility = workspace ? (privateTab ? 'private' : 'public') : undefined;+ const selected = channel && (!tool || params.get('capability') !== 'tools') ? 'channel' : 'tools';+ const updateParam = (key: string, value: string) => {+ const query = new URLSearchParams(params);+ query.set(key, value);+ setParams(query, { replace: true, state: location.state });+ };++ const onBack = () => {+ if (location.state?.marketplaceCatalog) navigate(-1);+ else navigate(MARKETPLACE_APPS_PATH);+ };+ return (+ <div {...stylex.props(catalogStyles.frame)}>+ {(appId === 'slack' || appId === 'discord') && <InstallResult key={appId} platform={appId} />}+ <Flexbox align={'flex-start'}>+ <Button icon={ChevronLeft} size={'small'} type={'text'} onClick={onBack}>+ {t('tab.apps')}+ </Button>+ </Flexbox>+ <AsyncBoundary+ data={app}+ empty={<Text type={'secondary'}>{t('apps.unavailable')}</Text>}+ error={error}+ isEmpty={!app}+ isLoading={loading}+ loading={<CatalogRowsSkeleton />}+ onRetry={retry}+ >+ {app && (+ <>+ <Flexbox horizontal align={'center'} gap={12}>+ <AppIcon app={app} />+ <Text as={'h1'} fontSize={24} weight={600}>+ {app.name}+ </Text>+ </Flexbox>+ {channel && tool && (+ <Segmented<'channel' | 'tools'>+ value={selected}+ options={[+ { label: t('apps.chatCapability'), value: 'channel' },+ { label: t('apps.toolCapability'), value: 'tools' },+ ]}+ onChange={(next) => updateParam('capability', next)}+ />+ )}+ {selected === 'channel' && channel && (+ <IntegrationDetail+ access={channel.access}+ appId={channel.appId}+ botUsername={channel.botUsername}+ name={app.name}+ platform={channel.id}+ />+ )}+ {selected === 'tools' && tool && (+ <>+ {workspace && inPublic && inPrivate && (+ <Segmented<'public' | 'private'>+ value={visibility}+ options={[+ {+ value: 'public',+ label: t('skillView.connectorTabs.workspace', { ns: 'setting' }),+ },+ {+ value: 'private',+ label: t('skillView.connectorTabs.private', { ns: 'setting' }),+ },+ ]}+ onChange={(next) => updateParam('visibility', next)}+ />+ )}+ {hasConnectorPage(app.id) || app.toolConnected ? (+ <>+ {tool.type === 'composio' && (+ <ComposioSkillItem server={composioServer} serverType={tool.serverType} />+ )}+ <SkillDetail+ identifier={app.id}+ type={tool.type === 'lobehub' ? 'lobehub-connector' : 'plugin'}+ visibility={visibility}+ />+ </>+ ) : (+ <AsyncBoundary+ data={(toolInitialized && (!workspace || initialized)) || undefined}+ error={toolSync[tool.type].error ?? connectorsSync.error}+ loading={<CatalogRowsSkeleton count={1} />}+ isLoading={+ toolSync[tool.type].isValidating || (!initialized && connectorsSync.isLoading)+ }+ onRetry={() => {+ retry();+ void connectorsSync.mutate();+ }}+ >+ {tool.type === 'lobehub' ? (+ <LobehubSkillItem+ provider={tool.provider}+ server={lobehubServers.find((s) => s.identifier === app.id)}+ />+ ) : (+ <ComposioSkillItem server={composioServer} serverType={tool.serverType} />+ )}+ </AsyncBoundary>+ )}+ </>+ )}+ </>+ )}+ </AsyncBoundary>+ </div>+ );+}diff --git a/src/features/Marketplace/Apps/AppDynamicMeta.ts b/src/features/Marketplace/Apps/AppDynamicMeta.tsnew file mode 100644index 00000000000..b6d414e69cd--- /dev/null+++ b/src/features/Marketplace/Apps/AppDynamicMeta.ts@@ -0,0 +1,20 @@+import { getComposioAppByIdentifier, getLobehubSkillProviderById } from '@lobechat/const';++import { SUPPORTED_MESSENGER_PLATFORMS } from '@/features/Messenger/platforms';+import { usePublishDynamicRouteMeta } from '@/features/RouteMeta/usePublishDynamicRouteMeta';+import type { DynamicRouteMetaProps } from '@/spa/router/routeMeta';+import { messengerSelectors, useMessengerStore } from '@/store/messenger';++export default function AppDynamicMeta({ onResolve, params }: DynamicRouteMetaProps) {+ const id = params.appId ?? '';+ const channelName = useMessengerStore(+ (state) => messengerSelectors.platforms(state)?.find((channel) => channel.id === id)?.name,+ );+ const title =+ channelName ??+ SUPPORTED_MESSENGER_PLATFORMS.find((channel) => channel.id === id)?.name ??+ getLobehubSkillProviderById(id)?.label ??+ getComposioAppByIdentifier(id)?.label;+ usePublishDynamicRouteMeta({ title }, onResolve);+ return null;+}diff --git a/src/features/Marketplace/Apps/AppIcon.tsx b/src/features/Marketplace/Apps/AppIcon.tsxnew file mode 100644index 00000000000..c09bb0197c0--- /dev/null+++ b/src/features/Marketplace/Apps/AppIcon.tsx@@ -0,0 +1,16 @@+import { Avatar, Icon } from '@lobehub/ui';++import { PlatformBrandIcon } from '@/features/Messenger/constants';++import type { MarketplaceApp } from './catalog';++export const AppIcon = ({ app, size = 24 }: { app: MarketplaceApp; size?: number }) => {+ if (app.channel) return <PlatformBrandIcon platform={app.channel.id} size={size} />;+ const icon = app.tool?.type === 'lobehub' ? app.tool.provider.icon : app.tool?.serverType.icon;+ if (!icon) return null;+ return typeof icon === 'string' ? (+ <Avatar avatar={icon} size={size} />+ ) : (+ <Icon icon={icon} size={size} />+ );+};diff --git a/src/features/Marketplace/Apps/ConnectedAppNav.tsx b/src/features/Marketplace/Apps/ConnectedAppNav.tsxnew file mode 100644index 00000000000..f81ffaf120c--- /dev/null+++ b/src/features/Marketplace/Apps/ConnectedAppNav.tsx@@ -0,0 +1,15 @@+import NavItem from '@/features/NavPanel/components/NavItem';+import WorkspaceLink from '@/features/Workspace/WorkspaceLink';++import { AppIcon } from './AppIcon';+import { getAppHome, hasAppConnection } from './catalog';+import { useMarketplaceApps } from './useMarketplaceApps';++export default function ConnectedAppNav({ selected }: { selected?: string }) {+ const { apps } = useMarketplaceApps();+ return apps.filter(hasAppConnection).map((app) => (+ <WorkspaceLink key={app.id} to={getAppHome(app)}>+ <NavItem active={selected === app.id} icon={() => <AppIcon app={app} />} title={app.name} />+ </WorkspaceLink>+ ));+}diff --git a/src/features/Marketplace/Apps/catalog.test.ts b/src/features/Marketplace/Apps/catalog.test.tsnew file mode 100644index 00000000000..53010a1ba48--- /dev/null+++ b/src/features/Marketplace/Apps/catalog.test.ts@@ -0,0 +1,70 @@+import { getConnectorCatalog } from '@lobechat/const';+import { describe, expect, it } from 'vitest';++import type { MessengerPlatformItem } from '@/store/messenger/projection';++import { buildMarketplaceApps, hasAppConnection } from './catalog';++const slack: MessengerPlatformItem = {+ appId: 'slack-app',+ botUsername: undefined,+ connectionMode: 'webhook',+ enabled: true,+ id: 'slack',+ name: 'Slack',+ platform: 'slack',+};+const inputs = {+ channels: [slack],+ isToolConnected: () => false,+ integrationConnected: () => false,+ installedChannels: new Set<string>(),+ linkedChannels: new Set<string>(),+ tools: getConnectorCatalog({ composio: true, lobehub: true }),+};++describe('marketplace apps', () => {+ it('lists Slack once with both capabilities and a pending personal binding', () => {+ const apps = buildMarketplaceApps({ ...inputs, installedChannels: new Set(['slack']) });+ const matches = apps.filter((app) => app.id === 'slack');+ expect(matches).toHaveLength(1);+ expect(matches[0]).toMatchObject({+ category: 'chat',+ channel: slack,+ channelPending: true,+ tool: { type: 'composio' },+ });+ expect(hasAppConnection(matches[0])).toBe(false);+ });++ it.each(['tool', 'channel'])('counts only the authorized Slack capability (%s)', (kind) => {+ const ids = new Set(['slack']);+ const apps = buildMarketplaceApps({+ ...inputs,+ ...(kind === 'tool' ? { isToolConnected: () => true } : { linkedChannels: ids }),+ });+ const slackApp = apps.find((app) => app.id === 'slack')!;+ expect(slackApp.channelLinked).toBe(kind === 'channel');+ expect(slackApp.toolConnected).toBe(kind === 'tool');+ expect(hasAppConnection(slackApp)).toBe(true);+ });++ it.each(['github', 'linear'])('counts a %s integration independently of tool OAuth', (id) => {+ const app = buildMarketplaceApps({+ ...inputs,+ integrationConnected: (provider) => provider === id,+ }).find((app) => app.id === id)!;+ expect(app.toolConnected).toBe(false);+ expect(hasAppConnection(app)).toBe(true);+ });++ it('lists only the supported capabilities on each deployment', () => {+ const channelOnly = buildMarketplaceApps({ ...inputs, tools: [] });+ expect(channelOnly).toHaveLength(1);+ expect(channelOnly[0].tool).toBeUndefined();+ const toolsOnly = buildMarketplaceApps({ ...inputs, channels: [] });+ expect(toolsOnly.find((app) => app.id === 'slack')?.category).toBe('chat');+ expect(toolsOnly.find((app) => app.id === 'whatsapp')?.category).toBe('chat');+ expect(toolsOnly.every((app) => !app.channel)).toBe(true);+ });+});diff --git a/src/features/Marketplace/Apps/catalog.ts b/src/features/Marketplace/Apps/catalog.tsnew file mode 100644index 00000000000..d90042a675c--- /dev/null+++ b/src/features/Marketplace/Apps/catalog.ts@@ -0,0 +1,106 @@+import type { ConnectorCatalogItem } from '@lobechat/const';++import type { MessengerPlatformItem } from '@/store/messenger/projection';++import { marketplaceAppPath } from '../paths';++export const appCategories = [+ 'chat',+ 'documents',+ 'projects',+ 'developer',+ 'productivity',+] as const;+type AppCategory = (typeof appCategories)[number];++export interface MarketplaceApp {+ category: AppCategory;+ channel?: MessengerPlatformItem;+ channelLinked: boolean;+ channelPending: boolean;+ id: string;+ integrationConnected: boolean;+ name: string;+ tool?: ConnectorCatalogItem;+ toolConnected: boolean;+}++const categoryByTool: Record<string, AppCategory> = {+ 'airtable': 'documents',+ 'clickup': 'projects',+ 'confluence': 'documents',+ 'dropbox': 'documents',+ 'figma': 'projects',+ 'github': 'developer',+ 'google-docs': 'documents',+ 'google-drive': 'documents',+ 'google-sheets': 'documents',+ 'jira': 'projects',+ 'linear': 'projects',+ 'notion': 'documents',+ 'onedrive': 'documents',+ 'posthog': 'developer',+ 'slack': 'chat',+ 'supabase': 'developer',+ 'vercel': 'developer',+ 'whatsapp': 'chat',+};++export const hasAppConnection = (app: MarketplaceApp) =>+ app.channelLinked || app.toolConnected || app.integrationConnected;++export const getAppHome = (app: MarketplaceApp) => {+ const path = marketplaceAppPath(app.id);+ return app.channel && app.toolConnected && !app.channelLinked ? `${path}?capability=tools` : path;+};++export const buildMarketplaceApps = ({+ channels,+ isToolConnected,+ integrationConnected,+ installedChannels,+ linkedChannels,+ tools,+}: {+ channels: readonly MessengerPlatformItem[];+ isToolConnected: (tool: ConnectorCatalogItem) => boolean;+ integrationConnected: (id: string) => boolean;+ installedChannels: ReadonlySet<string>;+ linkedChannels: ReadonlySet<string>;+ tools: readonly ConnectorCatalogItem[];+}): MarketplaceApp[] => {+ const apps = new Map<string, MarketplaceApp>();+ for (const tool of tools) {+ const id = tool.type === 'lobehub' ? tool.provider.id : tool.serverType.identifier;+ const name = tool.type === 'lobehub' ? tool.provider.label : tool.serverType.label;+ apps.set(id, {+ category: categoryByTool[id] ?? 'productivity',+ channelLinked: false,+ channelPending: false,+ id,+ name,+ integrationConnected: integrationConnected(id),+ tool,+ toolConnected: isToolConnected(tool),+ });+ }++ for (const channel of channels) {+ const app = apps.get(channel.id);+ const linked = linkedChannels.has(channel.id);+ const installed = installedChannels.has(channel.id);+ apps.set(channel.id, {+ ...app,+ category: 'chat',+ channel,+ channelLinked: linked && (channel.id !== 'wechat' || installed),+ channelPending: installed && !linked,+ id: channel.id,+ name: channel.name,+ integrationConnected: false,+ toolConnected: app?.toolConnected ?? false,+ });+ }++ return [...apps.values()];+};diff --git a/src/features/Marketplace/Apps/useMarketplaceApps.ts b/src/features/Marketplace/Apps/useMarketplaceApps.tsnew file mode 100644index 00000000000..df6a3b49640--- /dev/null+++ b/src/features/Marketplace/Apps/useMarketplaceApps.ts@@ -0,0 +1,88 @@+import isEqual from 'fast-deep-equal';++import { CONNECTOR_PAGE_IDS } from '@/features/Integrations/connectorPage';+import { useLinearConnections } from '@/features/Integrations/useLinearIntegration';+import { buildIntegrationItems } from '@/features/Settings/skill/features/connectorSections';+import { integrationActions, integrationSelectors, useIntegrationStore } from '@/store/integration';+import { messengerActions, messengerSelectors, useMessengerStore } from '@/store/messenger';+import { serverConfigSelectors, useServerConfigStore } from '@/store/serverConfig';+import { useToolStore } from '@/store/tool';+import { composioStoreSelectors, lobehubSkillStoreSelectors } from '@/store/tool/selectors';+import { ComposioServerStatus } from '@/store/tool/slices/composioStore';+import { LobehubSkillStatus } from '@/store/tool/slices/lobehubSkillStore/types';++import { buildMarketplaceApps } from './catalog';++export const useMarketplaceApps = () => {+ const configReady = useServerConfigStore((s) => s.serverConfigInit);+ const messenger = useServerConfigStore(serverConfigSelectors.enableBusinessFeatures);+ const lobehub = useServerConfigStore(serverConfigSelectors.enableLobehubSkill);+ const composio = useServerConfigStore(serverConfigSelectors.enableComposio);+ const channelsSync = messengerActions.useFetchPlatforms({ enabled: messenger });+ const linksSync = messengerActions.useFetchLinks({ enabled: messenger });+ const installsSync = messengerActions.useFetchInstallations({ enabled: messenger });+ const githubSync = integrationActions.useFetchGithubInstallations(configReady);+ const linear = useLinearConnections();+ const channels = useMessengerStore(messengerSelectors.platforms);+ const links = useMessengerStore(messengerSelectors.links);+ const installations = useMessengerStore(messengerSelectors.installations);+ const github = useIntegrationStore(integrationSelectors.scmInstallations);+ const platformsSettled = useMessengerStore(messengerSelectors.isPlatformsSettled);++ const useComposio = useToolStore((s) => s.useFetchUserComposioConnections);+ const useLobehub = useToolStore((s) => s.useFetchLobehubSkillConnections);+ const composioSync = useComposio(composio);+ const lobehubSync = useLobehub(lobehub);+ const composioServers = useToolStore(composioStoreSelectors.getServers, isEqual);+ const lobehubServers = useToolStore(lobehubSkillStoreSelectors.getServers, isEqual);+ const activeComposioIds = new Set(+ composioServers+ .filter((s) => s.status === ComposioServerStatus.ACTIVE)+ .map((s) => s.identifier),+ );+ const activeLobehubIds = new Set(+ lobehubServers+ .filter((s) => s.status === LobehubSkillStatus.CONNECTED)+ .map((s) => s.identifier),+ );+ const tools = buildIntegrationItems({+ pageOnlyProviderIds: CONNECTOR_PAGE_IDS,+ connectorAvailability: { composio, lobehub },+ isComposioActive: (id) => activeComposioIds.has(id),+ isLobehubConnected: (id) => activeLobehubIds.has(id),+ });+ const apps = buildMarketplaceApps({+ channels: messenger ? (channels ?? []) : [],+ isToolConnected: (tool) =>+ tool.type === 'lobehub'+ ? activeLobehubIds.has(tool.provider.id)+ : activeComposioIds.has(tool.serverType.identifier),+ integrationConnected: (id) =>+ (id === 'github' && Boolean(github?.length)) ||+ (id === 'linear' && Boolean(linear.data?.length)),+ installedChannels: new Set(installations?.map((s) => s.platform)),+ linkedChannels: new Set(links?.map((s) => s.platform)),+ tools,+ });+ const syncs = [+ ...(messenger ? [channelsSync, linksSync, installsSync] : []),+ githubSync,+ ...(lobehub ? [lobehubSync] : []),+ ...(composio ? [composioSync] : []),+ ];+ const error = syncs.find((s) => s.error)?.error ?? linear.error;+ const retry = () => {+ void linear.mutate();+ for (const sync of syncs) void sync.revalidate();+ };+ return {+ apps,+ composioServers,+ error,+ lobehubServers,+ retry,+ loading: !configReady || (messenger && !platformsSettled && !channelsSync.error),+ refreshing: linear.isValidating || syncs.some((s) => s.isValidating),+ toolSync: { composio: composioSync, lobehub: lobehubSync },+ };+};diff --git a/src/features/Marketplace/Catalog/DiscoverCatalogHeader.tsx b/src/features/Marketplace/Catalog/DiscoverCatalogHeader.tsxindex a421122da11..6742810192f 100644--- a/src/features/Marketplace/Catalog/DiscoverCatalogHeader.tsx+++ b/src/features/Marketplace/Catalog/DiscoverCatalogHeader.tsx@@ -47,6 +47,7 @@ const styles = stylex.create({const ConnectorAddAction = () => {const { t } = useTranslation('setting');+ const { t: td } = useTranslation('discover');const [open, setOpen] = useState(false);const { canManage, isPending } = useConnectorManageable();@@ -61,7 +62,7 @@ const ConnectorAddAction = () => {type={'primary'}onClick={() => setOpen(true)}>- {t('connectorMarket.add.custom')}+ {td('apps.addMcp')}</Button></Tooltip>{open && <CustomConnectorModal open onClose={() => setOpen(false)} />}@@ -82,7 +83,7 @@ const SkillImportAction = () => {interface DiscoverCatalogHeaderProps {group?: { backTo: string; title: string };- kind: CatalogKind | 'agent';+ kind: Exclude<CatalogKind, 'connector'> | 'agent' | 'app';sortControl?: ReactNode;titleExtra?: ReactNode;}@@ -114,7 +115,8 @@ const DiscoverCatalogHeader = ({value: draft.value.trim() === query ? draft.value : query,});}- const isConnector = kind === 'connector';+ const isMcp = kind === 'mcp';+ const isApp = kind === 'app';const isAgent = kind === 'agent';const search = (keyword: string) => {@@ -127,15 +129,25 @@ const DiscoverCatalogHeader = ({const title = isAgent? t('tab.assistant')- : ts(isConnector ? 'skillView.connectors' : 'skillView.skills');+ : isApp+ ? t('tab.apps')+ : isMcp+ ? t('tab.mcp')+ : ts('skillView.skills');const description = isAgent? t('catalog.agentDescription')- : ts(isConnector ? 'skillView.connectorsDesc' : 'skillView.skillsDesc');+ : isApp+ ? t('apps.description')+ : isMcp+ ? t('apps.mcpDescription')+ : ts('skillView.skillsDesc');const searchLabel = group? t('catalog.searchIn', { name: group.title }): isAgent? t('catalog.searchAgents')- : ts(isConnector ? 'connectorMarket.search.placeholder' : 'skillView.search.placeholder');+ : isApp || isMcp+ ? t('catalog.searchIn', { name: title })+ : ts('skillView.search.placeholder');return (<header {...stylex.props(styles.header, isMobileSurface() && styles.headerMobile)}>@@ -176,9 +188,9 @@ const DiscoverCatalogHeader = ({search(value);}}/>- {group || isAgent ? (+ {group || isAgent || isApp ? (sortControl- ) : isConnector ? (+ ) : isMcp ? (<ConnectorAddAction />) : (<SkillImportAction />diff --git a/src/features/Marketplace/Catalog/ConnectorCatalog.tsx b/src/features/Marketplace/Catalog/McpCatalog.tsxsimilarity index 65%rename from src/features/Marketplace/Catalog/ConnectorCatalog.tsxrename to src/features/Marketplace/Catalog/McpCatalog.tsxindex aaa8ead7ca4..0c39f89c486 100644--- a/src/features/Marketplace/Catalog/ConnectorCatalog.tsx+++ b/src/features/Marketplace/Catalog/McpCatalog.tsx@@ -1,19 +1,18 @@'use client';-import { Avatar, Icon, Segmented } from '@lobehub/ui';+import { Avatar, Icon } from '@lobehub/ui';import { McpIcon } from '@lobehub/ui/icons';import * as stylex from '@stylexjs/stylex';-import { ShieldCheck } from 'lucide-react';-import { memo } from 'react';+import isEqual from 'fast-deep-equal';+import { memo, type ReactNode } from 'react';import { useTranslation } from 'react-i18next';-import { useSearchParams } from 'react-router';import urlJoin from 'url-join';import AsyncBoundary from '@/components/AsyncBoundary';import { CatalogRowsSkeleton } from '@/components/Skeleton/MarketplaceCatalog';+import { matchesConnectorKeyword } from '@/features/Settings/skill/features/connectorSections';import { RowAddAction, RowMoreMenu } from '@/features/Settings/skill/features/RowActions';import SkillListRow from '@/features/Settings/skill/features/SkillListRow';-import { useFetchInstalledPlugins } from '@/hooks/useFetchInstalledPlugins';import { useCategory as useMcpCategory } from '@/hooks/useMCPCategory';import { usePermission } from '@/hooks/usePermission';import { useQuery } from '@/hooks/useQuery';@@ -28,11 +27,11 @@ import { connectorSelectors } from '@/store/tool/slices/connector';import { type DiscoverMcpItem, McpCategory, type McpQueryParams, McpSorts } from '@/types/discover';import CatalogViewTabs from '../CatalogViewTabs';-import { buildInstalledDetailPath } from '../InstalledNav';-import { MARKETPLACE_CONNECTOR_PATH, MARKETPLACE_MCP_PATH } from '../paths';+import { buildInstalledDetailPath, MARKETPLACE_MCP_PATH } from '../paths';import CatalogListView from './CatalogListView';import CatalogSection, { useSeenOnce } from './CatalogSection';import DiscoverCatalogHeader from './DiscoverCatalogHeader';+import { getInstalledMcpItems } from './installedMcps';import { openMcpConnectModal } from './McpConnectModal';import {buildCatalogListUrl,@@ -43,7 +42,6 @@ import {} from './sections';import { catalogStyles } from './styles';import { useCatalogDetailNavigate } from './useCatalogDetailNavigate';-import { useCatalogIntegrations } from './useCatalogIntegrations';const McpCatalogRow = memo<{ item: DiscoverMcpItem }>(({ item }) => {const { description, icon, identifier, name } = item;@@ -70,7 +68,7 @@ const McpCatalogRow = memo<{ item: DiscoverMcpItem }>(({ item }) => {if (legacy) {navigate(buildInstalledDetailPath(- 'connector',+ 'mcp',identifier,legacy.type === 'customPlugin' ? 'mcp-connector' : 'plugin',),@@ -83,7 +81,7 @@ const McpCatalogRow = memo<{ item: DiscoverMcpItem }>(({ item }) => {const connector = installs.find((item) => item.visibility !== 'private') ?? installs[0];if (connector) {navigate(- buildInstalledDetailPath('connector', identifier, 'mcp-connector', connector.visibility),+ buildInstalledDetailPath('mcp', identifier, 'mcp-connector', connector.visibility),);return;}@@ -147,7 +145,7 @@ const McpCatalogGroup = ({ category, count, eager, label, q }: McpGroup) => {label={label}loading={!data}sectionRef={sectionRef}- to={buildCatalogListUrl(MARKETPLACE_CONNECTOR_PATH, { category, q, source: 'public' })}+ to={buildCatalogListUrl(MARKETPLACE_MCP_PATH, { category, q })}onRetry={() => void mutate()}>{data?.items.slice(0, CATALOG_SECTION_SIZE).map((item) => (@@ -159,7 +157,13 @@ const McpCatalogGroup = ({ category, count, eager, label, q }: McpGroup) => {const MCP_PSEUDO_CATEGORIES = [McpCategory.All, McpCategory.Discover];-const McpCatalogGroups = ({ q }: { q?: string }) => {+const McpCatalogGroups = ({+ installedSection,+ q,+}: {+ installedSection?: ReactNode;+ q?: string;+}) => {const categories = useMcpCategory();const useMcpCategories = useDiscoverStore((s) => s.useMcpCategories);const { error, isLoading, mutate, queryKey } = useMcpCategories({ q });@@ -168,6 +172,7 @@ const McpCatalogGroups = ({ q }: { q?: string }) => {return (<div {...stylex.props(catalogStyles.sections)}>+ {installedSection}<AsyncBoundarydata={counts.length > 0 ? counts : undefined}error={error}@@ -176,7 +181,7 @@ const McpCatalogGroups = ({ q }: { q?: string }) => {onRetry={() => void mutate()}>{groups.length === 0 ? (- <McpCatalogList query={{ q }} />+ <McpCatalogList query={{ q }} showEmpty={!installedSection} />) : (groups.map(({ count, key, label }, index) => (<McpCatalogGroup@@ -196,8 +201,10 @@ const McpCatalogGroups = ({ q }: { q?: string }) => {const McpCatalogList = ({query: { category, connectionType, order, page, q, sort },+ showEmpty = true,}: {query: McpQueryParams;+ showEmpty?: boolean;}) => {const useMcpList = useDiscoverStore((s) => s.useFetchMcpList);const { error, isLoading, mutate, queryKey } = useMcpList({@@ -214,7 +221,7 @@ const McpCatalogList = ({return (<CatalogListView- empty={<McpEmpty search={Boolean(q)} />}+ empty={showEmpty && <McpEmpty search={Boolean(q)} />}error={error}hasData={!!data}isEmpty={items.length === 0}@@ -225,7 +232,7 @@ const McpCatalogList = ({<PaginationcurrentPage={data.currentPage}pageSize={data.pageSize}- path={MARKETPLACE_CONNECTOR_PATH}+ path={MARKETPLACE_MCP_PATH}total={data.totalCount}/>)@@ -239,100 +246,102 @@ const McpCatalogList = ({);};-const VerifiedConnectorList = ({ q }: { q?: string }) => {+const McpCatalog = () => {const { t } = useTranslation('discover');+ const { group, ...query } = useQuery() as McpQueryParams & { group?: string };+ const installedGroup = group === 'installed';+ const openDetail = useCatalogDetailNavigate();const { t: ts } = useTranslation('setting');- const rows = useCatalogIntegrations(q);- const [useFetchConnectors, initialized] = useToolStore((s) => [- s.useFetchConnectors,- s.isConnectorsInit,- ]);- const connections = useFetchConnectors(true);-- return (- <CatalogListView- error={connections.error}- hasData={initialized || rows.length > 0}- isEmpty={rows.length === 0}- loading={connections.isLoading}- empty={- <McpEmpty- description={q ? ts('connectorMarket.empty.search', { keyword: q }) : undefined}- search={Boolean(q)}- title={q ? undefined : t('catalog.noVerifiedConnectors')}- />- }- onRetry={() => void connections.mutate()}- >- {rows}- </CatalogListView>- );-};--const PublicConnectorList = ({ group, query }: { group: boolean; query: McpQueryParams }) => {- useFetchInstalledPlugins();- return group ? <McpCatalogList query={query} /> : <McpCatalogGroups q={query.q} />;-};--const ConnectorCatalog = () => {- const { t } = useTranslation('discover');- const { group, source, ...query } = useQuery() as McpQueryParams & {- group?: string;- source?: string;- };- const [, setParams] = useSearchParams();+ const connectors = useToolStore((s) => s.useFetchConnectors)(true);+ const plugins = useToolStore((s) => s.useFetchInstalledPlugins)(true);+ const initialized = useToolStore((s) => s.isConnectorsInit && s.isInstalledPluginsInit);+ const installed = useToolStore(getInstalledMcpItems, isEqual);const { category, q, sort } = query;const categories = useMcpCategory();- // Existing category, sort and pagination links predate the source filter.- const isMarketGroup =- group !== 'integrations' && (isCatalogListView(query) || Boolean(query.connectionType));- const isPublic = isMarketGroup || source === 'public';- const title =- categories.find((item) => item.key === category)?.label ??- (sort === McpSorts.CreatedAt ? t('catalog.new') : t('catalog.allConnectors'));+ const isMarketGroup = isCatalogListView(query) || Boolean(query.connectionType);+ const narrowed = installedGroup || isMarketGroup;+ const matches = installed.filter((item) =>+ matchesConnectorKeyword(q, [item.title, item.identifier, item.description]),+ );+ const label = t('catalog.yourMcpServers');+ const error = connectors.error ?? plugins.error;+ const loading = !initialized && (connectors.isLoading || plugins.isValidating);+ const retry = () => {+ void connectors.mutate();+ void plugins.revalidate();+ };+ const rows = (installedGroup ? matches : matches.slice(0, CATALOG_SECTION_SIZE)).map((item) => {+ const open = () => openDetail(item.path);+ return (+ <SkillListRow+ extra={<RowMoreMenu onOpenDetail={open} />}+ key={item.key}+ summary={item.private ? ts('skillView.connectorTabs.private') : item.description}+ title={item.title}+ icon={() =>+ item.avatar && item.avatar !== 'MCP_AVATAR' ? (+ <Avatar avatar={item.avatar} shape={'square'} size={24} />+ ) : (+ <Icon icon={McpIcon} size={20} />+ )+ }+ onClick={open}+ />+ );+ });+ const title = installedGroup+ ? label+ : (categories.find((item) => item.key === category)?.label ??+ (sort === McpSorts.CreatedAt ? t('catalog.new') : t('tab.mcp')));return (- <div {...stylex.props(catalogStyles.frame, isMarketGroup && catalogStyles.groupFrame)}>+ <div {...stylex.props(catalogStyles.frame, narrowed && catalogStyles.groupFrame)}><DiscoverCatalogHeader- kind={'connector'}+ kind={'mcp'}group={- isMarketGroup+ narrowed? {- backTo: buildCatalogListUrl(MARKETPLACE_CONNECTOR_PATH, { q, source: 'public' }),+ backTo: buildCatalogListUrl(MARKETPLACE_MCP_PATH, { q }),title,}: undefined}- titleExtra={- !isMarketGroup && (- <Segmented<'verified' | 'public'>- value={isPublic ? 'public' : 'verified'}- options={[- {- icon: <Icon icon={ShieldCheck} size={16} />,- label: t('catalog.verified'),- value: 'verified',- },- { label: t('catalog.public'), value: 'public' },- ]}- onChange={(next) => {- const params = new URLSearchParams();- if (q) params.set('q', q);- if (next === 'public') params.set('source', 'public');- setParams(params);- }}- />- )- }/>- <CatalogViewTabs active={'discover'} kind={'connector'} />- {isPublic ? (- <PublicConnectorList group={isMarketGroup} query={query} />+ <CatalogViewTabs active={'discover'} kind={'mcp'} />+ {installedGroup ? (+ <CatalogListView+ empty={<McpEmpty search={Boolean(q)} title={q ? undefined : t('apps.noInstalledMcp')} />}+ error={error}+ hasData={initialized || matches.length > 0}+ isEmpty={matches.length === 0}+ loading={loading}+ onRetry={retry}+ >+ {rows}+ </CatalogListView>+ ) : isMarketGroup ? (+ <McpCatalogList query={query} />) : (- <VerifiedConnectorList q={q} />+ <McpCatalogGroups+ q={q}+ installedSection={+ matches.length || (!initialized && error) ? (+ <CatalogSection+ count={matches.length}+ error={matches.length ? undefined : error}+ label={label}+ loading={false}+ to={buildCatalogListUrl(MARKETPLACE_MCP_PATH, { group: 'installed', q })}+ onRetry={retry}+ >+ {rows}+ </CatalogSection>+ ) : undefined+ }+ />)}</div>);};-export default ConnectorCatalog;+export default McpCatalog;diff --git a/src/features/Marketplace/Catalog/SkillCatalog.tsx b/src/features/Marketplace/Catalog/SkillCatalog.tsxindex 318119a8a98..d67ae486b42 100644--- a/src/features/Marketplace/Catalog/SkillCatalog.tsx+++ b/src/features/Marketplace/Catalog/SkillCatalog.tsx@@ -31,8 +31,7 @@ import {} from '@/types/discover';import CatalogViewTabs from '../CatalogViewTabs';-import { buildInstalledDetailPath } from '../InstalledNav';-import { MARKETPLACE_SKILL_PATH } from '../paths';+import { buildInstalledDetailPath, MARKETPLACE_SKILL_PATH } from '../paths';import CatalogListView from './CatalogListView';import CatalogSection, { useSeenOnce } from './CatalogSection';import DiscoverCatalogHeader from './DiscoverCatalogHeader';diff --git a/src/features/Marketplace/Catalog/installedMcps.test.ts b/src/features/Marketplace/Catalog/installedMcps.test.tsnew file mode 100644index 00000000000..cf143930037--- /dev/null+++ b/src/features/Marketplace/Catalog/installedMcps.test.ts@@ -0,0 +1,40 @@+import { describe, expect, it } from 'vitest';++import { initialState } from '@/store/tool/initialState';+import type { ConnectorWithTools } from '@/store/tool/slices/connector';++import { getInstalledMcpItems } from './installedMcps';++describe('getInstalledMcpItems', () => {+ it('opens the correct installation for a legacy shared server and a private server with the same identifier', () => {+ const shared: ConnectorWithTools = {+ credentials: null,+ id: 'shared',+ identifier: 'notes',+ isEnabled: true,+ mcpConnectionType: 'stdio',+ mcpServerUrl: null,+ metadata: { marketplaceInstalled: true },+ name: 'Notes',+ sourceType: 'marketplace',+ status: 'connected',+ tools: [],+ visibility: 'public',+ };+ const installed = getInstalledMcpItems({+ ...initialState,+ connectors: [+ shared,+ { ...shared, id: 'private', visibility: 'private' },+ { ...shared, id: 'pending', identifier: 'pending', metadata: {} },+ { ...shared, id: 'custom', identifier: 'calendar', sourceType: 'custom' },+ ],+ installedPlugins: [{ identifier: 'notes', type: 'plugin' }],+ });+ expect(installed.map((item) => item.path)).toEqual([+ '/marketplace/mcp/installed?open=plugin%3Anotes',+ '/marketplace/mcp/installed?open=mcp-connector%3Acalendar',+ '/marketplace/mcp/installed?open=mcp-connector%3Anotes&visibility=private',+ ]);+ });+});diff --git a/src/features/Marketplace/Catalog/installedMcps.ts b/src/features/Marketplace/Catalog/installedMcps.tsnew file mode 100644index 00000000000..9e7e7cdd832--- /dev/null+++ b/src/features/Marketplace/Catalog/installedMcps.ts@@ -0,0 +1,42 @@+import type { ToolStoreState } from '@/store/tool/initialState';+import { pluginSelectors } from '@/store/tool/selectors';+import { connectorSelectors } from '@/store/tool/slices/connector';++import { buildInstalledDetailPath } from '../paths';++export const getInstalledMcpItems = (state: ToolStoreState) => {+ const legacy = pluginSelectors+ .installedPluginMetaList(state)+ .filter((plugin) => plugin.type === 'plugin' || plugin.type === 'customPlugin')+ .map((plugin) => ({+ avatar: plugin.avatar,+ description: plugin.description || plugin.author,+ identifier: plugin.identifier,+ key: `plugin:${plugin.identifier}`,+ path: buildInstalledDetailPath(+ 'mcp',+ plugin.identifier,+ plugin.type === 'customPlugin' ? 'mcp-connector' : 'plugin',+ ),+ private: false,+ title: plugin.title || plugin.identifier,+ }));+ const connectors = connectorSelectors.userMcpConnectors(state).map((connector) => ({+ avatar: typeof connector.metadata?.avatar === 'string' ? connector.metadata.avatar : undefined,+ description:+ typeof connector.metadata?.description === 'string'+ ? connector.metadata.description+ : undefined,+ identifier: connector.identifier,+ key: `connector:${connector.id}`,+ path: buildInstalledDetailPath(+ 'mcp',+ connector.identifier,+ 'mcp-connector',+ connector.visibility,+ ),+ private: connector.visibility === 'private',+ title: connector.name || connector.identifier,+ }));+ return [...legacy, ...connectors];+};diff --git a/src/features/Marketplace/Catalog/useCatalogIntegrations.tsx b/src/features/Marketplace/Catalog/useCatalogIntegrations.tsxdeleted file mode 100644index 76d1e4454cb..00000000000--- a/src/features/Marketplace/Catalog/useCatalogIntegrations.tsx+++ /dev/null@@ -1,88 +0,0 @@-'use client';--import isEqual from 'fast-deep-equal';-import { useTranslation } from 'react-i18next';--import { useActiveWorkspaceId } from '@/business/client/hooks/useActiveWorkspaceId';-import { CONNECTOR_PAGE_IDS, hasConnectorPage } from '@/features/Integrations/connectorPage';-import ComposioSkillItem from '@/features/Settings/skill/features/ComposioSkillItem';-import {- buildIntegrationItems,- matchesIntegrationKeyword,-} from '@/features/Settings/skill/features/connectorSections';-import LobehubSkillItem from '@/features/Settings/skill/features/LobehubSkillItem';-import { serverConfigSelectors, useServerConfigStore } from '@/store/serverConfig';-import { useToolStore } from '@/store/tool';-import { composioStoreSelectors, lobehubSkillStoreSelectors } from '@/store/tool/selectors';-import { ComposioServerStatus } from '@/store/tool/slices/composioStore';-import { connectorSelectors, isIntegrationInConnectorTab } from '@/store/tool/slices/connector';-import { LobehubSkillStatus } from '@/store/tool/slices/lobehubSkillStore/types';--import { buildInstalledDetailPath, getInstalledVisibility } from '../InstalledNav';-import { useCatalogDetailNavigate } from './useCatalogDetailNavigate';--export const useCatalogIntegrations = (keyword?: string) => {- const { t } = useTranslation('setting');- const navigate = useCatalogDetailNavigate();- const visibility = getInstalledVisibility('connector', useActiveWorkspaceId(), null);- const composio = useServerConfigStore(serverConfigSelectors.enableComposio);- const lobehub = useServerConfigStore(serverConfigSelectors.enableLobehubSkill);-- const useLobehubConnections = useToolStore((s) => s.useFetchLobehubSkillConnections);- const useComposioConnections = useToolStore((s) => s.useFetchUserComposioConnections);- useLobehubConnections(lobehub);- useComposioConnections(composio);-- const connectors = useToolStore(connectorSelectors.connectorList, isEqual);- const lobehubServers = useToolStore(lobehubSkillStoreSelectors.getServers, isEqual);- const composioServers = useToolStore(composioStoreSelectors.getServers, isEqual);- const lobehubById = new Map(lobehubServers.map((server) => [server.identifier, server]));- const composioById = new Map(composioServers.map((server) => [server.identifier, server]));-- const matches = buildIntegrationItems({- connectorAvailability: { composio, lobehub },- isComposioActive: (id) => composioById.get(id)?.status === ComposioServerStatus.ACTIVE,- isLobehubConnected: (id) => lobehubById.get(id)?.status === LobehubSkillStatus.CONNECTED,- pageOnlyProviderIds: CONNECTOR_PAGE_IDS,- }).filter((item) => {- if (!matchesIntegrationKeyword(item, keyword, t)) return false;- if (item.type === 'lobehub')- return isIntegrationInConnectorTab(item.provider.id, connectors, visibility);-- const id = item.serverType.identifier;- return isIntegrationInConnectorTab(- id,- connectors,- visibility,- composioById.get(id)?.connectedAccountId,- );- });-- return matches.map((item) => {- if (item.type === 'lobehub') {- const id = item.provider.id;- return (- <LobehubSkillItem- connectable={lobehub}- key={id}- openWhenDisconnected={hasConnectorPage(id)}- provider={item.provider}- server={lobehubById.get(id)}- onSelect={() =>- navigate(buildInstalledDetailPath('connector', id, 'lobehub-connector', visibility))- }- />- );- }-- const id = item.serverType.identifier;- return (- <ComposioSkillItem- key={id}- server={composioById.get(id)}- serverType={item.serverType}- onSelect={() => navigate(buildInstalledDetailPath('connector', id, 'plugin', visibility))}- />- );- });-};diff --git a/src/features/Marketplace/CatalogViewTabs.tsx b/src/features/Marketplace/CatalogViewTabs.tsxindex 85daecf6873..9767c9249f1 100644--- a/src/features/Marketplace/CatalogViewTabs.tsx+++ b/src/features/Marketplace/CatalogViewTabs.tsx@@ -10,19 +10,22 @@ import { featureFlagsSelectors, useServerConfigStore } from '@/store/serverConfiimport { isMobileSurface } from '@/utils/mobileSurface';import {- MARKETPLACE_CONNECTOR_PATH,+ MARKETPLACE_APPS_PATH,MARKETPLACE_INSTALLED_CONNECTORS_PATH,+ MARKETPLACE_INSTALLED_MCP_PATH,MARKETPLACE_INSTALLED_SKILLS_PATH,+ MARKETPLACE_MCP_PATH,MARKETPLACE_SKILL_PATH,} from './paths';import { pillTabClassNames } from './pillTabs';export type CatalogView = 'discover' | 'installed';-export type CatalogKind = 'connector' | 'skill';+export type CatalogKind = 'connector' | 'mcp' | 'skill';export const CATALOG_VIEW_PATHS: Record<CatalogKind, Record<CatalogView, string>> = {+ mcp: { discover: MARKETPLACE_MCP_PATH, installed: MARKETPLACE_INSTALLED_MCP_PATH },connector: {- discover: MARKETPLACE_CONNECTOR_PATH,+ discover: MARKETPLACE_APPS_PATH,installed: MARKETPLACE_INSTALLED_CONNECTORS_PATH,},skill: {@@ -45,16 +48,7 @@ interface CatalogViewTabsProps {kind: CatalogKind;}-/**- * Switches a Marketplace entry between its public catalog (Discover) and its- * management page (Installed): Skills (`/marketplace/skill[/installed]`) and- * Connectors, which merges the MCP catalog with the connector manager- * (`/marketplace/connector[/installed]`).- * With the market disabled only the installed view exists, so no tabs render.- * Desktop has no tabs either: the sidebar lists the installed items under the- * Skills / Connectors entries (Codex Customize), so only mobile, which has no- * sidebar, switches views here.- */+/** The mobile catalog switcher. Desktop collections have dedicated sidebar links. */const CatalogViewTabs = memo<CatalogViewTabsProps>(({ active, inset, kind }) => {const { t } = useTranslation('discover');const navigate = useWorkspaceAwareNavigate();diff --git a/src/features/Marketplace/InstalledMcp.tsx b/src/features/Marketplace/InstalledMcp.tsxnew file mode 100644index 00000000000..318c2a2de54--- /dev/null+++ b/src/features/Marketplace/InstalledMcp.tsx@@ -0,0 +1,12 @@+import { ToolSettings } from '@/features/Settings/skill';++import CatalogViewTabs from './CatalogViewTabs';++export default function InstalledMcp() {+ return (+ <ToolSettings+ headerExtra={<CatalogViewTabs inset active={'installed'} kind={'mcp'} />}+ viewMode={'mcp'}+ />+ );+}diff --git a/src/features/Marketplace/InstalledNav.test.ts b/src/features/Marketplace/InstalledNav.test.tsindex f72248d858d..2739a14bcef 100644--- a/src/features/Marketplace/InstalledNav.test.ts+++ b/src/features/Marketplace/InstalledNav.test.ts@@ -1,101 +1,49 @@-import { fireEvent, render } from '@testing-library/react';+import { render } from '@testing-library/react';import { createElement } from 'react';-import { createMemoryRouter, MemoryRouter, RouterProvider } from 'react-router';+import { MemoryRouter } from 'react-router';import { describe, expect, it, vi } from 'vitest';-const { installedList, activeLocation } = vi.hoisted(() => ({- activeLocation: { pathname: '/acme/marketplace/connector/installed', search: '' },- installedList: vi.fn(() => null),-}));-vi.mock('@/features/Settings/skill/features/SkillList', () => ({ default: installedList }));-vi.mock('@/hooks/useActiveLocation', () => ({ useActiveLocation: () => activeLocation }));-vi.mock('@/business/client/hooks/useActiveWorkspaceId', () => ({- useActiveWorkspaceId: () => 'ws_1',-}));+import InstalledNav from './InstalledNav';+import { buildInstalledDetailPath } from './paths';+vi.mock('./Apps/ConnectedAppNav', () => ({ default: () => null }));+vi.mock('@/hooks/useActiveLocation', () => ({+ useActiveLocation: () => ({ pathname: '/acme/marketplace/mcp', search: '' }),+}));vi.mock('@/business/client/hooks/useActiveWorkspaceSlug', () => ({useActiveWorkspaceSlug: () => 'acme',}));-const {- default: InstalledNav,- buildInstalledDetailPath,- getInstalledVisibility,-} = await import('./InstalledNav');-describe('buildInstalledDetailPath', () => {it('opens one installed item on its installed page', () => {expect(buildInstalledDetailPath('skill', 'skill_123', 'agent-skill')).toBe('/marketplace/skill/installed?open=agent-skill%3Askill_123',);- expect(buildInstalledDetailPath('connector', 'acme:ci', 'mcp-connector')).toBe(- '/marketplace/connector/installed?open=mcp-connector%3Aacme%3Aci',+ expect(buildInstalledDetailPath('mcp', 'acme:ci', 'mcp-connector')).toBe(+ '/marketplace/mcp/installed?open=mcp-connector%3Aacme%3Aci',);});});-describe('getInstalledVisibility', () => {- it('has no tab outside a workspace or for skills', () => {- expect(getInstalledVisibility('connector', null, 'private')).toBeUndefined();- expect(getInstalledVisibility('skill', 'ws_1', 'private')).toBeUndefined();- });-- it('lists the tab the installed page is on, the shared pool by default', () => {- expect(getInstalledVisibility('connector', 'ws_1', null)).toBe('public');- expect(getInstalledVisibility('connector', 'ws_1', 'private')).toBe('private');- });-});-describe('buildInstalledDetailPath in a workspace', () => {// A private and a shared connector may share an identifier; without the tab// the installed page resolves the shared row.it('opens a private connector on the Private tab', () => {- expect(buildInstalledDetailPath('connector', 'acme', 'mcp-connector', 'private')).toBe(- '/marketplace/connector/installed?open=mcp-connector%3Aacme&visibility=private',+ expect(buildInstalledDetailPath('mcp', 'acme', 'mcp-connector', 'private')).toBe(+ '/marketplace/mcp/installed?open=mcp-connector%3Aacme&visibility=private',);});it('opens a shared connector on the default (shared) tab', () => {- expect(buildInstalledDetailPath('connector', 'acme', 'mcp-connector', 'public')).toBe(- '/marketplace/connector/installed?open=mcp-connector%3Aacme',- );- });-});--describe('installed connector sidebar selection', () => {- it('highlights the connector from the active desktop tab even when the shell router is on another URL', () => {- activeLocation.search = '?open=mcp-connector%3Aacme%3Aci&visibility=private';- render(createElement(MemoryRouter, { initialEntries: ['/'] }, createElement(InstalledNav)));- expect(installedList).toHaveBeenCalledWith(- expect.objectContaining({ selectedIdentifier: 'acme:ci', visibility: 'private' }),- undefined,+ expect(buildInstalledDetailPath('mcp', 'acme', 'mcp-connector', 'public')).toBe(+ '/marketplace/mcp/installed?open=mcp-connector%3Aacme',);});});-describe('installed connector collection link', () => {- it.each([- ['/acme/marketplace/connector', '', ''],- [- '/acme/marketplace/connector/installed',- '?open=mcp-connector%3Aexample&visibility=private',- '?visibility=private',- ],- ])(- 'opens the collection from %s%s even without visible rows',- (pathname, search, expectedSearch) => {- Object.assign(activeLocation, { pathname, search });- const router = createMemoryRouter([{ path: '*', element: createElement(InstalledNav) }], {- initialEntries: [pathname + search],- });- const view = render(createElement(RouterProvider, { router }));- const link = view.getByRole('link', { name: /installed/i });- const expectedPath = '/acme/marketplace/connector/installed';- expect(link.getAttribute('href')).toBe(expectedPath + expectedSearch);- fireEvent.click(link);- expect(router.state.location.pathname + router.state.location.search).toBe(- expectedPath + expectedSearch,- );- },- );+it('keeps the connected apps collection in the sidebar and the installed MCP collection in its catalog', () => {+ const view = render(createElement(MemoryRouter, null, createElement(InstalledNav)));+ expect(view.getAllByRole('link').map((link) => link.getAttribute('href'))).toEqual([+ '/acme/marketplace/app?view=connected',+ ]);});diff --git a/src/features/Marketplace/InstalledNav.tsx b/src/features/Marketplace/InstalledNav.tsxindex 0dbcdbcfea4..96a2f280729 100644--- a/src/features/Marketplace/InstalledNav.tsx+++ b/src/features/Marketplace/InstalledNav.tsx@@ -1,31 +1,17 @@'use client';-import type { ConnectorVisibility } from '@lobechat/types';import { Flexbox } from '@lobehub/ui';import { cssVar } from '@lobehub/ui/stylex/cssVar.stylex';import * as stylex from '@stylexjs/stylex';-import { memo, useCallback } from 'react';+import { memo } from 'react';import { useTranslation } from 'react-i18next';-import { useActiveWorkspaceId } from '@/business/client/hooks/useActiveWorkspaceId';import SectionTitle, { useSectionTriggerStyle } from '@/features/NavPanel/components/SectionTitle';-import type { ToolDetailType } from '@/features/Settings/skill/features/SkillDetail';-import SkillList from '@/features/Settings/skill/features/SkillList';-import { SkillListVariantProvider } from '@/features/Settings/skill/features/SkillListRow';-import {- encodeMobileSelection,- MOBILE_SELECTION_PARAM,- parseMobileSelection,-} from '@/features/Settings/skill/mobileSelection';-import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import WorkspaceLink from '@/features/Workspace/WorkspaceLink';import { useActiveLocation } from '@/hooks/useActiveLocation';-import {- getMarketplaceSubPath,- MARKETPLACE_INSTALLED_CONNECTORS_PATH,- MARKETPLACE_INSTALLED_SKILLS_PATH,-} from './paths';+import ConnectedAppNav from './Apps/ConnectedAppNav';+import { getMarketplaceSubPath, MARKETPLACE_CONNECTED_APPS_PATH } from './paths';const styles = stylex.create({collectionLink: {@@ -39,99 +25,26 @@ const styles = stylex.create({},});-export type InstalledKind = 'connector' | 'skill';--const INSTALLED_PATHS: Record<InstalledKind, string> = {- connector: MARKETPLACE_INSTALLED_CONNECTORS_PATH,- skill: MARKETPLACE_INSTALLED_SKILLS_PATH,-};--/**- * The workspace connector tab the sidebar lists, mirroring the installed page- * (`ToolSettings`): the shared pool unless that page is on its Private tab.- * A private and a shared connector may share an identifier, so the list and- * the detail it opens must name the same tab. Outside a workspace (and for- * skills) there are no tabs.- */-export const getInstalledVisibility = (- kind: InstalledKind | undefined,- workspaceId: string | null | undefined,- visibilityParam: string | null,-): ConnectorVisibility | undefined => {- if (kind !== 'connector' || !workspaceId) return undefined;- return visibilityParam === 'private' ? 'private' : 'public';-};--/**- * The installed page that opens one item's detail (`?open=<type>:<identifier>`),- * on the tab the row was listed under so the detail resolves that row.- */-export const buildInstalledDetailPath = (- kind: InstalledKind,- identifier: string,- type: ToolDetailType,- visibility?: ConnectorVisibility,-): string => {- const params = new URLSearchParams({- [MOBILE_SELECTION_PARAM]: encodeMobileSelection({ identifier, type }),- });- if (visibility === 'private') params.set('visibility', visibility);- return `${INSTALLED_PATHS[kind]}?${params.toString()}`;-};--/**- * Installed connectors stay in the Marketplace sidebar when the main section changes.- */const InstalledNav = memo(() => {const { t } = useTranslation('discover');const { pathname, search } = useActiveLocation();const searchParams = new URLSearchParams(search);- const navigate = useWorkspaceAwareNavigate();const sectionTriggerStyle = useSectionTriggerStyle();const subPath = getMarketplaceSubPath(pathname);- const onInstalledPage = subPath === getMarketplaceSubPath(MARKETPLACE_INSTALLED_CONNECTORS_PATH);- const selectedIdentifier = onInstalledPage- ? parseMobileSelection(searchParams.get(MOBILE_SELECTION_PARAM))?.identifier- : undefined;- const workspaceId = useActiveWorkspaceId();- const visibility = getInstalledVisibility(- 'connector',- workspaceId,- onInstalledPage ? searchParams.get('visibility') : null,- );-- const handleSelect = useCallback(- (identifier: string, type: ToolDetailType) => {- navigate(buildInstalledDetailPath('connector', identifier, type, visibility));- },- [navigate, visibility],- );-return (<Flexbox gap={2} paddingBlock={8} paddingInline={4}><WorkspaceLink- aria-current={onInstalledPage && !selectedIdentifier ? 'page' : undefined}className={stylex.props(styles.collectionLink).className}style={sectionTriggerStyle}- title={t('catalog.manageInstalledConnectors')}- to={- visibility === 'private'- ? `${MARKETPLACE_INSTALLED_CONNECTORS_PATH}?visibility=private`- : MARKETPLACE_INSTALLED_CONNECTORS_PATH+ to={MARKETPLACE_CONNECTED_APPS_PATH}+ aria-current={+ subPath === 'app' && searchParams.get('view') === 'connected' ? 'page' : undefined}>- <SectionTitle>{t('catalog.installed')}</SectionTitle>+ <SectionTitle>{t('apps.connected')}</SectionTitle></WorkspaceLink>- <SkillListVariantProvider value={'nav'}>- <SkillList- installedOnly- selectedIdentifier={selectedIdentifier}- viewMode={'connector'}- visibility={visibility}- onSelect={handleSelect}- />- </SkillListVariantProvider>+ <ConnectedAppNav selected={subPath?.startsWith('app/') ? subPath.slice(4) : undefined} /></Flexbox>);});diff --git a/src/features/Marketplace/marketplaceCopy.test.ts b/src/features/Marketplace/marketplaceCopy.test.tsindex 230a022593b..679d7b12e1a 100644--- a/src/features/Marketplace/marketplaceCopy.test.ts+++ b/src/features/Marketplace/marketplaceCopy.test.ts@@ -73,8 +73,9 @@ describe('Marketplace page copy', () => {it('translates every Marketplace sidebar entry in zh-CN', () => {const zh = readNs('zh-CN', 'discover');- const navKeys = ['tab.assistant', 'tab.skill', 'tab.connector', 'tab.model', 'tab.provider'];+ const navKeys = ['tab.assistant', 'tab.skill', 'tab.apps', 'tab.model', 'tab.provider'];for (const key of navKeys) expect(zh[key], `zh-CN/discover:${key}`).toMatch(/\p{Script=Han}/u);+ expect(zh['tab.mcp']).toBe('MCP');expect(zh['tab.skill']).toBe(readNs('zh-CN', 'setting')['tab.skill']);});diff --git a/src/features/Marketplace/paths.ts b/src/features/Marketplace/paths.tsindex 8383943223a..91f6a070c49 100644--- a/src/features/Marketplace/paths.ts+++ b/src/features/Marketplace/paths.ts@@ -1,3 +1,11 @@+import type { ConnectorVisibility } from '@lobechat/types';++import type { ToolDetailType } from '@/features/Settings/skill/features/SkillDetail';+import {+ encodeMobileSelection,+ MOBILE_SELECTION_PARAM,+} from '@/features/Settings/skill/mobileSelection';+/*** Marketplace (formerly Community) URL layout.*@@ -14,26 +22,63 @@ export const MARKETPLACE_PATH = `/${MARKETPLACE_SEGMENT}`;export const MARKETPLACE_AGENT_PATH = `${MARKETPLACE_PATH}/agent`;+export const MARKETPLACE_APPS_PATH = `${MARKETPLACE_PATH}/app`;+export const MARKETPLACE_CONNECTED_APPS_PATH = `${MARKETPLACE_APPS_PATH}?view=connected`;+export const marketplaceAppPath = (id: string) =>+ `${MARKETPLACE_APPS_PATH}/${encodeURIComponent(id)}`;+/** Skills discovery (the public catalog). */export const MARKETPLACE_SKILL_PATH = `${MARKETPLACE_PATH}/skill`;/** Installed skills management — moved here from `/settings/skill`. */export const MARKETPLACE_INSTALLED_SKILLS_PATH = `${MARKETPLACE_SKILL_PATH}/installed`;-/**- * Connectors discovery: the public MCP catalog (formerly the separate- * `/marketplace/mcp` list, now merged into Connectors).- */+/** Legacy catalog links use their search parameters to select Apps or MCP. */export const MARKETPLACE_CONNECTOR_PATH = `${MARKETPLACE_PATH}/connector`;/** Installed connector management — moved here from `/settings/connector`. */export const MARKETPLACE_INSTALLED_CONNECTORS_PATH = `${MARKETPLACE_CONNECTOR_PATH}/installed`;-/** MCP server detail pages keep their own path under the merged Connectors entry. */+/** Public MCP catalog and server details. */export const MARKETPLACE_MCP_PATH = `${MARKETPLACE_PATH}/mcp`;+export const MARKETPLACE_INSTALLED_MCP_PATH = `${MARKETPLACE_MCP_PATH}/installed`;++type InstalledKind = 'connector' | 'mcp' | 'skill';++const INSTALLED_PATHS: Record<InstalledKind, string> = {+ connector: MARKETPLACE_INSTALLED_CONNECTORS_PATH,+ mcp: MARKETPLACE_INSTALLED_MCP_PATH,+ skill: MARKETPLACE_INSTALLED_SKILLS_PATH,+};++/**+ * The installed page that opens one item's detail (`?open=<type>:<identifier>`),+ * on the tab the row was listed under so the detail resolves that row.+ */+export const buildInstalledDetailPath = (+ kind: InstalledKind,+ identifier: string,+ type: ToolDetailType,+ visibility?: ConnectorVisibility,+): string => {+ const params = new URLSearchParams({+ [MOBILE_SELECTION_PARAM]: encodeMobileSelection({ identifier, type }),+ });+ if (visibility === 'private') params.set('visibility', visibility);+ return `${INSTALLED_PATHS[kind]}?${params.toString()}`;+};++export const getLegacyConnectorCatalogPath = (params: URLSearchParams) => {+ const publicCatalog =+ params.get('source') === 'public' ||+ (params.get('group') !== 'integrations' &&+ ['category', 'sort', 'page', 'connectionType'].some((key) => params.has(key)));+ return publicCatalog ? MARKETPLACE_MCP_PATH : MARKETPLACE_APPS_PATH;+};+export const getMarketplaceEntryPath = (showMarket: boolean | undefined): string =>- showMarket ? MARKETPLACE_CONNECTOR_PATH : MARKETPLACE_INSTALLED_CONNECTORS_PATH;+ showMarket ? MARKETPLACE_APPS_PATH : MARKETPLACE_INSTALLED_CONNECTORS_PATH;/** Remaining marketplace path after the (optionally workspace-prefixed) marketplace root. */export const getMarketplaceSubPath = (pathname: string): string | undefined => {@@ -51,7 +96,14 @@ export const getMarketplaceSubPath = (pathname: string): string | undefined => {// The catalog pages render their own search and actions in the content header.export const hasCatalogPageHeader = (pathname: string): boolean => {const section = getMarketplaceSubPath(pathname);- return section === 'agent' || section === 'skill' || section === 'connector';+ return (+ section === 'agent' ||+ section === 'skill' ||+ section === 'connector' ||+ section === 'mcp' ||+ section === 'app' ||+ section?.startsWith('app/') === true+ );};/**diff --git a/src/features/Messenger/InstallResult.tsx b/src/features/Messenger/InstallResult.tsxnew file mode 100644index 00000000000..a582508f0fe--- /dev/null+++ b/src/features/Messenger/InstallResult.tsx@@ -0,0 +1,75 @@+'use client';++import { Button, Flexbox, Text, toast } from '@lobehub/ui';+import { useCallback, useEffect, useRef } from 'react';+import { useTranslation } from 'react-i18next';+import { useLocation, useNavigate } from 'react-router';++import ImperativeModal from '@/components/ImperativeModal';++import { PlatformAvatar } from './constants';+import { getDiscordInstallErrorReason, getSlackInstallErrorReason } from './i18n';+import type { MessengerOAuthInstallPlatform } from './installHref';++export default function InstallResult({ platform }: { platform: MessengerOAuthInstallPlatform }) {+ const { t, ready } = useTranslation('messenger');+ const { pathname, search, hash, state, key } = useLocation();+ const navigate = useNavigate();+ const handled = useRef<string>(undefined);+ const params = new URLSearchParams(search);+ const installed = params.get('installed');+ const error = params.get('error');+ const blocked = !installed && error === 'already_installed';+ const name = params.get('workspace');+ const dismiss = useCallback(() => {+ const next = new URLSearchParams(search);+ for (const param of ['installed', 'error', 'workspace']) next.delete(param);+ navigate({ pathname, search: next.toString(), hash }, { replace: true, state });+ }, [hash, navigate, pathname, search, state]);++ useEffect(() => {+ if (!ready || blocked || handled.current === key || (!installed && !error)) return;+ handled.current = key;++ if (installed) {+ toast.success(t(`messenger.${platform}.installResult.success`));+ } else if (error) {+ const getReason =+ platform === 'slack' ? getSlackInstallErrorReason : getDiscordInstallErrorReason;+ toast.error(t(`messenger.${platform}.installResult.failed`, { reason: getReason(t, error) }));+ }++ dismiss();+ }, [ready, blocked, key, installed, error, platform, t, dismiss]);++ return (+ <ImperativeModal+ footer={null}+ open={blocked && ready}+ title={blocked ? t(`messenger.${platform}.installBlocked.title` as const) : undefined}+ width={480}+ onCancel={dismiss}+ >+ {blocked && (+ <Flexbox align="center" gap={20} style={{ paddingBlock: 16 }}>+ <PlatformAvatar platform={platform} size={56} />+ <Flexbox align="center" gap={8}>+ <Text strong style={{ fontSize: 16, textAlign: 'center' }}>+ {name+ ? t(`messenger.${platform}.installBlocked.withName` as const, {+ workspace: name,+ })+ : t(`messenger.${platform}.installBlocked.withoutName` as const)}+ </Text>+ <Text style={{ textAlign: 'center' }} type="secondary">+ {t(`messenger.${platform}.installBlocked.nextSteps` as const)}+ </Text>+ </Flexbox>+ <Button block size="large" type="primary" onClick={dismiss}>+ {t(`messenger.${platform}.installBlocked.dismiss` as const)}+ </Button>+ </Flexbox>+ )}+ </ImperativeModal>+ );+}diff --git a/src/features/Messenger/IntegrationDetail/Discord.tsx b/src/features/Messenger/IntegrationDetail/Discord.tsxindex 8699e3d4933..09a44306170 100644--- a/src/features/Messenger/IntegrationDetail/Discord.tsx+++ b/src/features/Messenger/IntegrationDetail/Discord.tsx@@ -26,7 +26,7 @@ interface DiscordDetailProps {appId?: string;botUsername?: string;name: string;- onBack: () => void;+ onBack?: () => void;}// Discord: a single global user link (Discord uses an env-side bot token, sodiff --git a/src/features/Messenger/IntegrationDetail/Linq.tsx b/src/features/Messenger/IntegrationDetail/Linq.tsxindex 14ebc657c4d..a5689b91b02 100644--- a/src/features/Messenger/IntegrationDetail/Linq.tsx+++ b/src/features/Messenger/IntegrationDetail/Linq.tsx@@ -274,7 +274,7 @@ export { LinqLinkSetup };interface LinqDetailProps {name: string;- onBack: () => void;+ onBack?: () => void;}const LinqDetail = memo<LinqDetailProps>(({ name, onBack }) => {diff --git a/src/features/Messenger/IntegrationDetail/Slack.tsx b/src/features/Messenger/IntegrationDetail/Slack.tsxindex 3862187c792..7f5540dd0c5 100644--- a/src/features/Messenger/IntegrationDetail/Slack.tsx+++ b/src/features/Messenger/IntegrationDetail/Slack.tsx@@ -25,7 +25,7 @@ interface SlackDetailProps {appId?: string;botUsername?: string;name: string;- onBack: () => void;+ onBack?: () => void;}const SlackDetail = memo<SlackDetailProps>(({ appId, botUsername, name, onBack }) => {diff --git a/src/features/Messenger/IntegrationDetail/Telegram.tsx b/src/features/Messenger/IntegrationDetail/Telegram.tsxindex b06b445aa8e..204d126872e 100644--- a/src/features/Messenger/IntegrationDetail/Telegram.tsx+++ b/src/features/Messenger/IntegrationDetail/Telegram.tsx@@ -23,7 +23,7 @@ interface TelegramDetailProps {appId?: string;botUsername?: string;name: string;- onBack: () => void;+ onBack?: () => void;}// Telegram is the only remaining global-token bot with no install audit list,diff --git a/src/features/Messenger/IntegrationDetail/Wechat.tsx b/src/features/Messenger/IntegrationDetail/Wechat.tsxindex 256fc259fbf..943a7043466 100644--- a/src/features/Messenger/IntegrationDetail/Wechat.tsx+++ b/src/features/Messenger/IntegrationDetail/Wechat.tsx@@ -243,7 +243,7 @@ interface WechatDetailProps {requiredPlan?: 'paid';};name: string;- onBack: () => void;+ onBack?: () => void;}const WechatDetail = memo<WechatDetailProps>(({ access, name, onBack }) => {diff --git a/src/features/Messenger/IntegrationDetail/index.tsx b/src/features/Messenger/IntegrationDetail/index.tsxindex 68f18ad5fb9..260d27c8f0f 100644--- a/src/features/Messenger/IntegrationDetail/index.tsx+++ b/src/features/Messenger/IntegrationDetail/index.tsx@@ -19,7 +19,7 @@ interface IntegrationDetailProps {botUsername?: string;/** Brand-name label (e.g. `"Slack"`) sourced from the registry. */name: string;- onBack: () => void;+ onBack?: () => void;platform: MessengerPlatform;}diff --git a/src/features/Messenger/IntegrationDetail/shared.tsx b/src/features/Messenger/IntegrationDetail/shared.tsxindex abac7362a73..d871ef4506b 100644--- a/src/features/Messenger/IntegrationDetail/shared.tsx+++ b/src/features/Messenger/IntegrationDetail/shared.tsx@@ -135,7 +135,7 @@ interface DetailLayoutProps {hasConnections: boolean;headerAction: ReactNode;name: string;- onBack: () => void;+ onBack?: () => void;platform: MessengerPlatform;sectionTitle?: ReactNode;}@@ -155,14 +155,16 @@ export const DetailLayout = memo<DetailLayoutProps>(return (<Flexbox gap={20}>- <Flexbox horizontal align="center" gap={8}>- <span className={styles.backButton} onClick={onBack}>- <Icon icon={ArrowLeftIcon} size="small" />- </span>- <Text strong style={{ fontSize: 20 }}>- {name}- </Text>- </Flexbox>+ {onBack && (+ <Flexbox horizontal align="center" gap={8}>+ <span className={styles.backButton} onClick={onBack}>+ <Icon icon={ArrowLeftIcon} size="small" />+ </span>+ <Text strong style={{ fontSize: 20 }}>+ {name}+ </Text>+ </Flexbox>+ )}<Block className={styles.card}><Flexbox horizontal align="center" gap={16}>diff --git a/src/features/Messenger/IntegrationList.tsx b/src/features/Messenger/IntegrationList.tsxdeleted file mode 100644index 58988ab4c9e..00000000000--- a/src/features/Messenger/IntegrationList.tsx+++ /dev/null@@ -1,80 +0,0 @@-'use client';--import { Block, createStaticStyles, Flexbox, Icon, Tag, Text } from '@lobehub/ui';-import { ChevronRightIcon } from 'lucide-react';-import { memo } from 'react';-import { useTranslation } from 'react-i18next';--import type { SerializedMessengerPlatformDefinition } from '@/server/services/messenger/platforms/types';-import { densityVars } from '@/styles/densityVars';--import { type MessengerPlatform, PlatformAvatar } from './constants';--const styles = createStaticStyles(({ css, cssVar }) => ({- // Match the agent channel list's card weight: an outlined Block on- // colorBgContainer with a soft secondary border (the Block variant supplies- // both), rounded a step larger so it reads as the same surface as 消息频道.- card: css`- cursor: pointer;- padding: ${densityVars.cardPadding};- border-radius: ${cssVar.borderRadiusLG};- transition: border-color 0.2s ease;-- &:hover {- border-color: ${cssVar.colorPrimaryBorderHover};- }- `,- grid: css`- display: grid;- grid-template-columns: repeat(2, 1fr);- gap: ${densityVars.contentGap};-- @media (width <= 720px) {- grid-template-columns: 1fr;- }- `,-}));--interface IntegrationListProps {- onSelect: (platform: MessengerPlatform) => void;- platforms: SerializedMessengerPlatformDefinition[];-}--const IntegrationList = memo<IntegrationListProps>(({ onSelect, platforms }) => {- const { t } = useTranslation('messenger');-- return (- <div className={styles.grid}>- {platforms.map((platform) => (- <Block- className={styles.card}- key={platform.id}- variant={'outlined'}- onClick={() => onSelect(platform.id)}- >- <Flexbox horizontal align="center" gap={16}>- <PlatformAvatar platform={platform.id} size={48} />- <Flexbox flex={1} gap={2}>- <Text strong style={{ fontSize: 15 }}>- {platform.name}- </Text>- <Text style={{ fontSize: 13 }} type="secondary">- {t(`messenger.list.${platform.id}.description` as any)}- </Text>- </Flexbox>- {platform.access?.requiredPlan === 'paid' && (- <Tag color="blue" size="small">- {t('messenger.paidBadge')}- </Tag>- )}- <Icon icon={ChevronRightIcon} />- </Flexbox>- </Block>- ))}- </div>- );-});--IntegrationList.displayName = 'MessengerIntegrationList';--export default IntegrationList;diff --git a/src/features/Messenger/PushResourceModal/useSendToMessengerMenuItem.tsx b/src/features/Messenger/PushResourceModal/useSendToMessengerMenuItem.tsxindex a53645951d1..03f5290503b 100644--- a/src/features/Messenger/PushResourceModal/useSendToMessengerMenuItem.tsx+++ b/src/features/Messenger/PushResourceModal/useSendToMessengerMenuItem.tsx@@ -5,6 +5,7 @@ import { cssVar, Flexbox, Icon } from '@lobehub/ui';import { SendIcon, Settings2Icon } from 'lucide-react';import { useTranslation } from 'react-i18next';+import { MARKETPLACE_APPS_PATH, marketplaceAppPath } from '@/features/Marketplace/paths';import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import { messengerActions, messengerSelectors, useMessengerStore } from '@/store/messenger';import { serverConfigSelectors, useServerConfigStore } from '@/store/serverConfig';@@ -30,7 +31,7 @@ interface UseSendToMessengerMenuItemParams {* "Send to Messenger" entry for the resource row menu: a hover submenu with* one entry per available platform. A linked platform opens the push modal* (one entry per platform × Slack workspace); an unlinked one deep-links to- * that platform's messenger settings page for setup.+ * that platform's Marketplace app for setup.** The messenger store dedupes the reads across every row that renders this* hook, so a long file list still issues a single request each, and a reload@@ -108,7 +109,7 @@ export const useSendToMessengerMenuItem = ({),onClick: ({ domEvent }) => {domEvent.stopPropagation();- navigate(`/settings/messenger/${platform}`);+ navigate(marketplaceAppPath(platform));},},];@@ -146,7 +147,7 @@ export const useSendToMessengerMenuItem = ({});// Deployment has no messenger platform configured at all: fall back to a- // single entry pointing at the messenger settings overview.+ // single entry pointing at Marketplace Apps.if (children.length === 0) {children = [{@@ -155,21 +156,21 @@ export const useSendToMessengerMenuItem = ({label: t('FileManager.actions.sendToMessengerSetup'),onClick: ({ domEvent }) => {domEvent.stopPropagation();- navigate('/settings/messenger');+ navigate(MARKETPLACE_APPS_PATH);},},];} else {- // Trailing shortcut to the messenger settings overview.+ // Trailing shortcut to Marketplace Apps.children.push({ type: 'divider' },{icon: <Icon icon={Settings2Icon} />,key: 'send-to-messenger-settings',- label: t('FileManager.actions.sendToMessengerSettings'),+ label: t('FileManager.actions.manageChatApps'),onClick: ({ domEvent }) => {domEvent.stopPropagation();- navigate('/settings/messenger');+ navigate(MARKETPLACE_APPS_PATH);},},);diff --git a/src/features/Messenger/Verify/Body/Discord.tsx b/src/features/Messenger/Verify/Body/Discord.tsxindex ec60043d616..30b00ceacde 100644--- a/src/features/Messenger/Verify/Body/Discord.tsx+++ b/src/features/Messenger/Verify/Body/Discord.tsx@@ -3,6 +3,8 @@import { memo, useState } from 'react';import { useTranslation } from 'react-i18next';+import { marketplaceAppPath } from '@/features/Marketplace/paths';+import { buildDiscordOpenBotUrl } from '../../constants';import {ConfirmCard,@@ -66,9 +68,9 @@ const DiscordBody = memo<DiscordBodyProps>(blockingNotice={rebindBlocked? {- ctaHref: '/settings/messenger/discord',- ctaLabel: t('verify.confirm.relink.manage'),- description: t('verify.confirm.relink.description', {+ ctaHref: marketplaceAppPath('discord'),+ ctaLabel: t('verify.confirm.relink.openApp'),+ description: t('verify.confirm.relink.disconnectInMarketplace', {account:existingLink?.platformUsername ?? `ID ${existingLink?.platformUserId ?? ''}`,platform: platformLabel,diff --git a/src/features/Messenger/Verify/Body/Slack.tsx b/src/features/Messenger/Verify/Body/Slack.tsxindex 0c4b4d046f3..f224b5e4237 100644--- a/src/features/Messenger/Verify/Body/Slack.tsx+++ b/src/features/Messenger/Verify/Body/Slack.tsx@@ -3,6 +3,8 @@import { memo, useState } from 'react';import { useTranslation } from 'react-i18next';+import { marketplaceAppPath } from '@/features/Marketplace/paths';+import { buildSlackOpenBotUrl } from '../../constants';import {ConfirmCard,@@ -69,9 +71,9 @@ const SlackBody = memo<SlackBodyProps>(blockingNotice={rebindBlocked? {- ctaHref: '/settings/messenger/slack',- ctaLabel: t('verify.confirm.relink.manage'),- description: t('verify.confirm.relink.description', {+ ctaHref: marketplaceAppPath('slack'),+ ctaLabel: t('verify.confirm.relink.openApp'),+ description: t('verify.confirm.relink.disconnectInMarketplace', {account:existingLink?.platformUsername ?? `ID ${existingLink?.platformUserId ?? ''}`,platform: platformLabel,diff --git a/src/features/Messenger/Verify/Body/Telegram.tsx b/src/features/Messenger/Verify/Body/Telegram.tsxindex ea7aa541ee4..62e2a3a64b9 100644--- a/src/features/Messenger/Verify/Body/Telegram.tsx+++ b/src/features/Messenger/Verify/Body/Telegram.tsx@@ -3,6 +3,8 @@import { memo, useState } from 'react';import { useTranslation } from 'react-i18next';+import { marketplaceAppPath } from '@/features/Marketplace/paths';+import { buildTelegramBotUrl } from '../../constants';import {ConfirmCard,@@ -64,9 +66,9 @@ const TelegramBody = memo<TelegramBodyProps>(blockingNotice={rebindBlocked? {- ctaHref: '/settings/messenger/telegram',- ctaLabel: t('verify.confirm.relink.manage'),- description: t('verify.confirm.relink.description', {+ ctaHref: marketplaceAppPath('telegram'),+ ctaLabel: t('verify.confirm.relink.openApp'),+ description: t('verify.confirm.relink.disconnectInMarketplace', {account:existingLink?.platformUsername ?? `ID ${existingLink?.platformUserId ?? ''}`,platform: platformLabel,diff --git a/src/features/Messenger/Verify/Body/shared.tsx b/src/features/Messenger/Verify/Body/shared.tsxindex 48f6aa3b3c1..f4b667ee4e9 100644--- a/src/features/Messenger/Verify/Body/shared.tsx+++ b/src/features/Messenger/Verify/Body/shared.tsx@@ -6,6 +6,7 @@ import { memo, useEffect, useMemo, useState } from 'react';import { useTranslation } from 'react-i18next';import { ProductLogo } from '@/components/Branding';+import { marketplaceAppPath } from '@/features/Marketplace/paths';import { messengerService } from '@/services/messenger';import { messengerActions, messengerSelectors, useMessengerStore } from '@/store/messenger';import { serverConfigSelectors, useServerConfigStore } from '@/store/serverConfig';@@ -35,9 +36,7 @@ export const styles = createStaticStyles(({ css, cssVar }) => ({border-radius: 14px;background: ${cssVar.colorBgContainer};- box-shadow:- 0 1px 2px rgb(0 0 0 / 6%),- 0 4px 12px rgb(0 0 0 / 4%);+ box-shadow: ${cssVar.boxShadowTertiary};`,card: css`width: 100%;@@ -82,8 +81,8 @@ export const styles = createStaticStyles(({ css, cssVar }) => ({white-space: nowrap;`,successBubble: css`- color: #fff;- background: #22c55e;+ color: ${cssVar.colorTextLightSolid};+ background: ${cssVar.colorSuccess};`,warningBlock: css`padding-block: ${densityVars.contentGap};@@ -304,7 +303,7 @@ export const ConfirmCard = memo<ConfirmCardProps>(/>)}<Text style={{ fontSize: 12 }} type="secondary">- {t('verify.confirm.defaultAgentHint')}+ {t('verify.confirm.defaultAgentMarketplaceHint')}</Text></Flexbox></Flexbox>@@ -354,10 +353,10 @@ export const SuccessCard = memo<SuccessCardProps>(({ openBotUrl, platform, platf</Button>)}{/* Mirror the Slack/Discord install callback's landing page so every- platform's flow ends back on its Messenger settings tab. */}+ platform's flow ends back on its Marketplace app. */}<Buttonblock- href={`/settings/messenger/${platform}`}+ href={marketplaceAppPath(platform)}size="large"type={openBotUrl ? 'default' : 'primary'}>diff --git a/src/features/Messenger/index.tsx b/src/features/Messenger/index.tsxdeleted file mode 100644index 6123bd156b0..00000000000--- a/src/features/Messenger/index.tsx+++ /dev/null@@ -1,212 +0,0 @@-'use client';--import { Button, createStaticStyles, Flexbox, Text, toast } from '@lobehub/ui';-import { memo, useEffect, useState } from 'react';-import { useTranslation } from 'react-i18next';-import { useParams } from 'react-router';--import AsyncBoundary from '@/components/AsyncBoundary';-import ImperativeModal from '@/components/ImperativeModal';-import {- MessengerListGridSkeleton,- MessengerPlatformDetailSkeleton,-} from '@/components/Skeleton/Settings/MessengerDetail';-import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';-import { messengerActions, messengerSelectors, useMessengerStore } from '@/store/messenger';--import { type MessengerPlatform, PlatformAvatar } from './constants';-import { getDiscordInstallErrorReason, getSlackInstallErrorReason } from './i18n';-import IntegrationDetail from './IntegrationDetail';-import IntegrationList from './IntegrationList';--interface BlockedInstall {- // Empty string sentinel = open modal even when the tenant name is unknown.- name: string;- platform: 'slack' | 'discord';-}--const VALID_PLATFORMS: ReadonlySet<MessengerPlatform> = new Set([- 'slack',- 'telegram',- 'discord',- 'wechat',- 'linq',-]);--const isMessengerPlatform = (value: string | undefined): value is MessengerPlatform =>- !!value && VALID_PLATFORMS.has(value as MessengerPlatform);--const styles = createStaticStyles(({ css, cssVar }) => ({- emptyState: css`- padding-block: 48px;- padding-inline: 24px;- border: 1px dashed ${cssVar.colorBorder};- border-radius: ${cssVar.borderRadius};-- color: ${cssVar.colorTextSecondary};- text-align: center;- `,- page: css`- overflow-y: auto;- flex: 1;- `,-}));--const MessengerSettings = memo(() => {- const { t, ready } = useTranslation('messenger');-- const navigate = useWorkspaceAwareNavigate();- const params = useParams<{ sub?: string }>();- const selected: MessengerPlatform | null = isMessengerPlatform(params.sub) ? params.sub : null;- // Tenant name from `?workspace=...` plus the platform it belongs to. When- // set, render the takeover explainer modal — toast is too transient for a- // flow where the user just round-tripped through OAuth and needs clear- // next-step guidance.- const [blocked, setBlocked] = useState<BlockedInstall | null>(null);-- // A reload paints the last local copy, then revalidates in the background.- const platformsSync = messengerActions.useFetchPlatforms();- const platformList = useMessengerStore(messengerSelectors.platforms);- const isPlatformsSettled = useMessengerStore(messengerSelectors.isPlatformsSettled);- const isPlatformsConfirmed = useMessengerStore(messengerSelectors.isPlatformsConfirmed);-- // If the URL points at an unknown platform sub-segment, replace it with the- // bare list URL — keeps deep-links graceful when bots get removed from the- // registry.- useEffect(() => {- if (params.sub && !isMessengerPlatform(params.sub)) {- navigate('/settings/messenger', { replace: true });- }- }, [navigate, params.sub]);-- // Surface OAuth callback outcomes for the currently-selected platform. The- // callback redirects to `/settings/messenger/<platform>?installed=ok` (or- // `?error=...&workspace=...`); we toast success/generic-failure and escalate- // "already installed by another user" to a modal — the user just- // round-tripped through OAuth and needs clear next-step guidance.- useEffect(() => {- if (typeof window === 'undefined') return;- if (!selected) return;- // Wait for the `messenger` namespace to finish loading; otherwise the- // imperative toast captures the raw key as its text (useTranslation has- // `useSuspense: false`, so the component doesn't block on namespace load).- if (!ready) return;- const url = new URL(window.location.href);- const installed = url.searchParams.get('installed');- const error = url.searchParams.get('error');- const workspace = url.searchParams.get('workspace');- if (!installed && !error) return;-- if (installed && selected === 'slack') {- toast.success(t('messenger.slack.installResult.success'));- } else if (error === 'already_installed' && selected === 'slack') {- setBlocked({ name: workspace ?? '', platform: 'slack' });- } else if (error && selected === 'slack') {- toast.error(- t('messenger.slack.installResult.failed', {- reason: getSlackInstallErrorReason(t, error),- }),- );- } else if (installed && selected === 'discord') {- toast.success(t('messenger.discord.installResult.success'));- } else if (error === 'already_installed' && selected === 'discord') {- setBlocked({ name: workspace ?? '', platform: 'discord' });- } else if (error && selected === 'discord') {- toast.error(- t('messenger.discord.installResult.failed', {- reason: getDiscordInstallErrorReason(t, error),- }),- );- }-- url.searchParams.delete('installed');- url.searchParams.delete('error');- url.searchParams.delete('workspace');- window.history.replaceState({}, '', url.pathname + (url.search ? `?${url.searchParams}` : ''));- }, [t, selected, ready]);-- const platforms = platformList ?? [];- const selectedMeta = platforms.find((p) => p.id === selected);- // A restored copy may predate a newly enabled platform: until the server- // answers, a miss is still loading, not a reason to fall back to the list.- const isSelectedPending = !selectedMeta && !isPlatformsConfirmed && !platformsSync.error;-- return (- <div className={styles.page}>- <Flexbox gap={20}>- {selected && isSelectedPending ? (- <MessengerPlatformDetailSkeleton platform={selected} />- ) : selected && selectedMeta ? (- <IntegrationDetail- access={selectedMeta.access}- appId={selectedMeta.appId}- botUsername={selectedMeta.botUsername}- name={selectedMeta.name}- platform={selected}- onBack={() => navigate('/settings/messenger')}- />- ) : (- <>- <Text type="secondary">{t('messenger.subtitle')}</Text>- <AsyncBoundary- data={isPlatformsSettled || undefined}- error={platformsSync.error}- errorVariant={'block'}- isEmpty={platforms.length === 0}- loading={<MessengerListGridSkeleton />}- empty={- <div className={styles.emptyState}>{t('messenger.noPlatformsConfigured')}</div>- }- isLoading={- !isPlatformsSettled && (!platformsSync.error || platformsSync.isValidating)- }- onRetry={() => {- void platformsSync.revalidate();- }}- >- <IntegrationList- platforms={platforms}- onSelect={(platform) => navigate(`/settings/messenger/${platform}`)}- />- </AsyncBoundary>- </>- )}- </Flexbox>-- <ImperativeModal- footer={null}- open={blocked !== null}- width={480}- title={- blocked ? t(`messenger.${blocked.platform}.installBlocked.title` as const) : undefined- }- onCancel={() => setBlocked(null)}- >- {blocked && (- <Flexbox align="center" gap={20} style={{ paddingBlock: 16 }}>- <PlatformAvatar platform={blocked.platform} size={56} />- <Flexbox align="center" gap={8}>- <Text strong style={{ fontSize: 16, textAlign: 'center' }}>- {blocked.name- ? t(`messenger.${blocked.platform}.installBlocked.withName` as const, {- workspace: blocked.name,- })- : t(`messenger.${blocked.platform}.installBlocked.withoutName` as const)}- </Text>- <Text style={{ textAlign: 'center' }} type="secondary">- {t(`messenger.${blocked.platform}.installBlocked.suggestion` as const)}- </Text>- </Flexbox>- <Button block size="large" type="primary" onClick={() => setBlocked(null)}>- {t(`messenger.${blocked.platform}.installBlocked.dismiss` as const)}- </Button>- </Flexbox>- )}- </ImperativeModal>- </div>- );-});--MessengerSettings.displayName = 'MessengerSettings';--export default MessengerSettings;diff --git a/src/features/Settings/features/componentMap.desktop.ts b/src/features/Settings/features/componentMap.desktop.tsindex ea4ec930e24..d05594d34e7 100644--- a/src/features/Settings/features/componentMap.desktop.ts+++ b/src/features/Settings/features/componentMap.desktop.ts@@ -17,7 +17,6 @@ import Hotkey from '../hotkey';import Labels from '../labels';import Labs from '../labs';import Memory from '../memory';-import Messenger from '../messenger';import { DesktopNotificationSettings } from '../notification';import OAuthApps from '../oauth-apps';import Profile from '../profile';@@ -40,7 +39,6 @@ export const componentMap = {[SettingsTabs.Provider]: Provider,[SettingsTabs.ServiceModel]: ServiceModel,[SettingsTabs.Memory]: Memory,- [SettingsTabs.Messenger]: Messenger,[SettingsTabs.Notification]: DesktopNotificationSettings,[SettingsTabs.About]: About,[SettingsTabs.Hotkey]: Hotkey,diff --git a/src/features/Settings/features/componentMap.ts b/src/features/Settings/features/componentMap.tsindex ee04e6e219b..9153cf5cb87 100644--- a/src/features/Settings/features/componentMap.ts+++ b/src/features/Settings/features/componentMap.ts@@ -25,9 +25,6 @@ export const componentMap = {[SettingsTabs.Memory]: dynamic(() => import('../memory'), {loading: loading('Settings > Memory'),}),- [SettingsTabs.Messenger]: dynamic(() => import('../messenger'), {- loading: loading('Settings > Messenger'),- }),[SettingsTabs.Notification]: dynamic(() => import('@/business/client/BusinessSettingPages/Notification'),{diff --git a/src/features/Settings/features/tabTitles.ts b/src/features/Settings/features/tabTitles.tsindex acc474e03bf..88f481ef986 100644--- a/src/features/Settings/features/tabTitles.ts+++ b/src/features/Settings/features/tabTitles.ts@@ -27,7 +27,6 @@ export const SETTINGS_TAB_TITLE_KEYS: Partial<Record<SettingsTabs, TitleKey>> =// Labs has no `setting:tab.*` entry — the nav label comes from the labs namespace.[SettingsTabs.Labs]: ['labs', 'title'],[SettingsTabs.Memory]: ['setting', 'tab.memory'],- [SettingsTabs.Messenger]: ['setting', 'tab.messenger'],[SettingsTabs.Notification]: ['setting', 'tab.notification'],[SettingsTabs.OAuthApps]: ['auth', 'tab.oauthApps'],[SettingsTabs.Plans]: ['subscription', 'tab.plans'],diff --git a/src/features/Settings/hooks/useCategory.test.tsx b/src/features/Settings/hooks/useCategory.test.tsxindex 41edc02af74..5f4ac0cf3da 100644--- a/src/features/Settings/hooks/useCategory.test.tsx+++ b/src/features/Settings/hooks/useCategory.test.tsx@@ -70,7 +70,6 @@ describe('settings useCategory', () => {SettingsGroupKey.Account,SettingsGroupKey.Subscription,SettingsGroupKey.Agent,- SettingsGroupKey.Connection,SettingsGroupKey.Resource,SettingsGroupKey.System,]);@@ -83,8 +82,7 @@ describe('settings useCategory', () => {SettingsTabs.Stats,]);- expect(groupKeys(SettingsGroupKey.Connection)).toEqual([SettingsTabs.Messenger]);- // Skills, connectors and integrations moved to the Marketplace.+ expect(groupKeys(SettingsGroupKey.Connection)).toBeUndefined();expect(getItemKeys()).not.toContain(SettingsTabs.Skill);expect(getItemKeys()).not.toContain(SettingsTabs.Connector);@@ -98,12 +96,10 @@ describe('settings useCategory', () => {expect(keys).not.toContain('drive');});- // Messenger bots are LobeHub-operated and only configurable from the cloud- // admin, so the tab is a dead end on self-hosted deployments.it('keeps Provider and hides Messenger and OAuth Apps by default', () => {const keys = getItemKeys();- expect(keys).not.toContain(SettingsTabs.Messenger);+ expect(keys).not.toContain('messenger');expect(keys).toContain(SettingsTabs.Provider);expect(keys).not.toContain(SettingsTabs.OAuthApps);});diff --git a/src/features/Settings/hooks/useCategory.tsx b/src/features/Settings/hooks/useCategory.tsxindex c307bfb927f..0c070138da6 100644--- a/src/features/Settings/hooks/useCategory.tsx+++ b/src/features/Settings/hooks/useCategory.tsx@@ -20,7 +20,6 @@ import {KeyboardIcon,KeyIcon,Map,- MessageCircleIcon,MonitorSmartphoneIcon,PaletteIcon,Sparkles,@@ -196,13 +195,6 @@ export const useCategory = () => {// Connection group — the outside services agents can reach, whoever owns// the binding. Every entry here is already the user's own.const connectionItems: CategoryItem[] = [- // The bots are LobeHub-operated: their credentials are only ever written- // by the cloud admin, so a self-hosted deployment has nothing to bind to.- enableBusinessFeatures && {- icon: MessageCircleIcon,- key: SettingsTabs.Messenger,- label: t('tab.messenger'),- },// What connectors fire on their own: the event subscriptions agents made// through them. Connectors themselves are managed in the Marketplace.enableWebhook && {diff --git a/src/features/Settings/messenger/index.tsx b/src/features/Settings/messenger/index.tsxdeleted file mode 100644index bb99f560b02..00000000000--- a/src/features/Settings/messenger/index.tsx+++ /dev/null@@ -1,20 +0,0 @@-import { useTranslation } from 'react-i18next';--import MessengerSettings from '@/features/Messenger';-import SettingHeader from '@/features/Settings/features/SettingHeader';--interface PageProps {- showSettingHeader?: boolean;-}--const Page = ({ showSettingHeader = true }: PageProps) => {- const { t } = useTranslation('setting');- return (- <>- {showSettingHeader && <SettingHeader title={t('tab.messenger')} />}- <MessengerSettings />- </>- );-};--export default Page;diff --git a/src/features/Settings/skill/features/CatalogPageHeader.tsx b/src/features/Settings/skill/features/CatalogPageHeader.tsxindex 58589c32b27..27c524e2af1 100644--- a/src/features/Settings/skill/features/CatalogPageHeader.tsx+++ b/src/features/Settings/skill/features/CatalogPageHeader.tsx@@ -82,11 +82,11 @@ const CatalogPageHeader = memo<CatalogPageHeaderProps>(viewMode,visibility,}) => {- const { t } = useTranslation('setting');+ const { t } = useTranslation(['setting', 'discover']);const [showAddConnector, setShowAddConnector] = useState(false);const { allowed: canCreate } = usePermission('create_content');const { canManage, isPending } = useConnectorManageable();- const isConnectorView = viewMode === 'connector';+ const isConnectorView = viewMode !== 'skill';const isPrivateTab = visibility === 'private';const description = t(!isConnectorView@@ -115,7 +115,9 @@ const CatalogPageHeader = memo<CatalogPageHeaderProps>(type={'primary'}onClick={() => setShowAddConnector(true)}>- {t('connectorMarket.add.custom')}+ {viewMode === 'mcp'+ ? t('apps.addMcp', { ns: 'discover' })+ : t('connectorMarket.add.custom')}</Button></span></Tooltip>@@ -130,9 +132,12 @@ const CatalogPageHeader = memo<CatalogPageHeaderProps>({t('agentSkillModal.title')}</Button>);- const searchPlaceholder = t(- isConnectorView ? 'connectorMarket.search.placeholder' : 'skillView.search.placeholder',- );+ const searchPlaceholder =+ viewMode === 'mcp'+ ? t('catalog.searchIn', { ns: 'discover', name: 'MCP' })+ : t(+ isConnectorView ? 'connectorMarket.search.placeholder' : 'skillView.search.placeholder',+ );const searchBelowTitle = getPageSearchPlacement(compact) === 'below-title';const search = (@@ -156,7 +161,9 @@ const CatalogPageHeader = memo<CatalogPageHeaderProps>(<div {...stylex.props(styles.pageHeader, compact && styles.pageHeaderCompact)}><div {...stylex.props(styles.pageHeadRow)}><h1 {...stylex.props(styles.pageTitle)}>- {t(isConnectorView ? 'skillView.connectors' : 'skillView.skills')}+ {viewMode === 'mcp'+ ? t('tab.mcp', { ns: 'discover' })+ : t(isConnectorView ? 'skillView.connectors' : 'skillView.skills')}</h1><Flexbox horizontal align={'center'} flex={'none'} gap={12}>{!searchBelowTitle && search}@@ -173,7 +180,9 @@ const CatalogPageHeader = memo<CatalogPageHeaderProps>(</Flexbox></div>{searchBelowTitle && search}- <Text type={'secondary'}>{description}</Text>+ <Text type={'secondary'}>+ {viewMode === 'mcp' ? t('apps.mcpDescription', { ns: 'discover' }) : description}+ </Text></div>{showAddConnector && (<CustomConnectorModaldiff --git a/src/features/Settings/skill/features/ComposioSkillItem.tsx b/src/features/Settings/skill/features/ComposioSkillItem.tsxindex cca2144dd74..a5493e7db24 100644--- a/src/features/Settings/skill/features/ComposioSkillItem.tsx+++ b/src/features/Settings/skill/features/ComposioSkillItem.tsx@@ -493,41 +493,36 @@ const ComposioSkillItem = memo<ComposioSkillItemProps>(}return (- <Flexbox- horizontal- align="center"- className={stylex.props(styles.container).className}- gap={8}- justify="space-between"- style={{- ...(isSelected ? { background: 'var(--lobe-color-primary-bg)', borderRadius: 6 } : {}),- ...(onSelect ? { cursor: 'pointer' } : {}),- }}- onClick={onSelect}- >- <Flexbox horizontal align="center" gap={8} style={{ flex: 1, overflow: 'hidden' }}>- <Flexbox- horizontal- align="center"- gap={8}- style={{ cursor: onSelect ? undefined : 'pointer' }}- >- <div {...stylex.props(styles.icon, !isConnected && styles.disconnectedIcon)}>- {renderIcon()}- </div>- <span {...stylex.props(styles.title, !isConnected && styles.disconnectedTitle)}>- {serverType.label}- </span>+ <>+ <Flexbox+ horizontal+ align="center"+ className={stylex.props(styles.container).className}+ gap={8}+ justify="space-between"+ style={+ isSelected ? { background: 'var(--lobe-color-primary-bg)', borderRadius: 6 } : undefined+ }+ >+ <Flexbox horizontal align="center" gap={8} style={{ flex: 1, overflow: 'hidden' }}>+ <Flexbox horizontal align="center" gap={8}>+ <div {...stylex.props(styles.icon, !isConnected && styles.disconnectedIcon)}>+ {renderIcon()}+ </div>+ <span {...stylex.props(styles.title, !isConnected && styles.disconnectedTitle)}>+ {serverType.label}+ </span>+ </Flexbox>+ {!isConnected && renderStatus()}</Flexbox>- {!isConnected && renderStatus()}- </Flexbox>- {!onSelect && (<Flexbox horizontal align="center" gap={8}>{isConnected && renderStatus()}{renderAction()}</Flexbox>- )}- </Flexbox>+ </Flexbox>+ {actionError &&+ renderConnectorRowDescription({ error: actionError, name: serverType.label })}+ </>);},);diff --git a/src/features/Settings/skill/features/LeftPanel.tsx b/src/features/Settings/skill/features/LeftPanel.tsxindex e1f607217b9..8883e7dc0d3 100644--- a/src/features/Settings/skill/features/LeftPanel.tsx+++ b/src/features/Settings/skill/features/LeftPanel.tsx@@ -101,7 +101,7 @@ const LeftPanel = memo<LeftPanelProps>(const [showAddConnector, setShowAddConnector] = useState(false);const [keyword, setKeyword] = useState('');- const isConnectorView = viewMode === 'connector';+ const isConnectorView = viewMode !== 'skill';// Mobile column only: it has no Discover / Installed tabs, so the store// button stays its way to find more.const handleOpenStore = isConnectorView ? createSkillStoreModal : createMarketSkillStoreModal;diff --git a/src/features/Settings/skill/features/LobehubSkillItem.tsx b/src/features/Settings/skill/features/LobehubSkillItem.tsxindex 025ae32fa0e..f775131557e 100644--- a/src/features/Settings/skill/features/LobehubSkillItem.tsx+++ b/src/features/Settings/skill/features/LobehubSkillItem.tsx@@ -431,46 +431,41 @@ const LobehubSkillItem = memo<LobehubSkillItemProps>(}return (- <Flexbox- horizontal- align="center"- className={stylex.props(styles.container).className}- gap={8}- justify="space-between"- style={{- ...(isSelected ? { background: 'var(--lobe-color-primary-bg)', borderRadius: 6 } : {}),- ...(onSelect ? { cursor: 'pointer' } : {}),- }}- onClick={onSelect}- >- <Flexbox horizontal align="center" gap={8} style={{ flex: 1, overflow: 'hidden' }}>- <Flexbox- horizontal- align="center"- gap={8}- style={{ cursor: onSelect ? undefined : 'pointer' }}- onClick={- onSelect- ? undefined- : () => createLobehubSkillDetailModal({ identifier: provider.id })- }- >- <div {...stylex.props(styles.icon, !isConnected && styles.disconnectedIcon)}>- {renderIcon()}- </div>- <span {...stylex.props(styles.title, !isConnected && styles.disconnectedTitle)}>- {provider.label}- </span>+ <>+ <Flexbox+ horizontal+ align="center"+ className={stylex.props(styles.container).className}+ gap={8}+ justify="space-between"+ style={+ isSelected ? { background: 'var(--lobe-color-primary-bg)', borderRadius: 6 } : undefined+ }+ >+ <Flexbox horizontal align="center" gap={8} style={{ flex: 1, overflow: 'hidden' }}>+ <Flexbox+ horizontal+ align="center"+ gap={8}+ style={{ cursor: 'pointer' }}+ onClick={() => createLobehubSkillDetailModal({ identifier: provider.id })}+ >+ <div {...stylex.props(styles.icon, !isConnected && styles.disconnectedIcon)}>+ {renderIcon()}+ </div>+ <span {...stylex.props(styles.title, !isConnected && styles.disconnectedTitle)}>+ {provider.label}+ </span>+ </Flexbox>+ {!isConnected && renderStatus()}</Flexbox>- {!isConnected && renderStatus()}- </Flexbox>- {!onSelect && (<Flexbox horizontal align="center" gap={8}>{isConnected && renderStatus()}{renderAction()}</Flexbox>- )}- </Flexbox>+ </Flexbox>+ {actionError && renderConnectorRowDescription({ error: actionError, name: provider.label })}+ </>);},);diff --git a/src/features/Settings/skill/features/RowActions.tsx b/src/features/Settings/skill/features/RowActions.tsxindex 03eb9fedac5..e8b5c928c98 100644--- a/src/features/Settings/skill/features/RowActions.tsx+++ b/src/features/Settings/skill/features/RowActions.tsx@@ -69,6 +69,7 @@ type MenuItems = DropdownItem[];interface RowMoreMenuProps {/** Lifecycle items after "View details", e.g. Disconnect / Uninstall. */items?: MenuItems;+ label?: string;onOpenDetail?: () => void;}@@ -76,8 +77,9 @@ interface RowMoreMenuProps {* The page row's manage menu for an added entry: open the detail page, plus the* row's lifecycle actions (each keeps its own confirmation).*/-export const RowMoreMenu = memo<RowMoreMenuProps>(({ items = [], onOpenDetail }) => {+export const RowMoreMenu = memo<RowMoreMenuProps>(({ items = [], label, onOpenDetail }) => {const { t } = useTranslation('setting');+ const manageLabel = label ?? t('connectorMarket.action.manage');const menuItems: MenuItems = [...(onOpenDetail? [@@ -99,11 +101,7 @@ export const RowMoreMenu = memo<RowMoreMenuProps>(({ items = [], onOpenDetail })// lobe-design-ignore LOBE-DIV-CLICK: not a control; only stops propagation to the row<span style={{ display: 'inline-flex' }} onClick={(event) => event.stopPropagation()}><DropdownMenu items={menuItems} placement={'bottomRight'}>- <ActionIcon- aria-label={t('connectorMarket.action.manage')}- icon={MoreHorizontalIcon}- title={t('connectorMarket.action.manage')}- />+ <ActionIcon aria-label={manageLabel} icon={MoreHorizontalIcon} title={manageLabel} /></DropdownMenu></span>);diff --git a/src/features/Settings/skill/features/SkillDetail/index.test.tsx b/src/features/Settings/skill/features/SkillDetail/index.test.tsxindex a8445f3e615..b88e57008b8 100644--- a/src/features/Settings/skill/features/SkillDetail/index.test.tsx+++ b/src/features/Settings/skill/features/SkillDetail/index.test.tsx@@ -6,6 +6,7 @@ import userEvent from '@testing-library/user-event';import type { ReactNode } from 'react';import { beforeEach, describe, expect, it, vi } from 'vitest';+import ConnectorGate from '@/features/Integrations/ConnectorGate';import { LobehubSkillStatus } from '@/store/tool/slices/lobehubSkillStore/types';import SkillDetail from './index';@@ -63,6 +64,7 @@ const mocks = vi.hoisted(() => {return {confirmModal: vi.fn(),+ githubLocaleReady: true,permissions: {create_content: true,edit_own_content: true,@@ -90,7 +92,8 @@ vi.mock('@lobehub/ui', async (importOriginal) => ({}));vi.mock('react-i18next', () => ({- useTranslation: () => ({+ useTranslation: (namespace: string) => ({+ ready: namespace !== 'integration' || mocks.githubLocaleReady,t: (key: string, options?: { defaultValue?: string; name?: string } | string) => {const translations: Record<string, string> = {'tools.lobehubSkill.connect': 'Connect',@@ -112,6 +115,14 @@ vi.mock('react-i18next', () => ({}),}));+vi.mock('@/features/Integrations/useConnectorConnection', () => ({+ useConnectorConnection: () => ({ available: false }),+}));+vi.mock('@/features/Integrations/Github/RepositoryAccess', () => ({+ default: () => <div>Repository access</div>,+}));+vi.mock('@/features/Settings/skill/features/LobehubSkillItem', () => ({ default: () => null }));+vi.mock('@/features/AgentSkillDetail', () => ({default: () => <div data-testid="agent-skill-detail" />,}));@@ -239,6 +250,17 @@ describe('SkillDetail', () => {},);+ it('waits for translations before showing GitHub repository access on a cold load', () => {+ mocks.githubLocaleReady = false;+ const cold = render(<ConnectorGate identifier="github">{null}</ConnectorGate>);+ expect(screen.queryByText('Repository access')).toBeNull();+ cold.unmount();++ mocks.githubLocaleReady = true;+ render(<ConnectorGate identifier="github">{null}</ConnectorGate>);+ expect(screen.getByText('Repository access')).toBeTruthy();+ });+it('offers a Configure migration action for an un-migrated legacy custom MCP', async () => {// Legacy `user_installed_plugins` custom MCP with an mcp config but no// matching `user_connectors` row → the panel should surface the migrationdiff --git a/src/features/Settings/skill/features/SkillList.tsx b/src/features/Settings/skill/features/SkillList.tsxindex b4f01d151eb..66f7586d538 100644--- a/src/features/Settings/skill/features/SkillList.tsx+++ b/src/features/Settings/skill/features/SkillList.tsx@@ -1,5 +1,6 @@'use client';+import { hasCallableMcpEndpoint } from '@lobechat/const';import type { ConnectorVisibility } from '@lobechat/types';import { Button, Center, Empty } from '@lobehub/ui';import { SkillsIcon } from '@lobehub/ui/icons';@@ -102,14 +103,9 @@ export interface SkillListHeaderContext {refreshing: boolean;}-export type SkillViewMode = 'connector' | 'skill';+export type SkillViewMode = 'connector' | 'mcp' | 'skill';interface SkillListProps {- /**- * Sidebar mode (the Marketplace `Installed` section): one flat list of what- * is already in the library, no group headers and nothing left to add.- */- installedOnly?: boolean;/** Page search: filters every group by name, identifier and description. */keyword?: string;onClearKeyword?: () => void;@@ -129,7 +125,6 @@ interface SkillListProps {const SkillList = memo<SkillListProps>(({- installedOnly,keyword,onClearKeyword,onSelect,@@ -187,10 +182,12 @@ const SkillList = memo<SkillListProps>(// Keep each SWR handle so a failed skill fetch surfaces error + Retry instead// of a fake-empty list (each hook syncs into the store only on success —//- const isConnectorView = viewMode === 'connector';- const lobehubSkillsSWR = useFetchLobehubSkillConnections(isLobehubSkillEnabled);- const composioSWR = useFetchUserComposioConnections(isComposioEnabled);- const agentSkillsSWR = useFetchAgentSkills(true);+ const isConnectorView = viewMode !== 'skill';+ const lobehubSkillsSWR = useFetchLobehubSkillConnections(+ isLobehubSkillEnabled && viewMode !== 'mcp',+ );+ const composioSWR = useFetchUserComposioConnections(isComposioEnabled && viewMode !== 'mcp');+ const agentSkillsSWR = useFetchAgentSkills(viewMode === 'skill');const skillsError =viewMode === 'skill'? agentSkillsSWR.error@@ -200,8 +197,10 @@ const SkillList = memo<SkillListProps>(void agentSkillsSWR.mutate();return;}- void lobehubSkillsSWR.mutate();- void composioSWR.mutate();+ if (viewMode !== 'mcp') {+ void lobehubSkillsSWR.mutate();+ void composioSWR.mutate();+ }void connectorsSWR.mutate();};@@ -234,11 +233,14 @@ const SkillList = memo<SkillListProps>(// The connector catalog contains OAuth integrations, connected first.// A few dozen entries: cheap enough to derive on each render.- const allIntegrations = buildIntegrationItems({- ...connectionState,- connectorAvailability: { composio: isComposioEnabled, lobehub: isLobehubSkillEnabled },- pageOnlyProviderIds: CONNECTOR_PAGE_IDS,- });+ const allIntegrations =+ viewMode === 'mcp'+ ? []+ : buildIntegrationItems({+ ...connectionState,+ pageOnlyProviderIds: CONNECTOR_PAGE_IDS,+ connectorAvailability: { composio: isComposioEnabled, lobehub: isLobehubSkillEnabled },+ });// Each workspace tab lists its own pool. Built-in tools, plugins and agent// connectors carry no visibility and stay with the shared pool; a connector@@ -265,7 +267,11 @@ const SkillList = memo<SkillListProps>(const customMCPs = isPrivateTab? []: installedPluginList.filter((plugin) => plugin.type === 'customPlugin');- const agentBoundConnectors = isPrivateTab ? [] : allAgentBoundConnectors;+ const agentBoundConnectors = isPrivateTab+ ? []+ : viewMode === 'mcp'+ ? allAgentBoundConnectors.filter(hasCallableMcpEndpoint)+ : allAgentBoundConnectors;const connectorTabCount = countConnectorTabItems({customConnectors,@@ -287,8 +293,7 @@ const SkillList = memo<SkillListProps>(setRefreshing(true);const requests = isConnectorView? [- lobehubSkillsSWR.mutate(),- composioSWR.mutate(),+ ...(viewMode === 'mcp' ? [] : [lobehubSkillsSWR.mutate(), composioSWR.mutate()]),connectorsSWR.mutate(),fetchAgentBoundConnectors(),]@@ -363,10 +368,16 @@ const SkillList = memo<SkillListProps>(<Center className={stylex.props(styles.container).className} paddingBlock={48}><Emptyicon={SkillsIcon}- title={t(viewMode === 'skill' ? 'skillView.empty.title' : 'tab.skillEmpty')}- description={t(- viewMode === 'skill' ? 'skillView.empty.description' : 'tab.skillDesc',- )}+ description={+ viewMode === 'mcp'+ ? t('apps.mcpDescription', { ns: 'discover' })+ : t(viewMode === 'skill' ? 'skillView.empty.description' : 'tab.skillDesc')+ }+ title={+ viewMode === 'mcp'+ ? t('apps.noInstalledMcp', { ns: 'discover' })+ : t(viewMode === 'skill' ? 'skillView.empty.title' : 'tab.skillEmpty')+ }/></Center></>@@ -408,7 +419,6 @@ const SkillList = memo<SkillListProps>(return (<LobehubSkillItemconnectable={isLobehubSkillEnabled}- hideConnectedStatus={installedOnly}isSelected={selectedIdentifier === item.provider.id}key={item.provider.id}openWhenDisconnected={hasConnectorPage(item.provider.id)}@@ -424,7 +434,6 @@ const SkillList = memo<SkillListProps>(case 'composio': {return (<ComposioSkillItem- hideConnectedStatus={installedOnly}isSelected={selectedIdentifier === item.serverType.identifier}key={item.serverType.identifier}server={getComposioServerByIdentifier(item.serverType.identifier)}@@ -642,21 +651,6 @@ const SkillList = memo<SkillListProps>(}// ── Sidebar list (skills page, mobile) ───────────────────────────────────- if (installedOnly) {- const isConnected = (item: IntegrationItem) => isIntegrationConnected(item, connectionState);- const items = isConnectorView- ? [- ...partitionByInstalled(communitySkillItems, isConnected).installed.map(- renderIntegration,- ),- ...renderCommunityMCPs(),- ...renderCustomConnectors(),- ]- : [...renderAgentSkills(marketAgentSkills), ...renderAgentSkills(userAgentSkills)];-- return <div {...stylex.props(styles.container)}>{items}</div>;- }-const renderSection = (key: string, label: string, children: React.ReactNode) => {const isCollapsed = collapsed.has(key);return (diff --git a/src/features/Settings/skill/features/catalogAddAction.ts b/src/features/Settings/skill/features/catalogAddAction.tsindex a8fd92e5f8f..230cb28840c 100644--- a/src/features/Settings/skill/features/catalogAddAction.ts+++ b/src/features/Settings/skill/features/catalogAddAction.ts@@ -33,7 +33,7 @@ export const getCatalogAddAction = ({viewMode,visibility,}: CatalogAddActionInput): CatalogAddAction => {- if (viewMode !== 'connector') return { disabled: !canCreate, kind: 'importSkill' };+ if (viewMode === 'skill') return { disabled: !canCreate, kind: 'importSkill' };// A private connector is the caller's own; only the shared pool follows the policy.if (visibility === 'private' || canManageShared)diff --git a/src/features/Settings/skill/index.tsx b/src/features/Settings/skill/index.tsxindex 67c92f30eb9..fcb8e9f7fe8 100644--- a/src/features/Settings/skill/index.tsx+++ b/src/features/Settings/skill/index.tsx@@ -90,7 +90,7 @@ export const ToolSettings = memo<ToolSettingsProps>(({ headerExtra, viewMode })// detail opened from it returns to it and names that tab's row.const workspaceId = useActiveWorkspaceId();const visibility: ConnectorVisibility | undefined =- viewMode === 'connector' && workspaceId+ viewMode !== 'skill' && workspaceId? searchParams.get('visibility') === 'private'? 'private': 'public'@@ -167,7 +167,7 @@ export const ToolSettings = memo<ToolSettingsProps>(({ headerExtra, viewMode })fullWidthcompact={mobile}headerExtra={headerExtra}- page={!mobile || viewMode === 'skill'}+ page={!mobile || viewMode !== 'connector'}viewMode={viewMode}visibility={visibility}onDeleteSelected={closeStackedDetail}@@ -223,9 +223,13 @@ export const ToolSettings = memo<ToolSettingsProps>(({ headerExtra, viewMode })identifier={stackedSelected.identifier}type={stackedSelected.type}visibility={visibility}- listLabel={t(viewMode === 'skill' ? 'skillView.skills' : 'skillView.connectors', {- ns: 'setting',- })}+ listLabel={+ viewMode === 'mcp'+ ? t('tab.mcp', { ns: 'discover' })+ : t(viewMode === 'skill' ? 'skillView.skills' : 'skillView.connectors', {+ ns: 'setting',+ })+ }onBack={closeStackedDetail}/><Flexbox flex={1} style={{ minHeight: 0 }}>diff --git a/src/features/SettingsSearch/items.test.ts b/src/features/SettingsSearch/items.test.tsindex 99cc68ae091..6d949c15d0f 100644--- a/src/features/SettingsSearch/items.test.ts+++ b/src/features/SettingsSearch/items.test.ts@@ -95,9 +95,6 @@ describe('settings search index', () => {expect(TAB_SEARCH_EN_KEYWORDS[SettingsTabs.Provider]).toEqual(expect.arrayContaining(['api', 'model provider', 'language model', 'custom provider']),);- expect(TAB_SEARCH_EN_KEYWORDS[SettingsTabs.Messenger]).toEqual(- expect.arrayContaining(['telegram', 'slack', 'discord', 'wechat']),- );expect(TAB_SEARCH_EN_KEYWORDS[SettingsTabs.ServiceModel]).toEqual(expect.arrayContaining(['search', 'model assignment']),);diff --git a/src/features/SettingsSearch/items.ts b/src/features/SettingsSearch/items.tsindex 8c33bac538d..67e6dcb15fb 100644--- a/src/features/SettingsSearch/items.ts+++ b/src/features/SettingsSearch/items.ts@@ -105,15 +105,6 @@ export const TAB_SEARCH_EN_KEYWORDS: Partial<Record<string, string[]>> = {'setup script','repository',],- [SettingsTabs.Messenger]: [- 'messenger',- 'chat platform',- 'bot',- 'telegram',- 'slack',- 'discord',- 'wechat',- ],[SettingsTabs.Notification]: ['notification','email',@@ -223,7 +214,6 @@ export const TAB_SEARCH_KEYWORDS_KEYS: Partial<Record<string, string>> = {[SettingsTabs.Hotkey]: 'settingsSearch.tabKeywords.hotkey',[SettingsTabs.Labs]: 'settingsSearch.tabKeywords.labs',[SettingsTabs.Memory]: 'settingsSearch.tabKeywords.memory',- [SettingsTabs.Messenger]: 'settingsSearch.tabKeywords.messenger',[SettingsTabs.Notification]: 'settingsSearch.tabKeywords.notification',[SettingsTabs.OAuthApps]: 'settingsSearch.tabKeywords.oauthApps',[SettingsTabs.Plans]: 'settingsSearch.tabKeywords.plans',diff --git a/src/features/Workspace/workspaceAwarePath.ts b/src/features/Workspace/workspaceAwarePath.tsindex aa690ce1211..1327931efdb 100644--- a/src/features/Workspace/workspaceAwarePath.ts+++ b/src/features/Workspace/workspaceAwarePath.ts@@ -37,7 +37,7 @@ export const WORKSPACE_SETTINGS_TABS: ReadonlySet<string> = new Set(['about','advanced','apikey',- // Account-level tabs (profile / appearance / hotkey / messenger) are+ // Account-level tabs (profile / appearance / hotkey) are// mirrored under the workspace so members can reach them without leaving// the workspace.'appearance',@@ -67,6 +67,7 @@ export const WORKSPACE_SETTINGS_TABS: ReadonlySet<string> = new Set(['labels','labs','members',+ // Legacy settings bookmarks redirect to the app within the same workspace.'messenger','notification','oauth-apps',diff --git a/src/features/WorkspaceSetting/Layout.test.tsx b/src/features/WorkspaceSetting/Layout.test.tsxindex f742f1c0553..3d23ff94138 100644--- a/src/features/WorkspaceSetting/Layout.test.tsx+++ b/src/features/WorkspaceSetting/Layout.test.tsx@@ -39,7 +39,6 @@ vi.mock('./hooks/useCategory', () => ({{ key: 'profile', label: 'Jane Doe' },{ key: 'appearance', label: 'Appearance' },{ key: 'hotkey', label: 'Hotkeys' },- { key: 'messenger', label: 'Messenger' },{ key: 'labs', label: 'Labs' },{ key: 'advanced', label: 'Advanced' },{ key: 'about', label: 'About' },@@ -77,7 +76,6 @@ describe('WorkspaceSettingsContentLayout', () => {['usage', 'Usage'],['appearance', 'Appearance'],['hotkey', 'Hotkeys'],- ['messenger', 'Messenger'],['labs', 'Labs'],['about', 'About'],// The Profile nav item is labelled with the user's name; the header keepsdiff --git a/src/features/WorkspaceSetting/Layout.tsx b/src/features/WorkspaceSetting/Layout.tsxindex 7dfaa60d1bb..e6f7a18f6b5 100644--- a/src/features/WorkspaceSetting/Layout.tsx+++ b/src/features/WorkspaceSetting/Layout.tsx@@ -32,7 +32,6 @@ const COMPACT_HEADER_TABS = new Set<string>([WorkspaceSettingsTabs.Labels,WorkspaceSettingsTabs.Labs,WorkspaceSettingsTabs.Members,- WorkspaceSettingsTabs.Messenger,WorkspaceSettingsTabs.Notification,WorkspaceSettingsTabs.Plans,WorkspaceSettingsTabs.Profile,diff --git a/src/features/WorkspaceSetting/hooks/useCategory.test.tsx b/src/features/WorkspaceSetting/hooks/useCategory.test.tsxindex 273135a58b9..5c52e83916a 100644--- a/src/features/WorkspaceSetting/hooks/useCategory.test.tsx+++ b/src/features/WorkspaceSetting/hooks/useCategory.test.tsx@@ -92,7 +92,6 @@ describe('workspace settings useCategory', () => {WorkspaceSettingsTabs.Appearance,WorkspaceSettingsTabs.Hotkey,WorkspaceSettingsTabs.ChatPreference,- WorkspaceSettingsTabs.Messenger,]);expect(generalGroup?.items.map((item) => item.key)).not.toContain(WorkspaceSettingsTabs.Profile,diff --git a/src/features/WorkspaceSetting/hooks/useCategory.tsx b/src/features/WorkspaceSetting/hooks/useCategory.tsxindex 093e307ebfa..c8f9a5f59df 100644--- a/src/features/WorkspaceSetting/hooks/useCategory.tsx+++ b/src/features/WorkspaceSetting/hooks/useCategory.tsx@@ -19,7 +19,6 @@ import {KeyboardIcon,KeyIcon,Map,- MessageCircleIcon,MessagesSquareIcon,MonitorSmartphoneIcon,PaletteIcon,@@ -102,7 +101,7 @@ export const useWorkspaceSettingCategory = (): WorkspaceSettingCategoryGroup[] =return useMemo(() =>[- // Account-level settings (profile / appearance / hotkeys / messenger)+ // Account-level settings (profile / appearance / hotkeys)// follow the user, not the workspace. They are mirrored here so members// can reach them without leaving the workspace; the pages are the// personal ones.@@ -135,14 +134,6 @@ export const useWorkspaceSettingCategory = (): WorkspaceSettingCategoryGroup[] =key: WorkspaceSettingsTabs.ChatPreference,label: t('tab.chatPreference'),},- // The System Bot binding is a per-user identity (owned by userId,- // not the workspace); reaching a workspace's agents happens via the- // scope selector on the page itself.- {- icon: MessageCircleIcon,- key: WorkspaceSettingsTabs.Messenger,- label: t('tab.messenger'),- },],key: WorkspaceSettingsGroupKey.Account,title: t('group.profile'),@@ -241,9 +232,6 @@ export const useWorkspaceSettingCategory = (): WorkspaceSettingCategoryGroup[] =key: WorkspaceSettingsGroupKey.Agent,title: t('workspaceSetting.group.agent'),},- // Outside services the workspace's agents can reach. These bindings- // belong to the workspace; Messenger stays in Account because it is a- // per-user binding.enableWebhook && {items: [// Every member sees the workspace's event subscriptions, so it isdiff --git a/src/hooks/useMobileNavigation.ts b/src/hooks/useMobileNavigation.tsindex ef42630cc87..10c6014ddfb 100644--- a/src/hooks/useMobileNavigation.ts+++ b/src/hooks/useMobileNavigation.ts@@ -8,6 +8,8 @@ const MOBILE_NAV_ROUTES = new Set(['/marketplace','/marketplace/agent','/marketplace/connector',+ '/marketplace/app',+ '/marketplace/mcp','/marketplace/model','/marketplace/provider','/marketplace/skill',diff --git a/src/libs/next/config/define-config.ts b/src/libs/next/config/define-config.tsindex b7965cdac14..0de22e65bc5 100644--- a/src/libs/next/config/define-config.ts+++ b/src/libs/next/config/define-config.ts@@ -332,7 +332,7 @@ export function defineConfig(config: CustomNextConfig) {source: '/community/assistants',},{- destination: '/marketplace/connector',+ destination: '/marketplace/mcp',permanent: true,source: '/community/plugins',},diff --git a/src/routes/(main)/[workspaceSlug]/settings/messenger/index.tsx b/src/routes/(main)/[workspaceSlug]/settings/messenger/index.tsxdeleted file mode 100644index 6f379f601b0..00000000000--- a/src/routes/(main)/[workspaceSlug]/settings/messenger/index.tsx+++ /dev/null@@ -1,16 +0,0 @@-'use client';--import MessengerSetting from '@/features/Settings/messenger';--/**- * Account messenger bindings mirrored under- * `/:workspaceSlug/settings/messenger[/:sub]`. The binding is user-scoped;- * the workspace shell renders the compact header, so the page header is- * hidden. The platform detail level reads `sub` via `useParams` inside the- * feature, exactly as the personal route does.- */-const WorkspaceMessengerSetting = () => <MessengerSetting showSettingHeader={false} />;--WorkspaceMessengerSetting.displayName = 'WorkspaceMessengerSetting';--export default WorkspaceMessengerSetting;diff --git a/src/routes/(main)/community/(detail)/_layout/Header.tsx b/src/routes/(main)/community/(detail)/_layout/Header.tsxindex 8a8bba8cbd6..dac283e1018 100644--- a/src/routes/(main)/community/(detail)/_layout/Header.tsx+++ b/src/routes/(main)/community/(detail)/_layout/Header.tsx@@ -8,7 +8,7 @@ import { useTranslation } from 'react-i18next';import { useLocation } from 'react-router';import urlJoin from 'url-join';-import { MARKETPLACE_CONNECTOR_PATH, MARKETPLACE_SEGMENT } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH, MARKETPLACE_SEGMENT } from '@/features/Marketplace/paths';import NavHeader from '@/features/NavHeader';import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import StoreSearchBar from '@/routes/(main)/community/features/Search';@@ -45,7 +45,7 @@ const Header = memo(() => {return;}if (detailType === 'mcp') {- navigate(MARKETPLACE_CONNECTOR_PATH);+ navigate(MARKETPLACE_MCP_PATH);return;}// group_agent goes back to agent list pagediff --git a/src/routes/(main)/community/(detail)/app/index.tsx b/src/routes/(main)/community/(detail)/app/index.tsxnew file mode 100644index 00000000000..35b7e283fb6--- /dev/null+++ b/src/routes/(main)/community/(detail)/app/index.tsx@@ -0,0 +1 @@+export { default } from '@/features/Marketplace/Apps/AppDetail';diff --git a/src/routes/(main)/community/(detail)/mcp/features/Details/Related/index.tsx b/src/routes/(main)/community/(detail)/mcp/features/Details/Related/index.tsxindex ced433c3a52..28aef5f0e69 100644--- a/src/routes/(main)/community/(detail)/mcp/features/Details/Related/index.tsx+++ b/src/routes/(main)/community/(detail)/mcp/features/Details/Related/index.tsx@@ -3,7 +3,7 @@ import qs from 'query-string';import { memo } from 'react';import { useTranslation } from 'react-i18next';-import { MARKETPLACE_CONNECTOR_PATH } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import { useDetailContext } from '@/features/MCPPluginDetail/DetailProvider';import McpList from '../../../../../(list)/mcp/features/List';@@ -20,7 +20,7 @@ const Related = memo(() => {query: {category,},- url: MARKETPLACE_CONNECTOR_PATH,+ url: MARKETPLACE_MCP_PATH,})}>{t('mcp.details.related.listTitle')}diff --git a/src/routes/(main)/community/(detail)/mcp/features/Sidebar/Related/index.tsx b/src/routes/(main)/community/(detail)/mcp/features/Sidebar/Related/index.tsxindex c91123cb08e..9421cbe4e5e 100644--- a/src/routes/(main)/community/(detail)/mcp/features/Sidebar/Related/index.tsx+++ b/src/routes/(main)/community/(detail)/mcp/features/Sidebar/Related/index.tsx@@ -4,7 +4,7 @@ import { memo } from 'react';import { useTranslation } from 'react-i18next';import urlJoin from 'url-join';-import { MARKETPLACE_CONNECTOR_PATH } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import { useDetailContext } from '@/features/MCPPluginDetail/DetailProvider';import WorkspaceLink from '@/features/Workspace/WorkspaceLink';@@ -23,7 +23,7 @@ const Related = memo(() => {query: {category,},- url: MARKETPLACE_CONNECTOR_PATH,+ url: MARKETPLACE_MCP_PATH,})}>{t('mcp.details.related.listTitle')}diff --git a/src/routes/(main)/community/(detail)/model/features/Details/Related/index.tsx b/src/routes/(main)/community/(detail)/model/features/Details/Related/index.tsxindex c6eab66859f..e6c895e3337 100644--- a/src/routes/(main)/community/(detail)/model/features/Details/Related/index.tsx+++ b/src/routes/(main)/community/(detail)/model/features/Details/Related/index.tsx@@ -3,7 +3,7 @@ import qs from 'query-string';import { memo } from 'react';import { useTranslation } from 'react-i18next';-import { MARKETPLACE_CONNECTOR_PATH } from '@/features/Marketplace/paths';+import { MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import List from '../../../../../(list)/model/features/List';import Title from '../../../../../features/Title';@@ -20,7 +20,7 @@ const Related = memo(() => {query: {category,},- url: MARKETPLACE_CONNECTOR_PATH,+ url: MARKETPLACE_MCP_PATH,})}>{t('assistants.details.related.listTitle')}diff --git a/src/routes/(main)/community/(list)/app/index.tsx b/src/routes/(main)/community/(list)/app/index.tsxnew file mode 100644index 00000000000..593a7fb1b2d--- /dev/null+++ b/src/routes/(main)/community/(list)/app/index.tsx@@ -0,0 +1 @@+export { default } from '@/features/Marketplace/Apps/AppCatalog';diff --git a/src/routes/(main)/community/(list)/connector/index.tsx b/src/routes/(main)/community/(list)/connector/index.tsxdeleted file mode 100644index 27b2b69680f..00000000000--- a/src/routes/(main)/community/(list)/connector/index.tsx+++ /dev/null@@ -1 +0,0 @@-export { default } from '@/features/Marketplace/Catalog/ConnectorCatalog';diff --git a/src/routes/(main)/community/(list)/mcp/index.tsx b/src/routes/(main)/community/(list)/mcp/index.tsxnew file mode 100644index 00000000000..19424d8a5d4--- /dev/null+++ b/src/routes/(main)/community/(list)/mcp/index.tsx@@ -0,0 +1 @@+export { default } from '@/features/Marketplace/Catalog/McpCatalog';diff --git a/src/routes/(main)/community/(manage)/mcp/index.tsx b/src/routes/(main)/community/(manage)/mcp/index.tsxnew file mode 100644index 00000000000..14dd0b240a7--- /dev/null+++ b/src/routes/(main)/community/(manage)/mcp/index.tsx@@ -0,0 +1 @@+export { default } from '@/features/Marketplace/InstalledMcp';diff --git a/src/routes/(main)/community/_layout/Sidebar/Header/Nav.tsx b/src/routes/(main)/community/_layout/Sidebar/Header/Nav.tsxindex fce052e4625..978ece4f326 100644--- a/src/routes/(main)/community/_layout/Sidebar/Header/Nav.tsx+++ b/src/routes/(main)/community/_layout/Sidebar/Header/Nav.tsx@@ -2,24 +2,21 @@import { Flexbox } from '@lobehub/ui';import { SkillsIcon } from '@lobehub/ui/icons';-import { Blocks, Bot } from 'lucide-react';+import { Blocks, Bot, Cable } from 'lucide-react';import { memo, useMemo } from 'react';import { useTranslation } from 'react-i18next';import {getMarketplaceSubPath,MARKETPLACE_AGENT_PATH,- MARKETPLACE_CONNECTOR_PATH,- MARKETPLACE_INSTALLED_CONNECTORS_PATH,+ MARKETPLACE_APPS_PATH,+ MARKETPLACE_INSTALLED_MCP_PATH,MARKETPLACE_INSTALLED_SKILLS_PATH,+ MARKETPLACE_MCP_PATH,MARKETPLACE_SKILL_PATH,} from '@/features/Marketplace/paths';import NavItem from '@/features/NavPanel/components/NavItem';import { type NavItemProps } from '@/features/NavPanel/components/NavItem';-import {- MOBILE_SELECTION_PARAM,- parseMobileSelection,-} from '@/features/Settings/skill/mobileSelection';import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import WorkspaceLink from '@/features/Workspace/WorkspaceLink';import { useActiveLocation } from '@/hooks/useActiveLocation';@@ -27,8 +24,7 @@ import { featureFlagsSelectors, useServerConfigStore } from '@/store/serverConfiimport { DiscoverTab } from '@/types/discover';import { isModifierClick } from '@/utils/navigation';-/** Connectors: the MCP catalog plus the connector manager moved here from settings. */-const CONNECTOR_TAB = 'connector';+const APPS_TAB = 'app';interface Item {icon: NavItemProps['icon'];@@ -40,21 +36,9 @@ interface Item {url?: string;}-// Workspace-aware: `/:slug/marketplace/skill` resolves to `skill` as well.-// MCP detail pages (`mcp/:slug`) belong to Connectors, which absorbed the MCP list.-const useActiveTabKey = () => {- const { pathname, search } = useActiveLocation();- const subPath = getMarketplaceSubPath(pathname) ?? '';- if (- subPath === getMarketplaceSubPath(MARKETPLACE_INSTALLED_CONNECTORS_PATH) &&- parseMobileSelection(new URLSearchParams(search).get(MOBILE_SELECTION_PARAM))- )- return '';- return subPath.startsWith(DiscoverTab.Mcp) ? CONNECTOR_TAB : subPath;-};-const Nav = memo(() => {- const tab = useActiveTabKey();+ const { pathname } = useActiveLocation();+ const tab = getMarketplaceSubPath(pathname) ?? '';const navigate = useWorkspaceAwareNavigate();const { t } = useTranslation('discover');const { showMarket } = useServerConfigStore(featureFlagsSelectors);@@ -64,11 +48,15 @@ const Nav = memo(() => {[{icon: Blocks,- key: CONNECTOR_TAB,- title: t('tab.connector'),- // Connectors merges the MCP catalog (Discover) with the installed- // connectors; without the market only the installed view exists.- url: showMarket ? MARKETPLACE_CONNECTOR_PATH : MARKETPLACE_INSTALLED_CONNECTORS_PATH,+ key: APPS_TAB,+ title: t('tab.apps'),+ url: MARKETPLACE_APPS_PATH,+ },+ {+ icon: Cable,+ key: DiscoverTab.Mcp,+ title: t('tab.mcp'),+ url: showMarket ? MARKETPLACE_MCP_PATH : MARKETPLACE_INSTALLED_MCP_PATH,},{icon: SkillsIcon,diff --git a/src/routes/(main)/community/features/useNav.tsx b/src/routes/(main)/community/features/useNav.tsxindex d791e61e892..ea31a34bf4f 100644--- a/src/routes/(main)/community/features/useNav.tsx+++ b/src/routes/(main)/community/features/useNav.tsx@@ -1,6 +1,6 @@import { Icon } from '@lobehub/ui';import { SkillsIcon } from '@lobehub/ui/icons';-import { Blocks, Bot } from 'lucide-react';+import { Blocks, Bot, Cable } from 'lucide-react';import { type ReactNode } from 'react';import { useMemo } from 'react';import { useTranslation } from 'react-i18next';@@ -21,8 +21,7 @@ export const useNav = () => {const activeKey = useMemo(() => {const section = getMarketplaceSubPath(location.pathname)?.split('/')[0];// MCP and legacy plugin details belong to Connectors.- if (section === DiscoverTab.Mcp || section === DiscoverTab.Plugins)- return MARKETPLACE_CONNECTOR_TAB;+ if (section === DiscoverTab.Plugins) return DiscoverTab.Mcp;return section;}, [location.pathname]);@@ -30,8 +29,13 @@ export const useNav = () => {() => [{icon: <Icon icon={Blocks} size={ICON_SIZE} />,- key: MARKETPLACE_CONNECTOR_TAB,- label: <div style={{ color: 'inherit', display: 'inline' }}>{t('tab.connector')}</div>,+ key: 'app',+ label: <div style={{ color: 'inherit', display: 'inline' }}>{t('tab.apps')}</div>,+ },+ {+ icon: <Icon icon={Cable} size={ICON_SIZE} />,+ key: DiscoverTab.Mcp,+ label: t('tab.mcp'),},{icon: <Icon icon={SkillsIcon} size={ICON_SIZE} />,diff --git a/src/routes/(mobile)/community/(detail)/_layout/Header.tsx b/src/routes/(mobile)/community/(detail)/_layout/Header.tsxindex 8add65b7c01..f90f7970ca1 100644--- a/src/routes/(mobile)/community/(detail)/_layout/Header.tsx+++ b/src/routes/(mobile)/community/(detail)/_layout/Header.tsx@@ -4,6 +4,7 @@ import { ChatHeader } from '@lobehub/ui/mobile';import { memo } from 'react';import { useLocation } from 'react-router';+import { getMarketplaceSubPath, MARKETPLACE_MCP_PATH } from '@/features/Marketplace/paths';import { useWorkspaceAwareNavigate } from '@/features/Workspace/useWorkspaceAwareNavigate';import { mobileHeaderSticky } from '@/styles/mobileHeader';@@ -23,7 +24,11 @@ const Header = memo(() => {onBackClick={() =>typeof catalog === 'string'? navigate(catalog, { escape: true, replace: true })- : navigate(`/${path}`)+ : navigate(+ getMarketplaceSubPath(location.pathname)?.startsWith('mcp/')+ ? MARKETPLACE_MCP_PATH+ : `/${path}`,+ )}/>);diff --git a/src/spa/router/desktopRouter.shared.tsx b/src/spa/router/desktopRouter.shared.tsxindex 7426fcb2dc4..5f46d990f70 100644--- a/src/spa/router/desktopRouter.shared.tsx+++ b/src/spa/router/desktopRouter.shared.tsx@@ -440,7 +440,7 @@ const createMainAreaChildrenDefinition = (options: MainAreaRouteOptions = {}): Rloader: settingsTabLoader,path: ':tab',},- // Tabs that need a sub-segment (e.g. /settings/messenger/discord) reuse+ // Tabs that need a sub-segment reuse// the same tab page; nested feature components read `:sub` via useParams.{element: dynamicElement(diff --git a/src/spa/router/desktopRouter.sync.test.tsx b/src/spa/router/desktopRouter.sync.test.tsxindex b67b9984291..9c7eca905d5 100644--- a/src/spa/router/desktopRouter.sync.test.tsx+++ b/src/spa/router/desktopRouter.sync.test.tsx@@ -769,25 +769,30 @@ describe('desktop router shared definition', () => {);// Discover pages: no category column layout, the Codex groups are the page.expect(matchRoutes(routes, '/marketplace/skill')?.at(-1)?.route.path).toBe('skill');- const connectorDiscover = matchRoutes(routes, '/marketplace/connector')?.at(-1)?.route;- expect(connectorDiscover?.path).toBe('connector');+ const appDiscover = matchRoutes(routes, '/marketplace/app')?.at(-1)?.route;+ expect(appDiscover?.path).toBe('app');expect(- (connectorDiscover?.handle as { meta?: { titleKey?: string } } | undefined)?.meta?.titleKey,- ).toBe('navigation.marketplaceConnectors');+ (appDiscover?.handle as { meta?: { titleKey?: string } } | undefined)?.meta?.titleKey,+ ).toBe('navigation.marketplaceApps');},);it.each(mainAreaVariants)(- '%s folds the MCP list into Connectors and keeps MCP detail pages',+ '%s distinguishes Apps, their capabilities, and MCP routes',(_, factory) => {const routes = createMainAreaRoutes(factory);- for (const url of ['/marketplace/mcp', '/acme/marketplace/mcp']) {- const element = matchRoutes(routes, url)?.at(-1)?.route.element as- ReactElement<{ to: string }> | undefined;-- expect(element?.type, url).toBe(LegacyPathRedirect);- expect(element?.props.to, url).toBe('/marketplace/connector');+ for (const prefix of ['', '/acme']) {+ for (const [url, pattern] of [+ ['app', 'app'],+ ['app/slack', 'app/:appId'],+ ['mcp', 'mcp'],+ ['mcp/installed', 'mcp/installed'],+ ]) {+ expect(matchRoutes(routes, `${prefix}/marketplace/${url}`)?.at(-1)?.route.path).toBe(+ pattern,+ );+ }}expect(matchRoutes(routes, '/marketplace/mcp/notion')?.at(-1)?.route.path).toBe('mcp/:slug');diff --git a/src/spa/router/legacyPathRedirect.test.ts b/src/spa/router/legacyPathRedirect.test.tsindex 91b3d3caacd..201ec13f1f1 100644--- a/src/spa/router/legacyPathRedirect.test.ts+++ b/src/spa/router/legacyPathRedirect.test.ts@@ -3,18 +3,15 @@ import { createElement } from 'react';import { createMemoryRouter, RouterProvider, useLocation } from 'react-router';import { describe, expect, it } from 'vitest';-import {- MARKETPLACE_INSTALLED_CONNECTORS_PATH,- MARKETPLACE_INSTALLED_SKILLS_PATH,-} from '@/features/Marketplace/paths';import { initServerConfigStore, Provider } from '@/store/serverConfig/store';+import { buildLegacyCommunityRedirectPath, buildLegacyRedirectPath } from './legacyPathRedirect';import {- buildLegacyCommunityRedirectPath,- buildLegacyRedirectPath,- LegacyPathRedirect,-} from './legacyPathRedirect';-import { legacyCommunityRoutes, marketplaceIndexRoute } from './marketplaceRoutes';+ legacyCommunityRoutes,+ legacyConnectorCatalogRoute,+ legacySettingsMarketplaceRedirects,+ marketplaceIndexRoute,+} from './marketplaceRoutes';const CurrentUrl = () => {const { hash, pathname, search } = useLocation();@@ -23,25 +20,19 @@ const CurrentUrl = () => {const currentUrl = createElement(CurrentUrl);const agentPage = createElement('div', { 'data-testid': 'url' }, 'agent page');-const redirectTo = (to: string) => createElement(LegacyPathRedirect, { to });/** A route table shaped like the real one: personal and `/:workspaceSlug` mirrors. */const renderAt = (url: string, serverConfigInit = true) => {const store = initServerConfigStore({ serverConfigInit });- const legacy = [- { element: redirectTo(MARKETPLACE_INSTALLED_SKILLS_PATH), path: 'skill' },- { element: redirectTo(MARKETPLACE_INSTALLED_SKILLS_PATH), path: 'skill/:sub' },- { element: redirectTo(MARKETPLACE_INSTALLED_CONNECTORS_PATH), path: 'connector' },- { element: redirectTo(MARKETPLACE_INSTALLED_CONNECTORS_PATH), path: 'connector/:sub' },- ];+ const legacy = legacySettingsMarketplaceRedirects;// The real legacy table, beside a workspace agent route that competes for// `/community/agent/:id` (a lone `community/*` splat lost to it).const shared = [...legacyCommunityRoutes,// The real tree has static `marketplace/<section>` routes that outrank the workspace ones.- { children: [marketplaceIndexRoute], path: 'marketplace' },+ { children: [marketplaceIndexRoute, legacyConnectorCatalogRoute], path: 'marketplace' },{ element: currentUrl, path: 'marketplace/*' },- { element: currentUrl, path: 'marketplace/connector' },+ { element: currentUrl, path: 'marketplace/app' },{ element: currentUrl, path: 'marketplace/agent' },{ element: currentUrl, path: 'marketplace/agent/:slug' },{@@ -102,7 +93,7 @@ describe('buildLegacyRedirectPath', () => {describe('legacy URL redirects', () => {it.each([- [true, '/acme/marketplace/connector?q=developer#results'],+ [true, '/acme/marketplace/app?q=developer#results'],[false, '/acme/marketplace/connector/installed?q=developer#results'],] as const)('opens the original bookmark directly after loading showMarket=%s',@@ -130,19 +121,35 @@ describe('legacy URL redirects', () => {'/marketplace/connector/installed?open=agent-connector%3Arow-own',],['/settings/connector/legacy#section', '/marketplace/connector/installed#section'],+ ['/settings/integrations', '/marketplace/app'],+ ['/settings/integrations/github?pending=claim', '/marketplace/app/github?pending=claim'],+ [+ '/acme/settings/integrations/linear?installed=ok#done',+ '/acme/marketplace/app/linear?installed=ok#done',+ ],+ ['/settings/messenger', '/marketplace/app'],+ ['/settings/messenger/unknown', '/marketplace/app'],+ ['/settings/messenger/slack?installed=ok#link', '/marketplace/app/slack?installed=ok#link'],+ ['/acme/settings/messenger/telegram', '/acme/marketplace/app/telegram'],// Workspace scope keeps its slug.['/acme/settings/skill', '/acme/marketplace/skill/installed'],['/acme/settings/connector?open=mcp-connector%3Amwe','/acme/marketplace/connector/installed?open=mcp-connector%3Amwe',],+ ['/marketplace/connector?q=slack', '/marketplace/app?q=slack'],+ [+ '/acme/marketplace/connector?source=public&q=git#list',+ '/acme/marketplace/mcp?source=public&q=git#list',+ ],+ ['/marketplace/connector?category=search', '/marketplace/mcp?category=search'],// `/community` became `/marketplace`.- ['/marketplace', '/marketplace/connector'],- ['/community', '/marketplace/connector'],+ ['/marketplace', '/marketplace/app'],+ ['/community', '/marketplace/app'],['/community/skill?category=dev&page=2', '/marketplace/skill?category=dev&page=2'],['/community/mcp/notion', '/marketplace/mcp/notion'],- ['/acme/community', '/acme/marketplace/connector'],- ['/acme/marketplace?q=developer#results', '/acme/marketplace/connector?q=developer#results'],+ ['/acme/community', '/acme/marketplace/app'],+ ['/acme/marketplace?q=developer#results', '/acme/marketplace/app?q=developer#results'],['/acme/community/agent/some-agent#top', '/acme/marketplace/agent/some-agent#top'],['/community/agent', '/marketplace/agent'],['/community/agent/some-agent', '/marketplace/agent/some-agent'],diff --git a/src/spa/router/marketplaceRoutes.tsx b/src/spa/router/marketplaceRoutes.tsxindex 35e64fb6a6a..2b9a78943f1 100644--- a/src/spa/router/marketplaceRoutes.tsx+++ b/src/spa/router/marketplaceRoutes.tsx@@ -1,23 +1,27 @@'use client';import { Blocks, ShapesIcon } from 'lucide-react';-import type { RouteObject } from 'react-router';+import { lazy } from 'react';+import { type RouteObject, useParams, useSearchParams } from 'react-router';import CommunityListSkeleton from '@/components/Skeleton/CommunityList';import { MarketplaceCatalogSkeleton } from '@/components/Skeleton/MarketplaceCatalog';import { createSurfaceSkeleton } from '@/components/Skeleton/Surface';import {+ getLegacyConnectorCatalogPath,getMarketplaceEntryPath,LEGACY_COMMUNITY_SEGMENT,- MARKETPLACE_CONNECTOR_PATH,+ MARKETPLACE_APPS_PATH,MARKETPLACE_INSTALLED_CONNECTORS_PATH,MARKETPLACE_INSTALLED_SKILLS_PATH,MARKETPLACE_SEGMENT,+ marketplaceAppPath,} from '@/features/Marketplace/paths';import {marketplaceConnectorsRouteMeta,marketplaceInstalledSkillsRouteMeta,} from '@/features/Marketplace/routeMeta';+import { SUPPORTED_MESSENGER_PLATFORMS } from '@/features/Messenger/platforms';import { communityDetailRouteMeta } from '@/features/RouteMeta/communityRouteMeta';import {LegacyCommunityRedirect,@@ -36,6 +40,20 @@ import { dynamicElement, ErrorBoundary } from '@/utils/router';* Mobile reuses these with a shell header (`mobileRouter.config.tsx`).*/export const marketplaceManageRoutes: RouteObject[] = [+ {+ element: dynamicElement(+ () => import('@/routes/(main)/community/(manage)/mcp'),+ 'Marketplace > Installed MCP',+ ),+ handle: {+ meta: routeMeta({+ icon: Blocks,+ Skeleton: MarketplaceCatalogSkeleton,+ titleKey: 'navigation.marketplaceMcp',+ }),+ },+ path: 'mcp/installed',+ },{element: dynamicElement(() => import('@/routes/(main)/community/(manage)/skill-installed'),@@ -76,13 +94,63 @@ export const marketplaceIndexRoute: RouteObject = {index: true,};-/** `mcp` (the former MCP list) → the Connectors Discover page, query kept. */-export const marketplaceMcpListRedirect: RouteObject = {- element: <LegacyPathRedirect to={MARKETPLACE_CONNECTOR_PATH} />,+const LegacyConnectorCatalog = () => {+ const [params] = useSearchParams();+ return <LegacyPathRedirect to={getLegacyConnectorCatalogPath(params)} />;+};++export const legacyConnectorCatalogRoute: RouteObject = {+ element: <LegacyConnectorCatalog />,handle: LEGACY_REDIRECT_HANDLE,- path: 'mcp',+ path: 'connector',};+export const marketplaceAppAndMcpRoutes: RouteObject[] = [+ {+ element: dynamicElement(+ () => import('@/routes/(main)/community/(list)/app'),+ 'Marketplace > Apps',+ ),+ handle: {+ meta: routeMeta({+ icon: Blocks,+ Skeleton: MarketplaceCatalogSkeleton,+ titleKey: 'navigation.marketplaceApps',+ }),+ },+ path: 'app',+ },+ {+ element: dynamicElement(+ () => import('@/routes/(main)/community/(detail)/app'),+ 'Marketplace > App detail',+ ),+ handle: {+ meta: routeMeta({+ DynamicMeta: lazy(() => import('@/features/Marketplace/Apps/AppDynamicMeta')),+ icon: Blocks,+ Skeleton: createSurfaceSkeleton('detail'),+ titleKey: 'navigation.marketplaceApps',+ }),+ },+ path: 'app/:appId',+ },+ {+ element: dynamicElement(+ () => import('@/routes/(main)/community/(list)/mcp'),+ 'Marketplace > MCP',+ ),+ handle: {+ meta: routeMeta({+ icon: Blocks,+ Skeleton: MarketplaceCatalogSkeleton,+ titleKey: 'navigation.marketplaceMcp',+ }),+ },+ path: 'mcp',+ },+];+/*** `/marketplace/*` (and `/:workspaceSlug/marketplace/*`), formerly `/community`.* Shared by Web and Electron through `sharedMainAreaChildren`. The route id,@@ -100,9 +168,7 @@ export const marketplaceRoute: RouteObject = {},marketplaceIndexRoute,...marketplaceManageRoutes,- // The MCP list merged into Connectors; its URL (with `?category=` / `?q=`)- // forwards there. MCP detail pages stay at `mcp/:slug`.- marketplaceMcpListRedirect,+ legacyConnectorCatalogRoute,// List routes (with ListLayout){children: [@@ -163,20 +229,7 @@ export const marketplaceRoute: RouteObject = {},path: 'skill',},- {- element: dynamicElement(- () => import('@/routes/(main)/community/(list)/connector'),- 'Desktop > Discover > List > Connector',- ),- handle: {- meta: routeMeta({- icon: Blocks,- Skeleton: MarketplaceCatalogSkeleton,- titleKey: 'navigation.marketplaceConnectors',- }),- },- path: 'connector',- },+ ...marketplaceAppAndMcpRoutes,{element: dynamicElement(() => import('@/routes/(main)/community/(detail)/workspace'),@@ -323,6 +376,14 @@ export const legacyCommunityRoutes: RouteObject[] = [legacyCommunityRedirect(`${LEGACY_COMMUNITY_SEGMENT}/*`),];+const LegacyMessengerRedirect = () => {+ const { sub } = useParams();+ const platform = SUPPORTED_MESSENGER_PLATFORMS.find(({ id }) => id === sub);+ return (+ <LegacyPathRedirect to={platform ? marketplaceAppPath(platform.id) : MARKETPLACE_APPS_PATH} />+ );+};+/*** `settings/skill`, `settings/connector` and `settings/integrations` (plus their* `/:sub` forms) moved to@@ -330,20 +391,23 @@ export const legacyCommunityRoutes: RouteObject[] = [* workspace `/:workspaceSlug/settings` routes (desktop and mobile); the redirect* re-applies the slug and keeps `?open=` / `?skill=` deep links.*/+const legacySettingsLibraryRedirects: RouteObject[] = [+ ['skill', MARKETPLACE_INSTALLED_SKILLS_PATH],+ ['skill/:sub', MARKETPLACE_INSTALLED_SKILLS_PATH],+ ['connector', MARKETPLACE_INSTALLED_CONNECTORS_PATH],+ ['connector/:sub', MARKETPLACE_INSTALLED_CONNECTORS_PATH],+].map(([path, to]) => ({+ element: <LegacyPathRedirect to={to} />,+ handle: LEGACY_REDIRECT_HANDLE,+ path,+}));+export const legacySettingsMarketplaceRedirects: RouteObject[] = [- ...[- ['skill', MARKETPLACE_INSTALLED_SKILLS_PATH],- ['skill/:sub', MARKETPLACE_INSTALLED_SKILLS_PATH],- ['connector', MARKETPLACE_INSTALLED_CONNECTORS_PATH],- ['connector/:sub', MARKETPLACE_INSTALLED_CONNECTORS_PATH],- ].map(([path, to]) => ({- element: <LegacyPathRedirect to={to} />,- handle: LEGACY_REDIRECT_HANDLE,- path,- })),- ...['integrations', 'integrations/:sub'].map((path) => ({+ ...legacySettingsLibraryRedirects,+ { element: <LegacyMessengerRedirect />, handle: LEGACY_REDIRECT_HANDLE, path: 'messenger/:sub?' },+ {element: <LegacyIntegrationRedirect />,handle: LEGACY_REDIRECT_HANDLE,- path,- })),+ path: 'integrations/:sub?',+ },];diff --git a/src/spa/router/mobileRouter.config.tsx b/src/spa/router/mobileRouter.config.tsxindex d5132e4bd94..1b868fc8a75 100644--- a/src/spa/router/mobileRouter.config.tsx+++ b/src/spa/router/mobileRouter.config.tsx@@ -1,6 +1,6 @@'use client';-import { Blocks, BotIcon, Download, HomeIcon, Settings, ShapesIcon } from 'lucide-react';+import { BotIcon, Download, HomeIcon, Settings, ShapesIcon } from 'lucide-react';import type { RouteObject } from 'react-router';import {@@ -22,10 +22,11 @@ import {import { workspaceHomeRouteMeta } from '@/features/Workspace/routeMeta';import {legacyCommunityRoutes,+ legacyConnectorCatalogRoute,legacySettingsMarketplaceRedirects,+ marketplaceAppAndMcpRoutes,marketplaceIndexRoute,marketplaceManageRoutes,- marketplaceMcpListRedirect,} from '@/spa/router/marketplaceRoutes';import { mobileAgentRoute, mobileGroupRoute } from '@/spa/router/mobileAgentRoutes';import { mobileUnsupportedRoutes, mobileWorkspaceRoutes } from '@/spa/router/mobileWorkspaceRoutes';@@ -123,11 +124,12 @@ export const sharedMainAreaChildren: RouteObject[] = [// Installed skills and connectors: second-level pages with the shell's// back header (the settings layout drew it before they moved here)....overlayRoutes(marketplaceManageRoutes, {+ 'mcp/installed': withHandle({ mobileShellHeader: true }),'connector/installed': withHandle({ mobileShellHeader: true }),'skill/installed': withHandle({ mobileShellHeader: true }),}),marketplaceIndexRoute,- marketplaceMcpListRedirect,+ legacyConnectorCatalogRoute,// List routes (with ListLayout){children: [@@ -173,20 +175,7 @@ export const sharedMainAreaChildren: RouteObject[] = [},path: 'provider',},- {- element: dynamicElement(- () => import('@/routes/(main)/community/(list)/connector'),- 'Mobile > Discover > List > Connector',- ),- handle: {- meta: routeMeta({- icon: Blocks,- Skeleton: MarketplaceCatalogSkeleton,- titleKey: 'navigation.marketplaceConnectors',- }),- },- path: 'connector',- },+ ...marketplaceAppAndMcpRoutes,{element: dynamicElement(() => import('@/routes/(main)/community/(list)/skill'),diff --git a/src/spa/router/mobileRouter.test.tsx b/src/spa/router/mobileRouter.test.tsxindex 8ed53679d93..0e8b85ef7c1 100644--- a/src/spa/router/mobileRouter.test.tsx+++ b/src/spa/router/mobileRouter.test.tsx@@ -125,6 +125,7 @@ describe('mobile community route layouts', () => {describe('mobile Marketplace skill and connector pages', () => {it.each([+ ['/marketplace/mcp/installed', 'mcp/installed'],['/marketplace/skill/installed', 'skill/installed'],['/acme/marketplace/skill/installed', 'skill/installed'],['/marketplace/connector/installed', 'connector/installed'],@@ -145,9 +146,6 @@ describe('mobile Marketplace skill and connector pages', () => {['/settings/connector/sub', '/marketplace/connector/installed'],['/acme/settings/skill', '/marketplace/skill/installed'],['/acme/settings/connector', '/marketplace/connector/installed'],- // The MCP list merged into the Connectors Discover page.- ['/marketplace/mcp', '/marketplace/connector'],- ['/acme/marketplace/mcp', '/marketplace/connector'],])('redirects %s to %s', (url, to) => {const element = matchRoutes(mobileRoutes, url)?.at(-1)?.route.element asReactElement<{ to: string }> | undefined;diff --git a/src/spa/router/workspaceSettingsRoutes.tsx b/src/spa/router/workspaceSettingsRoutes.tsxindex 4a039ab207b..49ab3508f97 100644--- a/src/spa/router/workspaceSettingsRoutes.tsx+++ b/src/spa/router/workspaceSettingsRoutes.tsx@@ -455,33 +455,6 @@ export const workspaceSettingsContentRoute: RouteObject = {},path: 'chat-preference',},- {- element: dynamicElement(- () => import('@/routes/(main)/[workspaceSlug]/settings/messenger'),- 'Desktop > Workspace > Settings > Messenger',- ),- handle: {- meta: createWorkspaceSettingsRouteMeta(- WorkspaceSettingsTabs.Messenger,- createSurfaceSkeleton('list'),- ),- },- path: 'messenger',- },- // Platform detail level — the page reads the platform from `sub`.- {- element: dynamicElement(- () => import('@/routes/(main)/[workspaceSlug]/settings/messenger'),- 'Desktop > Workspace > Settings > Messenger > Platform',- ),- handle: {- meta: createWorkspaceSettingsRouteMeta(- WorkspaceSettingsTabs.Messenger,- createSurfaceSkeleton('list'),- ),- },- path: 'messenger/:sub',- },// Developer tools mirrored inside the workspace (user preferences).{element: dynamicElement(diff --git a/src/store/global/initialState.ts b/src/store/global/initialState.tsindex 70568bb7a77..9c205120ef0 100644--- a/src/store/global/initialState.ts+++ b/src/store/global/initialState.ts@@ -94,7 +94,6 @@ export enum SettingsTabs {Labs = 'labs',LLM = 'llm',Memory = 'memory',- Messenger = 'messenger',Notification = 'notification',OAuthApps = 'oauth-apps',// businessdiff --git a/src/store/integration/action.ts b/src/store/integration/action.tsindex 1304786055b..4c6d25af4c6 100644--- a/src/store/integration/action.ts+++ b/src/store/integration/action.ts@@ -26,6 +26,12 @@ export class IntegrationActionImpl {this.#set(initialIntegrationState, false, n('reset'));};+ useFetchGithubInstallations = (enabled: boolean) =>+ this.#private.scmInstallations.useSync(INTEGRATION_PARAMS, {+ dedupingInterval: DEDUPING_INTERVAL,+ enabled,+ });+/** Config, identity and installations of the GitHub integration; flags of all three. */useFetchGithub = () => {const options = { dedupingInterval: DEDUPING_INTERVAL };diff --git a/src/types/workspaceSettings.ts b/src/types/workspaceSettings.tsindex 0ca47473c23..7b2000a97ff 100644--- a/src/types/workspaceSettings.ts+++ b/src/types/workspaceSettings.ts@@ -25,7 +25,6 @@ export enum WorkspaceSettingsTabs {Labels = 'labels',Labs = 'labs',Members = 'members',- Messenger = 'messenger',Notification = 'notification',OAuthApps = 'oauth-apps',Plans = 'plans',