Microsoft Bot Framework

This article covers the steps on how to connect the Microsoft Bot Framework with the Infobip platform using WhatsApp and SMS as a communication channels. 

The Infobip adapter enables you to receive and send WhatsApp and SMS messages. Through the Infobip adapter, you can add an additional endpoint to your chatbot to receive WhatsApp messages.

Available Channels

The adapter currently supports the following scenarios listed below.

WhatsApp:

  • Send/receive text messages
  • Send/receive media messages (document, image, video, audio)
  • Send/receive location messages
  • Send message templates
  • Verify incoming Infobip requests
  • Receive delivery reports
  • Receive seen reports
  • Callback data – Add data in every message and that data will be returned to the chatbot in the message delivery report
  • Full incoming request from Infobip is added to the incoming activity as ChannelData

SMS:

  • Send/receive text messages
  • Verify incoming Infobip requests
  • Receive delivery reports
  • Callback data – Add data in every message and that data will be returned to the chatbot in the message delivery report
  • Full incoming request from Infobip is added to the incoming activity as ChannelData

Prerequisites

Before you proceed with the integration, refer to the following prerequisites:

Before you can connect the Azure Bot Service with the Infobip platform, first you have to adjust a few things on your Infobip account.

You need the following:

  • API key
  • Base URL
  • WhatsApp number
  • SMS number
  • WhatsApp scenario key (find the details in the README file within the adapter package)
  • SMS scenario key (find the details in the README file within the adapter package)

Once you have the API key and base URL, here are the things you need to provide to your dedicated Infobip Account Manager:

  • App Secret – Random generated string that will be used as a payload signature. Messages that come to your endpoint and do not have the signature will be rejected.
  • Bot URL – Infobip will forward all incoming WhatsApp messages on this endpoint. We will also complete the account configuration with the data provided.

API Key

Use the API key for request authentication and authorization. Use the same API key in both WhatsApp and SMS campaigns.

Here’s how to obtain the API key:

  1. Log in to the Infobip web interface and click MANAGE API KEYS.

Infobip web interface manage API keys

  1. To create a new API key, click NEW API KEY. Name your API key, set the expiration date, and select the PUBLIC API check box. The IP address is optional. Click SAVE.

Create API key - Microsoft Bot Framework integration

Base URL

To obtain your BASE URL, log in to the Infobip API Resource hub and copy your base URL. Here’s an example of how it looks like https://[baseURL].api.infobip.com/.

User Guide

Install the Infobip Microsoft Bot Infobip Adapter

Refer to the Bot Builder Community – Infobip Adapter with a detailed guide on how to install and set up the Infobip adapter NuGet package.

For more information on the WhatsApp as a communication channel, refer to our Documentation Hub.