Enforces rules in Gabe's discord server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
Geometer1729 7e6807c787
make count more interesting
3 years ago
..
docs Add thicc node modules 3 years ago
examples Add thicc node modules 3 years ago
lib Add thicc node modules 3 years ago
typings Add thicc node modules 3 years ago
.npmignore Add thicc node modules 3 years ago
LICENSE Add thicc node modules 3 years ago
README.md Add thicc node modules 3 years ago
example.js Add thicc node modules 3 years ago
fillsquare.png Add thicc node modules 3 years ago
logo-animated.svg Add thicc node modules 3 years ago
logo.ai Add thicc node modules 3 years ago
logo.svg Add thicc node modules 3 years ago
package.json Add thicc node modules 3 years ago

README.md

discord.io

A small, single-file, fully featured Discordapp library for Node.js and browsers.

Discord NPM

Requirements

Required:

  • Node.js 0.10.x or greater
  • Web Browser if not using Node.js

Optional:

  • Audio
    • Node.js 0.12.x
    • ffmpeg/avconv (needs to be added to PATH)

Documentation / Gitbooks

Getting Started:

Installing

Stable npm install discord.io

Latest npm install izy521/discord.io

Example

var Discord = require('discord.io');

var bot = new Discord.Client({
    token: "",
    autorun: true
});

bot.on('ready', function() {
    console.log('Logged in as %s - %s\n', bot.username, bot.id);
});

bot.on('message', function(user, userID, channelID, message, event) {
    if (message === "ping") {
        bot.sendMessage({
            to: channelID,
            message: "pong"
        });
    }
});