Comprehensive toolkit for Power Apps Code Apps development with specialized agents, agent skills and sub-agents, and code generation tools.
The CodeApps Toolkit is a Claude Code plugin that provides specialized agents, sub-agents for workflow automation, and code generation tools for building Power Apps Code Apps—custom web applications built with React + TypeScript that run within Power Apps using the Power Platform SDK.
Before installing the CodeApps Toolkit, ensure you have the following:
- Node.js (LTS version 18.x or higher)
- Power Platform CLI (PAC CLI) (latest version)
- Download: https://aka.ms/PowerPlatformCLI
- Verify with:
pac
- Git (for cloning the plugin)
- Power Platform Environment with Code Apps feature enabled
- Power Apps Premium License (required for Code Apps)
- Visual Studio Code with Power Platform Tools extension
- Microsoft 365 Developer Account (for testing)
- Basic knowledge of React and TypeScript
# Check Node.js version
node --version # Should be v18.x or higher
# Check PAC CLI installation
pac # Should show version info and available commands
# Check Git installation
git --version
# Authenticate with Power Platform
pac auth listCode generation skills include production-ready TypeScript templates with:
- Service Layer Templates: Dataverse and connector patterns with best practices built-in
- React Query Templates: Complete hooks with proper cache management
- Component Templates: Fluent UI v9 list views and forms
- Validation Scripts: Automated checks for common issues
- Working Examples: Complete reference implementations (1,600+ lines)
- codeapps-expert: Coordinator agent for orchestrating workflows
- codeapps-init: Project initialization specialist
- codeapps-dataverse: Dataverse integration specialist
- codeapps-connector: Power Platform connector specialist
- codeapps-deploy: Deployment and ALM specialist
- init-codeapp: Initialize new projects with proper configuration
- add-datasource: Add Dataverse tables or connectors
- deploy-codeapp: Deploy to Power Platform with validation
- gen-service: Generate service layer wrappers
- gen-hook: Generate React Query hooks
- gen-component: Generate Fluent UI v9 components
- fix-codeapp-issue: Diagnose and fix common issues
- codeapps-validator: Comprehensive project validation
- build-lint-validator: TypeScript and ESLint validation
CodeApps Toolkit is a Claude Code plugin. Install it once and use it across all your projects.
# Windows
git clone https://github.com/ramakrishnan24689/codeapps-toolkit.git "%USERPROFILE%\.claude\plugins\codeapps-toolkit"
# macOS/Linux
git clone https://github.com/ramakrishnan24689/codeapps-toolkit.git ~/.claude/plugins/codeapps-toolkitRestart Claude Code to load the plugin.
/plugin
You should see codeapps-toolkit listed with status information.
If you're developing or testing the plugin locally:
# Test plugin from a local directory
claude --plugin-dir ./codeapps-toolkit
# Or test multiple plugins
claude --plugin-dir ./codeapps-toolkit --plugin-dir ./another-plugin/init-codeapp my-todo-app
Or simply ask:
Initialize a new Code App called todo-app
What happens:
- Creates project from official Microsoft template
- Configures package.json for dual-server development
- Sets up vite.config.ts with
base: './'(critical for deployment) - Runs
pac code initto register with Power Platform - Validates entire setup
Add Dataverse Table:
/add-datasource dataverse account
Add Power Platform Connector:
/add-datasource connector shared_office365users <connection-id>
Or ask naturally:
Add the Contacts Dataverse table
Connect to Office 365 Users
What happens:
- Runs
pac code add-data-source - Generates service layer wrapper (avoiding common pitfalls)
- Creates React Query hooks
- Provides usage examples
/deploy-codeapp
Or:
Deploy my app to Power Platform
What happens:
- Pre-deployment validation (codeapps-validator)
- Build quality check (build-lint-validator)
- Build application
- Deploy to Power Platform (
pac code push) - Post-deployment verification
Single Prompt:
Build me a Power Apps Code App for contacts management using the standard Dataverse contact table.
Show contact full names, email addresses, and phone numbers.
Include a list view to display all contacts and a form view to add or edit contacts.
What the agent does automatically:
- ✅ Creates project:
ContactsManager - ✅ Adds Dataverse contact datasource
- ✅ Generates ContactService with CRUD operations
- ✅ Generates React Query hooks (useContacts, useCreateContact, etc.)
- ✅ Generates ContactsList and ContactForm components
- ✅ Validates project structure and build
- ✅ Delivers working app in ~20-30 minutes
Result: Complete working app ready to run with npm run dev
Single Prompt:
Build me a Power Apps Code App for document management that connects to SharePoint.
Connect to the Shared Documents library at
https://contoso.sharepoint.com/teams/rrdev/Shared%20Documents
and allow users to list files, view file details, and upload new documents.
Library ID 18bcc28c-1d2c-42c8-a13e-e5e2fb6d9bb4
What the agent does automatically:
- ✅ Creates project:
DocumentManager - ✅ Adds SharePoint connector datasource
- ✅ Generates SharePoint connector service
- ✅ Generates React Query hooks for file operations
- ✅ Generates file list and upload components
- ✅ Validates and builds
- ✅ Delivers working SharePoint integration
Result: Complete SharePoint document management app
Deployment:
- One Prompt → Complete App: No manual skill invocation needed
- Autonomous Execution: Agent handles the entire workflow
- Multi-Source Support: Works with Dataverse AND connectors (SharePoint, SQL, Office 365, etc.)
- Production Ready: Generated code follows best practices
graph LR
A[Initialize] --> B[Add Data Sources]
B --> C[Generate Code]
C --> D[Develop Features]
D --> E[Validate]
E --> F[Deploy]
- Initialize Project (
/init-codeapp) - Add Data Sources (
/add-datasource) - Generate Code (
/gen-service,/gen-hook,/gen-component) - Develop Features (write your code)
- Validate (automatic with codeapps-validator)
- Deploy (
/deploy-codeapp)
You can also let the codeapps-expert agent coordinate everything:
I want to build a Power Apps Code App for todos that uses Dataverse
The expert agent will:
- Initialize the project
- Add Dataverse table
- Generate service layers and hooks
- Guide you through development
- Help with deployment
The plugin uses specialized agents for focused tasks:
| Agent | Use When | Example |
|---|---|---|
| codeapps-expert | Need guidance or complex workflows | "Help me build a Power Apps Code App" |
| codeapps-init | Creating new projects | "Initialize a new Power Apps Code App" |
| codeapps-dataverse | Working with Dataverse | "Add the Accounts table" |
| codeapps-connector | Adding connectors | "Connect to SQL Server" |
| codeapps-deploy | Deploying apps | "Deploy to production" |
Claude automatically delegates to the right agent based on your request. You don't need to know which agent handles what—just ask naturally!
Initialize a new Code Apps project with:
- Official Microsoft template
- Dual-server development setup (Vite + pac code run)
- vite.config.ts with
base: './' - Comprehensive validation
Example:
/init-codeapp employee-directory
Add Dataverse table or Power Platform connector:
- Generates service layer wrapper
- Creates React Query hooks
- Handles CodeApps-specific issues
Examples:
/add-datasource dataverse account
/add-datasource connector shared_sql <connection-id> dbo.Users myDatabase
Deploy to Power Platform with validation:
- Pre-deployment validation
- Build quality check
- Asset path verification
- Post-deployment verification
Examples:
/deploy-codeapp
/deploy-codeapp "Marketing Apps"
Generate service layer wrapper with:
- Proper error handling
- System-managed field exclusion (Dataverse)
- Boolean field handling
- Data transformations
Generate React Query hooks:
- Query hooks (fetching data)
- Mutation hooks (create, update, delete)
- Proper cache invalidation
- TypeScript types
Generate Fluent UI v9 components:
- List views
- Detail views
- Forms (create/edit)
Types: list, detail, form
Diagnose and fix common issues:
- 404 asset errors (missing
base: './') - Dataverse OData errors (system-managed fields)
- Boolean field type mismatches
- Authentication failures
- Build errors
# Step 1: Initialize
/init-codeapp my-app
# Step 2: Add Dataverse tables
/add-datasource dataverse todos
/add-datasource dataverse contacts
# Step 3: Generate UI components
/gen-component todos list
/gen-component todos form
# Step 4: Develop features
# (Write your custom React code)
# Step 5: Deploy
/deploy-codeapp
# Step 1: Initialize
/init-codeapp employee-lookup
# Step 2: Add connectors
/add-datasource connector shared_office365users <connection-id>
/add-datasource connector shared_sharepointonline <connection-id> Employees <site-url>
# Step 3: Generate code
/gen-service connector office365users
/gen-hook userprofile
# Step 4: Deploy
/deploy-codeapp
# Deployed app shows blank screen
/fix-codeapp-issue
# The skill will:
# 1. Diagnose the issue (missing base: './')
# 2. Fix vite.config.ts
# 3. Rebuild the app
# 4. Guide you to redeploy
- Always validate before deploying (automatic with
/deploy-codeapp) - Use service layer wrappers (never call generated services directly)
- Use connection references for better ALM
- Test locally before deploying (
npm run dev) - Follow feature-first structure (
src/features/<feature>/)
- Modify files in src/generated/ (they're auto-regenerated)
- Send system-managed fields to Dataverse (ownerid, statecode, timestamps)
- Use absolute paths in vite.config.ts (always use
base: './') - Skip validation before deployment
- Use generated services directly in components
export default defineConfig({
plugins: [react()],
base: './', // ✅ CRITICAL for deployment
build: {
outDir: 'dist',
assetsDir: 'assets',
},
})Without this: Deployed app shows blank screen with 404 errors for assets.
// ❌ WRONG
const payload = {
name: dto.name,
ownerid: '', // ❌ Never send
statecode: 0, // ❌ Never send
};
// ✅ CORRECT
const payload = {
name: dto.name,
// Dataverse sets ownerid, statecode automatically
};// ❌ WRONG
updates.isCompleted = value ? 1 : 0;
// ✅ CORRECT
updates.isCompleted = value as any;Symptom: App works locally but shows blank screen when deployed
Cause: Missing base: './' in vite.config.ts
Fix:
/fix-codeapp-issue
Or manually add base: './' and redeploy.
Symptom: PrimitiveValue node with non-null value... 'ownerid'
Cause: Sending system-managed fields
Fix:
/fix-codeapp-issue
Or review your service layer and remove system-managed fields.
Symptom: Cannot convert literal '1' to expected type 'Edm.Boolean'
Cause: Sending numeric value instead of boolean
Fix: Use as any type assertion:
updates.booleanField = value as any;Agents in this plugin use persistent memory to learn and improve:
- User-level memory: Patterns across all your projects
- Project-level memory: Project-specific conventions
- Cross-session learning: Agents remember common issues and solutions
See CHANGELOG.md for detailed version history and release notes.
Current version: 1.0.0
- Official Docs: https://learn.microsoft.com/power-apps/developer/code-apps/
- GitHub Template: https://github.com/microsoft/PowerAppsCodeApps
- PAC CLI Reference: https://learn.microsoft.com/power-platform/developer/cli/reference/code
- React Query: https://tanstack.com/query/latest
- Fluent UI v9: https://react.fluentui.dev/
This plugin is designed to be extended. To add new:
- Agents: Add to
agents/ - Skills: Add to
skills/ - Templates: Add to
templates/ - Scripts: Add to
scripts/
MIT
For issues or questions:
- Open an issue in the repository
- Refer to official Power Apps Code Apps documentation
- Use
/fix-codeapp-issueskill for common problems
Built by Ramakrishnan Raman
Powered by Claude Code - https://code.claude.com





