β‘ Bun-First Runtime
Built from the ground up for Bun. Native WebSocket performance, lightning-fast startup times, and minimal memory footprint.
β‘ Bun-First Runtime
Built from the ground up for Bun. Native WebSocket performance, lightning-fast startup times, and minimal memory footprint.
π‘οΈ 100% Type-Safe
Complete TypeScript coverage with strict compile-time builders, Discord API v10 typing, and ergonomic autocomplete.
π Resilient Gateway
Automatic heartbeat ACK tracking, zombie connection detection, seamless session resume, and non-blocking reconnect cycles.
π― Bucket-Aware REST
Precise per-route Discord rate limit management with automatic retry backoff and non-leaking AbortSignal cancellations.
π§© Modular Architecture
Split into lightweight independent packages (@lunibee/ws, @lunibee/rest, @lunibee/builders, etc.) so you only load what you need.
β‘ Zero Bloat
No bloated legacy dependencies. Pure, modern ESM designed for speed, clarity, and rock-solid production bots.
import { Client, GatewayIntentBits, EmbedBuilder } from "lunibee";const client = new Client({ token: process.env.DISCORD_TOKEN!, intents: GatewayIntentBits.Guilds | GatewayIntentBits.GuildMessages | GatewayIntentBits.MessageContent,});client.on("ready", (user) => { console.log(`π Logged in as ${user.username}!`);});client.on("messageCreate", async (message) => { if (message.content === "!ping") { const embed = new EmbedBuilder() .setTitle("Pong! π") .setDescription("Lunibee is buzzing along smoothly.") .setColor(0xf59e0b) .setTimestamp(); await message.reply({ embeds: [embed] }); }});await client.login();You do not need to know Lunibeeβs internals before using it. Start with the task you want to accomplish, then follow the relevant guide.
Send a message
await channel.send({ content: "Hello! π" });Edit a message
await message.edit({ content: "Updated!" });Get the channel from a message
const channel = message.channel;Change a channel name
await channel.editName("support");Change a channel topic
await channel.editTopic("Support and help");Move a channel to another category
await channel.editParent(categoryId);The package pages below keep the same documentation structure, but each guide should answer the practical question first and then explain the underlying API.