Skip to main content
Glama
PowerPlatform MCP

PowerPlatform MCP

by michsob

PowerPlatform MCP / CLI

A Model Context Protocol (MCP) server and standalone CLI for querying and configuring PowerPlatform / Dataverse environments. Supports multiple environments, entity metadata, records, plugins, flows, solutions, workflows, business rules, security roles, custom APIs, web resources, and more — including write operations for automated environment setup.

Why MCP + CLI?

MCP integrates directly with AI clients (Claude, Cursor, GitHub Copilot) for interactive, conversational exploration of your environments.

CLI writes results to a file system cache instead of returning them inline. MCP tool responses are bound by the AI client's context window, which can truncate or degrade results when querying environments with hundreds of entities, flows, or plugin steps. The CLI avoids this limitation by persisting full results to disk, making them available for follow-up analysis without context pressure. Both interfaces share the same tools and capabilities.

Related MCP server: Dataverse MCP Server

Installation

Requires Node.js 22+ (< 25).

MCP Server

npm install -g powerplatform-mcp
# or
npx powerplatform-mcp

CLI

npm install -g powerplatform-cli
# or
npx powerplatform-cli

Docker

# MCP Server
docker pull ghcr.io/michsob/powerplatform-mcp
docker run --env-file .env ghcr.io/michsob/powerplatform-mcp

# CLI
docker pull ghcr.io/michsob/powerplatform-cli
docker run --env-file .env ghcr.io/michsob/powerplatform-cli entity-attributes account

Configuration

The tool supports multiple environments. Define them via environment variables:

POWERPLATFORM_ENVIRONMENTS=DEV,UAT,PROD

# For each environment, set:
POWERPLATFORM_DEV_URL=https://dev-org.crm.dynamics.com
POWERPLATFORM_DEV_CLIENT_ID=your-client-id
POWERPLATFORM_DEV_CLIENT_SECRET=your-client-secret
POWERPLATFORM_DEV_TENANT_ID=your-tenant-id

POWERPLATFORM_UAT_URL=https://uat-org.crm.dynamics.com
POWERPLATFORM_UAT_CLIENT_ID=...
POWERPLATFORM_UAT_CLIENT_SECRET=...
POWERPLATFORM_UAT_TENANT_ID=...

For local development, copy .env.example to .env and fill in your credentials.

Optionally, POWERPLATFORM_ENVIRONMENT_ID sets the Power Platform environment id that the Flow API calls use (flow run details, cancel, resubmit). Without it, the id is looked up from Dataverse.

The Flow API (api.flow.microsoft.com) refuses an app registration that has no maker access in the environment, whatever its Dataverse security roles. You'll see this as 403 EnvironmentAccessDenied. Run lists, with each run's status and error, come from Dataverse and keep working.

MCP Server

The MCP server is designed for AI-powered clients (Claude, Cursor, GitHub Copilot).

Available MCP Tools (68)

All tools accept an optional environment parameter to target a specific environment (defaults to the first configured).

List tools stop at maxRecords and say so: hasMore is true when more rows match, requestedMax is the cap, and totalMatching is the full count when Dataverse counted it (up to 5,000). When the list was cut, a warning comes before the data. Caps above 5,000 are read page by page.

Entity

Tool

Description

Required Params

Optional

get-entity-metadata

Get entity metadata

entityName

get-entity-attributes

List all attributes/fields

entityName

get-entity-attribute

Get a specific attribute

entityName, attributeName

get-entity-relationships

Get 1:N and N:N relationships

entityName

create-entity-string-attribute

Create a Single Line of Text column

entityName, schemaName, displayName

maxLength, requiredLevel, description, solutionName

get-entity-keys

List alternate keys on an entity

entityName

create-entity-alternate-key

Create an alternate key

entityName, schemaName, displayName, keyAttributes

languageCode, solutionName

Records

Tool

Description

Required Params

Optional

get-record

Get a record by ID

entityNamePlural, recordId

query-records

OData query

entityNamePlural, filter

maxRecords (default 50)

Plugins

Tool

Description

Required Params

Optional

get-plugin-assemblies

List plugin assemblies

includeManaged, maxRecords

get-plugin-assembly-complete

Assembly with types, steps, images

assemblyName

includeDisabled

get-entity-plugin-pipeline

Plugins executing on an entity

entityName

messageFilter, includeDisabled

get-plugin-trace-logs

Plugin trace logs

entityName, messageName, correlationId, pluginStepId, exceptionOnly, hoursBack, maxRecords

get-all-plugin-steps

All SDK message processing steps

includeDisabled, maxRecords

get-plugin-type

Look up a plugin type by class name

typeName

get-sdk-message

Look up an SDK message by name

messageName

create-plugin-step

Register a plugin step

name, pluginTypeId, sdkMessageId, stage, mode

rank, supportedDeployment, description, configuration, sdkMessageFilterId or entityName, filteringAttributes, solutionName

update-plugin-step

Change a plugin step in place; writes only what differs

stepId

name, description, stage, mode, rank, configuration, filteringAttributes (null clears them)

delete-plugin-step

Delete a plugin step, with its images

stepId

Flows (Power Automate)

Tool

Description

Required Params

Optional

get-flows

List cloud flows (smart filtering)

activeOnly, maxRecords, nameContains, excludeSystem, excludeCustomerInsights, excludeCopilotSales

search-workflows

Search workflows and flows

name, primaryEntity, description, category, statecode, includeDescription, maxResults

get-flow-definition

Full definition or parsed summary

flowId

summary

get-flow-runs

Flow run history

flowId

status, startedAfter, startedBefore, maxRecords

get-flow-run-details

Run details with action-level errors

flowId, runId

cancel-flow-run

Cancel a running/waiting run

flowId, runId

resubmit-flow-run

Retry a failed run

flowId, runId

scan-flow-health

Batch health scan (success rates)

daysBack, maxRunsPerFlow, maxFlows, activeOnly

get-flow-inventory

Lightweight flow inventory

maxRecords

Solutions

Tool

Description

Required Params

Optional

get-publishers

List publishers, with isreadonly (read-only ones came with managed solutions)

writableOnly

get-solutions

List visible solutions

get-solution

Get solution by unique name

uniqueName

get-solution-components

List components in a solution

solutionUniqueName

export-solution

Export solution (base64)

solutionName

managed

add-solution-component

Add a component to a solution

solutionUniqueName, componentId, componentType

addRequiredComponents

publish-customizations

Publish entity or all customizations

entityLogicalName

Workflows (Classic)

Tool

Description

Required Params

Optional

get-workflows

List classic workflows

activeOnly, maxRecords

get-workflow-definition

XAML definition or summary

workflowId

summary

get-ootb-workflows

Background, BPFs, actions, on-demand

maxRecords, categories

Business Rules

Tool

Description

Required Params

Optional

get-business-rules

List business rules

activeOnly, maxRecords

get-business-rule

Business rule with XAML

workflowId

Option Sets

Tool

Description

Required Params

get-global-option-set

Get a global option set definition

optionSetName

Configuration

Tool

Description

Required Params

Optional

get-connection-references

Connection references

maxRecords, managedOnly, hasConnection, inactive

get-environment-variables

Environment variable definitions + values, with the effective value (credential values masked)

maxRecords, managedOnly

create-environment-variable

Create an environment variable definition

schemaName, displayName, type

defaultValue, description, solutionName

set-environment-variable-value

Set or update an environment variable value

definitionId, value

existingValueId

Custom APIs

Tool

Description

Required Params

Optional

get-custom-apis

List Custom API definitions

maxRecords, includeManaged

get-custom-api

Get a Custom API by unique name

uniqueName

create-custom-api

Create a Custom API definition

uniqueName, name, displayName, bindingType, isFunction, isPrivate, allowedCustomProcessingStepType

description, pluginTypeId, pluginTypeName, boundEntityLogicalName, executePrivilegeName, solutionName

get-custom-api-response-properties

List response properties

customApiId

create-custom-api-response-property

Create a response property

customApiId, uniqueName, name, displayName, type

description, logicalEntityName, isOptional, solutionName

get-custom-api-request-parameters

List request parameters

customApiId

create-custom-api-request-parameter

Create a request parameter

customApiId, uniqueName, name, displayName, type

description, logicalEntityName, isOptional, solutionName

Web Resources

Tool

Description

Required Params

Optional

get-web-resources

List web resources

maxRecords, webResourceType, nameFilter

get-web-resource

Get a web resource by name

name

create-web-resource

Upload a new web resource

name, displayName, webResourceType, content

description, solutionName

Security Roles

Tool

Description

Required Params

Optional

get-security-roles

List customizable security roles

solutionUniqueName, excludeSystemRoles, includePrivileges, maxRecords

get-security-role-privileges

Privileges for a role (name, accessright, depth mask)

roleId

entityFilter, accessRightFilter

list-privileges

Browse the system privilege catalog to discover privilegeId GUIDs and supported depths

entityFilter, accessRightFilter, maxRecords

create-security-role

Create a new role (defaults to root BU); optional solutionUniqueName adds it to a solution in one step

name

businessUnitId, description, solutionUniqueName

clone-security-role

Clone a role with its privileges. Uses CloneAsRole with a create-then-copy fallback when the action isn't available

sourceRoleId

newName, targetBusinessUnitId, solutionUniqueName

update-security-role

Update a role's name, description, or business unit

roleId

name, description, businessUnitId, solutionUniqueName

delete-security-role

Delete a role (destructive — requires confirm: true)

roleId, confirm

add-security-role-privileges

Append privileges to a role (AddPrivilegesRole — leaves existing privileges intact)

roleId, privileges[]

remove-security-role-privileges

Remove privileges from a role (loops RemovePrivilegeRole)

roleId, privilegeIds[]

replace-security-role-privileges

Wipe and replace the full privilege set (ReplacePrivilegesRole — destructive, requires confirm: true)

roleId, privileges[], confirm

Each item in privileges[] is { privilegeId, depth, businessUnitId? }. Depth is one of Basic (user), Local (BU), Deep (BU + child), Global (org).

Dependencies

Tool

Description

Required Params

check-component-dependencies

Dependencies blocking deletion

componentId, componentType

check-delete-eligibility

Check if a component can be deleted

componentId, componentType

Service Endpoints

Tool

Description

Optional

get-service-endpoints

Service Bus, webhooks, Event Hub, Event Grid

maxRecords

MCP Prompts

Prompt

Description

Required Args

entity-overview

Entity overview with key attributes and relationships

entityName

attribute-details

Detailed attribute info (type, format, requirements)

entityName, attributeName

query-template

OData query template with example filters

entityName

relationship-map

Complete 1:N and N:N relationship map

entityName


CLI

Same tools as the MCP server, but results are cached to the file system for full-fidelity output on large data sets.

Global Option

--env <name> — target environment (defaults to first configured).

A list command that stops at --max prints a ⚠ line saying so, with the total when Dataverse counted it. flow-health also warns when a flow had more runs in the window than --max-runs (its success rate then covers the latest runs only), when it stopped at --max-flows, and when a flow's runs couldn't be read.

Commands

Entity

entity-metadata <entityName>
entity-attributes <entityName>
entity-attribute <entityName> <attributeName>
entity-relationships <entityName>
entity-keys <entityName>
create-entity <schemaName> <displayName> <displayCollectionName>  [--primary-name-schema <name>] [--primary-name-display <name>] [--description <desc>] [--ownership <UserOwned|OrganizationOwned>] [--has-activities] [--has-notes] [--solution <name>]
create-entity-string-attribute <entityName> <schemaName> <displayName>  [--max-length <n>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-memo-attribute <entityName> <schemaName> <displayName>  [--max-length <n>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-file-attribute <entityName> <schemaName> <displayName>  [--max-size-kb <n>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-integer-attribute <entityName> <schemaName> <displayName>  [--min <n>] [--max <n>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-decimal-attribute <entityName> <schemaName> <displayName>  [--precision <n>] [--min <n>] [--max <n>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-money-attribute <entityName> <schemaName> <displayName>  [--precision-source <0|1|2>] [--precision <n>] [--min <n>] [--max <n>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-boolean-attribute <entityName> <schemaName> <displayName>  [--true-label <label>] [--false-label <label>] [--default-value <true|false>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-datetime-attribute <entityName> <schemaName> <displayName>  [--format <DateOnly|DateAndTime>] [--behavior <UserLocal|DateOnly|TimeZoneIndependent>] [--required-level <level>] [--description <desc>] [--solution <name>]
create-entity-picklist-attribute <entityName> <schemaName> <displayName>  [-o <value:label>]... | [--global-option-set <name>] [--default-value <value>] [--required-level <level>] [--description <desc>] [--language-code <lcid>] [--solution <name>]
create-entity-lookup <referencingEntity> <referencedEntity> <relationshipSchemaName> <lookupSchemaName> <displayName>  [--required-level <level>] [--description <desc>] [--cascade-delete <NoCascade|RemoveLink|Restrict|Cascade>] [--solution <name>]
create-entity-alternate-key <entityName> <schemaName> <displayName> <keyAttributes...>  [--language-code <lcid>] [--solution <name>]
delete-entity-alternate-key <entityName> <keyName>
set-entity-change-tracking <entityName> <on|off>  [--solution <name>] [--no-publish]
update-entity-attribute <entityName> <attributeName>  [--required-level <None|Recommended|ApplicationRequired>] [--min <n>] [--max <n>] [--display-name <text>] [--description <text>] [--language-code <lcid>] [--solution <name>] [--no-publish]   # min/max on Integer, Decimal, Double, Money; a label is set in one language (default: the base language), the others stay
delete-entity-attribute <entityName> <attributeName>

Records

record <entityNamePlural> <recordId>
query-records <entityNamePlural> <filter>  [--max <n>]
create-record <entityNamePlural> <jsonBody>
update-record <entityNamePlural> <recordId> <jsonBody>
delete-record <entityNamePlural> <recordId>
associate-records <entityNamePlural> <recordId> <navigationProperty> <relatedEntityNamePlural> <relatedRecordId>
disassociate-records <entityNamePlural> <recordId> <navigationProperty> [relatedRecordId]

Plugins

plugin-assemblies                          [--include-managed] [--max <n>]
plugin-assembly <assemblyName>             [--include-disabled]
plugin-packages                            [--include-managed] [--max <n>]
plugin-type <typeName>
entity-pipeline <entityName>               [--message <msg>] [--include-disabled]
plugin-trace-logs                          [--entity <name>] [--message <msg>] [--correlation-id <id>] [--step-id <id>] [--hours <n>] [--max <n>] [--exceptions-only]
all-plugin-steps                           [--include-disabled] [--max <n>]
sdk-message <messageName>
register-plugin-package <filePath>         --name <name> --unique-name <uniqueName> [--pkg-version <version>] [--solution <name>]
update-plugin-package <filePath>           --plugin-package-id <id> [--pkg-version <version>]
create-plugin-step <name> <pluginTypeId> <sdkMessageId>  [--stage <n>] [--mode <n>] [--rank <n>] [--supported-deployment <n>] [--description <desc>] [--configuration <cfg>] [--message-filter-id <id> | --entity <logicalName>] [--filtering-attributes <csv>] [--solution <name>]   # --entity looks up the table's filter; filtering attributes on Update steps only
update-plugin-step <stepId>                [--name <name>] [--description <desc>] [--stage <n>] [--mode <n>] [--rank <n>] [--configuration <cfg>] [--filtering-attributes <csv> | --no-filtering-attributes]   # in place: keeps the id, images and solutions; writes only what differs
delete-plugin-step <stepId>                # with its images; a managed step is refused
create-plugin-step-image <stepId>          [--name <name>] [--entity-alias <alias>] [--image-type <0|1|2>] [--message-property-name <name>] [--attributes <csv>]

Flows

flows                                      [--active] [--name <contains>] [--include-managed] [--max <n>]
flow-definition <flowId>                   [--summary]
flow-inventory                             [--max <n>]
flow-runs <flowId>                         [--status <s>] [--after <iso>] [--before <iso>] [--max <n>]
flow-run-details <flowId> <runId>
flow-health                                [--days <n>] [--max-runs <n>] [--max-flows <n>] [--active]
search-workflows                           [--name <name>] [--entity <entity>] [--category <n>] [--active] [--max <n>]
create-cloud-flow <clientDataFile>         --name <name> [--primary-entity <entity>] [--solution <name>]
activate-flow <flowId>
deactivate-flow <flowId>

Solutions

solutions
solution <uniqueName>
solution-components <uniqueName>
publishers                                 [--writable-only]
add-solution-component <solutionUniqueName> <componentId> <componentType>  [--add-required]
publish-customizations                     [--entity <logicalName>]

Workflows

workflows                                  [--active] [--max <n>]
workflow-definition <workflowId>           [--summary]
ootb-workflows                             [--categories <0,1,2,3,4>] [--max <n>]

Business Rules

business-rules                             [--active] [--max <n>]
business-rule <workflowId>

Option Sets

optionset <optionSetName>

Dependencies

check-dependencies <componentId> <componentType>

Configuration

connection-references                      [--managed-only] [--has-connection] [--no-connection] [--inactive] [--max-records <n>]
create-connection-reference <logicalName> <displayName> <connectorId>  [--description <desc>] [--solution <name>]
environment-variables                      [--managed-only] [--max-records <n>] [--show-values]
create-environment-variable <schemaName> <displayName>  [--type <type>] [--default-value <val>] [--description <desc>] [--solution <name>]
set-environment-variable-value <definitionId> <value>   [--existing-value-id <id>]

environment-variables and the get-environment-variables tool mask credential values as *** (N chars). A value is masked when the variable is Secret-type, its name looks like a credential (secret, password, key, token, connection string, …), the value itself looks like one (a JWT, AccountKey=, Bearer …), or it is JSON with a credential-named key. Each variable says valueMasked and maskReason. plaintextCredential flags a literal credential stored in place of a Key Vault reference. The MCP tool always masks; the CLI prints and caches values in clear only with --show-values.

Custom APIs

custom-apis                                [--include-managed] [--max <n>]
custom-api <uniqueName>
create-custom-api <uniqueName> <displayName>  [--binding-type <n>] [--bound-entity <name>] [--is-function] [--is-private] [--processing-type <n>] [--plugin-type-id <id>] [--plugin-type-name <name>] [--execute-privilege <name>] [--description <desc>] [--solution <name>]
custom-api-response-properties <customApiId>
create-custom-api-response-property <customApiId> <uniqueName> <displayName>  [--type <n>] [--description <desc>] [--logical-entity <name>] [--name <name>] [--solution <name>]
custom-api-request-parameters <customApiId>
create-custom-api-request-parameter <customApiId> <uniqueName> <displayName>  [--type <n>] [--description <desc>] [--logical-entity <name>] [--optional] [--name <name>] [--solution <name>]

Web Resources

web-resources                              [--type <n>] [--name <contains>] [--max <n>]
web-resource <name>
create-web-resource <name> <displayName> <filePath>  [--type <n>] [--description <desc>] [--solution <name>]
push-web-resources <folder> <namePrefix>    [--solution <name>] [--no-publish]     # every file, named <namePrefix><path>, type from extension; writes only changed ones, then publishes them
set-entity-icon <entityName> <svgFilePath>  [--solution <name>] [--web-resource-name <name>] [--display-name <name>] [--no-publish]

Forms & Views

entity-forms <entityName>                  [--type <n>]
entity-form-fields <formId>
add-form-field <entityName> <formId> <attributeName>  [--after <attributeName>] [--read-only] [--label <text>]   # label: the column's display name; control: its type's
remove-form-field <entityName> <formId> <attributeName>
add-form-web-resource-tab <entityName> <formId> <label> <webResource>  [--tab-name <name>] [--rows <n>] [--no-pass-parameters] [--language-code <lcid>] [--solution <name>] [--dry-run]   # last tab, one HTML web resource; run again it replaces the tab; joins a solution only with --solution
set-form-layout <entityName> <formId> <layoutFile>       [--dry-run]
entity-views <entityName>
add-view-column <entityName> <viewId> <attributeName>   [--width <n>]
set-view-columns <entityName> <viewId> <columns...>     [--order-by <attr>] [--desc] [--find-columns <a,b>]
create-view <entityName> <name> <columns...>            [--order-by <attr>] [--desc] [--description <text>] [--state <active|inactive|all>] [--filter-xml <xml>] [--solution <name>]
remove-view-column <entityName> <viewId> <attributeName>

set-view-columns takes columns as name:width (e.g. contoso_name:250) and keeps the view's filters. On a Quick Find view, --find-columns also replaces the text and lookup columns the search box matches on.

create-view creates a public view on the table. If the table already has a view with that name, it updates that view instead, so you can safely run it again. By default the view lists active records; --filter-xml adds extra FetchXML <filter> elements.

set-form-layout replaces the form's tabs with the layout in a JSON file. It also replaces the header if the file has a header key; leave the key out to keep the current header, or set it to [] to remove it. Events, libraries, navigation and the footer are kept.

  • Fields: an item is a column logical name, or an object when it needs other settings. Labels default to the column's display name, and each control gets the classid for its column type.

  • Ids: tab, section and cell ids are derived from the form id and names. Re-applying a layout keeps the same ids.

  • Checks: the command rejects unknown or duplicate columns. It lists any custom columns left off the form.

  • --dry-run: builds the formxml into the cache without saving it.

{
  "header": [{ "field": "contoso_score", "readOnly": true }, "contoso_band"],
  "tabs": [{
    "name": "general", "label": "General",
    "columns": [
      { "width": "66%", "sections": [
        { "name": "details", "label": "Details", "items": ["contoso_name", { "field": "contoso_points", "readOnly": true }] },
        { "name": "points", "label": "Points", "columns": 2, "items": ["contoso_bonuspoints", "contoso_basepoints"] },
        { "name": "tasks", "label": "Tasks", "showLabel": false, "items": [{
          "subgrid": "Tasks", "label": "Tasks", "entity": "contoso_task",
          "relationship": "contoso_project_contoso_task_projectid",
          "viewId": "00000000-0000-0000-0000-000000000001", "recordsPerPage": 10
        }] },
        { "name": "hidden", "label": "Hidden", "visible": false, "items": ["contoso_state"] }
      ] },
      { "width": "34%", "sections": [
        { "name": "system", "label": "System", "items": [{ "field": "createdon", "readOnly": true }, { "field": "ownerid", "visible": false }] }
      ] }
    ]
  }]
}

A tab can give sections in place of columns, as shorthand for a single 100% column. These are the item options:

Item

Options

Field

field, label, readOnly, visible, showLabel

Subgrid

subgrid (control name), label, entity, relationship (leave out to list all records), viewId, recordsPerPage (default 5), enableViewPicker, enableQuickFind, showLabel, visible

Sections take name, label, showLabel, visible, columns (1–4) and items; tabs take name, label, showLabel, visible, expanded and columns or sections. Subgrids are written without rowspan: Unified Interface sizes the grid from recordsPerPage, and a rowspan would hide the cells below it.

PAC Integration

pac-auth                                   Authenticate pac CLI using environment credentials
generate-models <outdirectory>             [--settings <path>] [--entities <filter>] [--namespace <ns>]
deploy-plugin <pluginFile>                 --plugin-id <id> [--type <Nuget|Assembly>] [--configuration <config>]

Security Roles

security-roles                             [--solution <name>] [--include-system] [--include-privileges] [--max-records <n>]
security-role-privileges <roleId>          [--entity <name>] [--access-right <type>]
privileges                                 [--entity <name>] [--access-right <type>] [--max-records <n>]
create-security-role                       --name <name> [--bu <id>] [--description <desc>] [--solution <name>]
clone-security-role <sourceRoleId>         [--name <name>] [--target-bu <id>] [--solution <name>]
update-security-role <roleId>              [--name <name>] [--description <desc>] [--bu <id>] [--solution <name>]
delete-security-role <roleId>              --yes
add-role-privileges <roleId>               --privileges <spec>     # JSON array or shorthand <guid>:<Basic|Local|Deep|Global>,...
remove-role-privileges <roleId>            --privileges <id,id,id>
replace-role-privileges <roleId>           --privileges <spec> --yes

Model-driven Apps

create-model-driven-app <uniqueName> <displayName>  [--table <logicalName>]... [--group <Title=table,table>]... [--page <Group/Title=webresource[,icon]>]... [--solution-tables] [--group-title <title>] [--area-title <title>] [--description <desc>] [--solution <name>] [--language-code <lcid>] [--no-publish]

A --page is a web resource (an HTML page) in the app's site map, first in its group, with an optional SVG web resource as its icon; a group that only pages name comes before the others. Every page's web resource must exist and be published.

An app to browse tables in: the app (Unified Interface, the default icon), its site map (one area; a group per --group, and --tables and --solution-tables in a default group; a subarea per table) and the tables as app components. No forms or views are picked, so users see every form and view of each table. The app is validated and published (ValidateApp's warnings are printed; an error stops it before publishing). Run again, it rewrites the site map to the tables given and adds the tables the app lacks; it removes no component. System administrators and customizers see every app; other users need a security role associated with it.

Application Users

application-user <applicationId>           # the user of an app registration or managed identity, with its roles; exits 1 when there is none
create-application-user <applicationId>    [--role <idOrName>]... [--bu <id>]

create-application-user takes the application (client) id; for a managed identity, az ad sp show --id <principalId> --query appId. Dataverse names the user from Microsoft Entra ID, so the service principal must be in the environment's tenant. A role is a role id or name; a role id from another business unit is mapped to that role's copy in the user's. Run again, it keeps the user and adds only the roles it lacks; it refuses a disabled user and does not move a user to another business unit.

Service Endpoints

service-endpoints                          [--max <n>]

Development

git clone https://github.com/michsob/powerplatform-mcp.git
cd powerplatform-mcp
npm install
cp .env.example .env   # fill in credentials
npm run build
npm run inspector      # test with MCP Inspector

Releasing

To publish a new version:

  1. Update version in package.json and package.cli.json (the CLI is published with the version from package.json; keep the two in step)

  2. Merge the change to main

  3. Tag that commit on main with the same version and push the tag:

    VERSION=v$(node -p "require('./package.json').version")
    git tag "$VERSION"
    git push origin "$VERSION"

    The publish workflow refuses a tag that is not on main or does not match package.json.

GitHub Actions will automatically publish:

Package

npm

GitHub Packages

Docker (GHCR)

MCP Server

npm i powerplatform-mcp

npm i @michsob/powerplatform-mcp

ghcr.io/michsob/powerplatform-mcp

CLI

npm i powerplatform-cli

npm i @michsob/powerplatform-cli

ghcr.io/michsob/powerplatform-cli

npm publishing uses Trusted Publishing (OIDC) — no tokens or secrets needed. GitHub Packages and GHCR use the built-in GITHUB_TOKEN automatically.

License

MIT

Available Tools

38 tools
cancel-flow-runCancel Flow RunA

Cancel a running or waiting flow run. Cannot cancel flows already in a terminal state (Succeeded, Failed, Cancelled).

Inputs: flowId (required), runId (required), environment. Returns: success, flowId, runId, previousStatus

check-component-dependenciesCheck Component DependenciesA

Check dependencies for a PowerPlatform component before deletion. Returns all components that depend on the specified component.

Inputs: componentId (required), componentType (required), environment. Returns: componentId, componentType, dependencies

check-delete-eligibilityCheck Delete EligibilityA

Check if a PowerPlatform component can be safely deleted. Returns whether deletion is allowed and lists blocking dependencies.

Inputs: componentId (required), componentType (required), environment. Returns: componentId, componentType, canDelete, dependencies

export-solutionExport SolutionA

Export a solution as a base64-encoded package. This is a read-only operation that serializes the solution.

Inputs: solutionName (required), managed, environment. Returns: solutionName, exportResult

get-all-plugin-stepsGet All Plugin StepsC

Get all plugin SDK message processing steps across all assemblies in the environment

Inputs: includeDisabled, maxRecords, environment.

get-business-ruleGet Business RuleB

Get a specific business rule with its complete XAML definition

Inputs: workflowId (required), environment. Returns: workflowid, name, description, state, +12 more

get-business-rulesGet Business RulesC

Get all business rules in the environment

Inputs: activeOnly, maxRecords, environment. Returns: totalCount, businessRules

get-connection-referencesGet Connection ReferencesB

Get connection references in the PowerPlatform environment with optional filtering by managed status, connection presence, and active state

Inputs: maxRecords, managedOnly, hasConnection, inactive, +1 more. Returns: connectionReferences

get-entity-attributeGet Entity AttributeC

Get a specific attribute/field of a PowerPlatform entity

Inputs: entityName (required), attributeName (required), environment. Returns: entityName, attributeName, attribute

get-entity-attributesGet Entity AttributesC

Get attributes/fields of a PowerPlatform entity

Inputs: entityName (required), environment. Returns: entityName, attributes

get-entity-metadataGet Entity MetadataC

Get metadata about a PowerPlatform entity

Inputs: entityName (required), environment. Returns: entityName, metadata

get-entity-plugin-pipelineGet Entity Plugin PipelineA

Get all plugins that execute on a specific entity, organized by message and stage

Inputs: entityName (required), messageFilter, includeDisabled, environment. Returns: entity, messages, steps, executionOrder

get-entity-relationshipsGet Entity RelationshipsB

Get relationships (one-to-many and many-to-many) for a PowerPlatform entity

Inputs: entityName (required), environment. Returns: entityName, relationships

get-environment-variablesGet Environment VariablesB

Get environment variable definitions and their current values from the PowerPlatform environment

Inputs: maxRecords, managedOnly, environment. Returns: environmentVariables

get-flow-definitionGet Flow DefinitionB

Get a Power Automate flow with its complete definition or a parsed summary of triggers, actions, and connectors

Inputs: flowId (required), summary, environment. Returns: name, flowDefinition

get-flow-inventoryGet Flow InventoryA

Get complete inventory of all cloud flows (name, state, modified date). Lighter than scan-flow-health as it does not fetch run history.

Inputs: maxRecords, environment.

get-flow-run-detailsGet Flow Run DetailsA

Get detailed flow run information including action-level outputs and errors. For failed actions, fetches detailed error messages.

Inputs: flowId (required), runId (required), environment. Returns: flowId, status, actionsSummary, failedActionErrors

get-flow-runsGet Flow RunsC

Get flow run history for a specific Power Automate flow

Inputs: flowId (required), status, startedAfter, startedBefore, +2 more. Returns: flowId, totalCount, hasMore, runs

get-flowsGet FlowsB

Get Power Automate cloud flows with smart filtering (excludes system, Copilot Sales, and Customer Insights flows by default)

Inputs: activeOnly, maxRecords, excludeCustomerInsights, excludeSystem, +3 more. Returns: totalCount, hasMore, flows

get-global-option-setGet Global Option SetC

Get a global option set definition by name

Inputs: optionSetName (required), environment. Returns: optionSetName, optionSet

get-ootb-workflowsGet OOTB WorkflowsA

Get all non-cloud-flow workflows: background workflows, business rules, actions, BPFs, on-demand workflows

Inputs: maxRecords, categories, environment.

get-plugin-assembliesGet Plugin AssembliesC

Get all plugin assemblies in the environment

Inputs: includeManaged, maxRecords, environment. Returns: totalCount, assemblies

get-plugin-assembly-completeGet Plugin Assembly CompleteB

Get a plugin assembly by name with all related plugin types, steps, and images

Inputs: assemblyName (required), includeDisabled, environment. Returns: assembly, pluginTypes, steps, validation

get-plugin-trace-logsGet Plugin Trace LogsC

Get plugin trace logs with filtering options

Inputs: entityName, messageName, correlationId, pluginStepId, +4 more. Returns: totalCount, logs

get-publishersGet PublishersA

Get all non-readonly publishers in the PowerPlatform environment

Inputs: environment. Returns: publishers

get-recordGet RecordC

Get a specific record by entity name (plural) and ID

Inputs: entityNamePlural (required), recordId (required), environment. Returns: entityNamePlural, recordId, record

get-security-role-privilegesGet Security Role PrivilegesC

Get privileges assigned to a specific security role, optionally filtered by entity or access right

Inputs: roleId (required), entityFilter, accessRightFilter, environment. Returns: roleId, privileges

get-security-rolesGet Security RolesA

Get security roles in the PowerPlatform environment, filtered to unmanaged or customizable roles. Supports solution scoping and optional privilege details.

Inputs: solutionUniqueName, excludeSystemRoles, maxRecords, includePrivileges, +1 more. Returns: roles

get-service-endpointsGet Service EndpointsC

Get all service endpoints (Service Bus, webhooks, Event Hub, Event Grid)

Inputs: maxRecords, environment.

get-solutionGet SolutionC

Get a specific solution by its unique name

Inputs: uniqueName (required), environment. Returns: uniqueName, solution

get-solution-componentsGet Solution ComponentsB

Get all components in a solution, ordered by component type

Inputs: solutionUniqueName (required), environment. Returns: solutionUniqueName, components

get-solutionsGet SolutionsA

Get all visible solutions in the PowerPlatform environment, ordered by creation date

Inputs: environment. Returns: solutions

get-workflow-definitionGet Workflow DefinitionB

Get a specific classic workflow with its complete XAML definition or a structured summary

Inputs: workflowId (required), summary, environment.

get-workflowsGet WorkflowsC

Get all classic Dynamics workflows in the environment

Inputs: activeOnly, maxRecords, environment. Returns: totalCount, hasMore, requestedMax, workflows

query-recordsQuery RecordsC

Query records using an OData filter expression

Inputs: entityNamePlural (required), filter (required), maxRecords, environment. Returns: entityNamePlural, filter, count, records

resubmit-flow-runResubmit Flow RunB

Resubmit/retry a failed flow run using the original trigger inputs

Inputs: flowId (required), runId (required), environment. Returns: success, flowId, originalRunId, newRunId, +1 more

scan-flow-healthScan Flow HealthA

Batch-scan all Power Automate cloud flows for health metrics. Fetches run history for each flow and computes success rates, failure counts. WARNING: batch operation that may take several minutes.

Inputs: daysBack, maxRunsPerFlow, maxFlows, activeOnly, +1 more.

search-workflowsSearch WorkflowsB

Search workflows (both classic workflows and Power Automate flows) by name, entity, description, category, or state

Inputs: name, primaryEntity, description, category, +4 more. Returns: totalCount, hasMore, workflows

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 38 tools

    Disambiguation4/5

    Most tools have distinct purposes targeting specific PowerPlatform components like flows, solutions, entities, plugins, and workflows, with clear naming that minimizes overlap. However, some tools like 'get-flows', 'get-flow-inventory', and 'scan-flow-health' could cause minor confusion as they all retrieve flow information but with different scopes or detail levels, requiring careful reading of descriptions.

    Naming Consistency5/5

    Tool names follow a highly consistent verb_noun pattern throughout, such as 'get-flow-runs', 'export-solution', and 'query-records'. All tools use snake_case without deviation, and verbs like 'get', 'export', 'cancel', and 'scan' are applied predictably across the set, making the naming scheme easy to understand and navigate.

    Tool Count3/5

    With 38 tools, the count is borderline high for a single server, suggesting potential over-scoping or fragmentation. While PowerPlatform is a broad domain, this many tools might overwhelm agents and indicate that some could be consolidated (e.g., multiple 'get' tools for similar entities). A more focused set of 15-25 tools would likely improve usability without losing functionality.

    Completeness5/5

    The tool set provides comprehensive coverage for PowerPlatform operations, including CRUD-like actions (e.g., 'export-solution', 'query-records'), monitoring ('scan-flow-health', 'get-flow-run-details'), and management tasks ('cancel-flow-run', 'check-delete-eligibility'). It spans key areas like flows, solutions, entities, plugins, and workflows with no obvious gaps, enabling agents to handle most common scenarios in this domain.

    Maintenance

    ActivityNo data
    ResponsivenessLimited data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that enables CRUD operations and querying on Microsoft Dataverse through natural language.
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Model Context Protocol (MCP) server for Microsoft Dynamics 365 Business Central. Provides AI assistants with direct access to Business Central data through properly formatted API v2.0 calls.
      6
      10
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Provides intelligent access to PowerPlatform/Dataverse entities and records, enabling entity metadata exploration, OData querying, relationship mapping, and AI-assisted query building through MCP.
      8
      MIT