Generated banner for Teams App Developer
Generated logo for Teams App Developer

Teams App Developer

MicrosoftOfficialPublished by Microsoft

  • Skill
  • Tool integration
  • Software development
  • MIT
  • Medium risk

From the author

Builds, tests, and deploys Microsoft 365 apps and agents for Teams and Copilot. Includes sub-skills for project creation, local testing, cloud deployment, troubleshooting, and Slack-to-Teams migration. USE FOR: Teams agent, bot, tab, message extension, Declarative Agents, Custom Engine Agents, local testing, Agents Playground, Azure resource provision, remote deployment, Slack to Teams migration, cross-platform bot development, Block Kit to Adaptive Cards conversion. DO NOT USE FOR: general web development, non-bot/non-Teams projects.
— the description by Microsoft

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

The teams-app-developer skill provides a structured framework for managing the lifecycle of Microsoft 365 agents and Teams applications. It leverages the ATK CLI to handle project scaffolding, local testing via the Agents Playground, cloud provisioning on Azure, and troubleshooting. The skill includes specialized guidance for migrating Slack bots to Teams, including converting Block Kit UI to Adaptive Cards, and provides access to an extensive library of micro-expert documentation for cross-platform development.

What it does

  • Scaffolds new Microsoft 365 agents and Teams applications from templates.
  • Facilitates local testing using the Agents Playground or Teams-specific environments.
  • Automates Azure resource provisioning and cloud deployment workflows.
  • Provides diagnostic procedures for common authentication and configuration errors.
  • Supports migration of Slack bots to the Teams platform.
  • Manages project configuration and environment variables for ATK-based projects.

When to use it

  • When starting a new Teams app, bot, or Declarative Agent project.
  • When you need to test an agent locally before deploying to the cloud.
  • When migrating existing Slack bots to the Microsoft Teams ecosystem.
  • When troubleshooting deployment or authentication issues in a Teams project.
  • When you need to provision Azure infrastructure for a Teams application.

Advantages

  • Streamlines the development lifecycle with standardized CLI commands.
  • Reduces development time by offering a local testing playground.
  • Provides expert-level guidance for complex cross-platform migrations.
  • Ensures consistent configuration management across development environments.
  • Includes robust error-handling protocols for common platform-specific pitfalls.

Usage examples

“Create a new Teams bot project using the default template.”
The agent will initialize a new project folder, configure the necessary YAML files, and guide you through the initial setup using the ATK CLI.
“How do I migrate my Slack bot to Microsoft Teams?”
The agent will initiate the slack-to-teams workflow, providing access to cross-platform bridging experts and guidance on converting UI components.
“My Teams bot is returning a 401 error, how do I fix it?”
The agent will trigger the troubleshooting workflow, checking your environment variables, tunnel status, and authentication configuration.

Install

  1. Download the skill as a ZIP:

    https://mp-staging.autogineer.com/agent-skills/microsoft/teams-app-developer/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip teams-app-developer.zip -d .agents/skills

Documentation by Microsoft

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 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:

    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

atk --version  # Must be > 1.1.5-beta

If ATK is not found or version is too old:

npm i -g @microsoft/m365agentstoolkit-cli@beta

CLI Global Options

OptionMeaningRecommendation
-iInteractive modeAlways use -i false in automation to avoid hanging
-fProject folderDefault 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.
-hCommand helpUse atk <command> -h for quick syntax checks

Sub-Skills

Sub-SkillWhen to UseReference
create-projectScaffold new project from template, choose template, atk newcreate-project/create-project.md
test-playgroundTest locally with Agents Playground, agentsplayground, quick testingtest-playground/test-playground.md
test-teamsRun on Teams, devtunnel, sideload, Teams testing, test in Copilottest-teams/test-teams.md
provision-deployProvision Azure resources, deploy to cloud, atk provision, atk deployprovision-deploy/provision-deploy.md
troubleshootFix errors, 401, port conflicts, YAML errors, stale botstroubleshoot/troubleshoot.md
slack-to-teamsMigrate Slack bot to Teams, cross-platform bridging, Block Kit to Adaptive Cardsslack-to-teams/SKILL.md

MANDATORY: Before executing any workflow, read the corresponding sub-skill document.

Shared References

  • manifest-and-yaml.md — Project files, YAML config, env vars, .localConfigs flow

  • commands.md — ATK CLI commands: package, validate, share, collaborate

  • templates.md — Complete template catalog with language support

  • experts/ — 100+ micro-expert files: Teams SDK, Slack SDK, cross-platform bridging, deploy, AI models, security, language conversion

  • docs/ — Platform comparison guides: UI, messaging, identity, infrastructure, feature gaps

Workflow Chains

Match user intent to the smallest valid workflow.

User IntentWorkflow (read in order)
Build new app from scratchcreate-project → test-playground
Test existing project locallytest-playground (recommended) or test-teams
Deploy to Azureprovision-deploy
Fix broken bottroubleshoot → re-test
Migrate Slack bot to Teamsslack-to-teams

MANDATORY: Before executing any slack-to-teams workflow, read 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 for full config-file details.

Files

experts/slack/cli.datastore-env.md

cli.datastore-env

purpose

Datastore CRUD operations (slack datastore), environment variable management (slack env), and external authentication provider configuration (slack external-auth) via the Slack CLI.

rules

  1. Datastores are typed key-value stores on Slack's platform. Defined in the app manifest with a schema (attributes + primary key). Data persists across deployments. No external database needed for simple use cases.

  2. slack datastore put writes a single record. Accepts --datastore <name> and --item with a JSON object matching the datastore schema. Overwrites the record if the primary key already exists.

  3. slack datastore get reads a single record. Requires --datastore <name> and --item with the primary key field. Returns the full record as JSON.

  4. slack datastore delete removes a single record. Requires --datastore <name> and --item with the primary key. The record is permanently removed.

  5. slack datastore query retrieves multiple records. Supports --expression for filter expressions, --expression-values for parameter binding, and --limit for result caps. Uses DynamoDB-style filter syntax.

  6. Bulk operations exist for batch work. slack datastore bulk-put, slack datastore bulk-get, slack datastore bulk-delete accept arrays of items. More efficient than looping single operations.

  7. slack datastore count returns the record count. Useful for monitoring data growth and verifying bulk operations completed.

  8. slack datastore update modifies specific fields. Updates individual attributes without replacing the entire record. Requires the primary key and the fields to update.

  9. slack env add sets an environment variable. Environment variables are encrypted secrets stored on Slack's platform. Access them in functions via env.get("VAR_NAME"). Use for API keys, tokens, and configuration.

  10. slack env list shows all environment variables. Displays variable names (not values) for the app. Values are encrypted and not retrievable via the CLI.

  11. slack env remove deletes an environment variable. The variable is permanently removed and no longer available to functions.

  12. slack external-auth configures OAuth2 providers. Set up external auth providers (Google, GitHub, etc.) that your app's functions can use to make authenticated API calls on behalf of users.

patterns

Pattern 1: Datastore definition in manifest
// datastores/users.ts — Deno datastore definition
import { DefineDatastore, Schema } from "deno-slack-sdk/mod.ts";

export const UsersDatastore = DefineDatastore({
  name: "users",
  primary_key: "user_id",
  attributes: {
    user_id: { type: Schema.slack.types.user_id },
    display_name: { type: Schema.types.string },
    score: { type: Schema.types.number },
    joined_at: { type: Schema.types.string },  // ISO 8601 timestamp
    active: { type: Schema.types.boolean },
  },
});

// Register in manifest.ts:
// datastores: [UsersDatastore],
// botScopes: ["datastore:read", "datastore:write"],
Pattern 2: Datastore CRUD via CLI
# Put (create/upsert) a single record
slack datastore put --datastore users \
  --item '{"user_id": "U0123", "display_name": "Alice", "score": 42, "active": true}'

# Get a single record by primary key
slack datastore get --datastore users \
  --item '{"user_id": "U0123"}'
# Output: { "user_id": "U0123", "display_name": "Alice", "score": 42, "active": true }

# Update specific fields
slack datastore update --datastore users \
  --item '{"user_id": "U0123", "score": 50}'

# Delete a record
slack datastore delete --datastore users \
  --item '{"user_id": "U0123"}'

# Query with filter expression
slack datastore query --datastore users \
  --expression "score > :min_score AND active = :is_active" \
  --expression-values '{ ":min_score": 10, ":is_active": true }' \
  --limit 20

# Count all records
slack datastore count --datastore users
# Output: 47

# Bulk put multiple records
slack datastore bulk-put --datastore users \
  --items '[
    {"user_id": "U001", "display_name": "Alice", "score": 42, "active": true},
    {"user_id": "U002", "display_name": "Bob", "score": 38, "active": true},
    {"user_id": "U003", "display_name": "Charlie", "score": 55, "active": false}
  ]'

# Bulk get multiple records
slack datastore bulk-get --datastore users \
  --items '[{"user_id": "U001"}, {"user_id": "U002"}]'

# Bulk delete
slack datastore bulk-delete --datastore users \
  --items '[{"user_id": "U001"}, {"user_id": "U002"}]'
Pattern 3: Environment variables
# Add an environment variable (encrypted on Slack's platform)
slack env add MY_API_KEY
# CLI prompts for the value interactively (not shown in terminal)

# Or provide value inline (less secure — appears in shell history)
slack env add MY_API_KEY --value "sk-abc123..."

# List all env vars (names only — values are encrypted)
slack env list
# Output:
#   MY_API_KEY
#   DATABASE_URL
#   WEBHOOK_SECRET

# Remove an env var
slack env remove MY_API_KEY

# Access in function code (Deno example):
# const apiKey = env.get("MY_API_KEY");
Pattern 4: External auth provider setup
# Add an external OAuth2 provider
slack external-auth add

# Interactive wizard prompts for:
#   Provider name: google
#   Client ID: your-client-id
#   Client Secret: your-client-secret
#   Authorization URL: https://accounts.google.com/o/oauth2/v2/auth
#   Token URL: https://oauth2.googleapis.com/token
#   Scopes: email profile

# List configured providers
slack external-auth list

# Remove a provider
slack external-auth remove --provider google

# Select a provider token for a user (used in trigger/workflow setup)
slack external-auth select-auth --provider google

pitfalls

  • Missing datastore:read / datastore:write scopes — Datastores won't work without these bot scopes in the manifest. Add them before deploying.

  • Query expression syntax errors — Filter expressions use DynamoDB-style syntax. Attribute names are bare, values use :placeholder binding. Test queries in dev before deploying.

  • Expecting SQL-like queries — Datastores support basic filter expressions, not JOINs, GROUP BY, or complex aggregations. For complex queries, fetch data and process in function code.

  • Bulk operations item limit — Bulk commands have limits on items per request. For very large datasets, batch in chunks.

  • Env var values not retrievable — slack env list only shows names. You cannot read back the stored value. Keep a local record of what you set.

  • Env vars scoped to deployment target — Dev app (slack run) and deployed app (slack deploy) may use different env var stores. Set vars for both if needed.

  • Setting env vars via --value flag — The value appears in shell history. Prefer the interactive prompt for secrets.

  • Confusing datastore put with update — put replaces the entire record. update modifies specific fields. Use update to change one attribute without resending the full object.

references

instructions

Do a web search for:

  • "Slack CLI datastore put get query bulk operations 2025"

  • "Slack CLI env add environment variables encrypted"

  • "Slack CLI external-auth OAuth2 provider configuration"

Pair with:

  • cli.manifest-triggers.md — datastores are declared in the manifest

  • cli.local-dev-deploy.md — env vars apply to deployed apps

  • cli.getting-started.md — project must be set up before using datastores

  • runtime.bolt-foundations-ts.md — accessing datastores and env vars in function code

research

Deep Research prompt:

"Write a micro expert on Slack CLI datastore and environment management. Cover datastore CRUD (put, get, delete, update, query, count), bulk operations (bulk-put, bulk-get, bulk-delete), query expression syntax (DynamoDB-style filters), datastore definition in manifest.ts (DefineDatastore, Schema types, primary_key), environment variables (env add/list/remove, encrypted storage, accessing in functions), external auth provider configuration (OAuth2 setup, provider management). Include canonical patterns for: datastore definition, full CRUD operations, query with filter expressions, env var workflow, external auth setup."

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Needs: Needs an API key, Needs Python, Needs Node.js

Security

What our scanner noticed· Medium risk

  • Possible data-exfiltration endpoints
  • Instructions that use the network
  • Downloads piped into a shell

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Published by
Microsoft
Publisher
Microsoft (Official)
Source
microsoft/skills · .github/plugins/microsoft-365-agents-toolkit/skills/teams-app-developer · commit 0696600
Licence
MIT License (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by Microsoft.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download teams-app-developer.zip