webhooks-discord

> Send High Quality Embedded Webhooks To Your Discord Server


Install
npm install webhooks-discord@0.0.5

Documentation

Discord-Webhook

Send High Quality Embedded Webhooks To Your Discord Server

Usage

To Initialize

const Webhook = require("discord-webhook")
const Hook = new Webhook("WEBHOOK URL")

Info Format Webhook

Hook.Info("WEBHOOK NAME","Info")

Warn Format Webhook

Hook.Warn("WEBHOOK NAME", "Warning")

Error Format Webhook

Hook.Err("WEBHOOK NAME","Error")

Success Format Webhook

Hook.Success("WEBHOOK NAME","Success Webhook!")

Custom Format Webhook

Hook.Custom("WEBHOOK NAME","MESSAGE CONTENT","MESSAGE TITLE","MESSAGE COLOUR HEX (Optional)")

Custom Format Webhook With Image

Hook.Image("WEBHOOK NAME","MESSAGE CONTENT","MESSAGE TITLE", "IMAGE URL")

Announcement Format Webhook

Hook.Announcement("WEBHOOK NAME","Announcement Content")

Example Ready Event Discord.JS Handlers (Based On One File)

const Discord = require('discord.js')
const client = new Discord.Client(); // You Can Attatch Client Settings There
const Webhook = require('discord-webhook');
const Hook = new Webhook("WEBHOOK URL")

client.on('ready', () => 
console.log("[READY]", `Logged In As ${client.user.username}!`);
Hook.Info("Ready Event", `Logged In As ${client.user.username}!`);
}