teams-app-developer
microsoft/skills
Crée, teste et déploie des applications Microsoft 365 et des agents pour Teams et Copilot à l’aide de l’ATK CLI, avec des sous-compétences pour la création de projets, les tests locaux, le déploiement dans le cloud, le dépannage et la migration de Slack vers Teams.
...Développer toutBoîte à outils des agents Microsoft 365
Créez des agents Microsoft 365 et des applications Teams à l'aide de l'interface de ligne de commande (CLI) ATK.
Directives de comportement de l'IA
Stratégie de test : Privilégiez Agents Playground (plus rapide, aucune configuration M365 requise). N'utilisez le flux de travail Teams que si l'utilisateur en fait explicitement la demande.
Variables d'environnement : Ne codifiez JAMAIS de secrets ni ne créez de valeurs fictives. Demandez toujours aux utilisateurs les valeurs réelles.
Gestion des erreurs : Lisez attentivement les messages d'erreur. Vérifiez
env/.env.local,.localConfigsetatk auth list. Pièges courants :AADSTS7000229→aadApp/createmanque degenerateServicePrincipal: truedans le fichier YAML — ajoutez-le et reprovisionnezTENANT_IDmanquant dans.localConfigs→ le SDK utilise une autorité de jeton incorrecte → erreur 401 du connecteur Bot- L'erreur 401 persiste après la correction de l'authentification → l'URL du tunnel devtunnel est peut-être bloquée — créez un tunnel frais
- Consultez troubleshoot/troubleshoot.md pour les étapes de diagnostic complètes
Commandes à longue exécution — ATTENDRE la fin :
atk new,atk provision,atk deploypeuvent prendre plusieurs minutes- Attendez toujours la fin de l'exécution avant d'effectuer l'étape suivante (délai d'attente 120000ms+)
Démarrage du service local — Blocage du terminal (prévu) :
npm run dev,npm start,python app.py,devtunnel host, etc. bloqueront le terminal — le processus s'exécute indéfiniment- Exécutez TOUJOURS en tant que processus en arrière-plan (
isBackground=true) — N'utilisez JAMAISisBackground=falsepour ces commandes - N'ATTENDEZ PAS qu'il « termine » — vérifiez le démarrage en recherchant « listening on port » ou l'URL du tunnel dans la sortie
- Si des erreurs apparaissent, lisez les journaux, diagnostiquez, corrigez et redémarrez
- Utilisez un NOUVEAU terminal pour lancer Agents Playground ou ouvrir l'URL de sideloading Teams
Surveiller les journaux de l'application : Vérifiez périodiquement la sortie du terminal en arrière-plan pour détecter les erreurs d'exécution. Si l'application plante, lisez l'erreur, corrigez la cause racine et redémarrez.
Balises de télémétrie : Avant d'exécuter des commandes CLI
atk, définissez la variable d'environnement de session afin que toutes les invocations de la CLI soient marquées comme initiées par une compétence :export ATK_CLI_SKILL=trueExécutez cette commande une fois au début de la session. Toutes les commandes
atkultérieures dans le même terminal l'hériteront.
Configuration de la CLI ATK
atk --version # Doit être > 1.1.5-beta
Si ATK n'est pas trouvé ou si la version est trop ancienne :
npm i -g @microsoft/m365agentstoolkit-cli@beta
Options globales de la CLI
| Option | Signification | Recommandation |
|---|---|---|
| `-i` | Mode interactif | Toujours utiliser `-i false` dans l'automatisation pour éviter les blocages |
| `-f` | Dossier du projet | Par défaut, il s'agit du répertoire actuel, utilisé lors de la spécification d'un dossier personnalisé. Lors de l'initialisation d'un nouveau projet, il s'agit du dossier parent dans lequel le dossier du projet sera créé. |
| `-h` | Aide sur la commande | Utilisez `atk |
Compétences secondaires
| Compétence secondaire | Quand l'utiliser | Référence |
|---|---|---|
| **create-project** | Générer un nouveau projet à partir d'un modèle, choisir le modèle, `atk new` | create-project/create-project.md |
| **test-playground** | Tester localement avec Agents Playground, `agentsplayground`, test rapide | test-playground/test-playground.md |
| **test-teams** | Exécuter sur Teams, devtunnel, sideloading, test Teams, tester dans Copilot | test-teams/test-teams.md |
| **provision-deploy** | Provisionner les ressources Azure, déployer dans le cloud, `atk provision`, `atk deploy` | provision-deploy/provision-deploy.md |
| **troubleshoot** | Corriger les erreurs, 401, conflits de ports, erreurs YAML, bots obsolètes | troubleshoot/troubleshoot.md |
| **slack-to-teams** | Migration d'un bot Slack vers Teams, pontage interplateformes, Block Kit vers Adaptive Cards | slack-to-teams/SKILL.md |
OBLIGATOIRE : Avant d'exécuter n'importe quel flux de travail, lisez le document de la compétence secondaire correspondante.
Références partagées
- manifest-and-yaml.md — Fichiers de projet, configuration YAML, variables d'environnement, flux .localConfigs
- commands.md — Commandes CLI ATK : package, validate, share, collaborate
- templates.md — Catalogue complet des modèles avec prise en charge des langues
- experts/ — Plus de 100 fichiers d'expertise micro : SDK Teams, SDK Slack, pontage interplateformes, déploiement, modèles d'IA, sécurité, conversion de langues
- docs/ — Guides de comparaison des plateformes : interface utilisateur, messagerie, identité, infrastructure, lacunes fonctionnelles
Chaînes de flux de travail
Correspondance de l'intention de l'utilisateur avec le flux de travail valide le plus petit.
| Intention de l'utilisateur | Flux de travail (à lire dans l'ordre) |
|---|---|
| Créer une nouvelle application à partir de zéro | create-project → test-playground |
| Tester un projet existant localement | test-playground (recommandé) ou test-teams |
| Déployer sur Azure | provision-deploy |
| Corriger un bot défectueux | troubleshoot → re-test |
| Migration d'un bot Slack vers Teams | slack-to-teams |
OBLIGATOIRE : Avant d'exécuter n'importe quel flux de travail slack-to-teams, lisez d'abord slack-to-teams/SKILL.md. La compétence secondaire contient un système d'experts routés avec plus de 100 fichiers d'expertise micro pour le développement de bots interplateformes.
Résolution du contexte du projet ATK
Résolvez les valeurs de configuration uniquement lorsqu'elles sont manquantes. Si une valeur est déjà connue dans la session, réutilisez-la.
Étape 1 : Détecter le projet ATK
Si m365agentstoolkit*.yml existe dans le dossier actuel, traitez-le comme un projet ATK et analysez la configuration.
Étape 2 : Résoudre la configuration courante
Résolvez les variables référencées dans m365agentstoolkit*.yml. Variables courantes : AZURE_OPENAI_API_KEY AZURE_OPENAI_ENDPOINT AZURE_OPENAI_DEPLOYMENT_NAME
Étape 3 : Collecter les valeurs manquantes
Si les valeurs requises sont manquantes, demandez à l'utilisateur uniquement les valeurs manquantes.
Consultez manifest-and-yaml.md pour les détails complets du fichier de configuration.
---
name: teams-app-developer
description: Builds, tests, and deploys Microsoft 365 apps and agents for Teams and Copilot using the ATK CLI, with sub-skills for project creation, local testing, cloud deployment, troubleshooting, and Slack-to-Teams migration.
---
# Microsoft 365 Agents Toolkit Skill
Build Microsoft 365 agents and Teams apps using the ATK CLI.
## AI Behavior Guidelines
1. **Testing Strategy:** Recommend Agents Playground first (faster, no M365 needed). Use Teams workflow only if user explicitly requests it.
2. **Environment Variables:** NEVER hardcode secrets or make up placeholder values. Always ask users for real values.
3. **Error Handling:** Read error messages carefully. Check `env/.env.local`, `.localConfigs`, and `atk auth list`. Common pitfalls:
- **`AADSTS7000229`** → `aadApp/create` missing `generateServicePrincipal: true` in YAML — add it and re-provision
- **Missing `TENANT_ID`** in `.localConfigs` → SDK uses wrong token authority → 401 from Bot Connector
- **401 persists after auth fix** → devtunnel URL may be blacklisted — create a fresh tunnel
- See [troubleshoot/troubleshoot.md](troubleshoot/troubleshoot.md) for full diagnostic steps
4. **Long-Running Commands — WAIT for completion:**
- `atk new`, `atk provision`, `atk deploy` can take several minutes
- Always wait for completion before running the next step (timeout 120000ms+)
5. **Local Service Startup — Hangs terminal (expected):**
- `npm run dev`, `npm start`, `python app.py`, `devtunnel host`, etc. will hang — the process keeps running indefinitely
- ALWAYS run as a background process (`isBackground=true`) — NEVER use `isBackground=false` for these commands
- Do NOT wait for it to "finish" — verify startup by checking output for "listening on port" or tunnel URL
- If errors appear, read logs, diagnose, fix, restart
- Use a **NEW terminal** to launch Agents Playground or open Teams sideloading URL
6. **Monitor App Logs:** Periodically check background terminal output for runtime errors. If the app crashes, read the error, fix the root cause, and restart.
7. **Telemetry Tagging:** Before running any `atk` CLI commands, set the session environment variable so all CLI invocations are tagged as skill-initiated:
```bash
export ATK_CLI_SKILL=true
```
Run this once at the start of the session. All subsequent `atk` commands in the same terminal will inherit it.
## ATK CLI Setup
```bash
atk --version # Must be > 1.1.5-beta
```
If ATK is not found or version is too old:
```bash
npm i -g @microsoft/m365agentstoolkit-cli@beta
```
## CLI Global Options
| Option | Meaning | Recommendation |
| ------ | ---------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `-i` | Interactive mode | Always use `-i false` in automation to avoid hanging |
| `-f` | Project folder | Default to be current directory, used when specifying a custom folder. When scaffolding a new project, this is the parent folder where the project folder will be created under. |
| `-h` | Command help | Use `atk <command> -h` for quick syntax checks |
## Sub-Skills
| Sub-Skill | When to Use | Reference |
| -------------------- | -------------------------------------------------------------------------------- | ---------------------------------------------------------------------------- |
| **create-project** | Scaffold new project from template, choose template, `atk new` | [create-project/create-project.md](create-project/create-project.md) |
| **test-playground** | Test locally with Agents Playground, `agentsplayground`, quick testing | [test-playground/test-playground.md](test-playground/test-playground.md) |
| **test-teams** | Run on Teams, devtunnel, sideload, Teams testing, test in Copilot | [test-teams/test-teams.md](test-teams/test-teams.md) |
| **provision-deploy** | Provision Azure resources, deploy to cloud, `atk provision`, `atk deploy` | [provision-deploy/provision-deploy.md](provision-deploy/provision-deploy.md) |
| **troubleshoot** | Fix errors, 401, port conflicts, YAML errors, stale bots | [troubleshoot/troubleshoot.md](troubleshoot/troubleshoot.md) |
| **slack-to-teams** | Migrate Slack bot to Teams, cross-platform bridging, Block Kit to Adaptive Cards | [slack-to-teams/SKILL.md](slack-to-teams/SKILL.md) |
> **MANDATORY:** Before executing any workflow, read the corresponding sub-skill document.
## Shared References
- [manifest-and-yaml.md](toolkit/manifest-and-yaml.md) — Project files, YAML config, env vars, .localConfigs flow
- [commands.md](toolkit/commands.md) — ATK CLI commands: package, validate, share, collaborate
- [templates.md](toolkit/templates.md) — Complete template catalog with language support
- [experts/](experts/index.md) — 100+ micro-expert files: Teams SDK, Slack SDK, cross-platform bridging, deploy, AI models, security, language conversion
- [docs/](docs/README.md) — Platform comparison guides: UI, messaging, identity, infrastructure, feature gaps
## Workflow Chains
Match user intent to the smallest valid workflow.
| User Intent | Workflow (read in order) |
| ----------------------------- | ------------------------------------------- |
| Build new app from scratch | create-project → test-playground |
| Test existing project locally | test-playground (recommended) or test-teams |
| Deploy to Azure | provision-deploy |
| Fix broken bot | troubleshoot → re-test |
| Migrate Slack bot to Teams | slack-to-teams |
> **MANDATORY:** Before executing any slack-to-teams workflow, read [slack-to-teams/SKILL.md](slack-to-teams/SKILL.md) first. The sub-skill contains a routed expert system with 100+ micro-expert files for cross-platform bot development.
## ATK Project Context Resolution
Resolve config values only when missing. If a value is already known in the session, reuse it.
### Step 1: Detect ATK Project
If `m365agentstoolkit*.yml` exists in the current folder, treat it as an ATK project and parse configuration.
### Step 2: Resolve Common Configuration
Resolve variables referenced in `m365agentstoolkit*.yml`. Common variables:
AZURE_OPENAI_API_KEY
AZURE_OPENAI_ENDPOINT
AZURE_OPENAI_DEPLOYMENT_NAME
### Step 3: Collect Missing Values
If required values are missing, ask the user for only the missing ones.
Refer to [manifest-and-yaml.md](toolkit/manifest-and-yaml.md) for full config-file details.
Tous les fichiers
147 fichiersInstaller teams-app-developer
Téléchargez et extrayez les fichiers de compétences dans votre répertoire .claude/skills/.
Télécharger le ZIPClonez le dépôt et copiez les fichiers de compétence dans votre projet.
git clone https://github.com/microsoft/skills/tree/main/.github/plugins/microsoft-365-agents-toolkit/skills/teams-app-developer # Copy SKILL.md to your .claude/skills/ directory
Copier





Maison
