The open-source agent harness - the runtime layer that turns an LLM into a working agent.
chore [composeer]: show only authenticated or no auth connectors in composer (#87)
sayan-truefoundryc6a4dfd8e7d2
diff --git a/packages/frontend/README.md b/packages/frontend/README.mdindex ba313fc89..bc77815cf 100644--- a/packages/frontend/README.md+++ b/packages/frontend/README.md@@ -69,7 +69,7 @@ callbacks; `App.tsx` spreads them into `createTrueFoundryServer` (settings CRUD| Callback | Source || -------------- | ----------------------------------------------------------------- || `getModels` | `GET /api/v1/models` (also seeds `defaultAgentSpec.model`) |-| `getMcp` | `GET /api/v1/mcp-servers` |+| `getMcp` | `GET /api/v1/settings/mcp-servers` (carries auth status) || `getSkills` | `GET /api/v1/skills` when `GET /api/v1/capabilities` has skill on || `searchAgents` | Empty — Harness has no agent registry || `saveAgent` | Rejects — sessions are draft-only |diff --git a/packages/frontend/src/composerLists.ts b/packages/frontend/src/composerLists.tsindex a548f734a..abf376302 100644--- a/packages/frontend/src/composerLists.ts+++ b/packages/frontend/src/composerLists.ts@@ -9,9 +9,8 @@ export async function listModels(): Promise<Harness.Model[]> {const body = await client.models.list();return body.data;}--export async function listMcpServers(): Promise<Harness.McpServerReadEntry[]> {- const body = await client.mcpServers.list();+export async function listConfiguredMcpServers(): Promise<Harness.ConfiguredMcpServer[]> {+ const body = await client.settings.mcpServers.list();return body.data;}diff --git a/packages/frontend/src/harnessBuilderServer.ts b/packages/frontend/src/harnessBuilderServer.tsindex ec053cbde..f2273b83f 100644--- a/packages/frontend/src/harnessBuilderServer.ts+++ b/packages/frontend/src/harnessBuilderServer.ts@@ -3,7 +3,8 @@* Composer pickers + agent library stubs (Harness has no agent registry).*/import type { AgentBuilderServer } from '@truefoundry/trueforge-ui';-import { getCapabilities, listMcpServers, listModels, listSkills } from './composerLists';+import { getCapabilities, listConfiguredMcpServers, listModels, listSkills } from './composerLists';+import { toUiConnector } from './connectorCatalog';import type { HarnessAgentSpec } from './harnessServer';/** Harness model names are `provider/model`. */@@ -21,8 +22,7 @@ export function createHarnessBuilderServer(): AgentBuilderServer<HarnessAgentSpe? skills.map(skill => ({ id: skill.name, name: skill.name, description: skill.description })): [];},- getMcp: async () =>- (await listMcpServers()).map(server => ({ id: server.name, name: server.name, description: server.url })),+ getMcp: async () => (await listConfiguredMcpServers()).map(toUiConnector),searchAgents: () => Promise.resolve([]),saveAgent: () => Promise.reject(new Error('Harness has no agent registry — sessions are draft-only')),};diff --git a/packages/trueforge-ui-sdk/src/atoms/draft/DraftCompositeSelector.tsx b/packages/trueforge-ui-sdk/src/atoms/draft/DraftCompositeSelector.tsxindex 7fb448d35..d3a165472 100644--- a/packages/trueforge-ui-sdk/src/atoms/draft/DraftCompositeSelector.tsx+++ b/packages/trueforge-ui-sdk/src/atoms/draft/DraftCompositeSelector.tsx@@ -129,13 +129,20 @@ export function DraftCompositeSelector({ disabled, isRunning, onAttach }: DraftCreturn () => document.removeEventListener('mousedown', handler);}, [open]);+ // Keep unavailable selections visible so users can remove them.+ // Hosts that omit auth info keep their connectors selectable.+ const selectableConnectors = useMemo(+ () => connectors.filter(c => selectedMcpIds.has(c.id) || c.authenticated || !c.requiresAuth),+ [connectors, selectedMcpIds],+ );+const filteredConnectors = useMemo(() => {const needle = query.trim().toLowerCase();- if (!needle) return connectors;- return connectors.filter(+ if (!needle) return selectableConnectors;+ return selectableConnectors.filter(c => c.name.toLowerCase().includes(needle) || (c.description?.toLowerCase().includes(needle) ?? false),);- }, [connectors, query]);+ }, [selectableConnectors, query]);const filteredSkills = useMemo(() => {const needle = query.trim().toLowerCase();diff --git a/packages/trueforge-ui-sdk/src/server/types.ts b/packages/trueforge-ui-sdk/src/server/types.tsindex 8f2efa8f2..6a91c5edf 100644--- a/packages/trueforge-ui-sdk/src/server/types.ts+++ b/packages/trueforge-ui-sdk/src/server/types.ts@@ -31,6 +31,10 @@ export interface ConnectorState {id: string;name: string;description?: string;+ /** When true, the connector must be authenticated before use. Omitted when the host does not report auth. */+ requiresAuth?: boolean;+ /** When true, the connector is already authenticated. Omitted when the host does not report auth. */+ authenticated?: boolean;}/** Agents library row — UI shows name only. Host extends for metadata. */