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

@arish_scholar/fenrir

v2.0.0

Published

Fenrir - A full-featured Discord bot using Components v2

Readme

Fenrir

A full-featured Discord bot built with Components v2 and MongoDB, designed for community engagement, productivity, and study workflows.


Table of Contents


Features

  • Suggestion System — Submit, vote, moderate, and auto-log suggestions with Components v2 cards
  • Feedback System — Star-rated community reviews with dedicated channels
  • Pomodoro Timer — Voice-gated study timers with pause/resume, group sessions, task tracking, and reward roles
  • AI Chat — Auto-reply AI in configured channels using Groq with conversation memory
  • No Prefix — Global no-prefix system with expiry, boost rewards, and role management
  • Interactive UI — All messages use Discord Components v2 (Containers, Sections, Text Displays, Separators, Buttons)
  • MongoDB Storage — All guild and global data persisted in MongoDB Atlas
  • Prefix + Slash — Every command supports both /slash and .prefix execution

Commands

All commands support both slash (/command) and prefix (.command) syntax.

Utility

| Command | Description | |---------|-------------| | /help | Browse all commands by category with an interactive menu | | /calculator | Open an interactive button-based calculator | | /pomodoro | Start, stop, pause, extend, or check your Pomodoro study timer | | /tasks | Add, list, complete, remove, or clear your study task list | | /guildprofile | Customize the bot's profile for this server (avatar, nickname, bio) |

Community

| Command | Description | |---------|-------------| | /suggest | Submit a suggestion to the configured channel | | /feedback | Submit a star-rated review to the feedback channel | | /say | Send a message as the bot to a specific channel (server owner only) |

Moderation

| Command | Description | |---------|-------------| | /moderate | Approve, deny, or mark a suggestion as under consideration | | /purge | Bulk delete messages from a channel with optional user filter | | /steal | Shortcut for /emoji steal — steal an emoji or sticker from a message |

Emoji Management

| Command | Description | |---------|-------------| | /emoji list | List all server emojis with pagination (.emoji list) | | /emoji info <emoji> | Get details about an emoji (ID, type, creation date) | | /emoji add <emoji_or_url> [name] | Add an emoji from a custom emoji or image URL | | /emoji remove <name_or_id> | Remove a server emoji (with confirmation) | | /emoji rename <emoji> <name> | Rename a server emoji | | /emoji enlarge <emoji> | Show a large version of an emoji with a direct link | | /emoji steal [emoji] [message_id] | Steal emojis/stickers/attachments from a message |

Admin

| Command | Permission | Description | |---------|------------|-------------| | /setsuggestions | Manage Server | Set the channel for suggestions (auto-applies 5h slowmode) | | /removesuggestions | Manage Server | Remove the configured suggestion channel | | /setfeedback | Manage Server | Set the channel for feedback reviews | | /removefeedback | Manage Server | Remove the configured feedback channel | | /setlogs | Manage Server | Set the channel for high-vote suggestion logs | | /votethreshold | Manage Server | Set how many upvotes trigger a log entry | | /threadconfig | Manage Server | Configure slowmode for suggestion discussion threads | | /setstudyvc | Manage Server | Set the required voice channel for Pomodoro sessions | | /setpomodororeward | Manage Server | Add or remove reward roles for completed Pomodoro sessions | | /ytverify setup | Manage Server | Set the YouTube channel (validated via API) | | /ytverify channel | Manage Server | Set the verification channel | | /ytverify role | Manage Server | Set the role to assign on verification | | /ytverify toggle | Manage Server | Enable or disable verification | | /ytverify reset | Manage Server | Reset all verification settings | | /ytverify config | Manage Server | Show current configuration | | /ytverify test | Manage Server | Test the verification setup | | /ytverify verify | Everyone | Start the verification process | | /np | Bot Dev | Manage the global no-prefix user list | | /npconfig | Bot Dev | Configure no-prefix reward guilds and log channels | | /servers | Bot Dev | List, leave, or get invite links for connected servers |

AI / System

| Command | Description | |---------|-------------| | /setchannel | Set the AI auto-reply channel (admin only) | | /ping | Check gateway latency, REST latency, and uptime | | /stats | View bot statistics, server count, and system info | | /clear | Clear your personal AI conversation history |

Pterodactyl

| Command | Permission | Description | |---------|-----------|-------------| | /ptero setup | Server Owner | Configure panel URL, API key, and server creator role | | /ptero config | Everyone | Show current panel configuration | | /ptero panel | Everyone | Check panel status and node health | | /ptero nodes | Manage Server | List all nodes with resource info | | /ptero eggs | Manage Server | List available eggs | | /ptero server create | Creator Role | Create a server (requires node + egg selection) | | /ptero server list | Everyone | List servers by user email | | /ptero server info | Everyone | Show detailed server information | | /ptero server delete | Manage Server | Delete a server | | /ptero server start/stop/restart | Everyone | Power actions on a server |


Setup

Prerequisites

  • Node.js 18 or higher (below 22)
  • MongoDB Atlas cluster (or self-hosted MongoDB)
  • Discord Bot application with a bot token

Installation

# Clone the repository
git clone <your-repo-url> fenrir
cd fenrir

# Install dependencies
npm install

# Create your environment file
cp .env.example .env

Edit .env with your values, then start the bot:

npm start

Environment Variables

| Variable | Required | Description | |----------|----------|-------------| | TOKEN | Yes | Your Discord bot token | | CLIENT_ID | Yes | Your Discord application/client ID | | MONGODB_URI | Yes | MongoDB connection string | | EMOJI_GUILD_ID | No | Server ID for hosting custom emojis | | GROQ_API_KEY_1 | No | Groq API key for AI chat features | | YOUTUBE_API_KEY | No | YouTube Data API v3 key for verification |

Example .env:

TOKEN=your_bot_token_here
CLIENT_ID=your_client_id_here
MONGODB_URI=mongodb+srv://user:[email protected]/fenrir
EMOJI_GUILD_ID=123456789
GROQ_API_KEY_1=gsk_your_key_here
YOUTUBE_API_KEY=AIza_your_key_here

Bot Permissions

When inviting the bot, ensure it has these permissions:

  • Send Messages
  • Read Message History
  • Manage Messages (for prefix command cleanup)
  • Create Public Threads
  • Send Messages in Threads
  • Embed Links
  • Use Application Commands
  • Manage Roles (for Pomodoro rewards)

How It Works

Suggestions

  1. An admin runs /setsuggestions #channel to configure the suggestion channel
  2. Users submit suggestions via /suggest text or by posting directly in the channel
  3. Each suggestion appears as a Components v2 card with upvote/downvote buttons
  4. A discussion thread is automatically created under each suggestion
  5. When upvotes cross the threshold (/votethreshold), the suggestion is forwarded to the logs channel
  6. Moderators can /moderate suggestions to approve, deny, or mark as considered 5-hour slowmode is applied automatically to prevent spam.

Feedback

  1. An admin runs /setfeedback #channel to configure the feedback channel
  2. A prompt card with a "Submit Your Review" button is posted
  3. Users submit reviews via /feedback rating text with a 1-5 star rating
  4. Reviews appear as styled cards with star ratings and author info

Pomodoro Timer

  1. An admin runs /setstudyvc to require a specific voice channel
  2. Users start timers with /pomodoro start 25 while in the study VC
  3. Leaving the VC automatically stops the timer
  4. Supports pause/resume, +5 min extension, group invites, and task assignment
  5. Reward roles are granted after configurable session thresholds (/setpomodororeward)

AI Chat

  1. An admin runs /setchannel #ai-channel to configure the AI channel
  2. Messages in that channel get AI responses via Groq (Llama 3.1 / Mixtral)
  3. Conversation history is maintained per-user (last 4 messages)
  4. Users can clear their history with /clear
  5. 5-second cooldown between messages per user

YouTube Verification

  1. An admin configures with /ytverify setup <url> (validates channel via YouTube Data API v3)
  2. Admin sets verification channel (/ytverify channel #verify) and reward role (/ytverify role @role)
  3. Admin enables with /ytverify toggle
  4. Users run /ytverify verify to get a unique 6-character code
  5. Users add the code to their YouTube channel About → Description
  6. Users click Verify Now, paste their YouTube URL
  7. Bot fetches the channel via YouTube API, checks if the description contains the code
  8. If code matches → role is assigned. Code expires after 5 minutes.

Pterodactyl Panel

  1. Server owner runs /ptero setup <panel_url> <api_key> @creator_role to configure
  2. Panel API key is stored per-guild in MongoDB (each server can have its own panel)
  3. Members with the creator role can create servers via /ptero server create
  4. Server creation requires selecting a node and egg, plus specifying RAM/CPU/disk
  5. Admins can list nodes, eggs, view all servers, delete, and manage power states
  6. Normal users cannot create servers — only members with the configured creator role

No Prefix System

  • Bot developers can grant users global no-prefix access via /np
  • Supports timed access (10 minutes to lifetime)
  • Auto-rewards boosters of partner servers with 60-day no-prefix
  • Expiry is checked every 10 minutes; expired users are automatically removed and notified

Project Structure

fenrir/
  index.js              # Entry point — loads events, connects MongoDB, starts bot
  package.json
  .env                  # Environment variables (not committed)
  .env.example          # Template for environment variables
  LICENSE               # Proprietary license
  README.md

  commands/             # Slash + prefix command handlers
    calculator.js
    clear.js
    emoji.js
    feedback.js
    guildprofile.js
    help.js
    moderate.js
    noprefix.js
    npconfig.js
    ping.js
    pomodoro.js
    purge.js
    removefeedback.js
    removesuggestions.js
    say.js
    servers.js
    setchannel.js
    setfeedback.js
    setlogs.js
    setpomodororeward.js
    setstudyvc.js
    setsuggestions.js
    stats.js
    steal.js
    suggest.js
    tasks.js
    threadconfig.js
    votethreshold.js
    ytverify.js

  events/               # Discord event handlers
    guildMemberUpdate.js    # Boost-based no-prefix grants/removals
    interactionCreate.js    # Slash commands, buttons, select menus
    messageCreate.js        # Auto-suggest, AI auto-reply, prefix commands
    ready.js                # Startup: register commands, restore timers
    voiceStateUpdate.js     # Stop Pomodoro when leaving study VC

  utils/                # Shared utilities
    ai.js                   # Groq AI chat with conversation memory
    calculator.js           # Calculator session state
    commandLogic.js         # Suggestion/vote/feedback core logic
    components.js           # All Components v2 builders
    constants.js            # Prefix and color constants
    db.js                   # MongoDB read/write interface
    emojis.js               # Custom emoji resolution with fallbacks
    loading.js              # Command loading card builders
    mongodb.js              # Mongoose schemas and connection
    noprefixLogic.js        # No-prefix grant/revoke/expiry logic
    pomodoro.js             # Pomodoro timer, tasks, rewards

Credits

Fenrir was created and developed entirely by arish_scholar.

All design, architecture, and implementation credit goes to arish_scholar.


License

This project is proprietary and closed-source.

Copyright (c) 2024-2026 arish_scholar. All rights reserved.

You may not sell, share, modify, or distribute this software or its source code in any form. Unauthorized use will result in legal action.

See LICENSE for full details.