powerbi-mcp-server

powerbi-mcp-server

An MCP server that connects Claude and other MCP clients to Microsoft Power BI via its REST API using a Service Principal, enabling natural language queries to list workspaces, run DAX queries, refresh datasets, and explore reports.

Category
Visit Server

README

powerbi-mcp

An MCP server that connects Claude (and any MCP-compatible client) to Microsoft Power BI via the Power BI REST API using a Service Principal.

Tools exposed

Tool Description
list_workspaces List all workspaces the SP has access to
list_datasets List datasets in a workspace (or all)
execute_dax_query Run a DAX query against a dataset and get results
refresh_dataset Trigger an on-demand dataset refresh
list_reports List reports in a workspace (or all)
get_report_pages Get all pages in a report
get_report_visuals Get all visuals on a report page

Prerequisites

  1. Azure App Registration with these Power BI API permissions (Application, not Delegated):

    • Dataset.Read.All
    • Dataset.ReadWrite.All (for refresh)
    • Report.Read.All
    • Workspace.Read.All
  2. In Power BI Admin Portal → Tenant settings, enable:

    • Allow service principals to use Power BI APIs
    • Add the security group containing your App Registration
  3. Add the service principal as a Member or Admin to the workspaces you want to access.

Setup

# Clone and install
git clone <this-repo>
cd powerbi-mcp-server
pip install -e .

# Copy and fill in credentials
cp .env.example .env
# Edit .env with your tenant ID, client ID, client secret

Configure in Claude Code / Claude Desktop

Add this to your MCP configuration (~/.claude/claude_desktop_config.json for Desktop, or claude mcp add for Claude Code):

{
  "mcpServers": {
    "powerbi": {
      "command": "python",
      "args": ["-m", "powerbi_mcp"],
      "env": {
        "POWERBI_TENANT_ID": "your-tenant-id",
        "POWERBI_CLIENT_ID": "your-client-id",
        "POWERBI_CLIENT_SECRET": "your-client-secret"
      }
    }
  }
}

Or using uv (no install needed):

{
  "mcpServers": {
    "powerbi": {
      "command": "uvx",
      "args": ["--from", "/path/to/powerbi-mcp-server", "powerbi-mcp"],
      "env": {
        "POWERBI_TENANT_ID": "...",
        "POWERBI_CLIENT_ID": "...",
        "POWERBI_CLIENT_SECRET": "..."
      }
    }
  }
}

Claude Code CLI

claude mcp add powerbi \
  --command python \
  --args "-m powerbi_mcp" \
  -e POWERBI_TENANT_ID=your-tenant-id \
  -e POWERBI_CLIENT_ID=your-client-id \
  -e POWERBI_CLIENT_SECRET=your-client-secret

Example prompts

Once connected, you can ask Claude:

  • "List all Power BI workspaces I have access to."
  • "Run this DAX query on dataset abc-123: EVALUATE SUMMARIZE(Sales, Sales[Region], "Total", SUM(Sales[Amount]))"
  • "Refresh the dataset named 'Monthly Sales' in the Finance workspace."
  • "Show me all the pages and visuals in the Executive Dashboard report."

Development

pip install -e ".[dev]"
python -m powerbi_mcp   # runs the MCP server via stdio

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured