Microsoft Teams SDK Adds HTTP Server Adapter for Existing AI Agents

✍️ OpenClawRadar📅 Published: April 23, 2026🔗 Source
Microsoft Teams SDK Adds HTTP Server Adapter for Existing AI Agents
Ad

The Microsoft Teams SDK now provides an HTTP server adapter that allows developers to connect existing AI agents to Microsoft Teams without modifying their core code. This approach lets agents built for other platforms like Slack or LangChain run in Teams with minimal changes.

The Pattern

The core pattern involves three steps using the Teams TypeScript SDK:

import { App as TeamsApp, ExpressAdapter } from '@microsoft/teams.apps';

const adapter = new ExpressAdapter(expressApp); // 1. wrap your server const teamsApp = new TeamsApp({ httpServerAdapter: adapter }); // 2. create the app

teamsApp.on('message', async ({ send, activity }) => { // 3. handle messages await send(/* your agent's response */); });

await teamsApp.initialize(); // registers POST /api/messages on your server

The SDK injects a POST /api/messages route into your existing Express app. This is the endpoint Teams uses to deliver messages to your bot. Your server remains unchanged otherwise; the SDK just adds that one endpoint.

Ad

Scenario 1: Slack Bot Integration

If you have a Slack bot built with Bolt, you can run both Slack and Teams bots on the same Express server. The Teams SDK mounts at /api/messages while Slack uses /slack/events, allowing shared agent logic (LLM calls, database lookups, business rules) to live in plain functions that both handlers call.

Scenario 2: LangChain Integration

For existing LangChain chains, you can create a bridge file that imports your chain and connects it to Teams. The Teams message handler can invoke your LangChain chain and return responses to Teams users.

The SDK handles verification of incoming requests to ensure they're legitimately from Teams before invoking your handler, and automatically routes messages to the correct event handlers.

📖 Read the full source: HN AI Agents

Ad

👀 See Also