New to channel setup? For a hands-on, step-by-step tutorial, check out our Channel Setup Tutorial. This page is a comprehensive reference covering all Microsoft Teams features and configuration options.

Microsoft Teams is a collaboration platform for enterprises. OpenClaw (formerly Moltbot, Clawdbot) integrates with Teams using the Microsoft Bot Framework, providing chat, channels, and enterprise-grade features.

Quick Setup

Setting up Microsoft Teams requires creating a bot in Azure Portal:

  1. Create a Teams app in Azure Portal
  2. Configure Bot Framework
  3. Get bot credentials
  4. Configure in OpenClaw
  5. Deploy to Teams

Creating a Teams Bot

Step 1: Azure Portal Setup

  1. Go to Azure Portal
  2. Create a new "Azure Bot" resource
  3. Choose "Multi Tenant" or "Single Tenant" based on your needs
  4. Configure Microsoft App ID and password
  5. Set messaging endpoint (your OpenClaw Gateway URL)

Step 2: Bot Framework Configuration

  1. In Azure Bot resource, go to "Channels"
  2. Add Microsoft Teams channel
  3. Configure Teams-specific settings
  4. Copy the Microsoft App ID and password

Step 3: Teams App Manifest

Create a Teams app manifest with your bot details. This manifest defines your bot's capabilities and appearance in Teams.

Configuration

Configure Microsoft Teams in your OpenClaw configuration file:

Microsoft Teams Configuration
{
  "msteams": {
    "appId": "your-microsoft-app-id",
    "appPassword": "your-microsoft-app-password",
    "allowFrom": ["user1@domain.com", "user2@domain.com"]
  }
}

Environment Variables

You can also use environment variables:

Environment Variables
export MSTEAMS_APP_ID="your-microsoft-app-id"
export MSTEAMS_APP_PASSWORD="your-microsoft-app-password"

Access Control

User Allowlist

Control who can interact with your bot:

User Allowlist
{
  "msteams": {
    "appId": "your-microsoft-app-id",
    "appPassword": "your-microsoft-app-password",
    "allowFrom": [
      "user@example.com",
      "admin@example.com"
    ]
  }
}

Group Access Control

Configure group chat access:

Group Configuration
{
  "msteams": {
    "appId": "your-microsoft-app-id",
    "appPassword": "your-microsoft-app-password",
    "groupAllowFrom": ["team1@example.com"],
    "groupPolicy": "open"
  }
}

Group Policies:

  • "open" - Bot responds to all group messages
  • "allowlist" - Only respond in groups listed in groupAllowFrom

Teams Features

OpenClaw supports various Teams features:

  • 1-on-1 Chats - Direct conversations with users
  • Team Channels - Participate in team channels
  • Group Chats - Multi-user conversations
  • Mentions - Respond when mentioned in channels
  • File Sharing - Send and receive files
  • Rich Cards - Interactive message cards

Deployment

Deploy to Teams

  1. Package your Teams app manifest
  2. Upload to Teams (via App Studio or directly)
  3. Install to your organization or specific teams
  4. Test bot functionality

Messaging Endpoint

Your OpenClaw Gateway must be accessible from the internet for Teams to send messages. Configure:

  • Public URL for your Gateway
  • HTTPS endpoint (required by Teams)
  • Valid SSL certificate

Security Best Practices

  • Secure Credentials - Never share your App ID and password
  • Use Allowlists - Always configure allowFrom to control access
  • HTTPS Required - Teams requires HTTPS for messaging endpoints
  • Regular Updates - Keep your Teams app and OpenClaw updated
  • Audit Logs - Monitor bot interactions for security

Troubleshooting

Bot Not Responding

If the bot doesn't respond:

  1. Verify App ID and password are correct
  2. Check messaging endpoint is accessible
  3. Ensure HTTPS is properly configured
  4. Check Gateway is running and receiving requests
  5. Review Azure Bot logs

Authentication Issues

If authentication fails:

  1. Verify App ID matches Azure Bot resource
  2. Check App Password is correct
  3. Ensure bot is registered in Teams
  4. Check OAuth configuration if using SSO

Group Access Issues

If group features don't work:

  1. Check groupPolicy configuration
  2. Verify groupAllowFrom includes correct team IDs
  3. Ensure bot is added to the team/channel
  4. Check bot permissions in Teams

Learn More