FabricFabricSDK
Portal SDK

Agents

Trigger Fabric agents conversationally — list them, inspect their capabilities, chat with them.

Agents are the configured assistants that live in your Fabric portal — each has its own system prompt, model selection, tool grants, and authority scope. From an external MCP client (like Claude Desktop), you can enumerate them and chat with them as if they were participants in your conversation.

fabric_list_agents

> What agents does the engineering org have?

Input:

{
  projectId?: string,        // filter to project-scoped agents
  limit?: number,
  cursor?: string
}

Output:

{
  agents: Array<{
    id, slug, name, description,
    projectId,
    model,                  // e.g. "claude-haiku-4-5"
    isShared,
    createdAt, updatedAt
  }>,
  nextCursor?: string
}

fabric_get_agent_capabilities

> What can the migration-planner agent do?

Input: { agentIdOrSlug: string }

Output:

{
  agent: { id, slug, name, description, model },
  systemPrompt: string,
  tools: Array<{ name, description }>,
  authority: { resource, level }[]
}

The tools array is the union of MCP servers connected to the agent plus its native portal tools. The authority array describes what the agent is allowed to do without prompting for approval.

fabric_chat_with_agent

This is the trigger primitive — send the agent a message and get its response.

> Ask the migration-planner agent to draft a phase plan for the Postgres 16 upgrade.

Input:

{
  agentIdOrSlug: string,
  message: string,
  chatId?: string,           // continue an existing chat; omit to start fresh
  stream?: boolean           // default false (returns final message)
}

Output (non-streaming):

{
  chatId: string,
  message: {
    role: "assistant",
    content: string,
    toolCalls?: Array<{ name, input, output }>,
    citations?: Array<{ documentId, snippet, score }>
  },
  usage: { promptTokens, completionTokens, totalTokens }
}

The agent may call its own tools mid-turn (RAG queries, integration calls, workflow triggers). Those calls are recorded on the resulting message and visible in the portal's chat history alongside.

Patterns

Fan-out: list agents, then chat with several in parallel and aggregate the responses.

Hand-off: ask agent A something, take its output, send to agent B with different authority scope. The portal's audit log records both hops.

Stateful conversations: keep the chatId from the first response and pass it back on subsequent calls — the agent retains full conversation history server-side.