Skip to content
This repository has been archived by the owner on Jan 13, 2023. It is now read-only.

A chat Bot that allows room creation and population via Active Directory, Email or CSV file.

License

Notifications You must be signed in to change notification settings

SymphonyPlatformSolutions/symphony-roomzilla-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Symphony Roomzilla Bot

A JavaScript bot to manage room creation and population using either:

  • Active Directory Group
  • CSV File
  • Email File (EML)

Pre-requisite

The below are pre-requisites for installation:

  • CentOS 7+
  • Node Package Manager (npm)

Installation

  $ [sudo] npm install

Usage

Create Symphony chat room using Active Directory

  • Create a new chat room populated with a group of users
/create RoomName /group AD_GroupName

Create Symphony chat room using a CSV file

  • Drag and drop a CSV file of users you would like to create the room with.
  • Type the Room Name you would like to use and hit return.

Create Symphony chat room using an EML file

  • Drag and drop an email with users you would like to create the room with.
  • Type the Room Name you would like to use and hit return.

Please ensure your CSV file is formatted correctly and ends with a .csv extension. Below is an example template you can copy:

emailAddress,memberType
[email protected],owner
[email protected],
[email protected],owner

Configuration

Before launching the bot you will need to configure the following files for your own environment.

Symphony Configuration

You will need to edit the below file so it includes API endpoint information for your own Pod environment.

  src/config/config.json

Update the following to match your environment,

{
    "sessionAuthHost": "podDomain.symphony.com",
    "sessionAuthPort": 443,
    "keyAuthHost": "podDomain.symphony.com",
    "keyAuthPort": 443,
    "podHost": "podDomain.symphony.com",
    "podPort": 443,
    "agentHost": "podDomain.symphony.com",
    "agentPort": 443,
    "authType": "rsa",
    "botCertPath": "",
    "botCertName": "",
    "botCertPassword": "",
    "botPrivateKeyPath": "rsa/",
    "botPrivateKeyName": "rsa-private-key.pem",
    "botUsername": "bot.username",
    "botEmailAddress": "[email protected]",
    "appCertPath": "",
    "appCertName": "",
    "appCertPassword": "",
    "proxyURL": "",
    "proxyUsername": "",
    "proxyPassword": "",
    "authTokenRefreshPeriod": "30"
}

Below is further information regarding each of the configuration values,

Value Description
keyAuthHost FQDN for your KeyManager Authentication Endpoint
sessionAuthHost FQDN for your Pod SessionAuthentication Endpoint
agentHost FQDN for your Agent Endpoint
podHost FQDN of your Symphony Pod
botPrivateKeyName File name for your RSA PrivateKey file
botPrivateKeyPath Location for RSA Private Key
botUsername Service Account Username for your Bot
botEmailAddress Email Address for your Bot Service Account

Active Directory Configuration

You will need to create an Active Directory user account with read access to your LDAP directory. This is so the bot can search for users and groups when creating rooms. Please edit the below configuration file so it has the correct credentials,

  src/api/ldapAPI.js

Update the following to match your environment,

  var ActiveDirectory = require('activedirectory');
  var config = {
      url: 'ldap://1.1.1.1',
      baseDN: 'cn=users,dc=testdomain,dc=net',
      username: 'Sync User',
      password: 'mypassword',
      attributes: {
          user: ['sAMAccountName', 'mail', 'displayName'],
      },
  }

Below is further information regarding each of the configuration values,

Value Description
url FQDN or IP to connect to your Active Directory Server
baseDN Directory base location for searching for users
username Name of the Active Directory account the bot will use
password Password for the Active Directory account the bot will use
attributes Active Directory fields that will be returned in searches

Starting and Stopping the Bot

To start the bot application you can use the following command,

  $ [sudo] npm start

To stop the bot application you use the following command,

  $ [sudo] npm stop

Message Templates

The following folder has the formatting and templates for response messages and reports for room creation. You can modify this according to your requirements.

  src/lib/template.js

Room Member Limits

A configuration setting has been included in the below file to allow the administrator to set the maximum members that are allowed when creating a room.

  src/api.js

The value you need to update is show here. Update this to your preferred room size limit,

  let maxlimit = 100 // Maximum room members

Release Notes

1.0.1

  • Updated LICENCE information to be Apache 2.0 compliant.
  • Updated Symphony Node SDK Client version to latest, 1.0.11
  • Updated package.json to include latest versions of package dependencies.

1.0.0

  • Initial Bot Release

About

A chat Bot that allows room creation and population via Active Directory, Email or CSV file.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •