Skip to main content
Glama
Microsoft Fabric MCP Server

Microsoft Fabric MCP Server

by og-mcp

Microsoft Fabric MCP Server

A production-grade Model Context Protocol server for Microsoft Fabric. Exposes Fabric operations as MCP tools over stdio (local) and Streamable HTTP (hosted/multi-user).

  • TypeScript (ESM, Node 20+), REST-only (Fabric has no typed SDK)

  • Transparent Long-Running Operation (LRO) handling — 202 + Location is polled to completion automatically

  • Three auth modes: Azure CLI (az login), Service Principal (deploy path — Fabric has no PAT), OBO + Entra JWT (hosted)

  • Per-tool RBAC, destructive-op guard, secret redaction, structured logging, retry + per-host circuit breaker

  • Wraps the Fabric REST API, the Power BI API, and OneLake (per-resource token scopes)

Status: All phases complete — 105 tools across 17 domains, plus 4 resources and 4 prompts:

  • core (11) · items (7) · lakehouses (7) · warehouses (4) · sqlendpoints (3) · shortcuts (4)

  • notebooks (6) · pipelines (6) · jobs (6) · spark (6)

  • semanticmodels (5) · reports (3) · dataflows (5)

  • realtime (12: eventhouses, KQL databases, eventstreams) · onelake (5: files/dirs via DFS)

  • git (7: workspace Git integration) · platform (8: deployment pipelines, connections, gateways)

  • Resources: fabric://workspaces, fabric://workspace/{w}/items, …/lakehouses, …/item/{id}

  • Prompts: medallion-architecture, document-workspace, build-etl, diagnose-refresh

Hardening: per-host circuit breaker, retry + Retry-After, transparent LRO polling, secret redaction, per-tool RBAC + destructive guard, audit logging, ESLint, Vitest suite (unit + live MCP-protocol test), Azure Pipelines CI.


1. Prerequisites

  • Node.js ≥ 20

  • A Fabric-enabled tenant and an identity with a Fabric/Power BI license (or a service principal enabled for Fabric APIs and added to the workspaces)

  • One of: Azure CLI (az login), a service principal, or (hosted) an Entra app for OBO

Related MCP server: powerbi-mcp

2. Install & configure

cd "E:\MCP Servers\fabric-mcp-server"
npm install
cp .env.example .env   # PowerShell: Copy-Item .env.example .env

Minimum for local use with the Azure CLI:

AUTH_MODE=azcli
FABRIC_DEFAULT_WORKSPACE=        # optional default workspace ID

Auth modes

AUTH_MODE

Needs

Notes

azcli

az login

Easiest for dev. Token minted for the Fabric scope.

sp

AZURE_TENANT_ID, AZURE_CLIENT_ID, AZURE_CLIENT_SECRET

Deployment path. The SP must be enabled in Fabric tenant settings and added to the workspaces.

obo

same three

HTTP transport only. Validates the caller's Entra JWT, then exchanges it per resource (preserves user identity).

3. Build & run

npm run build && npm start        # stdio (default)
node dist/index.js --transport http   # Streamable HTTP on PORT (default 3100)

4. Connect a client (npx)

{
  "mcpServers": {
    "fabric": {
      "command": "npx",
      "args": ["-y", "fabric-mcp-server"],
      "env": { "AUTH_MODE": "azcli", "FABRIC_DEFAULT_WORKSPACE": "<workspace-id>" }
    }
  }
}

For deployment use AUTH_MODE=sp with the three AZURE_* env vars.

5. Scripts

Script

Purpose

npm run build

Compile TypeScript → dist/

npm start / start:http

Run compiled server (stdio / HTTP)

npm run dev / dev:http

Watch-mode dev (tsx)

npm run typecheck · lint · test · ci

Quality gates

6. Architecture

transport (stdio | http)
  → server (McpServer + registry)
    → dispatch (RBAC · destructive guard · audit · error envelope)
      → domain tools (Zod schemas)
        → domain services
          → FabricClient (REST + retry + circuit breaker + LRO polling)
            → credential (AzCli | ServicePrincipal | OBO) → per-resource token

Each Fabric area is a self-contained module under src/domains/<area>/ exporting a DomainModule. To add an area, create the module and append it to domains in src/server.ts.

Key Fabric specifics: every write is an LRO (handled in src/client/fabricClient.ts); item definitions (notebooks, pipelines) are base64 file parts (helpers in src/domains/_shared.ts); tokens are acquired per resource (Fabric / Power BI / OneLake).

Full walkthrough: see docs/END_TO_END_FLOW.md for how a request travels through every layer (startup, a tool call step by step, the LRO + item-definition mechanisms, auth/scope flows, resources/prompts, and a worked medallion-ETL example).

Available Tools

105 tools
fabric_add_workspace_role_assignmentB

Add a member (user/group/service principal) to a workspace with a role (Admin/Member/Contributor/Viewer).

Inputs: principalId (required), principalType (required), role (required), workspace.

fabric_assign_workspace_to_capacityC

Assign a workspace to a capacity.

Inputs: capacityId (required), workspace.

fabric_cancel_jobB

Cancel a running job instance.

Inputs: itemId (required), jobInstanceId (required), workspace.

fabric_create_dataflowC

Create a Dataflow Gen2.

Inputs: displayName (required), description, workspace.

fabric_create_eventhouseC

Create an eventhouse.

Inputs: displayName (required), description, workspace.

fabric_create_eventstreamC

Create an eventstream.

Inputs: displayName (required), description, workspace.

fabric_create_itemA

Create any Fabric item by type, optionally with a definition (file parts). Use the type-specific tools for richer ergonomics.

Inputs: displayName (required), type (required), description, definitionParts, +1 more.

fabric_create_job_scheduleB

Create a schedule for an item's job. configuration is the Fabric schedule object, e.g. {"type":"Daily","startDateTime":"2026-01-01T00:00:00","times":["09:00"],"localTimeZoneId":"UTC"}.

Inputs: itemId (required), jobType (required), configuration (required), enabled, +1 more.

fabric_create_kql_databaseC

Create a KQL database under an eventhouse.

Inputs: displayName (required), eventhouseId (required), description, workspace.

fabric_create_lakehouseC

Create a lakehouse, optionally schema-enabled.

Inputs: displayName (required), description, enableSchemas, workspace.

fabric_create_notebookA

Create a notebook. Optionally populate cells at creation and attach a default lakehouse.

Inputs: displayName (required), description, cells, defaultLakehouse, +1 more.

fabric_create_pipelineB

Create a data pipeline, optionally with activities + parameters.

Inputs: displayName (required), description, activities, parameters, +1 more.

fabric_create_shortcutB

Create a OneLake shortcut. target is the source definition, e.g. {"oneLake":{"workspaceId":"...","itemId":"...","path":"Tables/x"}} or {"adlsGen2":{...}} / {"amazonS3":{...}}.

Inputs: itemId (required), path (required), name (required), target (required), +1 more.

fabric_create_spark_job_definitionC

Create a Spark job definition.

Inputs: displayName (required), description, workspace.

fabric_create_warehouseC

Create a data warehouse.

Inputs: displayName (required), description, workspace.

fabric_create_workspaceC

Create a new workspace, optionally bound to a capacity.

Inputs: displayName (required), description, capacityId.

fabric_delete_connectionB
Destructive

Delete a connection. Destructive.

Inputs: id (required).

fabric_delete_dataflowB
Destructive

Delete a Dataflow Gen2. Destructive.

Inputs: dataflowId (required), workspace.

fabric_delete_eventhouseB
Destructive

Delete an eventhouse. Destructive.

Inputs: id (required), workspace.

fabric_delete_eventstreamC
Destructive

Delete an eventstream. Destructive.

Inputs: id (required), workspace.

fabric_delete_itemC
Destructive

Delete an item by ID. Destructive.

Inputs: itemId (required), workspace.

fabric_delete_kql_databaseB
Destructive

Delete a KQL database. Destructive.

Inputs: id (required), workspace.

fabric_delete_lakehouseB
Destructive

Delete a lakehouse. Destructive.

Inputs: lakehouseId (required), workspace.

fabric_delete_reportB
Destructive

Delete a report. Destructive.

Inputs: reportId (required), workspace.

fabric_delete_semantic_modelB
Destructive

Delete a semantic model. Destructive.

Inputs: modelId (required), workspace.

fabric_delete_shortcutB
Destructive

Delete a OneLake shortcut by path + name. Destructive.

Inputs: itemId (required), shortcutPath (required), name (required), workspace.

fabric_delete_warehouseC
Destructive

Delete a warehouse. Destructive.

Inputs: warehouseId (required), workspace.

fabric_delete_workspaceB
Destructive

Delete a workspace. Destructive.

Inputs: workspace.

fabric_delete_workspace_role_assignmentB
Destructive

Remove a role assignment from a workspace. Destructive.

Inputs: assignmentId (required), workspace.

fabric_deploy_stageA
Destructive

Deploy content from one deployment-pipeline stage to the next (long-running). Destructive — promotes content.

Inputs: id (required), sourceStageId (required), targetStageId (required), note, +1 more.

fabric_get_connectionA
Read-only

Get a connection by ID.

Inputs: id (required).

fabric_get_dataflowB
Read-only

Get a Dataflow Gen2 by ID.

Inputs: dataflowId (required), workspace.

fabric_get_deployment_pipelineA
Read-only

Get a deployment pipeline by ID.

Inputs: id (required).

fabric_get_deployment_stagesA
Read-only

Get the stages of a deployment pipeline.

Inputs: id (required).

fabric_get_eventhouseA
Read-only

Get an eventhouse by ID.

Inputs: id (required), workspace.

fabric_get_eventstreamB
Read-only

Get an eventstream by ID.

Inputs: id (required), workspace.

fabric_get_itemA
Read-only

Get a single item by ID.

Inputs: itemId (required), workspace.

fabric_get_item_definitionA
Read-only

Fetch an item's full definition (long-running). Returns the raw definition and decoded file contents.

Inputs: itemId (required), format, workspace.

fabric_get_job_instanceB
Read-only

Get the status/details of a job instance.

Inputs: itemId (required), jobInstanceId (required), workspace.

fabric_get_kql_databaseA
Read-only

Get a KQL database by ID.

Inputs: id (required), workspace.

fabric_get_lakehouseA
Read-only

Get a lakehouse (includes its SQL endpoint + OneLake paths).

Inputs: lakehouseId (required), workspace.

fabric_get_notebookA
Read-only

Get a notebook by ID.

Inputs: notebookId (required), workspace.

fabric_get_notebook_definitionA
Read-only

Fetch a notebook's definition and decoded cell source (long-running).

Inputs: notebookId (required), workspace.

fabric_get_pipelineA
Read-only

Get a data pipeline by ID.

Inputs: pipelineId (required), workspace.

fabric_get_pipeline_definitionA
Read-only

Fetch a pipeline's definition (activities/parameters) decoded (long-running).

Inputs: pipelineId (required), workspace.

fabric_get_reportB
Read-only

Get a report by ID.

Inputs: reportId (required), workspace.

fabric_get_semantic_modelB
Read-only

Get a semantic model by ID.

Inputs: modelId (required), workspace.

fabric_get_semantic_model_refresh_historyB
Read-only

Get the refresh history of a semantic model.

Inputs: modelId (required), workspace.

fabric_get_shortcutA
Read-only

Get a single OneLake shortcut by path + name.

Inputs: itemId (required), shortcutPath (required), name (required), workspace.

fabric_get_spark_job_definitionA
Read-only

Get a Spark job definition by ID.

Inputs: id (required), workspace.

fabric_get_sql_endpointA
Read-only

Get a SQL analytics endpoint (connection string, etc.).

Inputs: sqlEndpointId (required), workspace.

fabric_get_warehouseB
Read-only

Get a warehouse (includes its SQL connection string).

Inputs: warehouseId (required), workspace.

fabric_get_workspaceA
Read-only

Get a workspace by ID.

Inputs: workspace.

fabric_git_commitC

Commit workspace changes to Git (mode All or Selective).

Inputs: mode, comment, items, workspaceHead, +1 more.

fabric_git_connectB

Connect a workspace to a Git repository. gitProviderDetails = { gitProviderType: "AzureDevOps"|"GitHub", organizationName, projectName, repositoryName, branchName, directoryName }.

Inputs: gitProviderDetails (required), workspace.

fabric_git_disconnectB
Destructive

Disconnect a workspace from Git. Destructive.

Inputs: workspace.

fabric_git_get_connectionA
Read-only

Get a workspace's Git connection.

Inputs: workspace.

fabric_git_get_statusA
Read-only

Get the Git status (changes) of a workspace.

Inputs: workspace.

fabric_git_initializeC

Initialize the Git connection (after connect) to sync direction.

Inputs: workspace.

fabric_git_update_from_gitC

Update the workspace from the remote Git commit.

Inputs: remoteCommitHash (required), conflictResolutionPolicy, workspaceHead, workspace.

fabric_list_capacitiesA
Read-only

List the capacities the caller can access.

Inputs: no named parameters.

fabric_list_connectionsC
Read-only

List connections.

Inputs: no named parameters.

fabric_list_dataflowsA
Read-only

List Dataflow Gen2 items in a workspace.

Inputs: workspace.

fabric_list_deployment_pipelinesB
Read-only

List deployment pipelines.

Inputs: no named parameters.

fabric_list_eventhousesB
Read-only

List eventhouses in a workspace.

Inputs: workspace.

fabric_list_eventstreamsC
Read-only

List eventstreams in a workspace.

Inputs: workspace.

fabric_list_gatewaysB
Read-only

List gateways.

Inputs: no named parameters.

fabric_list_itemsB
Read-only

List items in a workspace, optionally filtered by type (Lakehouse, Notebook, DataPipeline, Warehouse, SemanticModel, Report, …).

Inputs: workspace, type.

fabric_list_job_instancesB
Read-only

List job instances (runs) for an item.

Inputs: itemId (required), workspace.

fabric_list_job_schedulesB
Read-only

List schedules configured for an item's job type.

Inputs: itemId (required), jobType (required), workspace.

fabric_list_kql_databasesA
Read-only

List KQL databases in a workspace.

Inputs: workspace.

fabric_list_lakehousesC
Read-only

List lakehouses in a workspace.

Inputs: workspace.

fabric_list_lakehouse_tablesB
Read-only

List the Delta tables in a lakehouse.

Inputs: lakehouseId (required), workspace.

fabric_list_livy_sessionsB
Read-only

List Spark Livy sessions in a workspace.

Inputs: workspace.

fabric_list_notebooksB
Read-only

List notebooks in a workspace.

Inputs: workspace.

fabric_list_pipelinesA
Read-only

List data pipelines in a workspace.

Inputs: workspace.

fabric_list_reportsC
Read-only

List reports in a workspace.

Inputs: workspace.

fabric_list_semantic_modelsC
Read-only

List semantic models (datasets) in a workspace.

Inputs: workspace.

fabric_list_shortcutsA
Read-only

List OneLake shortcuts on an item (e.g. a lakehouse).

Inputs: itemId (required), workspace.

fabric_list_spark_custom_poolsA
Read-only

List the custom Spark pools in a workspace.

Inputs: workspace.

fabric_list_spark_job_definitionsA
Read-only

List Spark job definitions in a workspace.

Inputs: workspace.

fabric_list_sql_endpointsA
Read-only

List SQL analytics endpoints in a workspace.

Inputs: workspace.

fabric_list_warehousesB
Read-only

List warehouses in a workspace.

Inputs: workspace.

fabric_list_workspace_role_assignmentsA
Read-only

List role assignments (members) on a workspace.

Inputs: workspace.

fabric_list_workspacesA
Read-only

List all Fabric workspaces the caller can access.

Inputs: no named parameters.

fabric_load_lakehouse_tableB

Load a file/folder in OneLake into a Delta table (long-running).

Inputs: lakehouseId (required), tableName (required), relativePath (required), pathType (required), +4 more.

fabric_onelake_create_directoryC

Create a directory in OneLake.

Inputs: path (required), workspace.

fabric_onelake_delete_pathC
Destructive

Delete a file or directory in OneLake. Destructive.

Inputs: path (required), recursive, workspace.

fabric_onelake_list_pathsA
Read-only

List files/directories under a OneLake directory (e.g. "{lakehouseId}/Files").

Inputs: directory (required), recursive, workspace.

fabric_onelake_read_fileA
Read-only

Read a text file from OneLake.

Inputs: path (required), workspace.

fabric_onelake_write_fileB

Write a (small) text file to OneLake (create → append → flush).

Inputs: path (required), content (required), workspace.

fabric_refresh_semantic_modelB

Trigger an asynchronous refresh of a semantic model.

Inputs: modelId (required), workspace.

fabric_refresh_sql_endpoint_metadataA

Sync a SQL analytics endpoint's metadata with its source lakehouse (long-running).

Inputs: sqlEndpointId (required), workspace.

fabric_run_dataflowB

Run (refresh) a Dataflow Gen2 on demand.

Inputs: dataflowId (required), workspace.

fabric_run_jobC

Run an on-demand job for any item, by job type. Optionally pass executionData.

Inputs: itemId (required), jobType (required), executionData, workspace.

fabric_run_notebookC

Run a notebook on demand. Optionally pass executionData (parameters, configuration).

Inputs: notebookId (required), executionData, workspace.

fabric_run_pipelineC

Run a data pipeline on demand. Optionally pass executionData (parameters).

Inputs: pipelineId (required), executionData, workspace.

fabric_run_spark_job_definitionC

Run a Spark job definition on demand.

Inputs: id (required), workspace.

fabric_run_table_maintenanceB

Run table maintenance (OPTIMIZE / V-Order / VACUUM) on a lakehouse table (long-running).

Inputs: lakehouseId (required), tableName (required), schemaName, optimize, +3 more.

fabric_unassign_workspace_from_capacityA

Unassign a workspace from its capacity.

Inputs: workspace.

fabric_update_itemC

Update an item's name/description.

Inputs: itemId (required), displayName, description, workspace.

fabric_update_item_definitionC

Replace an item's definition from file parts (long-running).

Inputs: itemId (required), parts (required), workspace.

fabric_update_notebook_definitionA

Replace a notebook's cells (long-running). Optionally attach a default lakehouse.

Inputs: notebookId (required), cells (required), defaultLakehouse, workspace.

fabric_update_pipeline_definitionB

Replace a pipeline's activities + parameters (long-running).

Inputs: pipelineId (required), activities (required), parameters, workspace.

fabric_update_workspaceB

Update a workspace name/description.

Inputs: workspace, displayName, description.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.8/5.0

    Scored across 105 tools

    Disambiguation2/5

    The generic item/job tools (fabric_get_item, fabric_delete_item, fabric_run_job, fabric_get_item_definition) overlap directly with type-specific tools (fabric_get_lakehouse, fabric_delete_lakehouse, fabric_run_notebook, fabric_get_notebook_definition), so an agent can easily select the wrong one for the same resource and action. Descriptions help in some cases, but the boundaries between generic and type-specific tools are repeatedly unclear.

    Naming Consistency4/5

    Tools consistently use the fabric_ prefix and mostly follow a verb_noun snake_case pattern (list/get/create/update/delete/run). Minor inconsistencies exist, such as domain-prefixed names like fabric_onelake_* and fabric_git_*, add vs create for role assignments, and generic vs type-specific definition/run tools.

    Tool Count1/5

    105 tools is an extreme count for an MCP tool surface, far beyond even the 25+ threshold. Many tools duplicate generic item operations (list_items vs list_lakehouses, delete_item vs delete_lakehouse, etc.), which inflates the count without adding proportional coherence.

    Completeness4/5

    The server covers most major Fabric domains—workspaces, lakehouses, warehouses, notebooks, pipelines, semantic models, shortcuts, Git, deployment pipelines, and jobs—and the generic item tools fill many lifecycle gaps. Some areas remain asymmetric (connections/gateways/capacities are mostly read/list-only, reports/semantic models lack direct create/update), but agents can often work around these via generic tools.

    Maintenance

    ActivityInactive
    ResponsivenessLimited data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      C
      maintenance
      Enables AI agents to interact with Microsoft Fabric by exposing tools for managing workspaces, notebooks, SQL queries, pipelines, and Livy Spark sessions. It provides a comprehensive set of operations for data engineering and analytics tasks using standard Azure authentication.
      37
      4
      MIT
    • F
      license
      C
      quality
      D
      maintenance
      A Python MCP server that lets you manage Microsoft Fabric through natural language in Claude Code or Claude Desktop, with 77+ tools covering workspaces, lakehouses, warehouses, SQL, DAX, semantic models, notebooks, pipelines, OneLake, and Microsoft Graph.
      83
      -
    • A
      license
      A
      quality
      D
      maintenance
      Exposes Azure AI Foundry agents, workflows, and AI Search vector-database capabilities as MCP tools, enabling natural language interaction with agents, semantic search, and index management.
      10
      2
      MIT