ARCHIVE NOTICE:
We are in the process of archiving the Bot Framework SDK Samples repository on GitHub. This means that this project will no longer be updated or maintained. Customers using this tool will not be disrupted. However, the tool will no longer be supported through
service tickets in the Azure portal and will not receive product updates.
To build agents with your choice of AI services, orchestration, and knowledge, consider using the Microsoft 365 Agents SDK. The Agents SDK is GA and has support for C#, JavaScript or Python. You can learn more about the Agents SDK at aka.ms/agents. If you're looking for a SaaS-based agent platform, consider Microsoft Copilot Studio. If you have an existing bot built with the Bot Framework SDK, you can update your bot to the Agents SDK. You can review the core changes and updates at Bot Framework SDK to Agents SDK migration guidance here. Support tickets for the Bot Framework SDK will no longer be serviced as of December 31, 2025.
We plan to archive this project no later than end of December of 2025.
Overview
This branch contains samples for the released version of the Microsoft Bot Framework V4 SDK for .NET, JS and Python.
Getting the samples
To use the samples, clone this GitHub repository using Git.
git clone https://github.com/Microsoft/BotBuilder-Samples.git
cd BotBuilder-Samples
Sample lists
Samples are designed to illustrate functionality you'll need to implement to build great bots!
Bot essentials
| Sample Name | Description | .NET | JavaScript | Python |
|---|
| 2 | Echo bot | Demonstrates how to receive and send messages. | .NET Core | [JavaScript][js#2], [TypeScript][ts#2] | [Python][py#2] |
| 3 | Welcome user | Introduces activity types and provides a welcome message on conversation update activity. | .NET Core | [JavaScript][js#3], [TypeScript][ts#3] | [Python][py#3] |
| 5 | Multi turn prompts | Demonstrates how to use waterfall dialog, prompts, and component dialog to create a simple interaction that asks the user for name, age, and prints back that information. | .NET Core | [JavaScript][js#5], [TypeScript][ts#5] | [Python][py#5] |
| 6 | Using cards | Introduces all card types including thumbnail, audio, media etc. Builds on Welcoming user + multi-prompt bot by presenting a card with buttons in welcome message that route to appropriate dialog. | .NET Core | [JavaScript][js#6], [TypeScript][ts#6] | [Python][py#6] |
| 7 | Adaptive cards | Demonstrates how the multi-turn dialog can use a card to get user input for name and age. | .NET Core | [JavaScript][js#7] | [Python][py#7] |
| 8 | Suggested actions | Demonstrates how to enable your bot to present buttons that the user can tap to provide input. |
Advanced bots
| Sample Name | Description | .NET | JavaScript | Python |
|---|
| 1 | Console echo bot | Introduces the concept of adapter and demonstrates a simple echo bot on console adapter and how to send a reply and access the incoming message. | .NET Core | [JavaScript][js#1], [TypeScript][ts#1] | [Python][py#1] |
| 1 | Browser echo bot | Demonstrates how to host a bot in the browser using Web Chat and a custom Web Chat Adapter. | | [ECMAScript 6][es#1] | |
| 16 | Proactive messages | Demonstrates how to send proactive messages to users. | .NET Core | [JavaScript][js#16], [TypeScript][ts#16] | [Python][py#16] |
| 17 | Multilingual bot | Using translate middleware to support a multi-lingual bot. Demonstrates custom middleware. | .NET Core | [JavaScript][js#17] | [Python][py#17] |
| 19 | Custom dialogs | Demonstrates complex conversation flow using the Dialogs library. | [.NET Core][cs#19] | [JavaScript][js#19] | [Python][py#19] |
| 23 | Facebook events | Integrate and consume Facebook specific payloads, such as post-backs, quick replies and opt-in events. | [.NET Core][cs#23] | [JavaScript][js#23] | [Python][py#23] |
| 42 | Scale out | Demonstrates how you can build your own state solution from the ground up that supports scaled out deployment with ETag based optimistic locking. |
Authentication samples
| Sample Name | Description | .NET | JavaScript | Python |
|---|
| 18 | OAuth authentication | Bot that demonstrates how to integrate OAuth providers. | .NET Core | [JavaScript][js#18] | [Python][py#18] |
| 24 | MSGraph authentication | Demonstrates bot authentication capabilities of Azure Bot Service. Demonstrates utilizing the Microsoft Graph API to retrieve data about the user. | [.NET Core][cs#24] | [JavaScript][js#24] | [Python][py#24] |
| 46 | Teams authentication | Demonstrates how to use authentication for a bot running in Microsoft Teams. | .NET Core | JavaScript | Python |
| 84 | Certificate authentication | Demonstrates how to use Certificates to authenticate the bot | [.NET Core][cs#84] | [JavaScript][js#84] | |
| 85 | Subject name/issuer authentication | Demonstrates how to use the subject name/issuer authentication in a bot | [.NET Core][cs#85] | [JavaScript][js#85] | |
| 86 | Federated Credentials authentication | Demonstrates how to use the FIC in a bot authentication | [.NET Core][cs#86] | [JavaScript][js#86] |
Custom question answering samples
| Sample Name | Description | .NET | JavaScript | Python |
|---|
| 12 | Custom question answering (simple) | Demonstrates how to use Custom question answering to have simple single-turn conversations | .NET Core | [JavaScript][js#12] | |
| 48 | Custom question answering (advanced) | Demonstrates how to integrate Multiturn and Active learning in a Custom question answering bot | [.NET Core][cs#48] | [JavaScript][js#48] | |
Skills samples
| Sample Name | Description | .NET Core | JavaScript | Python |
|---|
| 80 | Skills - simple bot to bot | This sample shows how to connect a skill to a skill consumer. | [.NET Core][cs#80] | [JavaScript][js#80] | [Python][py#80] |
| 81 | Skills - skill dialog | This sample shows how to connect a skill to a skill dialog consumer. | [.NET Core][cs#81] | [JavaScript][js#81] | [Python][py#81] |
| 82 | Skills - SSO with CloudAdapter | This sample shows how to use SSO with skills and CloudAdapter. | [.NET Core][cs#82] | [JavaScript][js#82] | NA |
Experimental / preview samples
A collection of experimental samples exist, intended to provide samples for features currently in preview or as a way to solicit feedback on a given design, approach, or technology being considered by the Bot Framework Team.