
enelyse/powerbi-mcp-server
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
Claude による Power BI デスクトップを制御するための MCP サーバー
概要
⚠️ – API や動作が通知なしで変更される場合があります。 Power BI デスクトップ MCP Server では、Claude (または MCP クライアント) は、自然言語を使用して、実行中の Power BI デスクトップインスタンスに話します。 Model Context プロトコルを Tabular オブジェクトモデルに橋渡しするので、チャットを離れずに DAX を検査、最適化、作成できます。 ステップバイステップの設定(パワーBI前提条件、.NETライブラリ、環境変数)は、INSTALLATION.mdに住んでいます。 現在のPower BIモデルの表をリストします。 - .env.exampleを.envにコピーし、Microsoft Analysis Services DLLが自動検出されていない場合は、TOM DLL PATHを設定します。 オプション変数には、LOG LEVEL、MCP KNOWLEDGE BASE、POWERBI WORKSPACE NAME が含まれます。 - Claude Desktop(またはMCPホスト)にCLIエントリーポイントを追加します。 - CLIは、python -m powerbi mcpの周りの細いラッパーです。 サーバは、デプロイメントとデバッグのどちらの呼び出しでも動作します.
概要(AI 翻訳)
⚠️Alpha version - APIと動作は通知なしで変更される場合があります。
Power BI デスクトップ MCP Server では、Claude (または MCP クライアント) は、自然言語を使用して、実行中の Power BI デスクトップインスタンスに話します。 Model Context プロトコルを Tabular オブジェクトモデルに橋渡しするので、チャットを離れずに DAX を検査、最適化、作成できます。
インストール
ステップバイステップの設定(パワーBI前提条件、.NETライブラリ、環境変数)は、INSTALLATION.mdに住んでいます。
ローカル開発のため:
クイック例
現在のPower BIモデルの表をリストします。
知識ベースへの輸出措置:
式でオプティマイザを実行します。
設定
-
[
.env.exampleを.env]にコピーし、Microsoft Analysis Services DLLが自動検出されていない場合は[[TOM_DLL_PATH]を設定してください。 オプション変数は[[LOG_LEVEL,MCP_KNOWLEDGE_BASE], [POWERBI_WORKSPACE_NAME]を含みます。 -
Claudeデスクトップ(または任意のMCPホスト)にCCLエントリーポイントを追加します。
-
CLI は
python -m powerbi_mcp.serverの周りの細いラッパーなので、デプロイやデバッグのための呼び出し作業も行います。
##特徴
- DAXコード生成と測定作成
- 測定およびテーブルメタデータ検査
- DAXオプティマイザとルールベースの提案
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
Power BI Desktop MCP Server
⚠️ Alpha version – APIs and behaviours may change without notice.
Power BI Desktop MCP Server lets Claude (or any MCP client) talk to a running Power BI Desktop instance using natural language. It bridges the Model Context Protocol to the Tabular Object Model so you can inspect, optimize, and author DAX without leaving chat.
Installation
Step-by-step setup (Power BI prerequisites, .NET libraries, environment variables) lives in INSTALLATION.md.
For local development:
pip install -e .
# or install from the current directory:
pip install .
Quick Example
List the tables in your current Power BI model:
python examples/list_model_info.py --include-columns
Export measures to the knowledge base:
python examples/export_measures_to_knowledge_base.py --project "Executive Dashboard"
Run the optimizer on an expression:
python examples/optimize_dax.py --expr "CALCULATE(SUM(Sales[Amount]), FILTER(ALL(Date), Date[Year] = 2024))"
Configuration
-
Copy
.env.exampleto.envand setTOM_DLL_PATHif the Microsoft Analysis Services DLLs are not auto-detected. Optional variables includeLOG_LEVEL,MCP_KNOWLEDGE_BASE, andPOWERBI_WORKSPACE_NAME. -
Add the CLI entry point to Claude Desktop (or any MCP host):
{ "mcpServers": { "powerbi": { "command": "powerbi-mcp-server", "args": [] } } } -
The CLI is a thin wrapper around
python -m powerbi_mcp.server, so either invocation works for deployments and debugging.
Features
- DAX code generation and measure creation
- Measure and table metadata inspection
- DAX optimizer with rule-based suggestions
- TMDL import/export helpers
- Knowledge base bridge for storing curated measures
- Example scripts for quick automation (
examples/directory)
Known Issues
- Power BI visuals live outside the XMLA endpoint, so visual creation/editing is not supported.
- The server connects to the most recently opened Power BI Desktop workspace; multiple instances are not yet multiplexed.
- Write operations require the Power BI model to allow external tools and, in some scenarios, elevated permissions.
pythonnetrelies on local Microsoft Analysis Services DLLs; misconfiguredTOM_DLL_PATHis the most common setup failure.
Contributing
Pull requests are welcome. Please:
- Open an issue describing the change if it alters behaviour or APIs.
- Keep additions formatted with
ruff/blackstyle conventions (if configured) and include type hints. - Add or update example scripts/tests where it helps illustrate new functionality.
インストール
This server does not publish a one-line install command.
Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →設定
{
"mcpServers": {
"powerbi": {
"command": "powerbi-mcp-server",
"args": []
}
}
}