Power Platform Graph Azure
STDIOMCP tools for Graph API, Azure REST API and Power Platform Admin APIs integration.
MCP tools for Graph API, Azure REST API and Power Platform Admin APIs integration.
This repository contains the Model Context Protocol (MCP) tools for using Graph API, Azure REST API using Azure CLI, and Power Platform Admin APIs/Dataverse APIs using Power Platform CLI.
GenAIScript is a framework that enables you to communicate with AI models (even local models). GenAIScript can use MCP tools, and can also act as the MCP server.
This is how Anthropic, the creators of MCP specification, defines Model Context Protocol
MCP is an open protocol that standardizes how applications provide context to LLMs. Think of MCP like a USB-C port for AI applications. Just as USB-C provides a standardized way to connect your devices to various peripherals and accessories, MCP provides a standardized way to connect AI models to different data sources and tools.
genaiscript
CLI using npm install -g genaiscript
, or use npx genaiscript
If you install the March 2025 version of VSCode Insiders, you should be able to run the GenAIScript MCP server locally, to get the tool versions installed on your local machine.
mcp.json is where you would configure the MCP servers. You don't even need to clone this repo with this approach, as GenAIScript can clone the repo in the background for you to just use the tools. If you are using the --remote
flag, you don't need to install the GenAIScript extension at all, as npx would pull in everything for you.
GitHub Copilot does not seem to like CLIs trying to authenticate in VSCode Insiders. If you try to do that Power Platform CLI would fail with The requested service provider could not be loaded or initialized.
error.
You have two options:
genaiscript.env
in the .devcontainer folder. Use the below as a sample.PAC_CLIENT_ID=2caa17e6-884b-473b-80c5-c05d8859a2fa
PAC_CLIENT_SECRET=
ENVIRONMENT_URL=https://abc.crm6.dynamics.com
TENANT_ID=
AZ_CLIENT_ID=aba9829f-6288-44d7-9168-53eca9a1f4a5
AZ_CLIENT_SECRET=
DOCKER_CONTAINER=true
Config for Windows
{ "globalShortcut": "Ctrl+Space", "mcpServers": { "genaiscript-mcp": { "type": "stdio", "command": "cmd", "args": [ "/c", "npx", "genaiscript", "mcp", "--remote", "https://github.com/rajyraman/genaiscript-pac-az-mcp/", "--remote-branch", "main", "--groups", "mcp", "--startup", "mcp_resources" ], "env": { "DEBUG": "*" } } } }
Config for MacOS/Linux
{ "globalShortcut": "Ctrl+Space", "mcpServers": { "genaiscript-mcp": { "type": "stdio", "command": "npx", "args": [ "genaiscript", "mcp", "--remote", "https://github.com/rajyraman/genaiscript-pac-az-mcp/", "--remote-branch", "main", "--groups", "mcp", "--startup", "mcp_resources" ], "env": { "DEBUG": "*" } } } }
MCP config inside VSCode Insiders is via in mcp.json file in the .vscode folder. Config for Windows
Running npx directly seems to create problems in Windows. So, we have to use cmd
to launch npx
.
{ "servers": { "genaiscript-mcp-remote": { "type": "stdio", "command": "cmd", "args": [ "/c", "npx", "genaiscript", "mcp", "--remote", "https://github.com/rajyraman/genaiscript-pac-az-mcp/", "--remote-branch", "main", "--groups", "mcp" ], "env": { "DEBUG": "*" } // "envFile": "${workspaceFolder}/.env" } } }
Config for MacOS/Linux
{ "servers": { "genaiscript-mcp-remote": { "type": "stdio", "command": "npx", "args": [ "genaiscript", "mcp", "--remote", "https://github.com/rajyraman/genaiscript-pac-az-mcp/", "--remote-branch", "main", "--groups", "mcp" ], "env": { "DEBUG": "*" } // "envFile": "${workspaceFolder}/.env" } } }
You can start the MCP Server by clicking the Start link. If it is already running, you would see a Running indicator.
Use az.prompt.md for any Azure REST API, or Graph API questions.
Use pac.prompt.md for any Power Platform questions.
You can use the prompt in VSCode like below.
In Claude Desktop, you can upload the prompt file to the session. The prompts are available as Resources. Choose the appropriate prompt for what you plan to ask Claude. You can choose both if needed, but it is better to choose one, test out the experience first before choosing both.
Below is how you can use it in the GitHub Copilot chat.