add-action
Guide users through adding a new connector action to a Copilot Studio agent. Connector actions require UI-based connection setup,…
Generate and insert an Adaptive Card into a Copilot Studio topic using AdaptiveCardPrompt. Use when the user asks to add an adaptive card, rich card, form card, info card, confirmation card, or interactive card to a topic.
Claude Code
$ npx -y skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card --agent claude-code
Codex
$ npx skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card -a codex -y
Cursor
$ npx skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card -a cursor -y
Gemini CLI
$ npx skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card -a gemini-cli -y
GitHub Copilot
$ npx skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card -a github-copilot -y
OpenCode
$ npx skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card -a opencode -y
Windsurf
$ npx skills add microsoft/skills-for-copilot-studio --skill add-adaptive-card -a windsurf -y
user-invocable: false description: Generate and insert an Adaptive Card into a Copilot Studio topic using AdaptiveCardPrompt. Use when the user asks to add an adaptive card, rich card, form card, info card, confirmation card, or interactive card to a topic. argument-hint: <card-type> in <topic-name> allowed-tools: Bash(node *schema-lookup.bundle.js *), Read, Write, Edit, Glob context: fork agent: copilot-studio-author
Add an `AdaptiveCardPrompt` node to an existing Copilot Studio topic. Use this for all Adaptive Card scenarios — display-only cards, input forms, and confirmation flows.
1. **Auto-discover the agent directory**:
Glob: agents/**/agent.mcs.yml
NEVER hardcode an agent name.
2. **Clarify requirements** from the user if not specified:
3. **Read the target topic file** to understand its structure and find the correct insertion point.
4. **Verify the schema** if needed:
# Copilot Studio node schema
node ${CLAUDE_SKILL_DIR}/../../scripts/schema-lookup.bundle.js summary AdaptiveCardPrompt
# Adaptive Cards element schema (v1.6 — the version supported by Copilot Studio)
node ${CLAUDE_SKILL_DIR}/../../scripts/schema-lookup.bundle.js ac-summary TextBlock
node ${CLAUDE_SKILL_DIR}/../../scripts/schema-lookup.bundle.js ac-summary Input.Text
node ${CLAUDE_SKILL_DIR}/../../scripts/schema-lookup.bundle.js ac-search Action5. **Select and adapt the template** from [card-templates.md](card-templates.md) matching the requested type.
6. **Generate unique IDs** for all new nodes (format: `<nodeType>_<6-8 random alphanumeric>`).
7. **Insert the node(s)** at the correct position in the `actions` array using Edit.
8. **Validate** the updated topic file:
node ${CLAUDE_SKILL_DIR}/../../scripts/schema-lookup.bundle.js validate <topic-file.yml>9. **Inform the user** that they must push (VS Code Extension) and publish (Copilot Studio UI) before testing with `/chat-with-agent` or `/run-tests`.
`AdaptiveCardPrompt` is the correct node kind for all Adaptive Cards in Copilot Studio. The card JSON is embedded as a **multiline YAML literal string** under `card: |`.
- kind: AdaptiveCardPrompt
id: adaptiveCardPrompt_m9Kp2x
card: |
{
"type": "AdaptiveCard",
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"version": "1.5",
"body": [...],
"actions": [...]
}
output:
binding:
fieldId: Topic.MyVariable
outputType:
properties:
fieldId:
type: String**Rules**:
| Node | Use When | |------|----------| | `AdaptiveCardPrompt` | Any Adaptive Card — with or without input fields | | `SendActivity` | Plain text messages with optional `{}` variable interpolation |
Do NOT use `SendActivity` with an `attachments` array for Adaptive Cards.
Do NOT use `style: "Email"` or `style: "Tel"` for validation — these only change the mobile keyboard and do not validate on submit. Always use `regex`:
{
"type": "Input.Text",
"id": "email",
"label": "Email address",
"placeholder": "Enter your email address",
"isRequired": true,
"regex": "^[a-zA-Z0-9._%+\\-]+@[a-zA-Z0-9.\\-]+\\.[a-zA-Z]{2,}$",
"errorMessage": "Enter a valid email address"
}{
"type": "Input.Text",
"id": "mobile",
"label": "Mobile number",
"placeholder": "Enter your mobile number",
"isRequired": true,
"regex": "^[+]?[0-9][\\s\\-\\(\\)0-9]{6,14}$",
"errorMessage": "Enter a valid mobile number"
}| Approach | Validates on submit? | Notes | |----------|---------------------|-------| | `regex` | Yes — blocks submit if pattern fails | Use for email, phone, any format | | `isRequired: true` | Yes — blocks submit if empty | Mandatory fields | | `style: "Email"` | No | Keyboard hint only — never use for validation | | `style: "Tel"` | No | Keyboard hint only — never use for validation |
> **Rule**: Every `Input.ChoiceSet` (and any required input) must have a `label` property, or the VS Code extension raises `AdaptiveCardInputIsRequiredMissingLabel`.
output:
binding:
userName: Topic.UserName
userEmail: Topic.UserEmail
category: Topic.Category
outputType:
properties:
userName:
type: String
userEmail:
type: String
category:
type: StringCard JSON is static — Power Fx expressions and `{}` interpolation do not work inside the card body. Use `SendActivity` before or after `AdaptiveCardPrompt` for dynamic content:
- kind: SendActivity
id: sendMessage_Rz4Wq1
activity: "Hello {Topic.UserName}, pleaseA plugin for Claude Code, GitHub Copilot CLI, and VS Code that enables authoring, testing, and troubleshooting Microsoft Copilot Studio STANDARD agents through YAML files — directly from your terminal or editor.
Guide users through adding a new connector action to a Copilot Studio agent. Connector actions require UI-based connection setup,…
Add generative answer nodes (SearchAndSummarizeContent or AnswerQuestionWithAI) to a Copilot Studio topic. Use this instead of…
Add a global variable to a Copilot Studio agent. Use when the user needs a variable that persists across topics in the same…
Add a knowledge source (public website or SharePoint) to a Copilot Studio agent. Use when the user asks to add a knowledge…
Add or modify a node in an existing Copilot Studio topic. Use when the user asks to add a question, message, condition, variable,…
Add child agents, connected agents, or other multi-agent patterns to a Copilot Studio agent. Use when the user asks to create a…
Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid…
Design and build AI agents for any domain. Use when users: (1) ask to "create an agent", "build an assistant", or "design an AI…