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

ryuko

v0.2.0

Published

A full-featured Lavalink v4 music framework for Node.js with built-in queue, autoplay, filters, and plugin support

Readme

ryuko

A full-featured Lavalink v4 music framework for Node.js.
Built-in queue, autoplay, recommendations, filter presets, and a plugin system — all with zero unnecessary dependencies and clear, readable errors.


Features

  • Full Lavalink v4 support (WebSocket + REST)
  • Built-in queue with loop modes, shuffle, and history
  • Built-in autoplay and track recommendations
  • Filter presets — bassboost, nightcore, vaporwave, 8D, and more
  • Smart track resolver — URLs, search queries, and playlists in one call
  • Multi-node cluster support with automatic load balancing
  • Plugin system — extend the library without forking it
  • Structured logging with optional debug mode
  • Clear, readable errors — every error tells you what went wrong and how to fix it
  • Zero unnecessary dependencies — only ws and undici
  • CommonJS — works everywhere

Installation

npm install ryuko 

Requirements:

  • Node.js 18 or higher
  • A running Lavalink v4 server

Quick Start

const { Ryuko } = require("ryuko");

// 1. Create the client
const client = new Ryuko({
  nodes: [
    {
      id:       "main",
      host:     "localhost",
      port:     2333,
      password: "youshallnotpass",
    },
  ],
  sendGatewayPayload: (guildId, payload) => {
    // Send the payload to Discord using your gateway library
    // e.g. gateway.send(guildId, payload);
  },
  debug: false, // Set to true to enable verbose logging
});

// 2. Connect when your bot is ready
client.connect(botUserId);

// 3. Forward Discord voice events
gateway.on("VOICE_STATE_UPDATE",  data => client.handleVoiceUpdate(data));
gateway.on("VOICE_SERVER_UPDATE", data => client.handleVoiceUpdate(data));

// 4. Play music
const player = client.createPlayer(guildId);
player.connect(voiceChannelId, { deafened: true });

const { result } = await client.play(guildId, "never gonna give you up");
console.log(`Now playing: ${result.tracks[0].title}`);

Table of Contents


Client Setup

new Ryuko(options)

| Option | Type | Required | Description | |---|---|---|---| | nodes | NodeConfig[] | ✅ | Array of Lavalink node configs | | sendGatewayPayload | Function | ✅ | Function to send payloads to Discord gateway | | user | string \| object | ❌ | Bot user or ID (can also be passed to connect()) | | debug | boolean | ❌ | Enable verbose debug logging (default: false) | | plugins | Plugin[] | ❌ | Plugins to load on startup | | resolver | object | ❌ | TrackResolver options (see Resolver) |


Player

Create and control music players per guild.

// Create a player
const player = client.createPlayer(guildId);

// Connect to a voice channel
player.connect(channelId, { deafened: true });

// Play a track directly
const track = await client.resolver.resolveFirst("lofi beats");
await player.play(track);

// Or add to queue (auto-starts if idle)
await player.addToQueue(track);

Filters

Apply audio effects using built-in presets or custom filter objects.

const { Filters } = require("ryuko");

// Use a preset
await player.setFilters(Filters.bassboost());

Resolver

The built-in resolver handles URLs, search queries, and playlists automatically.

const { SearchSource } = require("ryuko");

// Auto-detects URLs vs search queries
const result = await client.resolver.resolve("[https://youtu.be/dQw4w9WgXcQ](https://youtu.be/dQw4w9WgXcQ)");

Autoplay

Enable autoplay on a player and Ryuko will automatically fetch and play a related track when the queue runs out.


Multi-Node Cluster

Ryuko extends Cluster and supports multiple Lavalink nodes out of the box.

const client = new Ryuko({
  nodes: [
    { id: "us-east",  host: "node1.example.com", port: 2333, password: "pass" },
  ],
  sendGatewayPayload: (guildId, payload) => gateway.send(guildId, payload),
});

License

MIT