discord-alert

1.1.0 • Public • Published

Discord Alert

A lightweight package to send message/notification with http request to discord server

Install

$ npm install discord-alert

or

$ yarn add discord-alert

Usage

import Notification from "discord-alert";

Notification("discord webhook url", "message");

Parameters

url your discord server webhook url
message what message you want to send each time a certain event is being triggered.

Example

There are various cases where you can use this package. I'm using it to send a notification each time a user submits a support message for my personal site.

Instead of receiving the notification through email which is quite convoluted (since you need an SMTP server, etc to make it work). I see discord webhook is much simpler and suit my need.

Author

Package Sidebar

Install

npm i discord-alert

Weekly Downloads

0

Version

1.1.0

License

ISC

Unpacked Size

2.15 kB

Total Files

3

Last publish

Collaborators

  • melvnl