The PowerPlatform Model Context Protocol (MCP) Server is a powerful tool designed to provide intelligent access to PowerPlatform/Dataverse entities and records. It offers context-aware assistance, entity exploration, and metadata access, making it an essential tool for developers and data modelers working with PowerPlatform.
You can install and run the PowerPlatform MCP Server in two ways:
npm install -g powerplatform-mcp
Then run it:
powerplatform-mcp
Run without installing:
npx powerplatform-mcp
Before running the server, set the following environment variables:
# PowerPlatform/Dataverse connection details
POWERPLATFORM_URL=https://yourenvironment.crm.dynamics.com
POWERPLATFORM_CLIENT_ID=your-azure-app-client-id
POWERPLATFORM_CLIENT_SECRET=your-azure-app-client-secret
POWERPLATFORM_TENANT_ID=your-azure-tenant-id
The PowerPlatform MCP Server is designed to work with MCP-compatible clients like Cursor, Claude App, and GitHub Copilot. Once running, it exposes tools for retrieving PowerPlatform entity metadata and records.
get-entity-metadata
: Get metadata about a PowerPlatform entity.get-entity-attributes
: Get attributes/fields of a PowerPlatform entity.get-entity-attribute
: Get a specific attribute/field of a PowerPlatform entity.get-entity-relationships
: Get relationships for a PowerPlatform entity.get-global-option-set
: Get a global option set definition.get-record
: Get a specific record by entity name and ID.query-records
: Query records using an OData filter expression.use-powerplatform-prompt
: Use pre-defined prompt templates for PowerPlatform entities.The server includes a prompts feature that provides formatted, context-rich information about PowerPlatform entities.
The use-powerplatform-prompt
tool supports the following prompt types:
await mcpClient.invoke("use-powerplatform-prompt", {
promptType: "ENTITY_OVERVIEW",
entityName: "account"
});
await mcpClient.invoke("use-powerplatform-prompt", {
promptType: "ATTRIBUTE_DETAILS",
entityName: "account",
attributeName: "revenue"
});
await mcpClient.invoke("use-powerplatform-prompt", {
promptType: "QUERY_TEMPLATE",
entityName: "account"
});
await mcpClient.invoke("use-powerplatform-prompt", {
promptType: "RELATIONSHIP_MAP",
entityName: "contact"
});
Here are some examples of how you can interact with the assistant using the PowerPlatform MCP prompts:
User: "Tell me about the Account entity in our PowerPlatform environment"
User: "Help me write a query to find active accounts with revenue over $1M in California"
User: "How are Accounts and Contacts related in our system?"
User: "What kind of field is the revenue field on Account?"
User: "I need to design a solution for tracking product reviews. Which entities should I relate to?"
User: "Why am I getting 'invalid property' when querying account.customertypecode?"
The PowerPlatform MCP Server is licensed under the MIT License.
The PowerPlatform Model Context Protocol Server is a tool designed to enhance the capabilities of PowerPlatform/Dataverse development by providing intelligent, context-aware access to entity metadata and records.