Create Echo Bot with Bot Framework SDK C# .NET{Part 1}

Create AI Echo Chatbot with Azure Bot Framework
Bhargil Joshi
17-Jul-2020
Reading Time: 3 minutes

The bot framework enables you to build bots that support different types of interaction with users. Your bot can also have more guided interactions where it provides the users with choices or actions.

The conversation can use simple text strings or more complex rich cards that contain text, images, and action buttons. And, you can add natural language interactions, which let your users interact with your bots in a natural and expressive way.

NOTE: This is Part 1 of series of 5 articles, we will learn how to create a bot using Bot Framework using the C# template, and then testing it with the Bot Framework emulator.

Here is the Glimpse of Full Series of Creating Basic to Fully Functional Customize Chat Bot using Azure Bot Framework SDK.

  1. Part 1: Basic introduction about Bot Framework and create + deploy simple echo bot.
  2. Part 2: Welcome user and Prompt simple user interaction bot.
  3. Part 3: Multi-turn bot using card and action suggestion (take input and return with suggestion).
  4. Part 4: NLP and Language Understanding Bot.

Prerequisites:

  • Visual Studio 2019 or later
  • Bot Framework SDK v4 Template for C#
  • .NET Core 3.1
  • Bot Framework Emulator
  • Basic knowledge Asp.net Core and async programming language C# 

How to Create an Echo Bot using Bot Framework SDK? Step-by-step Guide

Step 1: Download and Install Visual Studio Template using this link

Step 2: Create a New Project using Echo Bot (.net Core 3.1 Bot Framework v4) Template.

create new project using echo bot

These templates contain all the code that’s necessary to create a bot for the quickstart.

Step 3: Start your project now, it will run the default port locally on 3978 looks like this.

EchoBotDemo Bot

Step 4: Download and Install Bot Emulator using this link.

Step 5: Start Emulator and follow these steps

  1. Start the Bot Framework Emulator
  2. Click Open Bot on the Emulator’s Welcome tab
  3. Enter Bot’s URL, which is the URL of the local port, with /api/messages added to the path, http://localhost:3978/api/messages
Bot Framework Emulator

Step 6: Hurreyyyy!!! Now your echo bot is ready, just type a message and the bot will echo of your message.

Create Echo Bot Output

That’s it for now. Stay Connected with us to learn more about Chat Bot Development.

If you’re looking for experienced Chatbot Developers or NET Developers, Contact us to discuss more.