Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
  • 2 commits
  • 2 files changed
  • 0 commit comments
  • 2 contributors
Commits on Mar 22, 2013
@aaronpk aaronpk Adds 'names' listener to node bot with docs update
bd8f485
Commits on Apr 04, 2013
@wraithan Merge pull request #80 from aaronpk/names_listener
Adds 'names' listener to node bot with docs
e1db1ba
Showing with 32 additions and 0 deletions.
  1. +14 −0 bot.js
  2. +18 −0 docs/services_devel.rst
View
14 bot.js
@@ -119,6 +119,20 @@ zenircbot = {
zenircbot.pub.publish('in', JSON.stringify(msg));
});
+ bot.addListener('names', function(channel, nicks) {
+ console.log('Names: '+channel);
+ console.log(nicks);
+ var msg = {
+ version: 1,
+ type: 'names',
+ data: {
+ channel: channel,
+ nicks: nicks
+ }
+ };
+ zenircbot.pub.publish('in', JSON.stringify(msg));
+ });
+
bot.addListener('error', function(message) {
console.log(message);
});
View
18 docs/services_devel.rst
@@ -135,6 +135,24 @@ The possible ``in`` messages.
}
}
+.. js:data:: "names"
+
+ Sent whenever a list of names is received for a channel::
+
+ {
+ "version": 1,
+ "type": "names",
+ "data": {
+ "channel": "",
+ "nicks": {
+ "nick": "",
+ "op_nick": "@"
+ }
+ }
+ }
+
+ This can be triggered by sending a raw command of "NAMES #channel"
+
Out messages
~~~~~~~~~~~~

No commit comments for this range

Something went wrong with that request. Please try again.