
Deploy Site
Publish an existing Power Pages code site to a target Power Platform environment after PAC CLI auth and build checks are green.
Overview
deploy-site is an agent skill for the Ship phase that guides PAC CLI verification, authentication, environment confirmation, build, and upload of an existing Power Pages code site.
Install
npx skills add https://github.com/microsoft/power-platform-skills --skill deploy-siteWhat is this skill?
- End-to-end PAC CLI deploy flow: tooling check, authentication, environment confirmation, build, and upload
- Tracks all phases upfront with TaskCreate/TaskUpdate before execution
- Blocks deployment until PAC availability, auth, and target environment are verified
- Requires explicit user consent before any environment setting changes (e.g. unblocking JavaScript attachments)
- Runs plugin version check via check-version.js before guiding deploy steps
Adoption & trust: 78 installs on skills.sh; 349 GitHub stars; 3/3 security scanners passed (skills.sh audits).
What problem does it solve?
You have a built Power Pages code site locally but lack a repeatable, consent-aware path to authenticate PAC CLI and publish to the right environment.
Who is it for?
Solo builders who already cloned or scaffolded a Power Pages code site and need a structured PAC CLI publish run without guessing auth or environment steps.
Skip if: Greenfield Dataverse schema design, first-time site provisioning without a code site, or teams that want fully unattended tenant configuration changes without confirmation.
When should I use this skill?
The user wants to deploy, upload, or publish their Power Pages code site using PAC CLI.
What do I get? / Deliverables
After the skill completes, the code site is built and uploaded to the confirmed Power Pages environment with deployment blockers documented or resolved with your approval.
- Deployed or uploaded code site in the target environment
- Task-tracked deployment phase log
- Documented blockers or consent prompts for environment changes
Recommended Skills
Journey fit
Deployment is the last mile of shipping a code site—upload and publish after build artifacts exist. Launch under Ship is where solo builders move from local or CI builds to a live Power Pages environment.
How it compares
Use this structured deploy workflow instead of running undocumented pac commands from chat without environment or consent gates.
Common Questions / FAQ
Who is deploy-site for?
deploy-site is for solo and indie builders shipping Power Pages code sites with PAC CLI who want an agent to verify tooling, auth, and the target environment before upload.
When should I use deploy-site?
Use deploy-site in the Ship phase when you need to deploy, upload, or publish an existing code site; after activate-site or manual provisioning when the site exists and you are ready to go live.
Is deploy-site safe to install?
It can run Bash and touches cloud deployment credentials—review the Security Audits panel on this page and confirm environment changes before approving any PAC-driven setting updates.
SKILL.md
READMESKILL.md - Deploy Site
> **Plugin check**: Run `node "${CLAUDE_PLUGIN_ROOT}/scripts/check-version.js"` — if it outputs a message, show it to the user before proceeding. # Deploy Power Pages Code Site Guide the user through deploying an existing Power Pages code site to a Power Pages environment using PAC CLI. Follow a systematic approach: verify tooling, authenticate, confirm the target environment, build and upload the site, and handle any blockers. ## Core Principles - **Verify before acting**: Always confirm PAC CLI availability, authentication status, and the target environment before attempting any deployment. - **Use TaskCreate/TaskUpdate**: Track all progress throughout all phases — create the todo list upfront with all phases before starting any work. - **Never change environment settings without consent**: If deployment requires modifying environment configuration (e.g., unblocking JavaScript attachments), always explain the change and get explicit user permission first. **Initial request:** $ARGUMENTS --- ## Phase 1: Verify PAC CLI **Goal**: Ensure PAC CLI is installed and available on the system PATH **Actions**: 1. Create todo list with all 6 phases (see [Progress Tracking](#progress-tracking) table) 2. Run `pac help` to check if the PAC CLI is installed and available on the system PATH. ```bash pac help ``` 3. **If the command succeeds**: PAC CLI is installed. Proceed to Phase 2. 4. **If the command fails** (command not found / not recognized): 1. Inform the user that PAC CLI is required but not installed. 2. Fetch installation instructions from `https://aka.ms/PowerPlatformCLI` using the following approach: - Tell the user: "PAC CLI is not installed. You can install it by running:" ```bash dotnet tool install --global Microsoft.PowerApps.CLI.Tool ``` - If `dotnet` is also not available, direct the user to <https://aka.ms/PowerPlatformCLI> for full installation instructions including .NET SDK setup. 3. After installation, verify by running `pac help` again. 4. If it still fails, stop and ask the user to resolve the installation manually. **Output**: PAC CLI installed and verified --- ## Phase 2: Verify Authentication **Goal**: Ensure the user is authenticated with PAC CLI and has a valid session **Actions**: 1. Run `pac auth who` to check the current authentication status. ```bash pac auth who ``` 2. **If authenticated**: Extract the following values from the output: - **Environment name** and **URL** - **Environment ID** — the GUID after `Environment ID:` - **Cloud** — the value after `Cloud:` (e.g., `Public`, `UsGov`, `UsGovHigh`, `UsGovDod`, `China`) Proceed to Phase 3. 3. **If not authenticated**: 1. Inform the user they are not authenticated with PAC CLI. 2. Use `AskUserQuestion` to ask for the environment URL: | Question | Header | Options | |----------|--------|---------| | You are not authenticated with PAC CLI. Please provide your Power Pages environment URL (e.g., `https://org12345.crm.dynamics.com`) so I can authenticate you. | Auth | *(free text input via "Other")* | Provide two placeholder options to guide the user: - "I'll paste the URL" (description: "Select 'Other' below and paste your environment URL") - "I don't know my URL" (description: "You can find it in the Power Platform admin center under Environments > your environment > Environment URL") 3. Once the user provides the URL, run the authentication command: ```bash pac auth create