Learn how to integrate Bolt.new AI with Microsoft Teams in 2025 with this clear step-by-step guide for seamless workflows.

Book a call with an Expert
Starting a new venture? Need to upgrade your web app? RapidDev builds application with your growth in mind.
The direct answer: You don’t “integrate Bolt.new AI into Microsoft Teams” directly. Bolt.new is a browser-based workspace, not a Teams app. The correct pattern is: you build a backend (inside bolt.new) that exposes a public HTTPS endpoint, register a Microsoft Teams bot in Azure Bot Framework, configure its messaging endpoint to point to your Bolt backend, handle Teams events via Microsoft Bot Framework REST schemas, and optionally wrap your Bolt-based logic behind a Teams message extension or slash-command–style bot. Teams talks to your server via standard Bot Framework webhooks; your server (running in bolt.new) talks back using the Bot Framework API.
Below is the clear, real, step‑by‑step explanation of how to make a Bot Framework–based Teams integration work using a backend built inside bolt.new.
Microsoft Teams does not connect directly to an AI workspace. It only talks to:
Bolt.new acts as your development sandbox where you host the backend code, usually an Express.js server, that receives Teams events and sends replies.
This is the cleanest, simplest, and fully real-world approach.
import express from "express";
import { BotFrameworkAdapter } from "botbuilder";
const app = express();
// Load secrets from environment variables
const adapter = new BotFrameworkAdapter({
appId: process.env.MICROSOFT_APP_ID, // Provided by Azure Bot registration
appPassword: process.env.MICROSOFT_APP_PASSWORD
});
// Basic bot logic
adapter.onTurn(async (context) => {
if (context.activity.type === "message") {
await context.sendActivity("Hello from Bolt.new backend! You said: " + context.activity.text);
}
});
// Teams will POST here
app.post("/api/messages", (req, res) => {
adapter.processActivity(req, res, async (context) => {
// Bot logic handled above
});
});
// Start server
app.listen(3000, () => {
console.log("Bolt.new bot server running on port 3000");
});
This code is fully valid and matches Microsoft Bot Framework SDK for Node.js.
Inside the if (context.activity.type === "message") block, call an LLM API such as OpenAI or Azure OpenAI. Example:
import OpenAI from "openai";
const client = new OpenAI({ apiKey: process.env.OPENAI_API_KEY });
// ...
if (context.activity.type === "message") {
const userText = context.activity.text;
const ai = await client.chat.completions.create({
model: "gpt-4o-mini",
messages: [{ role: "user", content: userText }]
});
await context.sendActivity(ai.choices[0].message.content);
}
This approach is exactly how production-grade Teams bots are built.
When it comes to serving you, we sweat the little things. That’s why our work makes a big impact.