Skip to content

bernkastel02/discord.htc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

discord.htc logo

npm version david

How to install

You will need node.js 4+ to run the library

NPM Install Command

npm install discord.htc

or saving to your package.json...

npm install --save discord.htc

Ping Example

const DHTC = require('discord.htc')
var bot = new DHTC('bot token')
var prefix = '!'

bot.on('botReady', () => {
  console.log('Ready!')
})

bot.on('createdMessage', (message) => {
  if (message.content.startsWith(`${prefix}ping`)) {
    bot.makeMessage(message.channel_id, 'pong')
  }
})

bot.connect()

Discord Server

https://discord.gg/hbKjYTu

NPM Package

https://www.npmjs.com/package/discord.htc

About

A JavaScript Handler made for Discord utilizing its API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published