Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var builder = require('botbuilder');
require('dotenv').config();
var botbuilder_azure = require('botbuilder-azure');
var lifx = require('lifx-http-api'),
lifxClient;
lifxClient = new lifx({
bearerToken: process.env['LifxApiKey']
});
var connector = new botbuilder_azure.BotServiceConnector({
appId: process.env['MicrosoftAppId'],
appPassword: process.env['MicrosoftAppPassword']
// openIdMetadata: process.env['BotOpenIdMetadata']
});
var bot = new builder.UniversalBot(connector, {
storage: new builder.MemoryBotStorage()
});
let luisModelUrl = `https://${process.env['LuisAPIHostName']}/luis/v2.0/apps/${
process.env['LuisAppId']
}?subscription-key=${process.env['LuisAPIKey']}`;
// Main dialog with LUIS
const recognizer = new builder.LuisRecognizer(luisModelUrl);
const intents = new builder.IntentDialog({ recognizers: [recognizer] })