Skip to content
This repository was archived by the owner on Oct 21, 2024. It is now read-only.

Commit f8eb9fc

Browse files
Merge pull request #5 from artificialsolutions/update_dependencies
Update dependencies
2 parents 4ce33ab + b61208b commit f8eb9fc

File tree

3 files changed

+97
-79
lines changed

3 files changed

+97
-79
lines changed

README.md

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# tie-api-example-bot-framework
1+
# Microsft Bot Framework connector for Teneo
22
This node.js example connector allows you to make your Teneo bot available using the Microsoft Bot Framework, allowing you to target channels like Skype, Microsoft Teams and Cortana. The connector acts as middleware between the Microsoft Bot Framework and Teneo. This guide will take you through the steps of registering a new Microsoft bot app and deploying the connector and make it available via Skype.
33

44
## Prerequisites
@@ -9,22 +9,27 @@ The Microsoft Bot Framework requires that the connector is available via https.
99
Your bot needs to be published and you need to know the engine url.
1010

1111
## Setup instructions
12-
### Create an app in Microsoft's Application Registration Portal
13-
Before we can deploy our connector, we need an 'Application Id' and 'Application password' from Microsoft. To obtain those, we need to create an app in Microsoft's Application Registration Portal.
14-
1. Go to [https://apps.dev.microsoft.com/](https://apps.dev.microsoft.com/#/appList) and choose 'Add an app'
15-
2. Provide an 'Application Name' (for example, your bot's name) and click 'Create'
16-
3. Copy the 'Application Id' in the 'Properties' section, you will need it later.
17-
4. Under 'Application Secrets' click 'Generate new password'. Copy the password that is shown in the popup, you will need it later. Store it securely. This is the only time when it will be displayed.
12+
### Create an App Registration in Microsoft's Azure Portal
13+
Before we can deploy our connector, we need an 'Application Id' and 'Application password' from Microsoft. To obtain those, we need to create an 'App Registration' in Microsoft's Azure Portal.
14+
1. Go to [https://portal.azure.com/#home](https://portal.azure.com/#home) and in the search bar, find 'App Registrations' and select it from the list of suggested results.
15+
2. On the page that appears, choose 'New registration'
16+
3. Enter an 'Application Name' (for example, your bot's name)
17+
- give the app registration a name
18+
- in the Supported account types, select the 'Accounts in any organizational directory and personal Microsoft accounts (e.g. Skype, Xbox, Outlook.com)' radio button. If any of the other options are selected, bot creation will fail.
19+
- Next click the 'Register' button.
20+
4. An new page will be opened with the details of your app registration. Copy the 'Application (client) ID' and store it somewhere. You will need it in the next steps.
21+
5. Click on the 'Certificates & Secrets' menu section. Click the 'New Client Secret' button, leave the description empty and click the 'Add' button.
22+
6. Copy the generated secret, you will need it in the next step. Store it securely. This is the only time when it will be displayed.
1823

1924
### Deploy the bot connector
20-
Click the button below to deploy the connector to Heroku:
25+
We now have the details the connector needs to be able to run. Click the button below to deploy the connector to Heroku:
2126

2227
[![Deploy](https://www.herokucdn.com/deploy/button.svg?classes=noborder)](https://heroku.com/deploy?template=https://github.com/artificialsolutions/tie-api-example-ms-bot-framework)
2328

2429

2530
In the 'Config Vars' section, add the following:
26-
* **MICROSOFT_APP_ID:** The 'Application Id' you copied earlier.
27-
* **MICROSOFT_APP_PASSWORD:** The Application password you copied earlier.
31+
* **MICROSOFT_APP_ID:** The 'Application (Client) ID' you copied earlier.
32+
* **MICROSOFT_APP_PASSWORD:** The 'Client Secret' you copied earlier.
2833
* **TENEO_ENGINE_URL:** The engine url.
2934

3035
Click 'View app' and copy the url of your Heroku app, you will need it in the next step.
@@ -33,12 +38,13 @@ If you prefer to run your bot locally, see [Running the connector locally](#runn
3338

3439
### Register a bot with the Azure Bot Service
3540
To register your bot with the Azure Bot Service, you will need to create a new 'Bot Channels Registration'.
36-
1. Visit [https://portal.azure.com/#create/hub](https://portal.azure.com/#create/hub) and click 'Create'.
37-
2. Give the bot a name, this name will be available in Skype etc.
41+
1. Go back to [https://portal.azure.com/#home](https://portal.azure.com/#home) and in the search bar, find 'Bot Channels Registration' and select if from the suggested results (it will show up on the right, in the 'Marketplace' section).
42+
2. Give the bot a name, this is the name that will be available in Skype etc.
3843
3. Provide the details for the Subscription, Resource Group and Location.
3944
4. For 'Pricing Tier' you can choose the free 'F0 (10K Premium Messages)' during development.
4045
5. Enter the following URL in the Messaging Endpoint field: https://[yourherokuappname].herokuapp.com/api/messages (replace [yourherokuappname] with the name of your app on Heroku).
41-
6. Click on 'Auto create App ID and password' and in the 'blade' that appears click 'Create new' and in the next blade that appears enter your Application Id and Application Password and click 'Ok'.
46+
- If you are running the connector locally, use the ngrok url which will look something like https://6ed67af7.ngrok.io/api/message
47+
6. Click on 'Auto create App ID and password' and in the 'blade' that appears click 'Create new' and in the next blade that appears enter the 'Application (client) ID' and 'Client Secret' that you copied earlier and click 'Ok'.
4248
7. Click 'Create' in the first blade to create your bot. You will be notified when the bot is available.
4349

4450
That's it! You can now test your bot by opening your bot resource in the Azure portal and choosing 'Test in Web Chat'.
@@ -49,7 +55,7 @@ You can make your bot available on various channels by opening your bot resource
4955
For example, to make your bot available on Skype, follow these steps:
5056
1. Click on the featured 'Skype' channel. This will make your bot accessible from Skype.
5157
2. Go back to the 'Channels' list. Skype should now also be shown in the list of channels for your bot. Click on the link 'Skype'.
52-
3. A new page will open. Click the 'Add to Contacts' and follow the instructions to add your bot to your Skype contacts
58+
3. A new page will open. Click the 'Add to Contacts' and follow the instructions to add your bot to your Skype contacts.
5359

5460
## Adding media to messages
5561
To add [media or cards](https://docs.microsoft.com/en-us/azure/bot-service/bot-builder-howto-add-media-attachments?view=azure-bot-service-4.0&tabs=javascript), this connector looks for an output parameter `msbotframework` in the engine response. The value of that parameter is assumed to contain the media or card JSON as defined by Microsoft.

package-lock.json

Lines changed: 73 additions & 61 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@artificialsolutions/tie-api-example-ms-bot-framework",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"description": "Example connector for Teneo and Microsoft Bot Framework",
55
"author": "Lucas Willering",
66
"license": "Apache-2.0",
@@ -14,9 +14,9 @@
1414
"url": "https://github.com/artificialsolutions/tie-api-example-ms-bot-framework"
1515
},
1616
"dependencies": {
17-
"@artificialsolutions/tie-api-client": "^1.3.2",
17+
"@artificialsolutions/tie-api-client": "^1.3.3",
1818
"botbuilder": "~4.4.0",
19-
"restify": "^8.2.0",
20-
"node-fetch": "^2.6.0"
19+
"node-fetch": "^2.6.0",
20+
"restify": "^8.4.0"
2121
}
2222
}

0 commit comments

Comments
 (0)