power-platform-skills
Safety scan
A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.
Check it deeper on your machine
It has changed since its scan on 11 Nov 2026. Its scripts were only partly scanned.
As a Claude Code plugin, install it and then ask Claude Code:
/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/microsoft/power-platform-skills with scanskillsafety
Or from a terminal, clone it and run it:
git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/microsoft/power-platform-skills'
It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.
Badge for your README
Markdown
[](/listings/microsoft-power-platform-skills)HTML
<a href="/listings/microsoft-power-platform-skills"><img src="/api/listings/microsoft-power-platform-skills/badge.svg" alt="findsafeskills safety rating" /></a>Install
Install instructions from the README
As written by the repo's author. findsafeskills has not verified these steps.
Quick Install (Recommended)
Run the installer to set up all plugins with auto-update enabled:
**Windows (PowerShell)**:
iwr https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js -OutFile install.js; node install.js; del install.js
**Mac OS/Linux/Windows (cmd)**:
curl -fsSL https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js | node
The installer automatically:
- Installs `pac` CLI if not already installed - Detects available tools (GitHub Copilot CLI, Claude Code) - Registers the plugin marketplace and installs all listed plugins except `dataverse` - Enables auto-update so plugins stay current
The installer validates plugin names in local and downloaded marketplace manifests before installation. Names must follow the Open Plugins format: 1–64 lowercase ASCII letters or digits, with single dots or hyphens allowed between alphanumeric endpoints. CLI arguments are passed directly to executables; Windows batch launchers accept only shell-inert arguments.
To also install the [Dataverse](#dataverse-external) plugin, pass `--include-dataverse`:
iwr https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js -OutFile install.js; node install.js --include-dataverse; del install.js
curl -fsSL https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js | node - --include-dataverse
The `-` tells Node to read the piped script, so the arguments after it reach the installer.
Manual Installation
If you prefer to install manually, run these commands inside a GitHub Copilot CLI or Claude Code session:
1. Add the marketplace
```bash /plugin marketplace add microsoft/power-platform-skills ```
2. Install the desired plugin
```bash /plugin install power-pages@power-platform-skills /plugin install model-apps@power-platform-skills /plugin install pcf@power-platform-skills /plugin install mcp-apps@power-platform-skills /plugin install code-apps-preview@power-platform-skills /plugin install mobile-app@power-platform-skills /plugin install power-apps-mobile-extension@power-platform-skills /plugin install canvas-apps@power-platform-skills /plugin install power-automate@power-platform-skills /plugin install process-intelligence@power-platform-skills /plugin install dataverse@power-platform-skills ```
What was scanned
The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.
.claude-plugin/marketplace.json · Manifest · 60 lines
View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)
This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.
- {
- "name": "power-platform-skills",
- "owner": {
- "name": "Microsoft"
- },
- "metadata": {
- "description": "Plugins for Power Platform development with Claude Code and GitHub Copilot",
- "pluginRoot": "."
- },
- "plugins": [
- {
- "name": "power-pages",
- "source": "./plugins/power-pages"
- },
- {
- "name": "model-apps",
- "source": "./plugins/model-apps"
- },
- {
- "name": "pcf",
- "source": "./plugins/pcf"
- },
- {
- "name": "mcp-apps",
- "source": "./plugins/mcp-apps"
- },
- {
- "name": "canvas-apps",
- "source": "./plugins/canvas-apps"
- },
- {
- "name": "code-apps-preview",
- "source": "./plugins/code-apps"
- },
- {
- "name": "mobile-app",
- "source": "./plugins/mobile-apps"
- },
- {
- "name": "power-apps-mobile-extension",
- "source": "./plugins/power-apps-mobile-extension"
- },
- {
- "name": "power-automate",
- "source": "./plugins/power-automate"
- },
- {
- "name": "process-intelligence",
- "source": "./plugins/process-intelligence"
- },
- {
- "name": "dataverse",
- "source": {
- "source": "git-subdir",
- "url": "microsoft/Dataverse-skills",
- "path": ".github/plugins/dataverse"
- }
- }
- ]
- }
README.md · README · 404 lines
View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)
This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.
- # Power Platform Skills
- Plugins from Microsoft that teach AI assistants, such as GitHub Copilot and Claude Code, to build on Power Platform.
- **[Browse the plugins and install them with one click](https://microsoft.github.io/power-platform-skills/)**
- You describe what you want in your own words, such as "Create a Power Pages site with React for a job board" or "Why did the last run of my approval flow fail?".
- Your assistant asks follow-up questions, shows you what it plans to do, and asks before it runs commands or changes files.
- Then it does the work, from creating tables to publishing the result to your Power Platform environment.
- ## What can I build?
- | I want to... | Plugin | Try asking |
- | --- | --- | --- |
- | Build a website | [Power Pages](plugins/power-pages/README.md) | "Create a Power Pages site with React for a job board" |
- | Build a business app | [Model-driven apps](plugins/model-apps/README.md) | "Build an app for tracking service requests" |
- | Build or change a canvas app | [Canvas apps](plugins/canvas-apps/README.md) | "Edit my Canvas App to add a new screen for reports" |
- | Build a web app with code | [Code apps](plugins/code-apps/README.md) (preview) | "Create a code app for tracking customer requests" |
- | Build a phone app | [Mobile apps](plugins/mobile-apps/README.md) (private preview) | "Build me a small notes app" |
- | Add native phone features to a canvas app | [Power Apps Mobile extensions](plugins/power-apps-mobile-extension/README.md) (preview) | "Design a native barcode scanning feature for my wrapped canvas app" |
- | Automate work | [Power Automate](plugins/power-automate/README.md) | "Create a flow that emails me when a new item is added to my SharePoint list" |
- | Work with Dataverse data | [Dataverse](https://github.com/microsoft/Dataverse-skills) | "Import this CSV into the contacts table" |
- | Find where a process slows down | [Process Intelligence](plugins/process-intelligence/README.md) | "Which steps cause the most waiting in this process?" |
- | Build custom controls for forms and views | [PCF](plugins/pcf/README.md) (preview) | "Create a PCF star rating control for a model-driven form" |
- | Build tools and widgets for AI assistants | [MCP Apps](plugins/mcp-apps/README.md) | "Show account revenue as a bar chart" |
- The [plugin website](https://microsoft.github.io/power-platform-skills/) shows what each plugin needs and more things to ask.
- ## Before you start
- - **Choose an AI assistant.** Use the [GitHub Copilot app](https://github.com/features/ai/github-app), [GitHub Copilot CLI](https://docs.github.com/copilot/how-tos/copilot-cli/set-up-copilot-cli/install-copilot-cli), or [Claude Code](https://code.claude.com/docs/en/setup).
- - **Get a Power Platform environment.** You'll need permission to create or change resources in it.
- For learning and experiments, start with a free [developer environment](https://learn.microsoft.com/power-platform/developer/create-developer-environment) rather than an environment with live apps or data.
- - **Install [Node.js](https://nodejs.org/en/download).** The quick installer and most plugins need it to run.
- Check your chosen plugin's page for any additional tools, such as the Azure CLI or the .NET SDK.
- Requirements vary by plugin, so you don't need to install every tool up front.
- ## Installation
- ### Quick install (recommended)
- Open a terminal and run one command.
- It installs every plugin into Claude Code and GitHub Copilot CLI, whichever you have.
- **Windows (PowerShell)**:
- ```powershell
- iwr https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js -OutFile install.js; node install.js; del install.js
- ```
- **macOS, Linux, or Windows (cmd)**:
- ```bash
- curl -fsSL https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js | node
- ```
- The installer:
- - Installs the Power Platform CLI (`pac`) if it is missing
- - Finds Claude Code and GitHub Copilot CLI on your computer
- - Adds this plugin marketplace and installs every plugin except `dataverse`
- - Turns on automatic updates, so your plugins stay current
- To also install the [Dataverse](#dataverse-external) plugin, pass `--include-dataverse`:
- ```powershell
- iwr https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js -OutFile install.js; node install.js --include-dataverse; del install.js
- ```
- ```bash
- curl -fsSL https://raw.githubusercontent.com/microsoft/power-platform-skills/main/scripts/install.js | node - --include-dataverse
- ```
- The `-` tells Node to read the piped script, so the arguments after it reach the installer.
- ### Install one plugin with a click
- The **Claude Code** links open a terminal with the install command already typed.
- Press Enter to install.
- If nothing happens, open Claude Code once and send any message, then try the link again.
- For the **GitHub Copilot app**, [add the Power Platform marketplace](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Fmarketplace%2Fadd%3Fsource%3Dmicrosoft%252Fpower-platform-skills) first.
- You only do this once.
- The app asks you to confirm each step.
- | Plugin | Claude Code | GitHub Copilot app |
- | --- | --- | --- |
- | Power Pages | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=power-pages) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dpower-pages%2540power-platform-skills) |
- | Model-driven apps | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=model-apps) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dmodel-apps%2540power-platform-skills) |
- | Canvas apps | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=canvas-apps) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dcanvas-apps%2540power-platform-skills) |
- | Code apps | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=code-apps-preview) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dcode-apps-preview%2540power-platform-skills) |
- | Mobile apps | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=mobile-app) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dmobile-app%2540power-platform-skills) |
- | Power Apps Mobile extensions | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=power-apps-mobile-extension) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dpower-apps-mobile-extension%2540power-platform-skills) |
- | Power Automate | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=power-automate) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dpower-automate%2540power-platform-skills) |
- | Process Intelligence | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=process-intelligence) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dprocess-intelligence%2540power-platform-skills) |
- | Dataverse | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=dataverse) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Ddataverse%2540power-platform-skills) |
- | PCF code components | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=pcf) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dpcf%2540power-platform-skills) |
- | MCP Apps | [Install in Claude Code](https://microsoft.github.io/power-platform-skills/install/?app=claude-code&plugin=mcp-apps) | [Install in GitHub Copilot app](https://github.com/copilot/app/launch?open=ghapp%3A%2F%2Fplugins%2Finstall%3Fsource%3Dmcp-apps%2540power-platform-skills) |
- The Claude desktop app's Code tab and the Claude Code extension for VS Code use the plugins you install in Claude Code.
- VS Code also picks up plugins you install with GitHub Copilot CLI.
- ### Manual installation
- To install from inside a GitHub Copilot CLI or Claude Code session, run these commands:
- 1. Add the marketplace
- ```bash
- /plugin marketplace add microsoft/power-platform-skills
- ```
- 2. Install the plugins you want
- ```bash
- /plugin install power-pages@power-platform-skills
- /plugin install model-apps@power-platform-skills
- /plugin install canvas-apps@power-platform-skills
- /plugin install code-apps-preview@power-platform-skills
- /plugin install mobile-app@power-platform-skills
- /plugin install power-apps-mobile-extension@power-platform-skills
- /plugin install power-automate@power-platform-skills
- /plugin install process-intelligence@power-platform-skills
- /plugin install dataverse@power-platform-skills
- /plugin install pcf@power-platform-skills
- /plugin install mcp-apps@power-platform-skills
- ```
- ## Your first request
- 1. Open a terminal, make an empty folder for your project, and go into it:
- ```bash
- mkdir my-first-site
- cd my-first-site
- ```
- 2. Start your assistant by typing `claude` or `copilot`.
- In the GitHub Copilot app, add the folder and start a session instead.
- 3. Describe what you want, for example "Create a Power Pages site with React for a job board".
- 4. Answer its questions.
- It may ask you to sign in to Power Platform in your browser and to pick an environment.
- 5. Read each permission request before you approve it.
- When it finishes, it tells you what it created.
- ## Questions
- ### Do I need to know how to code?
- No.
- You describe what you want in your own words.
- You run a few commands to install things, and some plugins are aimed at developers.
- The [plugin website](https://microsoft.github.io/power-platform-skills/) says who each plugin is for.
- ### What does it cost?
- The plugins are free and open source under the [MIT](LICENSE) license.
- You need your own AI assistant, such as GitHub Copilot or Claude, and a Power Platform environment, which can need Power Platform licenses.
- ### Can it break something?
- Your assistant asks before it runs commands or changes files.
- Many plugins also show you a plan or confirm the environment before they publish.
- Try things in a [developer environment](https://learn.microsoft.com/power-platform/developer/create-developer-environment) first.
- It's free and separate from your organization's live apps.
- ### Why does my assistant keep asking for permission?
- Plugins edit files, run commands, and call MCP servers, and your assistant asks before each one by default.
- Read what it wants to do before you approve it.
- If you trust the work and want fewer prompts, see [Running Without Interruption](#running-without-interruption).
- ### What data is collected?
- Some plugins send usage data to Microsoft by default, and each one has a command to turn it off.
- See [Telemetry](#telemetry) for what is collected.
- ### How do I update or remove a plugin?
- The quick install turns on automatic updates.
- Otherwise, run `claude plugin update <name>` or `copilot plugin update <name>`.
- To remove a plugin, run `claude plugin uninstall <name>` or `copilot plugin uninstall <name>`.
- ### Where do I get help?
- Most plugins include a `report-issue` skill that drafts a bug report for you.
- You can also [open an issue](https://github.com/microsoft/power-platform-skills/issues) or read [SUPPORT.md](SUPPORT.md).
- ## Words you'll see
- For plugins and skills in action, watch the 35-second video [What are plugins and skills?](https://microsoft.github.io/power-platform-skills/#questions) on the plugin website.
- | Word | What it means |
- | --- | --- |
- | AI assistant | An AI tool that can work on your computer, such as Claude Code or GitHub Copilot. |
- | Plugin | A package that teaches your assistant a set of jobs. |
- | Skill | Instructions for one job, such as creating a site. Your assistant picks one from your request, or you can type its name, such as `/create-site`. |
- | Marketplace | A list of plugins your assistant can install. This repository is one. |
- | Environment | A space in Power Platform that holds your apps, flows, and data. |
- | Dataverse | The database behind Power Apps and Power Automate. |
- | PAC CLI | The Power Platform command-line tool. Plugins use it to sign in and publish. |
- | Azure CLI | Microsoft's command-line tool for Azure. Some plugins use it to sign in. |
- | MCP server | A small program that gives your assistant extra tools, such as access to a service. |
- ## Available Plugins
- ### [Power Pages](plugins/power-pages/README.md) (`plugins/power-pages`)
- Create and deploy Power Pages sites using modern development approaches.
- **Currently supported**: Code Sites (SPAs) with React, Angular, Vue, or Astro
- ### [Model Apps](plugins/model-apps/README.md) (`plugins/model-apps`)
- Build model-driven Power Apps end to end, and the generative pages that go in them.
- **Skills**: `/app-builder` builds and edits a whole app — tables, relationships, forms,
- views, charts, security roles, app + sitemap — from a natural-language intent; `/genpage` builds
- generative pages for an app that already exists. Use either independently — neither requires the other
- **Stack**: React + TypeScript + Fluent, deployed through the headless `cds-maker-sdk` (PAC CLI signs you in and chooses the environment)
- ### [PCF](plugins/pcf/README.md) (`plugins/pcf`)
- Build, test, diagnose, upgrade, deploy, verify and inventory Power Apps component framework (PCF) code components for model-driven apps, with guided setup for Power Pages field controls and canvas apps. Canvas apps need an admin to turn on **Power Apps component framework for canvas apps** in each environment.
- **Skills**: `/pcf:pcf` scaffolds Microsoft-maintained PCF templates and recipes, runs gates, deploys with PAC, and verifies registration and bindings.
- **Status**: Preview — see [capabilities](plugins/pcf/docs/pcf-capabilities.md)
- **Stack**: Node.js 20+, Power Apps component framework, PAC CLI, .NET SDK, and Azure CLI for verification/inventory
- ### [MCP Apps](plugins/mcp-apps/README.md) (`plugins/mcp-apps`)
- Generate self-contained JavaScript server runtimes, JSON Schema registration metadata,
- and interactive single-file MCP App widgets for codeful MCP tools.
- **Skills**: `/generate-codeful-mcp-tool` creates a named `runTool` server entry point plus
- its description, MCP behavior annotations, input schema, and structured output schema,
- with verified Dataverse access; `/generate-mcp-app-ui` creates an HTML widget that embeds
- its runtime by default for hosts that block public URLs, while retaining an opt-in CDN
- mode. It can consume model-visible content, structured output, and widget-private
- metadata.
- **Stack**: JavaScript codeful tools + HTML widgets using the MCP Apps protocol
- ### [Code Apps](plugins/code-apps/AGENTS.md) (`plugins/code-apps`)
- Build and deploy Power Apps code apps connected to Power Platform via connectors.
- **Stack**: React + Vite + TypeScript, deployed via PAC CLI
- ### [Mobile Apps](plugins/mobile-apps/README.md) (`plugins/mobile-apps`)
- Build and deploy Power Apps code apps for mobile with native device capabilities.
- **Stack**: Expo + React Native + TypeScript, deployed via Power Apps Wrap
- ### [Power Apps Mobile Extension](plugins/power-apps-mobile-extension/README.md) (`plugins/power-apps-mobile-extension`)
- Build third-party native controls for wrapped Canvas apps and package them as verified
- `.ppmplugin` bundles with matching dispatcher PCF controls.
- **Stack**: Kotlin + Objective-C, Power Apps component framework, and Power Apps Wrap
- ### [Canvas Apps](plugins/canvas-apps/AGENTS.md) (`plugins/canvas-apps`)
- Author Power Apps Canvas Apps using the Canvas Authoring MCP server.
- **Stack**: PA YAML (`.pa.yaml`) authored via `CanvasAuthoringMcpServer`, requires .NET 10 SDK
- ### [Power Automate](plugins/power-automate/README.md) (`plugins/power-automate`)
- Build, edit, run, and debug Power Automate cloud flows via the FlowAgent MCP server.
- **Stack**: Node.js 18+, Azure CLI (`az login`), self-contained MCP bundle
- ### [Process Intelligence](plugins/process-intelligence/README.md) (`plugins/process-intelligence`)
- Analyze Power Automate Process Mining data, including bottlenecks, variants,
- cohorts, rework and object-centric executions through guided MCP workflows.
- **Skills**: `/analytics` and `/investigate-process` guide analysis;
- `/analyze-performance`, `/analyze-variants`, `/analyze-drivers`, `/compare-cohorts`,
- `/derive-metric` and `/analyze-objects` answer focused questions.
- `/setup` and `/report-issue` handle connection setup and support drafts.
- See the [skill catalog](plugins/process-intelligence/README.md#skills).
- **Stack**: Node.js 22+ (maintained LTS recommended), Azure CLI, self-contained MCP bundle
- GCC, GCC High, DoD and Mooncake are not supported yet.
- ### [Dataverse](https://github.com/microsoft/Dataverse-skills) (external)
- Work with Microsoft Dataverse: connect to an environment, query and change records, manage tables and columns, and handle security, administration, and solutions.
- **Stack**: Dataverse MCP server, Dataverse CLI, Python SDK, and PAC CLI
- This plugin is maintained in [microsoft/Dataverse-skills](https://github.com/microsoft/Dataverse-skills), and this marketplace installs it straight from that repository's default branch.
- Report issues and send changes there.
- If you already installed `dataverse` from the `dataverse-skills` marketplace, keep only one of the two installs so its skills are not loaded twice.
- ## Running Without Interruption
- Plugins in this repo may invoke multiple tools (file edits, shell commands, MCP servers) during a session, which can result in frequent approval prompts. Use the options below to reduce or eliminate these interruptions.
- > **Warning**: Auto-approval options give the agent the same access you have on your machine. Only use these in trusted or sandboxed environments.
- ### GitHub Copilot CLI
- #### Option 1 — Allow specific tools (recommended)
- Pre-approve only the tools your workflow needs:
- ```bash
- copilot --allow-tool 'write' --allow-tool 'shell(npm run build)' --allow-tool 'shell(pac *)'
- ```
- #### Option 2 — Allow all tools in Copilot
- ```bash
- copilot --allow-all-tools
- ```
- To allow everything except dangerous commands:
- ```bash
- copilot --allow-all-tools --deny-tool 'shell(rm)' --deny-tool 'shell(git push)'
- ```
- See the [Copilot CLI docs](https://docs.github.com/en/copilot/how-tos/use-copilot-agents/use-copilot-cli) for the full reference.
- ### Claude Code
- #### Option 1 — Permission mode (recommended)
- Set the `acceptEdits` mode to auto-approve file edits while still prompting for shell commands:
- ```jsonc
- // .claude/settings.json (project-level) or ~/.claude/settings.json (user-level)
- {
- "defaultMode": "acceptEdits",
- "permissions": {
- "allow": [
- "Bash(npm run *)",
- "Bash(git *)",
- "Bash(pac *)"
- // add other commands your workflow needs
- ]
- }
- }
- ```
- #### Option 2 — Allow all tools
- Press <kbd>Shift</kbd>+<kbd>Tab</kbd> during a session to cycle to **auto-accept** mode, or launch with:
- ```bash
- claude --dangerously-skip-permissions
- ```
- See the [Claude Code permissions docs](https://code.claude.com/docs/en/permissions) for the full reference.
- ## Documentation
- - [Power Pages Code Sites](https://learn.microsoft.com/en-us/power-pages/configure/create-code-sites)
- - [Power Pages REST API](https://learn.microsoft.com/en-us/rest/api/power-platform/powerpages/websites)
- - [Generative Pages with External Tools](https://learn.microsoft.com/en-us/power-apps/maker/model-driven-apps/generative-page-external-tools)
- - [Build Model-Driven Apps with External Tools](https://learn.microsoft.com/en-us/power-apps/maker/model-driven-apps/model-driven-app-external-tools)
- - [Power Apps Code Apps](https://learn.microsoft.com/power-apps/developer/code-apps/)
- - [PAC CLI Reference](https://learn.microsoft.com/en-us/power-platform/developer/cli/reference)
- ## Contributing
- To work on the plugins, see [CONTRIBUTING.md](CONTRIBUTING.md) and the [developer guide](docs/development.md).
- The developer guide covers loading a plugin from a local checkout and how the repository fits together.
- ## License
- The code in this repo is licensed under the [MIT](LICENSE) license.
- ## Trademarks
- This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft
- trademarks or logos is subject to and must follow
- [Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/legal/intellectualproperty/trademarks/usage/general).
- Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
- Any use of third-party trademarks or logos are subject to those third-party's policies.
- ## Telemetry
- Some plugins send usage data to Microsoft to help improve them: Power Pages, Model-driven apps, PCF, Mobile apps, Power Apps Mobile extensions, and Power Automate.
- It is on by default.
- - **What's sent:** which skill ran, the plugin version, your AI assistant, and your operating system, and for some skills whether they succeeded and how long they took.
- When you're signed in to Power Platform, it can also include your organization and tenant IDs, and for some plugins your Microsoft Entra user ID.
- - **What's never sent:** what you type, file paths, site or app names, error messages, or usernames.
- - **To turn it off** for a plugin, ask your assistant to "turn off telemetry", or run the plugin's telemetry skill, such as `/power-pages:telemetry off`.
- In scripts and CI, set the plugin's environment variable instead, such as `POWER_PLATFORM_SKILLS_TELEMETRY_POWER_PAGES_OPTOUT=1`.
- Turning it off stops sending; the plugin still keeps a local log, so you can see what would have been sent.
- Each plugin's README lists exactly what it sends, and the [telemetry guide](shared/telemetry/README.md) has the full details.
- See also the [Microsoft Privacy Statement](https://www.microsoft.com/privacy/privacystatement).
plugins/mobile-apps/scripts/lib/telemetry/lib/agent-info.js · Bundled script · 215 lines · 1 finding marked
- "use strict";
- const fs = require("node:fs");
- const path = require("node:path");
- const { runNative } = require("./native-exec");
- let pacCliVersionCache;
- // Reads the PAC CLI version once per process via `pac --version`, started by
- // absolute path from PATH (see native-exec.js). Best-effort
- // and fail-closed: missing executable, timeout, or unparseable output all
- // resolve to "".
- //
- // PAC 2.x prints the version banner ("Version: X.Y.Z+...") to stdout as part
- // of its preamble but then treats `--version` as an unknown command and
- // exits with status 1. execFileSync throws on non-zero exit, attaching the
- // captured stdout to err.stdout — so we parse that fallback path too.
- function readPacCliVersion(opts = {}) {
- if (pacCliVersionCache !== undefined) return pacCliVersionCache;
- if (opts._exec === false) {
- pacCliVersionCache = "";
- return "";
- }
- const exec = typeof opts._exec === "function" ? opts._exec : runNative;
- let stdout = "";
- try {
- stdout = exec("pac", ["--version"], {
- encoding: "utf8",
- timeout: 8000,
- stdio: ["ignore", "pipe", "pipe"],
- });
- } catch (err) {
- stdout = (err && err.stdout) ? String(err.stdout) : "";
- }
- const match = String(stdout || "").match(/Version:\s*(\d+\.\d+\.\d+(?:\.\d+)?)/);
- pacCliVersionCache = match ? match[1] : "";
- return pacCliVersionCache;
- }
- // Test seam.
- function _resetCache() {
- pacCliVersionCache = undefined;
- }
- // Parses a dotted semver out of the AI_AGENT env var. Claude Code sets
- // AI_AGENT=claude-code_<maj>-<min>-<patch>_agent (e.g.
- // "claude-code_2-1-156_agent"); the version segment uses dashes, so we
- // normalize separators to dots. The "claude-code" name prefix carries no
- // digits, so the first numeric run is the version.
- function parseVersionFromAiAgent(aiAgent) {
- if (typeof aiAgent !== "string") return "";
- const match = aiAgent.match(/\d+(?:[._-]\d+)+/);
- return match ? match[0].replace(/[._-]/g, ".") : "";
- }
- // Reads the Claude Code CLI version. Primary source is the installed
- // package.json: the hook subprocess inherits CLAUDE_CODE_EXECPATH from Claude
- // Code, and jumping one directory above the executable's bin/ lands on the npm
- // package root. That layout only exists for npm-global installs — the native
- // installer ships a standalone binary with no sibling package.json — so when
- // the read yields nothing, fall back to the version carried in AI_AGENT, which
- // Claude Code sets regardless of install method.
- function readClaudeCodeVersion(env) {
- const execPath = env.CLAUDE_CODE_EXECPATH;
- if (execPath) {
- try {
- const pkgPath = path.join(path.dirname(execPath), "..", "package.json");
- const pkg = JSON.parse(fs.readFileSync(pkgPath, "utf8"));
- if (pkg && typeof pkg.version === "string") return pkg.version;
- } catch {
- // pkg unreadable; fall through to the AI_AGENT fallback
- }
- }
- return parseVersionFromAiAgent(env.AI_AGENT);
- }
- function isTruthyEnv(value) {
- if (typeof value !== "string") return false;
- const normalized = value.trim().toLowerCase();
- return normalized !== "" && normalized !== "0" && normalized !== "false";
- }
- function firstEnv(env, keys) {
- for (const key of keys) {
- if (typeof env[key] === "string" && env[key]) return env[key];
- }
- return "";
- }
- function normalizeAgentName(name) {
- return String(name || "").toLowerCase().replace(/[^a-z0-9]/g, "");
- }
- const AGENT_DETECTORS = [
- {
- name: "Claude Code",
- aliases: ["claude", "claudecode"],
- isPresent: (env) => isTruthyEnv(env.CLAUDECODE),
- version: readClaudeCodeVersion,
- },
- {
- name: "Copilot CLI",
- aliases: ["copilot", "copilotcli", "githubcopilot", "githubcopilotcli"],
- isPresent: (env) => isTruthyEnv(env.COPILOT_CLI),
- version: (env) =>
- firstEnv(env, ["COPILOT_CLI_BINARY_VERSION", "COPILOT_CLI_VERSION"]),
- },
- {
- name: "Codex",
- aliases: ["codex", "codexcli", "openaicodex"],
- isPresent: (env) => isTruthyEnv(env.CODEX_CLI) || isTruthyEnv(env.CODEX),
- version: (env) =>
- firstEnv(env, [
- "CODEX_CLI_BINARY_VERSION",
- "CODEX_CLI_VERSION",
- "CODEX_VERSION",
- ]) || parseVersionFromAiAgent(env.AI_AGENT),
- },
- {
- name: "OpenCode",
- aliases: ["opencode", "opencodecli", "open_code"],
- isPresent: (env) => isTruthyEnv(env.OPENCODE_CLI) || isTruthyEnv(env.OPENCODE),
- version: (env) =>
- firstEnv(env, [
- "OPENCODE_CLI_BINARY_VERSION",
- "OPENCODE_CLI_VERSION",
- "OPENCODE_VERSION",
- ]) || parseVersionFromAiAgent(env.AI_AGENT),
- },
- {
- name: "Hermes",
- aliases: ["hermes", "hermescli", "hermesagent"],
- isPresent: (env) =>
- isTruthyEnv(env.HERMES_CLI) ||
- isTruthyEnv(env.HERMES) ||
- isTruthyEnv(env.HERMES_AGENT),
- version: (env) =>
- firstEnv(env, [
- "HERMES_CLI_BINARY_VERSION",
- "HERMES_CLI_VERSION",
- "HERMES_AGENT_VERSION",
- "HERMES_VERSION",
- ]) || parseVersionFromAiAgent(env.AI_AGENT),
- },
- {
- name: "OpenClaw",
- aliases: ["openclaw", "openclawcli"],
- Note: Quoted as data in code: Matches the ClawHavoc malware campaign against agent skills (Koi Security, February 2026; samples in the openclaw/skills archive)
- Line 147 on GitHub
- isPresent: (env) =>
- isTruthyEnv(env.OPENCLAW_CLI) || isTruthyEnv(env.OPENCLAW),
- version: (env) =>
- firstEnv(env, [
- "OPENCLAW_CLI_BINARY_VERSION",
- "OPENCLAW_CLI_VERSION",
- "OPENCLAW_VERSION",
- ]) || parseVersionFromAiAgent(env.AI_AGENT),
- },
- ];
- function detectorForName(name) {
- const normalized = normalizeAgentName(name);
- return AGENT_DETECTORS.find((detector) =>
- detector.aliases.some((alias) => normalizeAgentName(alias) === normalized)
- );
- }
- function detectFromAiAgent(env) {
- const aiAgent = env.AI_AGENT;
- if (typeof aiAgent !== "string" || !aiAgent) return null;
- const normalized = normalizeAgentName(aiAgent);
- const detector = AGENT_DETECTORS.find((candidate) =>
- candidate.aliases.some((alias) => normalized.includes(normalizeAgentName(alias)))
- );
- if (!detector) return null;
- return {
- aiAgentName: detector.name,
- aiAgentVersion: detector.version(env) || parseVersionFromAiAgent(aiAgent),
- };
- }
- function detectKnownAgent(env) {
- for (const detector of AGENT_DETECTORS) {
- if (detector.isPresent(env)) {
- return {
- aiAgentName: detector.name,
- aiAgentVersion: detector.version(env) || "",
- };
- }
- }
- return detectFromAiAgent(env);
- }
- // Detects the AI agent host. Prefers explicit env vars; falls back to
- // built-in detection for known CLI hosts. When AI_AGENT_NAME is set explicitly
- // but AI_AGENT_VERSION is empty, backfill the version from whichever detector
- // matches — avoids emitting an empty aiAgentVersion just because the settings
- // file only carried half the pair.
- function readAiAgent(env = process.env) {
- const explicitName = env.AI_AGENT_NAME;
- const explicitVersion = env.AI_AGENT_VERSION;
- if (explicitName) {
- let version = explicitVersion || "";
- if (!version) {
- const explicitDetector = detectorForName(explicitName);
- const detected = detectKnownAgent(env);
- if (explicitDetector) version = explicitDetector.version(env) || "";
- if (!version && detected) version = detected.aiAgentVersion || "";
- }
- return { aiAgentName: explicitName, aiAgentVersion: version };
- }
- const detected = detectKnownAgent(env);
- if (detected) return detected;
- return { aiAgentName: "", aiAgentVersion: "" };
- }
- module.exports = { readPacCliVersion, readAiAgent, _resetCache };
plugins/model-apps/scripts/lib/cli-failure.js · Bundled script · 137 lines · 1 finding marked
- 'use strict';
- // How a CLI child process failed, and how long one Azure CLI call may take.
- //
- // The auth preflight and every Dataverse token read shell out to `az` (check-auth also to `pac`), and
- // each failure used to come back as the same thing: null. A slow Azure CLI therefore read as a missing
- // or signed-out one — a cached-token read was measured at 44.6 s on a busy machine, past the 30 s
- // budget, and check-auth reported `az_missing` ("not installed") while every script said "run az login".
- // Neither was the problem. A failure now has one of three kinds, and a timeout is reported as one.
- const AZ_TIMEOUT_ENV = 'POWER_PLATFORM_SKILLS_AZ_TIMEOUT_MS';
- const DEFAULT_AZ_TIMEOUT_MS = 60000;
- // The range an override may take: 1 s to 15 min. Shared by the parser and the advice below, so the
- // advice can never suggest a value the parser would reject — and so fall back to the 60 s default.
- const MIN_AZ_TIMEOUT_MS = 1000;
- const MAX_AZ_TIMEOUT_MS = 900000;
- // The budget for one Azure CLI call: 60 s, or POWER_PLATFORM_SKILLS_AZ_TIMEOUT_MS milliseconds (1 s to
- // 15 min). An unusable value keeps the default rather than failing the run — this is a tuning knob for
- // a slow machine, not an input a mistake in which should stop the work.
- function azTimeoutMs(env = process.env) {
- const n = Number(env && env[AZ_TIMEOUT_ENV]);
- return Number.isInteger(n) && n >= MIN_AZ_TIMEOUT_MS && n <= MAX_AZ_TIMEOUT_MS ? n : DEFAULT_AZ_TIMEOUT_MS;
- }
- // 'timeout' | 'missing' | 'failed' for an error from the process runner, or null for none. The shapes
- // Node gives each case (https://nodejs.org/api/child_process.html):
- // execFileSync / spawnSync past `timeout` code 'ETIMEDOUT'
- // execFile past `timeout` killed: true, signal: the kill signal, code: null
- // not on PATH code 'ENOENT' — the runner resolves the executable before
- // it spawns anything ("spawn az ENOENT: not found on PATH")
- // Any other code (a non-zero exit, output past maxBuffer — which also kills the child) is 'failed'.
- function cliFailureKind(error) {
- if (!error) return null;
- if (error.code === 'ETIMEDOUT') return 'timeout';
- if (error.code === 'ENOENT') return 'missing';
- if (typeof error.code === 'string') return 'failed';
- if (error.killed === true && error.signal) return 'timeout';
- if (/\bENOENT\b/.test(String(error.message || ''))) return 'missing';
- return 'failed';
- }
- // What to tell the user when `command` ran out of time: that it was slow, and how to allow it longer. The
- // suggested budget is double the one that ran out (at least 2 min), CAPPED at the maximum the parser
- // accepts — a suggestion above it would be rejected and quietly put the budget back to 60 s. Once the
- // budget is already the maximum, more time is not the remedy, and the advice says so.
- function azTimeoutAdvice(command, ms = azTimeoutMs()) {
- const ranOut = `\`${command}\` did not answer within ${Math.round(ms / 1000)} s.`;
- if (ms >= MAX_AZ_TIMEOUT_MS) {
- return `${ranOut} That is already the longest ${AZ_TIMEOUT_ENV} allows (${MAX_AZ_TIMEOUT_MS / 60000} min), so `
- + `waiting longer will not help: run \`${command}\` yourself to see whether Azure CLI answers at all, then retry.`;
- }
- const longer = Math.min(Math.max(ms * 2, 120000), MAX_AZ_TIMEOUT_MS);
- return `${ranOut} Azure CLI can take that long to start on a busy machine — retry, or allow it longer with `
- + `${AZ_TIMEOUT_ENV}=${longer}.`;
- }
- // One argument of a command that a message tells the user — or the agent driving the skill — to paste, written so that pasting the command hands the
- // program it runs (`node`) exactly this value, as ONE argument, in the shells the skill's own commands are written for: PowerShell (Windows PowerShell 5.1
- // and PowerShell 7) and the POSIX shells (sh, bash, zsh). The skill's instructions quote arguments in single quotes ('<working-dir>/<file>.tsx'); cmd.exe,
- // which reads no single quotes, is not one of them.
- // letters and digits of any script, and `_ . / : -` written bare: no shell reads anything in them
- // (not a leading `-`)
- // anything else single-quoted: inside '…' neither PowerShell nor a POSIX shell expands, substitutes or splits
- // anything, so `;`, `$(…)`, backticks, `|`, `&`, globs, `\` and white space stay literal
- // null — no spelling, so the caller writes a placeholder and names the value outside the command (commandArgOrPlaceholder) — for:
- // a single quote, or one PowerShell reads as one PowerShell doubles a quote, a POSIX shell closes and reopens one: no spelling is literal in both
- // (‘ ’ ‚ ‛), a line break or another control
- // character (a tab is fine)
- // a double quote; white space with a `\` at the Windows PowerShell does not hand a native program its arguments as they are: it joins them into one
- // end; the empty value command line, wrapping a value that holds white space in double quotes and escaping nothing, so the
- // program drops a `"` ('x"y.tsx' arrives as xy.tsx) and reads the closing quote after a final `\` as
- // an escaped one ('C:\Dev User\' arrives as C:\Dev User"); an empty value is not passed at all.
- // PowerShell 7.3 and later pass all three as they are; Windows PowerShell 5.1 is still the one
- // Windows ships.
- // exactly `--%` PowerShell's stop-parsing token: both PowerShells take it for the token even quoted, and drop it
- // Measured on Windows PowerShell 5.1 and PowerShell 7.6 (tests/cli-failure.test.js runs every spelling through each shell it finds and reads node's argv).
- // See https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_parsing#passing-arguments-that-contain-quote-characters and
- // https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_parsing#the-stop-parsing-token.
- // A path can come from an untrusted checkout, so a value is written bare only when it is plain: a file named `x;rm -rf ~;.tsx`, written bare or in double
- Note: Quoted as data in code: Runs `rm -rf` against a root or home-directory path
- Line 80 on GitHub
- // quotes, would run its second half when the advice is pasted.
- const BARE_ARG = /^(?!-)[\p{L}\p{N}_./:-]+$/u;
- const UNQUOTABLE = /['"\u2018\u2019\u201A\u201B\p{Zl}\p{Zp}]|[^\P{Cc}\t]/u;
- function commandArg(value) {
- const text = String(value);
- if (BARE_ARG.test(text)) return text;
- if (UNQUOTABLE.test(text) || text === '' || text === '--%' || (/\s/u.test(text) && text.endsWith('\\'))) return null;
- return `'${text}'`;
- }
- // commandArg's spelling of `value`, or — when it has none — `placeholder` (`<file>`), with the sentence a message adds to name the value as data, never as part of
- // a command.
- function commandArgOrPlaceholder(value, placeholder) {
- const arg = commandArg(value);
- if (arg !== null) return { arg, note: '' };
- return {
- arg: placeholder,
- note: `${placeholder} is ${JSON.stringify(String(value))}; it is not written into the command because no way of writing it reaches the command unchanged in both PowerShell and a POSIX shell.`,
- };
- }
- // The `--authorize <approval>` flag a message tells the maker to paste, as ONE argument. An approval is built from a name the maker wrote (a view, a form, a rule,
- // a dashboard key), so it can hold white space — `adopt:view:contoso_item/Declared Items` — and an unquoted paste reaches the CLI as two arguments
- // (`adopt:view:contoso_item/Declared`, `Items`), which it rejects as an approval nothing declares.
- // A spelling is printed only when it reaches Windows PowerShell 5.1, PowerShell 7 and the POSIX shells as that one unchanged argument (measured in each):
- // plain (letters, digits, `_ . / : -`) written bare, exactly as before: `--authorize adopt:view:contoso_item/Items`
- // white space and ordinary punctuation double-quoted, the spelling the printed approvals already used for a form, a rule and a process flow:
- // `--authorize "adopt:view:contoso_item/Declared Items"`
- // a `$`, a backtick, `\`, `!` or a curly double quote, and no quote of any kind
- // commandArg's single-quoted spelling, literal in all three: `--authorize 'adopt:view:contoso_item/cost $5'`
- // anything else (a `"`; an apostrophe together with one of the characters above; a final `\`; a control character)
- // no spelling is printed. The three shells quote these characters differently — Windows PowerShell 5.1 in particular joins
- // its arguments into one command line and re-splits it, so a `"` followed by white space is cut in two whatever is written
- // around it — and a spelling that is wrong in one of them hands the CLI a different, shortened key. The message gives the
- // exact key as a JSON string and says to pass that key as ONE `--authorize` argument.
- // a line break (`\n`, `\r`, U+2028, U+2029) or NUL (U+0000)
- // cannot be given at all: the approval parser (build-model-app.js authorizationKeys) reads a name with `.`, which stops at a
- // line break, and refuses NUL by name (no operating system passes NUL in a process argument), so it refuses such a key
- // whatever the shell does; the message says so.
- // Double quotes rather than commandArg's single quotes keep the spelling already printed (and pinned) for forms, rules and process flows.
- const DOUBLE_QUOTE_UNSAFE = /["$`\\!\u201C\u201D\u201E\u201F\p{Zl}\p{Zp}]|[^\P{Cc}\t]/u;
- const LINE_BREAK = /[\n\r\u2028\u2029]|\u0000/;
- function authorizeFlag(approval) {
- const text = String(approval);
- if (BARE_ARG.test(text)) return `--authorize ${text}`;
- if (text !== '' && !DOUBLE_QUOTE_UNSAFE.test(text)) return `--authorize "${text}"`;
- if (LINE_BREAK.test(text)) {
- return `--authorize <approval> — <approval> is ${JSON.stringify(text)}; it holds ${text.includes('\u0000') ? 'a NUL character (U+0000), which no command-line argument can carry and' : 'a line break, which'} the build's approval reader does not accept in a name, so this approval cannot be given: rename the item so its name has none`;
- }
- // Windows PowerShell 5.1 wraps an argument that holds white space in double quotes itself, so a final `\` would escape that closing quote.
- const single = text.endsWith('\\') ? null : commandArg(text);
- if (single !== null) return `--authorize ${single}`;
- return `--authorize <approval> — <approval> is exactly the JSON string ${JSON.stringify(text)} (decode its escapes); its characters are quoted differently by each shell, so pass that exact key as ONE --authorize argument, for example by asking the agent to run the build with it`;
- }
- module.exports = { AZ_TIMEOUT_ENV, DEFAULT_AZ_TIMEOUT_MS, MIN_AZ_TIMEOUT_MS, MAX_AZ_TIMEOUT_MS, azTimeoutMs, cliFailureKind, azTimeoutAdvice, commandArg,
- commandArgOrPlaceholder, authorizeFlag };
Ratings and comments
Sign in to rate this skill.
Sign inFree to use. If it’s helped, pass it on.