Get the users of a slack community.
Install with npm:
$ npm install --save slack-users
var slackUsers = require('slack-users');
Get the slack users for the specified team.
Params
options {Object}: Options object used for getting users.options.team {String}: Name of slack team to get users from.optins.token {String}: Slack token to use when getting users.cb {Function}: Callback functions passing an error if one occurs or an array of users when successful.Example
var options = {
team: 'my-slack-team',
token: 'my-slack-token'
};
slackUsers(options, function(err, users) {
if (err) return console.error(err);
console.log(users);
//=> [
//=> {id: '', name: 'doowb', ...},
//=> {id: 'USLACKBOT', name: 'slackbot', ...}
//=> ]
});
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Please read the contributing guide for avice on opening issues, pull requests, and coding standards.
(This document was generated by verb-generate-readme (a verb generator), please don't edit the readme directly. Any changes to the readme must be made in .verb.md.)
To generate the readme and API documentation with verb:
$ npm install -g verb verb-generate-readme && verb
Install dev dependencies:
$ npm install -d && npm test
Brian Woodward
Copyright © 2016, Brian Woodward. Released under the MIT license.
This file was generated by verb-generate-readme, v0.1.30, on August 29, 2016.