Skip to content

BTTRLabs/Notify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Notify SDK

Notify SDK is a TypeScript library for sending notifications across multiple messaging services. Write your notifications once and deliver them anywhere. Built by BTTR Labs, it powers BTTR Pinger, handling millions of messages every month.

Install

Add the core package and the adapters you need:

bun add @bttr-stack/notify
bun add @bttr-stack/discord-adapter
bun add @bttr-stack/telegram-adapter
bun add @bttr-stack/slack-adapter

Usage

import { CardBuilder } from "@bttr-stack/notify";
import { convertToDiscordWebhook, sendDiscordWebhook } from "@bttr-stack/discord-adapter";

const message = new CardBuilder()
  .setTitle("Deploy")
  .setDescription("Production is live.")
  .build();

const body = convertToDiscordWebhook(message);
await sendDiscordWebhook(process.env.DISCORD_WEBHOOK_URL!, body);

More: examples/.

Packages

Package Role
@bttr-stack/notify Types, CardBuilder, utils.
@bttr-stack/discord-adapter convertToDiscordWebhook, sendDiscord (webhook, channel, or DM via REST).
@bttr-stack/telegram-adapter convertToTelegram, Bot API send.
@bttr-stack/slack-adapter convertToSlack, webhooks + chat.postMessage.

Each adapter has a README.md.

Contributing

CONTRIBUTING.md

License

Apache 2.0

About

Notify SDK is a TypeScript library for sending notifications across multiple messaging services. Write your notifications once and deliver them anywhere.

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors