exobot-exobot-plugin-permissions
Set permissions for chat commands. Create arbitrary role groups and wrap plugins in exobot configuration.
Usage
exobot role authorize admin <password>
exobot role add admins <username>
exobot role remove admins <username>
exobot role add coffeedrinkers <username>
exobot role remove coffeedrinkers <username>
Installation
npm install --save @exoplay/exobot/exobot-plugin-points
A Setup Example
import Exobot from '@exoplay/exobot';
import { Wrap, Permissions } from '@exoplay/exobot-plugin-permissions';
import { SomeOtherPlugin } from 'elsewhere';
const Bot = new Exobot(BOT_NAME, {
// ...
plugins: [
// Set up the permissions plugin with a password
new Permissions({
adminPassword: process.env.ADMIN_PASSWORD,
}),
// Wrap arbitrary plugins and pass in an array of roles with access
Wrap(SomeOtherPlugin, ['coffeedrinkers', 'testers']),
],
});
License
LGPL licensed. Copyright 2016 Exoplay, LLC. See LICENSE file for more details.