npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@wump/framework

v0.0.3

Published

A clean and simple Discord bot framework

Downloads

245

Readme

@Wump/framework

A clean Discord bot framework that gets out of your way.

wump is a modern Discord bot framework built on top of Discord.js, designed to make bot development cleaner, faster and less verbose — with built-in command handling, guards, collectors, voice support and more.

npm downloads license typescript discord.js stars issues


Installation

npm install @wump/framework

Voice support requires an additional package:

npm install @discordjs/voice

Quick Start

import { Client, Intents } from '@wump/framework';

const client = new Client({
    intents: [Intents.Guilds, Intents.GuildMessages, Intents.MessageContent]
});

client.event.clientReady({ once: true, run: () => {
    console.log(`Logged in as ${client.user.tag}`);
}});

await client.connect('YOUR_TOKEN');

Commands

Slash Command

import { SlashCommand, CommandOptions } from '@wump/framework';

export default SlashCommand({
    name: 'ping',
    description: 'Replies with Pong!',
    execute: (interaction) => {
        interaction.reply('Pong!');
    }
});

Slash Command with Options

import { SlashCommand, CommandOptions } from '@wump/framework';

export default SlashCommand({
    name: 'say',
    description: 'Say something',
    options: {
        'text': { type: CommandOptions.String, description: 'Text to say', required: true },
        'user': { type: CommandOptions.User, description: 'User to mention', required: false },
    },
    execute: (interaction) => {
        const text = interaction.options.getString('text');
        interaction.reply(text!);
    }
});

Slash Command with Subcommands

import { SlashCommand, CommandOptions } from '@wump/framework';

export default SlashCommand({
    name: 'user',
    description: 'User commands',
    subcommands: {
        'info': {
            description: 'Get user info',
            options: {
                'user': { type: CommandOptions.User, description: 'User', required: true }
            },
            execute: (interaction) => {
                const user = interaction.options.getUser('user');
                interaction.reply(`User: ${user?.username}`);
            }
        },
        'search': {
            description: 'Search group',
            subcommands: {
                'guild': {
                    description: 'Search in guild',
                    options: {
                        'user': { type: CommandOptions.User, description: 'User', required: true }
                    },
                    execute: (interaction) => {
                        interaction.reply('Searching in guild...');
                    }
                }
            }
        }
    }
});

Prefix Command

import { PrefixCommand } from 'wump';

export default PrefixCommand({
    name: 'ping',
    aliases: ['p'],
    execute: (ctx) => {
        ctx.reply('Pong!');
    }
});

Events

Inline

client.event.messageCreate({ once: false, run: (message) => {
    console.log(message.content);
}});

// PascalCase alias (mirrors Discord.js)
client.event.MessageCreate({ once: false, run: (message) => {
    console.log(message.content);
}});

File-based

// events/ready.ts
import { Event, Events } from '@wump/framework';

export default Event({
    name: Events.ClientReady,
    once: true,
    execute: (client) => {
        console.log(`Logged in as ${client.user.tag}`);
    }
});

File-based Handlers

await client.settings.handlers({
    commands: ['./commands'],
    events: ['./events'],
});

Handlers are recursive — all .ts and .js files in subdirectories are loaded automatically.


Settings

// Prefix commands
client.settings.prefix({
    prefix: '!',
    caseInsensitive: true,
    mention: true, // also triggers on @bot ping
});

// Guild-specific slash commands (instant deploy)
client.settings.guild({
    enabled: true,
    guildId: 'YOUR_GUILD_ID',
});

Guards

import { SlashCommand, Guards } from 'wump';

export default SlashCommand({
    name: 'ban',
    description: 'Ban a user',
    guards: [Guards.InGuild, Guards.HaveAdmin],
    options: {
        'user': { type: CommandOptions.User, description: 'User to ban', required: true }
    },
    execute: (interaction) => {
        interaction.reply('Banned!');
    }
});

Available Guards

| Guard | Description | |---|---| | Guards.InGuild | Must be used in a server | | Guards.IsDM | Must be used in DMs | | Guards.IsNSFW | Must be in an NSFW channel | | Guards.InVoiceChannel | User must be in a voice channel | | Guards.HaveAdmin | User must be an administrator | | Guards.HavePermission(...perms) | User must have specific permissions | | Guards.BotHavePermission(...perms) | Bot must have specific permissions | | Guards.IsOwner(id) | Must be the specified user | | Guards.Cooldown(ms) | Cooldown per user in milliseconds |


Collectors

Collector (continuous)

ctx.channel.collector({
    type: 'message',
    filter: (m) => m.author.id === ctx.author.id,
    time: 30000,
    max: 10,
    collect: { once: false, run: (m) => {
        console.log(m.content);
    }},
    end: { run: (collected) => {
        console.log(`Collected ${collected.size} messages`);
    }}
});

Await (one-shot)

// await a message
const msg = await ctx.channel.awaitMessage({
    filter: (m) => m.author.id === ctx.author.id,
    time: 15000,
});

// await a reaction
const reaction = await ctx.message.awaitReaction({
    filter: (r) => r.emoji.name === '✅',
    time: 15000,
});

// await a component (button/select)
const component = await ctx.message.awaitComponent({
    filter: (i) => i.user.id === ctx.author.id,
    time: 15000,
});

// await a modal
const modal = await ctx.message.awaitModal({ time: 15000 });

Get

const user    = await client.get.user({ method: 'fetch', user: '123456789' });
const guild   = await client.get.guild({ method: 'cache', guild: '987654321' });
const channel = await client.get.channel({ method: 'fetch', channel: '111222333' });
const member  = await client.get.member({ method: 'cache', guild: '987654321', member: '123456789' });
const role    = await client.get.role({ method: 'cache', guild: '987654321', role: '444555666' });
const message = await client.get.message({ method: 'fetch', channel: '111222333', message: '777888999' });

Voice

import { VoiceManager } from '@wump/framework';

const connection = VoiceManager.join({
    channelId: 'CHANNEL_ID',
    guildId: 'GUILD_ID',
    adapterCreator: guild.voiceAdapterCreator,
});

await connection.waitUntilReady();

await connection.play({
    input: 'https://example.com/audio.mp3',
    volume: 0.5,
    onStart: () => console.log('Playing!'),
    onFinish: () => connection.disconnect(),
});

connection.pause();
connection.resume();
connection.stop();
connection.disconnect();

Sharding

import { ShardManager } from '@wump/framework';

const manager = new ShardManager({
    file: './dist/bot.js',
    token: 'YOUR_TOKEN',
    totalShards: 'auto',
});

manager.onShardCreate((shard) => {
    console.log(`Shard ${shard.id} created`);
});

await manager.spawn();

Components

wump re-exports all Discord.js builders:

import {
    EmbedBuilder,
    ButtonBuilder,
    ButtonStyle,
    ActionRowBuilder,
    StringSelectMenuBuilder,
    ModalBuilder,
    TextInputBuilder,
    TextInputStyle,
    // Components v2
    ContainerBuilder,
    SectionBuilder,
    TextDisplayBuilder,
    ThumbnailBuilder,
    MediaGalleryBuilder,
    SeparatorBuilder,
    SeparatorSpacingSize,
    // Utils
    Colors,
    MessageFlags,
} from '@wump/framework';

License

GPL-3.0 © ghostxbit

If you fork or modify wump, you must keep credits to the original author and license your work under GPL-3.0. See NOTICE.md for details.