From sebastienlevert-m365-copilot-skills
Quickly scaffolds new Microsoft 365 Copilot declarative agent (M365 agent, copilot agent, agent, declarative copilot, copilot) projects using ATK CLI. Collects project information and creates the initial project structure. Use only when creating a new empty M365 Copilot agent project from scratch.
npx claudepluginhub joshuarweaver/cascade-code-general-misc-4 --plugin sebastienlevert-m365-copilot-skillsThis skill uses the workspace's default tool permissions.
Copy this command EXACTLY. Replace `<project-name>` with the user's project name:
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Checks Next.js compilation errors using a running Turbopack dev server after code edits. Fixes actionable issues before reporting complete. Replaces `next build`.
Copy this command EXACTLY. Replace <project-name> with the user's project name:
npx -p @microsoft/m365agentstoolkit-cli@latest atk new -n <project-name> -c declarative-agent -with-plugin type-spec -i false
| ❌ INVALID COMMAND | WHY IT FAILS |
|---|---|
atk init | DOES NOT EXIST - there is no init command |
atk init --template | DOES NOT EXIST - there is no init command or --template flag |
atk create | DOES NOT EXIST - there is no create command |
atk scaffold | DOES NOT EXIST - there is no scaffold command |
--template anything | DOES NOT EXIST - there is no --template flag |
--template declarative-copilot | DOES NOT EXIST - this is completely made up |
--template m365-agent | DOES NOT EXIST - this is completely made up |
Any command without npx -p @microsoft/m365agentstoolkit-cli@latest prefix | WILL FAIL - atk might not be installed globally |
✅ CORRECT:
npx -p @microsoft/m365agentstoolkit-cli@latest atk new -n my-agent -c declarative-agent -with-plugin type-spec -i false
❌ WRONG (DO NOT USE):
atk init my-agent --template declarative-copilot
❌ WRONG (DO NOT USE):
atk init my-agent --template m365-agent
❌ WRONG (DO NOT USE):
atk create my-agent
This skill does ONE thing: creates new M365 Copilot agent project structures. It:
All architecture, planning, implementation, and deployment is handled by the m365-agent-developer skill.
Use this skill ONLY when:
Do NOT use this skill when:
Follow these exact steps when creating a new M365 Copilot agent project:
Action: Verify the user wants to create a NEW M365 Copilot agent project.
Check for:
If existing project: Stop and recommend using m365-agent-developer skill.
Action: First, check if the current directory is empty. Then ask for the project name.
Directory Check (CRITICAL):
ls -A to check if current directory is empty.) when evaluating if directory is empty:
.claude, .copilot, .github are configuration/metadata folders❌ Error: Current directory is not empty!
This skill requires an empty directory to scaffold a new M365 Copilot agent project.
Please navigate to an empty directory or create a new one first.
If directory is empty, collect:
Example question:
What would you like to name your M365 Copilot agent project?
Action: Execute the scaffolding command, then move files from the ATK-created subfolder to the current directory.
Commands to execute sequentially:
npx -p @microsoft/m365agentstoolkit-cli@latest atk new -n <project-name> -c declarative-agent -with-plugin type-spec -i false
BEFORE YOU RUN ANY COMMAND, VERIFY:
npx -p @microsoft/m365agentstoolkit-cli@latestatk new (NOT atk init, NOT atk create)-c declarative-agent (NOT --template)-with-plugin type-spec-i falseIF YOUR COMMAND LOOKS LIKE ANY OF THESE, STOP - IT IS WRONG:
atk init ... → WRONG, use atk new--template ... → WRONG, use -c declarative-agentnpx -p @microsoft/m365agentstoolkit-cli@latest → WRONGParameters:
-n <project-name>: The project name provided by the user (ONLY parameter to customize)-c declarative-agent: Create a declarative agent (REQUIRED - do not change)-with-plugin type-spec: Include TypeSpec plugin scaffolding (REQUIRED - do not change)-i false: Non-interactive mode (REQUIRED - do not change)Note: ATK will create a subfolder named <project-name> with all project files.
mv <project-name>/* <project-name>/.* . 2>/dev/null || true
rmdir <project-name>
Why this is important:
Action: Provide a simple confirmation message and automatically continue to m365-agent-developer skill.
Message template:
✅ Project created in current directory: <absolute-current-directory-path>
Your empty M365 Copilot agent project structure is ready.
🎯 Continuing with the m365-agent-developer skill to help you design and implement your agent...
Then immediately invoke m365-agent-developer skill:
For detailed examples of how to use this skill, see the Examples Reference.
For detailed best practices when scaffolding M365 Copilot agent projects, see the Best Practices Reference.